Overview
Scope3’s Conversion API follows the IAB Tech Lab ECAPI v1.0 specification for server-to-server conversion measurement. This enables you to:- Send purchase, sign-up, and other conversion events
- Attribute conversions back to ad impressions and clicks
- Optimize campaigns based on actual outcomes
Prerequisites
Before sending conversion events, you’ll need two things:1. Get Your Dataset ID
Use thecustomer_dataset_get_id MCP tool to retrieve your dataset ID:
2. Get Your API Key
- Visit agentic.scope3.com/api-keys
- Sign up or log into your Scope3 account
- Generate a new API key (starts with
scope3_)
Endpoints
- Production
- Staging
Request Format
Minimal Example (Purchase with Click ID)
Full Example (with Identity Tokens)
Required Fields
| Field | Type | Description |
|---|---|---|
data_set_id | string | Your dataset ID (from customer_dataset_get_id tool) |
event_type | string | Event type (see supported types below) |
timestamp | integer | Unix epoch timestamp in seconds |
Optional Fields
| Field | Type | Description |
|---|---|---|
id | string | Unique event identifier (for deduplication) |
source | string | Event source (e.g., “website”, “app”, “pos”) |
value | number | Monetary value of the conversion |
currency | string | ISO 4217 currency code (e.g., “USD”, “EUR”) |
user_data | object | User identification data (see below) |
properties | object | Additional event properties |
Supported Event Types
Commerce Events
Commerce Events
| Event Type | Description |
|---|---|
purchase | User completes a purchase |
add_to_cart | User adds item to cart |
begin_checkout | User begins checkout |
add_payment_info | User adds payment info |
Lead Events
Lead Events
| Event Type | Description |
|---|---|
lead | Lead generated |
sign_up | User signs up |
complete_registration | User completes registration |
subscribe | User subscribes |
Engagement Events
Engagement Events
| Event Type | Description |
|---|---|
page_view | User views a page |
view_content | User views content |
Attribution Methods
Scope3 supports two attribution methods depending on your use case:| Method | Use Case | How It Works |
|---|---|---|
| Click Attribution | Online conversions (same session/device) | Pass the clkid from the landing page URL |
| Offline Attribution | Cross-device or offline conversions | Pass pre-resolved identity tokens (UIDs) |
Click Attribution (Online)
When a user clicks an ad served through Scope3, we append a uniqueclkid parameter to the landing page URL:
- Capture the
clkidfrom the URL when the user lands - Store it (cookie, session, or database)
- Include it as
user_data.click_idwhen sending conversion events
Offline Attribution (Cross-Device / Offline)
For conversions that happen on a different device or offline, use pre-resolved identity tokens. These allow Scope3 to match the conversion back to ad exposure even without a click ID. Use cases:- User sees ad on mobile, purchases on desktop
- User sees ad online, purchases in physical store
- CRM/offline sales data upload
Supported Identity Providers
| Provider | Source | atype | Description |
|---|---|---|---|
| LiveRamp | liveramp.com | 3 | RampID (person-based) |
| ID5 | id5-sync.com | 1 | ID5 ID (device-based) |
| atype | Meaning |
|---|---|
| 1 | Device ID |
| 3 | Person ID |
Response Format
Success (200 OK)
Error Responses
| Status | Error | Description |
|---|---|---|
| 400 | Invalid JSON payload | Malformed JSON |
| 400 | Validation error | Missing required fields |
| 401 | Unauthorized | Invalid or missing API key |
| 403 | Access denied to dataset | API key doesn’t have access to this dataset |
| 415 | Content-Type must be application/json | Wrong content type |
Code Examples
- cURL
- Python
- JavaScript
Best Practices
Always Capture Click ID
Always Capture Click ID
Store the
clkid parameter immediately when users land from ads. Use cookies, session storage, or your database to persist it until conversion.Send Events Server-Side
Send Events Server-Side
Never expose your API key in client-side code. Always send conversion events from your backend server.
Include Transaction ID
Include Transaction ID
Include a unique
id field for each event to help with deduplication. This prevents duplicate conversions from being counted.Use Accurate Timestamps
Use Accurate Timestamps
Send the actual event time, not the time you’re sending the request. This ensures accurate attribution windows.
Test in Staging First
Test in Staging First
Use the staging endpoint (
ping.staging.scope3.com) to validate your integration before sending events to production.