Adjust
AIRSHIP MAINTAINED INTEGRATION
This integration is maintained by Airship. Please contact Airship for support.Adjust provides mobile measurement capabilities, helping you learn about your audience. This integration helps you take advantage of your audience data from Adjust in Airship, either to segment your audience or to trigger automated messages.
- Set attributes on your Airship audience, using information from Adjust to personalize messages and refine your audience. You must set up attributes in Airship to receive this information before you can set attributes from Adjust.
- Send custom events from Adjust into Airship, utilizing your audience information from Adjust to personalize and trigger automations and journeysA series of messages that is initiated by a trigger. Airship sends messages in the series based on your timing settings, and you can also set conditions that determine its continuation. Journeys can be connected to other journeys and to in-app experiences to create continuous user experiences. .
To set up this integration, you must:
- Associate
channel_id
values with Adjust’sairship_channel_id
callback parameter. - Provide a token to Adjust.
- Create Attributes in Airship to receive audience data set by Adjust.
SDK Setup
To use the Adjust integration, you must add Adjust dependencies and associate Airship Channel IDs with Adjust’s airship_channel_id
callback parameter.
Android Setup
For more information, see the Adjust Android SDK Docs
- Add dependencies to
build.gradle
implementation 'com.adjust.sdk:adjust-android:4.22.0' implementation 'com.android.installreferrer:installreferrer:1.1.2'
- Associate channel IDs with Adjust
airship_channel_id
String channelId = UAirship.shared().getChannel().getId(); Adjust.addSessionPartnerParameter("airship_channel_id", channelId);
iOS Setup
For iOS, you must add the Adjust dependency to your Podfile
and then associate channel IDs with Adjust’s airship_channel_id
callback parameter. For more information, see the Adjust iOS SDK Docs.
Podfile
- If this is your first time using CocoaPods, Install CocoaPods using
gem install cocoapods
. Otherwise, continue to Step 3. - Run
pod setup
to create a local CocoaPods spec mirror. - Create a
Podfile
in your Xcode project directory by runningpod init
in your terminal, edit thePodfile
generated and add the dependencypod 'Adjust', '~> 4.22.1'
. - Run
pod install
in your Xcode project directory. CocoaPods should download and install the added library, and create a new Xcode workspace. Open up this workspace in Xcode or typingopen *.xcworkspace
in your terminal.
airship_channel_id
let channelId = UAirship.channel()?.identifier
if (channelId != nil) {
Adjust.addSessionPartnerParameter("airship_channel_id", value: channelId!)
}
airship_channel_id
NSString *channelId = [UAirship channel].identifier;
[Adjust addSessionPartnerParameter:@"airship_channel_id" value:channelId];
Adjust Setup
You’ll generate a token in Airship and provide the token to Adjust to enable this integration. After you set up the integration in Airship, you’ll need to determine the events and parameters that you want to send from Adjust to Airship.
To turn on Adjust’s integration with Airship:
In Airship, generate a Token with the All Access role. You’ll provide your token and app key to Adjust to enable this integration.
- Go to Settings » Project Configuration and click Manage for Tokens.
- Click Create Token.
- Enter a token Name. This is just a friendly name to help you recognize your tokens in Airship.
- Select the Role you want to grant for this token. For additional information, see Airship API Security.
- Audience Modification: Grants read and write permission to audience APIs, including channels, named users, segments, lists, etc. Use this permission for users sending custom events into Airship.
- All Access: Grants full access to your Airship project, except Acoustic integrations. You should use this permission when creating a token for an inbound message handling webhook.
- Click Create Token.
- Copy the values, then click Got it to close the window.
In Adjust, click for your app’s options, and select Partner Setup » ADD PARTNERS.
Select Add next to Airship.
Enable the Events and Attributes that you want to send from Adjust to Airship.
- EU Data Center — Set this to
On
if you are implemented in Airship’s European Data Center. If you are unsure which data center you are on, ask Airship Support. - In-App Revenue Forwarding sends Revenue Events into Airship as custom events.
- Parameter Forwarding sets attributes on your Airship audience, according to the Partner Parameter Mapping.
- Session Forwarding sends information about in-app sessions to Airship as custom events.
- EU Data Center — Set this to
(Optional) Click Event Linking to set custom
name
parameters for events from Adjust.(Optional) Click Partner Parameter Mapping to see the names of attributes that Adjust will set on your Airship audience. If you change a parameter name mapping here, you’ll need to create a new attribute in Airship to receive the Adjust parameter.
Click Save.
Create Adjust Attributes in Airship
You must create attributes in Airship before Adjust can set attributes on your audience. If an Attribute ID does not exist in Airship, or is of the wrong type, Adjust will not be able to set an attribute on your audience.
Repeat the following process for each entry in the table below to create your Adjust attributes. Use the Attribute ID and Type exactly as they appear in the table.
Go to Audience » Attributes » Attribute List and click Create Attribute.
Fill in your attribute using the Attribute ID, Name, and Type exactly as listed in the table below.
Click Add.
Attribute Name | Adjust parameter | Attribute ID | Type |
---|---|---|---|
Adjust Device ID | adid | adjust_device_id | Text |
Adjust Device City | city | adjust_device_city | Text |
Adjust Device Country Subdivision | country_subdivision | adjust_device_country_subdivision | Text |
Adjust Device Country Code | country | adjust_device_country_code | Text |
Adjust Device Currency Code | currency | currency adjust_currency_code | Text |
Adjust Device Model Number | device_name | adjust_device_model_number | Text |
Adjust Google Play Store Store Ad ID MD5 Hash | gps_adid_md5 | adjust_gps_ad_id_md5 | Text |
Adjust Google Play Store Ad ID | gps_adid | adjust_gps_ad_id | Text |
Adjust Device IP Address | ip_address | adjust_device_ip_address | Text |
Adjust Is Reattributed | is_reattributed | adjust_is_reattributed | Number1 |
Adjust Device ISP | isp | adjust_device_isp | Text |
Adjust Device Language Code | language | adjust_device_language_code | Text |
Adjust Last Session Time in Seconds | last_time_spent | adjust_last_time_spent | Number |
Adjust Lifetime Session Count | lifetime_session_count | adjust_lifetime_session_count | Number |
Adjust Attribution Method | match_type | adjust_attribution_method | Text |
Adjust OAID Device ID MD5 Hash | oaid_md5 | adjust_oaid_device_id_md5 | Text |
Adjust OAID Device ID | oaid | adjust_oaid_device_id | Text |
Adjust Device Postal Code | postal_code | adjust_device_postal_code | Text |
Adjust Random Device Reference Tag | reftag | adjust_reftag | Text |
Adjust Device Region Code | region | adjust_device_region_code | Text |
Adjust Reporting Currency | reporting_currency | adjust_reporting_currency | Text |
Adjust SDK Version | sdk_version | adjust_sdk_version | Text |
Adjust Session Count | session_count | adjust_session_count | Number |
Adjust Current Session Time in Seconds | time_spent | adjust_time_spent | Number |
Adjust Tracking Enabled | tracking_enabled | adjust_tracking_enabled | Number1 |
Adjust Tracking Limited | tracking_limited | adjust_tracking_limited | Number1 |
Adjust Web Unique ID | web_uuid | adjust_web_uuid | Text |
1 Value is either 0 (false) or 1 (true/enabled).
Airship Channel Example with Adjust Attributes
Attributes appear in an attributes
object on the channel. Attributes won’t appear on channels until set from Adjust.
{
"channel_id": "516a818b-b57e-4a35-b7ad-41c6ef447364",
"device_type": "android",
"installed": true,
"opt_in": true,
"background": true,
"push_address": "<push_address>",
"created": "2019-07-31T00:10:34",
"last_registration": "2020-08-17T08:11:46",
"alias": null,
"tags": [],
"tag_groups": {
"group": [
"tags"
]
},
"device_attributes": {
"ua_device_os": "10",
"ua_country": "US",
"ua_device_model": "SM-G973U",
"ua_local_tz": "America/Los_Angeles",
"ua_app_version": "<version>",
"ua_location_settings": "true",
"ua_language": "en",
"ua_sdk_version": "13.2.0",
"ua_carrier": "Verizon "
},
"attributes": {
"adjust_lifetime_session_count": 45,
"adjust_device_postal_code": "97209",
"adjust_device_region_code": "US",
}
}
Custom Event Properties from Adjust
Events from Adjust are of the Custom
type, with the body.name
of the event representing the Adjust event type — install
, rejected install
, session
, in-app event
, reattribution
, or rejected reattribution
. Properties from Adjust appear in the body.properties
object.
Custom Event Property | Description |
---|---|
adjust_attribution_method | Attribution method |
partner_parameters | Custom partner parameters collected by the Adjust SDK or S2S request and transmitted to third party providers via postbacks |
reporting_revenue | Revenue, as reported in the Adjust Dashboard, in whole currency units |
revenue_float | Revenue, as sent from Adjust SDK, in whole currency units |
revenue_usd_cents | Revenue, in US cents |
revenue_usd | Revenue, in US dollars |
revenue | Revenue, as sent from Adjust SDK in cents |
{
"id": "aae70da5-a276-4dd4-a11e-f5b5796a52f1",
"offset": "1000000000780",
"occurred": "2020-08-17T22:37:53.000Z",
"processed": "2020-08-17T22:40:35.337Z",
"device": {
"ios_channel": "c014a2ed-4c30-4f6d-a9b3-e2ba7a01b45c",
"channel": "c014a2ed-4c30-4f6d-a9b3-e2ba7a01b45c",
"device_type": "IOS",
"attributes": {
"locale_variant": "",
"app_version": "1.0",
"device_model": "x86_64",
"connection_type": "WIFI",
"app_package_name": "com.urbanairship.partner.adjust",
"iana_timezone": "America/Los_Angeles",
"push_opt_in": "false",
"locale_country_code": "US",
"device_os": "13.0",
"locale_timezone": "-25200",
"locale_language_code": "en",
"location_enabled": "false",
"background_push_enabled": "false",
"ua_sdk_version": "13.2.0",
"location_permission": "UNPROMPTED"
}
},
"body": {
"name": "session",
"session_id": "c014a2ed-4c30-4f6d-a9b3-e2ba7a01b45c",
"source": "API",
"properties": {
"adjust_attribution_method": "",
"partner_parameters": "",
"reporting_revenue": 25,
"revenue_float": 25.00,
"revenue_usd_cents": 2500,
"revenue_usd": 25,
"revenue": 2500
}
},
"type": "CUSTOM"
}
Categories