This article describes how to set up the Twitter Conversions connector.

In this article:

API Information

This connector uses the following vendor API:

  • API Name: Twitter Ads API
  • API Version: v11
  • API Endpoint: https://ads-api.twitter.com/
  • Rate limit: 60,000 events per account, per 15 minute interval

Prerequisites

  1. Twitter Ads API access
  2. Twitter Developer account
  3. Twitter user account with permissions to send events to desired ad accounts

If you already have an actively used Twitter Ads API application, both the application and existing access tokens may be used for the Conversion API. For more information, see Conversion API Set Up in the Twitter documentation.

How it Works

Use the Twitter Conversion API to create a separate server-side application that passes conversion events to Twitter for use in optimization, measurement, and attribution across your campaigns. With this API, you can measure the impact of running ads on Twitter by sending conversion events without the need for a Twitter website pixel.

Currently, there are two primary use cases for measuring ad impact using matching identifiers:

  • Click-through conversions for website traffic campaigns using the Twitter Click ID
  • View-through and click-through conversions for all Twitter campaigns using email

You can measure one or more of the following website actions with conversion tracking depending on your ad campaign:

  • Site visit: User visits a landing page on an advertiser’s site
  • Purchase: User completes a purchase of a product or service on the advertiser’s site
  • Download: User downloads a file, such as a white paper or software package, from the advertiser’s site
  • Sign up: User signs up for the advertiser’s service, newsletter, or email communication
  • Custom: This is a catch-all category for a custom action that does not fall into one of the categories above

Using the Twitter Conversion API

To use the Twitter Conversion API, you need to create a new conversion event in the Twitter Ads Manager or use an existing event already created and used with the Twitter Pixel. To deduplication conversions between Twitter Pixel and Twitter Conversion API requests, use the existing event you created for the Pixel.

Using an Existing Conversion Event in Ads Manager

To use an existing event used with the Twitter Pixel, use the Event ID from that event. If you use both Twitter Pixel and the Twitter Conversion API for the same event, ensure to use the deduplication key in both the Twitter Pixel code snippet and the Twitter Conversion API request (as conversion_id ). For more information about deduplication, see the Testing Events and Deduplication section in Conversion API Set Up in the Twitter documentation.

Identifiers for Conversion Events

For a conversion event to be passed in the Twitter Conversion API, there needs to be at least one Twitter Click ID ( twclid ) or email address set as the as the event identifier.

To successfully setup conversion events to be passed to the Twitter Conversion API, we recommend the following configurations:

  • Always parse the twclid value when it is present in the URL query parameters to be passed to Tealium EventStream API Hub.
  • Store the data alongside relevant form fields or conversion event information.

Deduplication

For Page View events, including Twitter-defined Site Visit and Landing Page View events, Twitter provides a 30 minute window for deduplication. Other event types, such as Purchase and Lead, are not deduplicated. 

Manage event duplication using the conversion_id event parameter, which can be included in Pixel or Twitter Conversion API requests.

Connector Actions

Action Name AudienceStream EventStream
Send Conversion Event

Configure Settings

Twitter Conversions requires allowlisting on your Twitter account. For assistance with allowlisting, contact your Twitter representative..

Navigate to the Connector Marketplace and add a new connector. For general instructions on how to add a connector, see the About Connectors article.

After adding the connector, configure the following settings:

  • Event Source ID
    The base-36 ID of a specific event, matching that of a pre-configured event contained within this ad account. This is called Website Tag ID in the Ads Manager, and Ads API and must be a Single Event Tag.
    This value can be created in the following ways:
    • Within the Single-Event Website tag configuration. Log in to your ads account at ads.twitter.com and select Events Manager under Tools.
    • Use the API. See Web Event Tags for more details.
    • Contact your Twitter account manager.
  • Ad Account ID
    Provide your Twitter ad account ID.
    Account ID appears in your account's URL when you are logged in. For example, if the URL is https://ads.twitter.com/accounts/1234abcd/, then the account ID is 1234abcd.

Click Done when you are finished configuring the connector.

Action Settings — Parameters and Options

Click Continue to configure the connector actions. Enter in a name for the action and then select the action type from the drop-down menu.

The following section describes how to set up parameters and options for each action.

Action — Send Conversion Event

Parameters

Parameter Description
Account ID Override (required) The leveraged account's ID. Required for all Advertiser API requests, excluding GET accounts. This account must be associated with the authenticated user.
Event Source ID Override (required) The base-36 ID of a specific event, matching that of a pre-configured event contained within this ad account. This is called Website Tag ID in the Ads Manager, and Ads API and must be a Single Event Tag.
Conversion Time (required) The conversion event's date and time, in ISO 8601 format. If not available, defaults to the time of the event.
Twitter Click ID (recommended) The Twitter Click ID, as parsed from the click-through URL. For example, 26l6412g5p4iyj65a2oic2ayg2.
Email Address (already SHA256 hashed, recommended) A hashed email address (SHA256) in lowercase format, and without trailing or leading spaces.
Email Address (apply SHA256 hash) An email address in lowercase format and without trailing or leading spaces.
Conversion Value When the conversion type is a purchase, the price of purchased items in the specified currency.
Number of Items When the conversion type is a purchase, the number of items being purchased. Must be a positive integer greater than zero.
Currency When the conversion type is a purchase, the currency in which to filter results by, in ISO-4217 format (for example, USD for US dollars).
Event Source URL The URI-encoded URL source of the conversion event. For example: https%3A%2F%2Fwww.twitter.com%2Fhome.



Public