How to connect CleverPush with Adjust

This can be completed in a few simple steps.

 

1. Attribute Setup:

Create Adjust attributes in the CleverPush channel settings under
Segmentation -> Attributes

 

2. SDK Setup

We want to save the Adjust Attribution data into the CleverPush Attributes.

 

2.1 iOS SDK Setup

Please refer to the Adjust docs on how Attribution callbacks work on iOS:
https://github.com/adjust/ios_sdk#attribution-callback

- (void)adjustAttributionChanged:(ADJAttribution *)attribution {
  if (attribution.network != nil)
    [CleverPush setSubscriptionAttribute:@"adjust_network" value:attribution.network];
  if (attribution.campaign != nil)
    [CleverPush setSubscriptionAttribute:@"adjust_campaign" value:attribution.campaign]; 
  if (attribution.adgroup != nil)
    [CleverPush setSubscriptionAttribute:@"adjust_adgroup" value:attribution.adgroup];
  if (attribution.creative != nil)
    [CleverPush setSubscriptionAttribute:@"adjust_creative" value:attribution.creative]; 
}

 

2.2 Android SDK Setup

Please refer to the Adjust docs on how Attribution callbacks work on Android:

https://github.com/adjust/android_sdk#attribution-callback

AdjustConfig config = new AdjustConfig(this, appToken, environment);
config.setOnAttributionChangedListener(new OnAttributionChangedListener() {
    @Override
    public void onAttributionChanged(AdjustAttribution attribution) {
        if (attribution.network != null)
            CleverPush.getInstance(this).setSubscriptionAttribute("adjust_network", attribution.network);
        if (attribution.campaign != null)
            CleverPush.getInstance(this).setSubscriptionAttribute("adjust_campaign", attribution.campaign);
        if (attribution.adgroup != null) 
            CleverPush.getInstance(this).setSubscriptionAttribute("adjust_adgroup", attribution.adgroup);
        if (attribution.creative != null)
            CleverPush.getInstance(this).setSubscriptionAttribute("adjust_creative", attribution.creative);
    }
});

 

Finished! You can now use the Adjust attributes for segmenting users in CleverPush.

 

Start your free trial now

Non-binding test phase, ends automatically after 30 days