Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Conversion Rule API Schema
| Field Name | Type | Description | Example |
|---|---|---|---|
| account | URN | The Sponsored Ad Account URN for the account where this conversion rule is created. Refer Find Ad Accounts By Authenticated User API to select an ad account. |
urn:li:sponsoredAccount:12345 |
| name | string | A short name for this rule, which is shown in the UI and in reports. | Summer_Sale CRM Leads |
| conversionMethod | string | A method enum that specifies how a conversion event should be registered. For streaming conversions via API, the only supported value is CONVERSIONS_API. |
CONVERSIONS_API |
| enabled (optional) | boolean | Set to true or false to enable or disable this rule from matching conversions. The initial state can be either, but only rules that are enabled trigger the conversion events. Default is true. |
true |
| postClickAttributionWindowSize (optional) |
int | The conversion window timeframe (in days) during which conversions are attributed to a LinkedIn ad after a member clicks on it (post-click conversion). Default is 30. Allowed values are:
|
90 |
| viewThroughAttributionWindowSize (optional) |
int | The conversion window timeframe (in days) during which conversions are attributed to a LinkedIn ad after a member views it (view-through conversion). Default is 7. Allowed values are:
|
30 |
| attributionType (optional) | string | The model that describes how conversion actions are to be counted. Default is "LAST_TOUCH_BY_CAMPAIGN". Acceptable values are:
|
|
| type | string | Specifies the conversion type to track for this conversion rule, such as PURCHASE, LEAD, or SIGN_UP. Complete list is as follows:
Note: MARKETING_QUALIFIED_LEAD and SALES_QUALIFIED_LEAD conversion types are supported only for API versions 202608 and later. |
|
| valueType (optional) |
string (default= DYNAMIC) |
|
|
| ownershipType (optional) |
string (default= OWNED) |
|
| Request Parameter Name | Type | Description | Example |
|---|---|---|---|
| autoAssociationType (optional) | string | A type enum that defines how campaigns should be associated with the conversion rule. Acceptable values are: ALL_CAMPAIGNS and OBJECTIVE_BASED. If this parameter is not included, then no campaigns are automatically associated and additional actions are required to associate campaigns. Allowed values are:
|
autoAssociationType= ALL_CAMPAIGNS |
Streaming Conversion Events API Schema
| Field | Type | Description | Example |
|---|---|---|---|
| conversion | URN | URN of the conversion rule created. The format of your input should be urn:lla:llaPartnerConversion:ID, where you must replace ID with the respective conversion rule ID. You can parse the id field in response body or from the x-restli-id response header from Create a new Conversion Rule API or id of existing conversion rules from the Find Conversion Rules by Ad Account API. Alternatively, you can also find it from the conversion URL in LinkedIn Campaign Manager by selecting the conversion rule to edit, and extract id that immediately follows /conversions/ in the URL (/campaignmanager/accounts/{accountId}/conversions/{conversionId}). |
urn:lla:llaPartnerConversion:123 |
| conversionHappenedAt | long | Epoch timestamp in milliseconds at which the conversion event happened. Note: If your source records conversion timestamp in seconds, please insert 000 at the end to transform it to milliseconds. | 1590739275000 |
| conversionValue (optional) |
Object | The monetary value for this conversion. It contains “currencyCode” in ISO format (e.g. “USD”) and the “amount” value of the conversion in decimal string. (e.g. “100.05”). Advertisers can set conversion values dynamically here or set a fix value when creating conversion. | {"currencyCode": "USD", "amount": "50.0"} |
| eventId (optional) |
string | The unique id generated by advertisers to indicate each event. This field is optional and is used for deduplication. | ABCDppSv6KBwg |
| user | Object | Object containing userIds, userInfo, lead and externalIds attributes of the user who performed the conversion. See ConversionEventUser below. |
For more details about usage, refer to the Sample Request |
ConversionEventUser
The user attributes related to the user who performed the conversion event.
| Field | Type | Description |
|---|---|---|
| userIds | List (idType,idValue) | List of one or more identifiers to match the conversion user with objects containing idType and idValue. Currently supported idType are:
|
| userInfo (optional) | userInfo | Object containing additional fields in plain text for probabilistic user matching. Currently supported fields are:
|
| lead (optional) | LeadGenFormResponseUrn | The leadGenFormResponse is generated when users submit LinkedIn Lead-gen form and advertisers can download it from Campaign Manager UI or Lead Sync API. It is in format of urn:li:leadGenFormResponse:id. |
| externalIds (optional) | List (string) | A list of externalIds. An externalId contains an advertiser-provided identifier representing the user who triggered the conversion event. The maximum supported size of the list is 1 at the moment. If the list contains multiple values, only the first value is used. Advertisers must send the externalId together with regular standard identifiers (for example, userIds or userInfo) in order for it to be matched. Once matched, LinkedIn preserves the External ID to LinkedIn Member mapping for one year across ad accounts owned by the same Business Manager. Subsequent events can then include just the externalId, without needing to repeat the other standard identifiers, and the existing association will be used for matching. Refer to Custom Matching Identifiers for more details. |
idType
| Field | Type | Description |
|---|---|---|
| SHA256_EMAIL | string | The email address of the contact associated with the conversion event. It must be converted to lower case, without any whitespaces and then hashed in SHA256 format. The result should be a HEX-encoded string with a maximum length of 64 characters. |
| LINKEDIN_FIRST_PARTY_ADS_TRACKING_UUID | string | First party cookie or Click ID. Advertisers need to enable enhanced conversion tracking from Campaign Manager in order to activate first party cookies that appends a click ID parameter li_fat_id to the click URLs. Refer Enabling Click IDs for implementation details. |
| ACXIOM_ID | string | User identifier for matching with LiveRamp identity graph. |
| PLAINTEXT_IP_ADDRESS | string | IP address of the user in plain text format. Currently, only IPv4 addresses are supported. LinkedIn will generate the SHA256 hash with salt from your plain text address before matching. |
| SHA256_IP_ADDRESS | string | IP address of the user, hashed using SHA256. Currently, only IPv4 addresses are supported. The result should be a HEX-encoded string of exactly 64 characters. |
| GOOGLE_AID | string | User identifier for matching with Android devices. The Google Advertising ID (GAID or Android Ad ID) is a unique, user-resettable, and anonymous identifier for Android devices. |
userInfo
| Field | Type | Description | Example |
|---|---|---|---|
| firstName | string | The first name of the contact to match the conversion. | Mike |
| lastName | string | The last name of the contact to match the conversion. | Smith |
| companyName (optional) |
string | A plain text string representing the company of the contact to match. | Microsoft |
| title (optional) |
string | A plain text string representing the title of the contact to match. | Software Engineer |
| countryCode (optional) |
string | An ISO standardized two letter country code representing the country/region of the contact to match. | US |
Input Data Validation
An input request undergoes validation and fails if the following rules are not met:
- The
conversionURN must be valid with formaturn:lla:llaPartnerConversion:<id>. - The authenticated user must have a valid user access role (other than
VIEWERrole) on the ad account where the conversion rule is created. - The
userIdsfield in the input request must include at least one or more of the following unless other validuseridentifier is provided:- A valid userId with idType
SHA256_EMAIL. - A valid userId with idType
LINKEDIN_FIRST_PARTY_ADS_TRACKING_UUID. - A valid userId with idType
ACXIOM_ID. - A valid userId with idType
PLAINTEXT_IP_ADDRESS. - A valid userId with idType
SHA256_IP_ADDRESS. - A valid userId with idType
GOOGLE_AID.
- A valid userId with idType
- Including
userInfoin the input request can improve match rates. If included, it must contain bothfirstNameandlastName. - If you include
userInfoorexternalIdsorleadwithout any valididTypeinuserIds, you must use an empty list [] foruserIds. conversionHappenedAtmust be a valid timestamp representing the number of milliseconds since epoch time. The timestamp must be within the past 90 days.