Adjust real-time callbacks
Note that data generated by third-party data integration counts toward the cluster's data consumption
Summary
Interface overview
| Interface | Type | Granularity | Attribution | Cost | Revenue | Impressions | Clicks | Conversions |
|---|---|---|---|---|---|---|---|---|
| Real-time callbacks | Callback | User level | ✅ | ✅ | ✅ |
Adjust provides real-time callbacks for a range of events. Select the data types to send back in the Adjust dashboard and set the AE system's callback link as the callback URL to receive detailed user-level data.
Before you start connecting Adjust data, make sure that you have read the AE system's user identification rules and understand how AE identifies a user through #distinct_id and #account_id
Integration process
- Integrate the Adjust client SDK and the AE SDK, and set the AE user identification IDs in the Adjust SDK
- Log in to the AE backend, go to the Third-party Integration module, add an Adjust real-time callback plan, and complete the related configuration
- Log in to the Adjust dashboard and complete the callback configuration
- Check whether the AE system receives the data successfully, and build reports
1. Client SDK configuration
The first step in integrating Adjust data is to connect the AE SDK with the Adjust SDK on the client and set the AE system's user identification IDs in the Adjust SDK
1.1 Option 1 (automatic integration)
-
If you integrate the Android or iOS SDK:
- If the SDK version is 2.8.0~2.8.1, you can use this option directly
- If the SDK version is 2.8.2 or later, you also need to install the third-party data plugin. For details, see Android SDK third-party data and iOS SDK third-party data
-
If you integrate Unity SDK 2.4.0 or later, or Unreal SDK 1.5.0 or later, you can use this option directly
Note that AE SDK initialization and the code that enables automatic integration must run before the Adjust SDK is initialized. Follow these steps:
1. Initialize the AE SDK.
2. Call `enableThirdPartySharing` to set the distinct ID automatically.
3. Initialize the Adjust SDK.
The following are code samples for the SDK on each platform:
- Android
- iOS
- Unity
- Unreal
// 1. Initialize the Android SDK
TDConfig config = TDConfig.getInstance(this, APPID, TE_SERVER_URL);
TDAnalytics.init(config);
// 2. Call the enableThirdPartySharing API to set ta_distinct_id in Adjust events
TDAnalytics.enableThirdPartySharing(TDThirdPartyType.ADJUST);
// 3. Initialize the Adjust SDK
// ...
// 4. After registration or character creation, call login to set the account ID, then sync the data again (optional)
TDAnalytics.login("account_id");
TDAnalytics.enableThirdPartySharing(TDThirdPartyType.ADJUST);
// 1. Initialize the iOS SDK
TDConfig *config = [[TDConfig alloc] init];
config.appid = appid;
config.serverUrl = url;
[TDAnalytics startAnalyticsWithConfig:config];
// 2. Call the enableThirdPartySharing API to set ta_distinct_id in Adjust events
[TDAnalytics enableThirdPartySharing:TDThirdPartyTypeAdjust];
// 3. Initialize the Adjust SDK
// ...
// 4. After registration or character creation, call login to set the account ID, then sync the data again (optional)
[TDAnalytics login:@"account_id"];
[TDAnalytics enableThirdPartySharing:TDThirdPartyTypeAdjust];
// 1. Initialize the Unity SDK
TDConfig config = new TDConfig("APPID","SERVER");
TDAnalytics.Init(config);
// 2. Call enableThirdPartySharing to set ta_distinct_id in Adjust events
TDAnalytics.EnableThirdPartySharing(TDThirdPartyType.ADJUST);
// 3. Initialize the Adjust SDK
// ...
// 4. After registration or character creation, call login to set the account ID, then sync the data again (optional)
TDAnalytics.Login("account_id");
TDAnalytics.EnableThirdPartySharing(TDThirdPartyType.ADJUST);
// 1. Initialize the Unreal SDK
UTDAnalytics::Initialize();
// 2. Call enableThirdPartySharing to set ta_distinct_id in Adjust events
TArray<FString> EventTypeList;
EventTypeList.Emplace(TEXT("TAThirdPartyShareTypeADJUST"));
UTDAnalytics::EnableThirdPartySharing(EventTypeList, AppID);
// 3. Initialize the Adjust SDK
// ...
// 4. After registration or character creation, call login to set the account ID, then sync the data again (optional)
UTDAnalytics::Login("account_id", AppID);
TArray<FString> EventTypeList;
EventTypeList.Emplace(TEXT("TAThirdPartyShareTypeADJUST"));
UTDAnalytics::EnableThirdPartySharing(EventTypeList, AppID);
If you call the login() or identify() method of the AE SDK, call enableThirdPartySharing() again to sync the data.
This option works by automatically calling the addGlobalCallbackParameter() method of the Adjust SDK internally to pass in the distinct ID and account ID of the AE project.
1.2 Option 2 (manual integration)
With manual integration, you use the addGlobalCallbackParameter() API in the Adjust SDK to set the distinct ID and account ID of the AE project.
Note that AE SDK initialization and the addGlobalCallbackParameter call must run before the Adjust SDK is initialized. Follow these steps:
1. Initialize the AE SDK.
2. Call `addGlobalCallbackParameter` to set the distinct ID.
3. Initialize the Adjust SDK.
The following are manual integration code samples for the SDK on each platform:
- Android
- iOS
- Unity
- Unreal
// 1. Initialize the Android SDK
TDConfig config = TDConfig.getInstance(this, APPID, TE_SERVER_URL);
TDAnalytics.init(config);
// 2. Get the AE distinct ID, which corresponds to #distinct_id in AE
String distinctId = TDAnalytics.getDistinctId();
// 3. Set the distinct ID in events collected by Adjust
// For Adjust SDK versions earlier than V5, use the addSessionCallbackParameter API
//Adjust.addSessionCallbackParameter("ta_distinct_id", distinctId);
// For Adjust SDK V5 and later, use the addGlobalCallbackParameter API
Adjust.addGlobalCallbackParameter("ta_distinct_id", distinctId);
// 4. Initialize the Adjust SDK
// ...
// 5. After registration or character creation, call login to set the account ID, then sync the data again (optional)
String accountId = "ta_account_id";
TDAnalytics.login(accountId);
Adjust.addGlobalCallbackParameter("ta_account_id", accountId);
// 1. Initialize the iOS SDK
TDConfig *config = [[TDConfig alloc] init];
config.appid = appid;
config.serverUrl = url;
[TDAnalytics startAnalyticsWithConfig:config];
// 2. Get the AE distinct ID, which corresponds to #distinct_id in AE
NSString *distinctId = [TDAnalytics getDistinctId];
// 3. Set the distinct ID in events collected by Adjust
/*
For Adjust SDK versions earlier than V5, use the addSessionCallbackParameter API
[Adjust addSessionCallbackParameter:@"ta_distinct_id" value:distinctId];
*/
// For Adjust SDK V5 and later, use the addGlobalCallbackParameter API
[Adjust addGlobalCallbackParameter:distinctId forKey:@"ta_distinct_id"];
// 4. Initialize the Adjust SDK
// ...
// 5. After registration or character creation, call login to set the account ID, then sync the data again (optional)
NSString *accountId = @"ta_account_id";
[TDAnalytics login:accountId];
[Adjust addGlobalCallbackParameter:accountId forKey:@"ta_account_id"];
// 1. Initialize the Unity SDK
TDConfig config = new TDConfig("APPID","SERVER");
TDAnalytics.Init(config);
// 2. Get the AE distinct ID, which corresponds to #distinct_id in AE
var distinctId = TDAnalytics.GetDistinctId();
// 3. Set the distinct ID in events collected by Adjust
/**
For Adjust SDK versions earlier than V5, use the addSessionCallbackParameter API:
Adjust.addSessionCallbackParameter("ta_distinct_id", distinctId);
*/
// For Adjust SDK V5 and later, use the AddGlobalCallbackParameter API
Adjust.AddGlobalCallbackParameter("ta_distinct_id", distinctId);
// 4. Initialize the Adjust SDK
// ...
// 5. After registration or character creation, call login to set the account ID, then sync the data again (optional)
var accountId = "account_id";
TDAnalytics.Login(accountId);
Adjust.AddGlobalCallbackParameter("ta_account_id", accountId);
// 1. Initialize the Unreal SDK
UTDAnalytics::Initialize();
// 2. Get the AE distinct ID, which corresponds to #distinct_id in AE
FString distinctId = UTDAnalytics::GetDistinctId();
// 3. Set the distinct ID in events collected by Adjust
Adjust::AddSessionCallbackParameter(TEXT("ta_distinct_id"), distinctId);
// 4. Initialize the Adjust SDK
// ...
// 5. After registration or character creation, call login to set the account ID, then sync the data again (optional)
FString accountId = "account_id";
UTDAnalytics::Login(accountId);
Adjust::AddSessionCallbackParameter(TEXT("ta_account_id"), accountId);
2. Plan configuration
After completing the SDK configuration, log in to the AE backend and complete the Adjust configuration in the Third-party Integration module. The image below shows the Adjust configuration page:
2.1 User identification fields
Because Adjust sends back user-level data, you need to set user identification rules for it, that is, the fields in the callback data that correspond to #distinct_id and #account_id. Based on this configuration, the AE system sets these fields as the user identification fields of the data when it converts the callback data.
If you configured the client SDK as described in the previous step of this document, you can use the default values directly:
- Field associated with the account ID: ta_account_id
- Field associated with the distinct ID: ta_distinct_id
The AE system uses this configuration to identify users in the callback data, so that the user-level data sent back by Adjust can be associated with the corresponding users in the AE project.
The default rules are:
- Account ID: checks whether ta_account_id exists in the callback data. If it does, sets it as #account_id; if not, leaves it empty
- Distinct ID: checks whether ta_distinct_id exists in the callback data. If it does, sets it as #distinct_id; if not, leaves it empty
- If both the account ID and the distinct ID are empty, the record is treated as invalid data and discarded
2.2 Event Data Configuration
After you turn on the Event Data Configuration switch, all data sent back by Adjust is written to the event table. We recommend that you enable event data ingestion.
2.3 User Properties Configuration
By default, the AE system automatically writes the attribution fields in the Adjust callback data to standardized user properties. The following are the fields written to user properties and their meanings:
| Adjust field | User property name in AE | Description |
|---|---|---|
| network_name | te_ads_object.media_source | Channel |
| campaign_name | te_ads_object.campaign_name | Campaign |
| adgroup_name | te_ads_object.ad_group_name | Ad group |
| creative_name | te_ads_object.ad_name | Ad creative |
The default user property ingestion rules in earlier versions differ from the current ones, so be careful to distinguish them. To merge the old and new properties, you can use the custom property feature
To make changes, click Configure Rules to go to the ingestion rule configuration page, as shown below
Here, you can change which events user properties come from. If you do not want user properties to be written frequently, turn off Include all events and change the source event name to install. With this configuration, the AE system extracts the fields to be written to user properties only from the install events sent back by Adjust. The default Integration method is user_setOnce, which means only the first reported information is kept.
You can click the Property Mapping button to add fields to be written to user properties. You can also click the Rule button on the left to add a new set of rules. For example, you can extract ad revenue from the monetization data sent back by Adjust and write it to a user property with user_add to record each user's cumulative ad revenue.
To turn off user property ingestion, stop all rules:
2.4 End Point
2.4.1 Default configuration
If you have configured system-level and project-level data reporting URLs, the following link is displayed. You can copy the URL directly and paste it into the real-time callback configuration in the Adjust dashboard:
If no URL is displayed here, open Project Settings → Settings → Implementation from the menu in the upper right corner and configure the URL for public network. This URL is the data reporting URL configured in the AE SDK. After configuring it, go back to End Point on the Adjust real-time callback configuration page and copy the endpoint URL.
2.4.2 Custom macros
The Adjust callback URL contains a structure called a macro, written as {macro_name}. You can think of a macro as a placeholder: when the data sent back contains a field that corresponds to a macro, Adjust fills the field value in where the macro is. Taking {campaign_name} as an example, when Adjust sends back data, it fills in the value of campaign_name where the macro is in the callback URL. You can watch the Adjust callback demo video to learn what macros do.
The AE interface displays the callback URL, and we recommend that you copy it directly. Note that you need to replace the following in the URL:
- {receiver-host}: the data reporting URL, that is, the public network URL under Project Settings → Settings → Implementation in the AE backend
- {app-id}: the APP ID of the AE project
The data source URL in earlier versions differs from the current one, so be careful to distinguish them. We recommend that you use the new URL.
If you want to add other parameters, see this document
2.5 Event ingestion rules
-
The created_at_milli field in the data is used as the event's #event_time. If created_at_milli does not exist, the value of created_at is used as #event_time
-
The event names in the data are:
- Install: install
- Ad revenue: ad_revenue
- Other events: the event names in the Adjust dashboard
-
All other fields configured in the callback link are stored
2.6 Standardized fields
The following event properties are standardized:
| Original field | Standardized field | Description |
|---|---|---|
| network_name | te_ads_object.media_source | Media source |
| ad_mediation_platform | te_ads_object.media_source | Monetization channel |
| campaign_name | te_ads_object.campaign_name | Campaign name |
| google_ads_campaign_name | te_ads_object.campaign_name | Campaign name (Google Ads data only) |
| google_ads_campaign_id | te_ads_object.campaign_id | Campaign ID (Google Ads data only) |
| adgroup_name | te_ads_object.ad_group_name | Ad group name |
| google_ads_adgroup_name | te_ads_object.ad_group_name | Ad group name (Google Ads data only) |
| google_ads_adgroup_id | te_ads_object.ad_group_id | Ad group ID (Google Ads data only) |
| creative_name | te_ads_object.ad_name | Ad name |
| google_ads_creative_id | te_ads_object.ad_id | Ad ID (Google Ads data only) |
| ad_revenue_placement | te_ads_object.placement | Monetization ad placement |
| google_ads_placement | te_ads_object.placement | Ad placement (Google Ads data only) |
| cost_amount | te_ads_object.cost | Campaign cost |
| cost_currency | te_ads_object.currency | Currency of the user acquisition spend |
| revenue_usd | te_ads_object.revenue | Monetization revenue |
| Fixed value USD | te_ads_object.currency | Currency of the monetization revenue |
| country | te_ads_object.country | Country or region code |
| os_name | te_ads_object.platform | Platform, such as Android or iOS |
| app_id | te_ads_object.app_id | App ID |
| app_name | te_ads_object.app_name | App name |
3. Adjust real-time callback configuration
After completing the configuration in the AE backend, log in to the Adjust dashboard with an admin account. In the left menu, click AppView > All apps, find the app for which you want to configure callbacks, and click the Server callbacks button to go to the callback configuration page.
Then, on the callback configuration page, click the new callback button in the upper right corner and create a new callback with Classic Setup.
After evaluating all callback events, we recommend that you configure separate single-event callbacks for the install and ad revenue events. The following are the events we recommend sending back:
| Event | Event name (Trigger) |
|---|---|
| Install | install |
| Ad revenue (requires Adjust Growth Solution) | ad revenue |
We recommend that you use the following macros for callbacks of the install event (install)
https://{receiver-host}/attribution/callback/adjust/{app-id}?network_name={network_name}&campaign_name={campaign_name}&adgroup_name={adgroup_name}&creative_name={creative_name}&activity_kind={activity_kind}&created_at_milli={created_at_milli}&timezone={timezone}&event_name={event_name}&cost_amount={cost_amount}&cost_currency={cost_currency}&publisher_parameters={publisher_parameters}&app_id={app_id}&app_name={app_name}&country={country}&os_name={os_name}&app_version={app_version}
For the ad revenue event (ad revenue), we recommend the following macros
https://{receiver-host}/attribution/callback/adjust/{app-id}?network_name={network_name}&campaign_name={campaign_name}&adgroup_name={adgroup_name}&creative_name={creative_name}&activity_kind={activity_kind}&created_at_milli={created_at_milli}&timezone={timezone}&event_name={event_name}&cost_amount={cost_amount}&cost_currency={cost_currency}&publisher_parameters={publisher_parameters}&app_id={app_id}&app_name={app_name}&country={country}&os_name={os_name}¤cy={currency}&revenue={revenue_float}&placement={ad_revenue_placement}&ad_revenue_unit={ad_revenue_unit}&ad_revenue_network={ad_revenue_network}&app_version={app_version}
4. Next steps
4.1 Check data ingestion
You can check on the Management page whether the callback events have been stored:
- Install: install
- Ad revenue: ad_revenue
- Other events: the event names in the Adjust dashboard
4.2 Recommended reports
Here are a few suggestions for building reports:
- In the Events Analysis model, use Adjust callback data to build core metrics for ad campaigns and ad monetization, and create ad analysis reports
- In the Retention Analysis model, combine ad monetization from callback data with in-game payment events to calculate LTV including ad monetization at granularities such as media source and campaign
- In the Funnel Analysis model, add the install event to the new user conversion funnel, and analyze the conversion of users from different sources at granularities such as media source and campaign
5. Appendix
5.1 Fix for Facebook user attribution placeholders showing as Unattributed
Background
After Facebook deprecated AMM, user attribution placeholders from Facebook (such as {campaign_name}) all return Unattributed. To still get attribution information for users from Facebook on Android, you need to use new placeholders.
Solution steps: configuration on the Adjust side
- Install the Install Referrer plugin
First, make sure that your Android app integrates the following SDK component: https://help.adjust.com/zh/article/get-started-android-sdk?src=search_page#set-up-install-referrer
- Add the Decryption Key from Facebook to the Adjust Facebook module
Next, you can get the Decryption Key in your Facebook developer account (https://developers.facebook.com/) (Dashboard > Settings > Basic > Android (Google Play) Install Referrer Decryption Key). Each Decryption Key corresponds to a unique Facebook App ID. This value is the key to getting the app's data source. Add it to the Adjust dashboard (app settings of the Android app > Partner setup > Facebook)
- Use the new placeholders
The following are the new placeholders used in this solution to get app data. Adjust currently supports adding these placeholders to install activity callbacks and hopes to extend them to other activities in the future. For now, Adjust recommends that you map install and post-install event data with {adid} or another internal ID.
- {fb_install_referrer}: the full decoded Facebook install referrer value
- {fb_install_referrer_ad_id}: "ad_id" in the full Facebook install referrer value
- {fb_install_referrer_adgroup_id}: "adgroup_id" in the full Facebook install referrer value
- {fb_install_referrer_adgroup_name}: "adgroup_name" in the full Facebook install referrer value
- {fb_install_referrer_campaign_id}: "campaign_id" in the full Facebook install referrer value
- {fb_install_referrer_campaign_name}: "campaign_name" in the full Facebook install referrer value
- {fb_install_referrer_campaign_group_id}: "campaign_group_id" in the full Facebook install referrer value
- {fb_install_referrer_campaign_group_name}: "campaign_group_name" in the full Facebook install referrer value
- {fb_install_referrer_account_id}: "account_id" in the full Facebook install referrer value
- {fb_install_referrer_ad_objective_name}: "ad_objective_name" in the full Facebook install referrer value
Solution steps: configuration in the AE backend
Open the Adjust real-time callback plan. The main part affected is User Properties Configuration. If you want to set Facebook attribution fields as user properties, enter the macro names in the Source Property column and set the target property names:

