X (Twitter) Conversions API
Server-side event delivery to X's (Twitter's) Conversions API for enhanced ad attribution and privacy-compliant conversion tracking.
X Conversions API is a server destination in the walkerOS flow:
Sends conversion events server-side to X's Conversions API, bypassing browser limitations for improved data quality. Deduplicates with the browser-side X Pixel via `conversion_id`.
Installation
- Integrated
- Bundled
Configuration
This destination uses the standard destination config wrapper (consent, data, env, id, ...). For the shared fields see destination configuration. Package-specific fields live under config.settings and are listed below.
Settings
| Property | Type | Description | More |
|---|---|---|---|
pixelId | string | X Pixel ID used in the Conversions API endpoint URL | |
eventId | string | Default pre-registered conversion event ID | |
consumerKey | string | OAuth 1.0a API Key (Consumer Key) for X Ads API | |
consumerSecret | string | OAuth 1.0a API Key Secret (Consumer Secret) | |
accessToken | string | OAuth 1.0a User Access Token | |
accessTokenSecret | string | OAuth 1.0a User Access Token Secret | |
apiVersion | string | X Ads API version number | |
doNotHash | Array<string> | Array of user data fields that should not be hashed | |
url | string | Custom base URL for the X Conversions API endpoint | |
user_data | Record<string, string> | Mapping configuration for user identifiers |
Mapping
Per-event rules under config.mapping. For the standard rule fields (consent, condition, data, batch, name, policy) see mapping.
| Property | Type | Description | More |
|---|---|---|---|
eventId | string | Override the default conversion event ID for this event | |
value | string | number | Conversion monetary value (sent to X as a string) | |
currency | string | ISO 4217 currency code | |
number_items | integer | Number of items in the conversion | |
description | string | Free-text description of the conversion |
Examples
lead
purchase
purchase with twclid
User identification
The destination builds an identifiers array. Each identifier is a separate single-key object in the payload. At least one primary identifier is required. Events without one are silently skipped.
Primary identifiers:
hashed_email: resolved fromevent.user.emailor auser_data.emailmapping. The email is normalized (trimmed, lowercased) and SHA-256 hashed before sending. SetdoNotHash: ['email']if you are pre-hashing upstream.hashed_phone_number: resolved fromevent.user.phoneor auser_data.phonemapping. SHA-256 hashed. UsedoNotHash: ['phone']to skip.twclid: X click ID (pass-through, not hashed). Typically forwarded from the browser session:
Secondary identifiers (optional): ip_address, user_agent, pass-through.
Per-event overrides
The default eventId from settings applies to all events. Override it per event via mapping to route different events to different pre-registered conversion events:
Browser deduplication
When running both the browser-side X Pixel and this server destination, the walkerOS event id is sent as conversion_id on both sides. X deduplicates conversions that share the same conversion_id and conversion event, so only one conversion is counted.