adjust-icon

Batch.com SDK integration

You can integrate the Adjust SDK with Batch.com events by following one of the methods below.

Before you begin

To use this feature, you first need to download and set up the Adjust iOS SDK.

To integrate Adjust with the Batch.com SDK, you need to send attribution to the Batch.com SDK. You should send this information after receiving a response from the Adjust servers. To do this, follow the steps in the attribution callback setup guide.

Example

You can set the callback method like this:

- (void)adjustAttributionChanged:(ADJAttribution *)attribution {
// initiate Batch user editor to set new attributes
BatchUserDataEditor *editor = [BatchUser editor];
if (attribution.network != nil)
[editor setAttribute:attribution.network forKey:@"adjust_network"];
if (attribution.campaign != nil)
[editor setAttribute:attribution.campaign forKey:@"adjust_campaign"];
if (attribution.adgroup != nil)
[editor setAttribute:attribution.adgroup forKey:@"adjust_adgroup"];
if (attribution.creative != nil)
[editor setAttribute:attribution.creative forKey:@"adjust_creative"];
// send new attributes to Batch servers
[editor save];
}