The Adjust Android Extension for Adobe Experience SDK enables you to send additional information to Adjust to forward to your callback URL and network partners. Global parameters are string key-value pairs that you can use to communicate more information about a device or user.
Global callback parameters
If you register a callback URL in the Adjust dashboard, Adjust sends a GET
request to your callback URL when the SDK sends session data. To append parameters to this callback request, set the global parameters in your code.
Reference
The Adjust
class methods manage the global callback parameters. You can add and remove individual parameters, or reset all parameters at once.
Add a global callback parameter
To add a global callback parameter, call the Adjust.addGlobalCallbackParameter
method with the following arguments:
key
:String
The parameter key.
value
:String
The parameter value.
You can add multiple parameters by calling the Adjust.addGlobalCallbackParameter
method multiple times.
Remove a global callback parameter
To remove a global callback parameter, call the Adjust.removeGlobalCallbackParameter
method with the following argument:
key
:String
The key of the parameter you want to remove.
Remove all global callback parameters
To remove all global callback parameters at once, call the Adjust.removeGlobalCallbackParameters
method.
This method removes all active global callback parameters, meaning you won't receive any parameters in callbacks from Adjust.
Global partner parameters
You can send extra information to your network partners by adding partner parameters. Sharing additional parameters with your external partners enables more granular analysis and facilitates retargeting.
When the Adjust Android Extension for Adobe Experience SDK sends session data, Adjust's servers forward any global partner parameters to any partners you've configured.
Read choose data sharing options to learn how to configure what data you share with external partners.
Reference
The Adjust
class methods manage the global partner parameters. You can add and remove individual parameters, or reset all parameters at once.
Add a global partner parameter
To add a global partner parameter, call the Adjust.addGlobalPartnerParameter
method with the following arguments:
key
:String
The parameter key.
value
:String
The parameter value.
You can add multiple parameters by calling the Adjust.addGlobalPartnerParameter
method multiple times.
Remove a global partner parameter
To remove a global partner parameter, call the Adjust.removeGlobalPartnerParameter
method with the following argument:
key
:String
The key of the parameter you want to remove.
Remove all global partner parameters
To remove all global partner parameters at once, call the Adjust.removeGlobalPartnerParameters
method.
This method removes all active global partner parameters, meaning no parameters will be sent to network partners.
Tutorial: Add and remove global parameters
You can change your global callback and partner parameters at any time by calling the methods described on this page. If you followed the integration guide, your MainActivity.java
file should look something like this:
Add new functions to update global parameters:
addAdjustGlobalCallback
: This function adds a new global callback.removeAdjustGlobalCallback
: This function removes a global callback added byaddAdjustGlobalCallback
.removeAllAdjustGlobalCallbacks
: This function removes all global callbacks.addAdjustGlobalPartnerParam
: This function adds a new global partner parameter.removeAdjustGlobalPartnerParam
: This function removes the global partner parameter added byaddAdjustGlobalPartnerParam
.removeAllAdjustGlobalPartnerParams
: This function removes all global partner parameter.
These functions take a View
as an argument and return void
. To handle the update, call the relevant Adjust
class method within the body of each function.
Here's the updated MainActivity.java
file: