Track user acquisition
Record acquisition data from mobile measurement partners to understand where your players come from.
Read time 4 minutesLast updated 19 hours ago
As users installing your game can come from multiple ad networks and campaigns, it is common to use a Mobile Measurement Partner (MMP) to identify which network and campaign a player installing the game comes from. This is called attribution: attributing an app install to a specific network and campaign. The most used MMPs are AppsFlyer, Adjust, Singular, Kochava, and Tenjin. You can track the data provided by MMPs on the client side such as (but not limited to): the ad network, the specific ad which brought the user to your game, and the cost to acquire this user. All of this data can be recorded in our
acquisitionSourceacquisitionSource
event
This event should be populated with the information available from the attribution provider's SDK. Ensure you also follow any guidance on tracking installs that is found on any MMP's own documentation.
The table below explains the attribution event parameters.
acquisitionSourceParameter | Description | Data type | Required |
|---|---|---|---|
| The name of the specific marketing provider used to drive traffic to the game. We recommend using the acquisition network name as this will be the name displayed when filtering or grouping by an acquisition channel. For a deeper analysis, use the network and campaign names. This will populate the "Acquisition Channel" dimension, which is found in many filters and group by options across the Analytics tools. | | Yes |
| The ID of the acquisition campaign. | | Yes |
| The acquisition campaign creative ID. | | Yes |
| The cost of the install e.g. 2.36. | | No |
| The ISO 4217 three-letter currency code for the install cost currency, e.g. GBP or USD. | | No |
| The acquisition campaign name e.g. Interstitial:Halloween21. | | Yes |
| The acquisition campaign network e.g. Ironsource, Facebook Ads. | | No |
| The name of the attribution provider in use e.g. Adjust, AppsFlyer, Singular. | | Yes |
| The acquisition campaign type. e.g. CPI. | | No |
Implement with the SDK
The SDK provides theAcquisitionSourceEventvar acquisitionSource = new AcquisitionSourceEvent(){ AcquisitionChannel = "Unity", AcquisitionCampaignId = "gwOfhjSjyiNfGdGlUjLK", AcquisitionCreativeId = "creative_name", AcquisitionCampaignName = "Game Name OS Country", AcquisitionProvider = "AppsFlyer", AcquisitionCampaignType = "CPI", AcquisitionCost = 12, AcquisitionCostCurrency = "EUR", AcquisitionNetwork = "Unity",};AnalyticsService.Instance.Record(acquisitionSource);
Implement with the REST API
TheacquisitionSource{ "eventTimestamp": {{eventDate}}, "eventVersion": 1, "userID": {{userId}}, "eventName": "acquisitionSource", "eventUUID": {{eventUUID}}, "eventParams": { "clientVersion":"0.1", "platform":"Android", "userCountry":"DK", "acquisitionChannel":"Unity", "acquisitionCampaignId":"gwOfhjSjyiNfGdGlUjLK", "acquisitionCampaignType":"CPI", "acquisitionCampaignName":"Game Name OS Country", "acquisitionCreativeId":"creative_name", "acquisitionCost":"12", "acquisitionCostCurrency":"EUR", "acquisitionNetwork":"Unity", "acquisitionProvider":"AppsFlyer" }}
Populating the fields from different SDKs
Adjust SDK integration guide
You can register a callback to get notified each time the Adjust SDK updates the conversion value for the user and sends the data to Analytics using the values from attribution variables following the mapping example below. For more details about Adjust SDK integration, refer to https://github.com/adjust/unity_sdk#attribution-callback.Parameter | Value from Adjust SDK (AdjustAttribution attribution) | Required |
|---|---|---|
| Depends on the use case. We recommend using the acquisition network name by default, | Yes |
| | Yes |
| | Yes |
| | Yes |
| | No |
| | Yes |
| | No |
| | Yes |
| | No |
Appsflyer SDK integration guide
Appsflyer SDK provides functionality to access real-time user attribution data for each install. See details about integration here about how to register a callback. You can register a callback to get notified each time the Appsflyer SDK updates the conversion value for the user and sends the data to Analytics using the values from attribution payload following the mapping example below. For more details about Appsflyer Payload, see here. The following fields are recommended guidelines and not exhaustive:Parameter | Appsflyer Conversion Data Payload Fields | Required |
|---|---|---|
| Depends on the use case. We recommend using the acquisition network name by default, | Yes |
| | Yes |
| | Yes |
| | Yes |
| Check with provider | No |
| | Yes |
| | No |
| | Yes |
| Check with provider | No |