StoreKit Ad Network (SKAdNetwork) is Apple’s attribution framework for app install and reinstall attribution. The SKAdNetwork workflow goes like this:
- Apple gathers attribution information and notifies the relevant ad network.
- The network sends a postback with this information to Adjust.
- Adjust displays SKAdNetwork data in Datascape.
Disable SKAdNetwork communication
The Adjust SDK communicates with SKAdNetwork by default. The SDK registers for SKAdNetwork attribution upon initialization.
You can disable SKAdNetwork communication by calling the disableSkanAttribution
method with no argument.
Update conversion values
Conversion values are a mechanism used to measure user behavior in SKAdNetwork. You can map 64 conditions to values from 0
through 63
and send this integer value to SKAdNetwork on user install. This gives you insight into how your users interact with your app in the first few days.
If you manage your conversion values with Adjust, the servers update this value in the SDK. You can also update this value by using the updateSkanConversionValue
method. It accepts the following arguments:
Argument | Data type | Description |
---|---|---|
fineValue | Integer | Your conversion value. Must be between 0 and 63 . |
coarseValue | SKAdNetwork.CoarseConversionValue | The coarse conversion value. This value is used if your app doesn’t have sufficient installs to reach the privacy threshold.
|
lockWindow | Boolean | Whether to send the postback before the conversion window ends. Use true to tell the system to send the postback without waiting for the end of the conversion window. Defaults to false . |
completion | Function | An optional completion handler you provide to catch and handle any errors this method encounters when you update a conversion value. Set this value to nil if you don’t provide a handler. |
SKAdNetwork callbacks
SKAdNetwork 4.0 postbacks contain some additional information to give advertisers more insight into their users. When Adjust’s servers update conversion values, this additional information is sent in an untyped dictionary. To access this information, pass a completion handler to the [adjustSkanUpdatedWithConversionData]
method. You can access the callback information in your completion handler.
conversion_value
: The updated conversion value.coarse_value
: The updated coarse conversion valuelock_window
: Whether to send the postback before the conversion window endserror
: Any error message returned by the update.
Example
This example shows how to log the the fine conversion value, the coarse conversion value, and whether the SKAdNetwork postback is set to send before the conversion window ends.
Set up direct install postbacks
You can configure your app to send a copy of winning SKAdNetwork callbacks to Adjust. This enables you to use SKAdNetwork information in your analytics.
To set up direct install postbacks, you need to add the Adjust callback URL to your Info.plist
file:
- Select Info.plist in the Project navigator in Xcode.
- Select the Add button beside a key in the property list editor and press
Return
. - Enter
NSAdvertisingAttributionReportEndpoint
as the key name. - Set the Type to String in the pop up menu.
- Enter the address
https://adjust-skadnetwork.com
.