Set up deferred deep linking
A deferred deep link sends a user to a place in your app after routing them via the App Store to install the app first.
This is how a deferred deep link works:
- The user clicks on an Adjust deep link.
- The Adjust server redirects the user to the App Store.
- The user installs your app and opens it.
- The Adjust backend performs attribution and sends the deep link to the Adjust SDK.
- Your app displays its preliminary content, such as onboarding screens and user login, if applicable.
- Your app retrieves the deep link from the Adjust SDK and handles the deep link.
Check out the Facebook deferred deep linking documentation for information about how to configure deep linking with your Facebook campaigns.
There are 2 approaches to set up deferred deep linking in your app:
- Adjust's servers automatically pass the deferred deep link to the Adjust SDK. When the user opens your app, the Adjust SDK automatically calls the
open(_:options:completionHandler:)method with the deep link. If your app doesn't have preliminary content (for example: onboarding screens and user login), or if your app already handles this content before opening the deep link, then no further configuration is required, and you can skip the rest of this section.
- If your app has preliminary content (for example: onboarding screens and user login), but your app doesn't already handle this before handling the deep link, then you can add a deferred deep link listener.
- Set up a delegate callback for deferred deep linking. If you have already configured attribution callbacks, you can skip this step.
- If you haven’t already done so, create an instance of the
ADJConfigclass and set a delegate on the
ADJConfigobject in your app delegate. You need to set the delegate in
ADJConfigbefore initializing the SDK.
- Add the
adjustDeeplinkResponsedeferred deep link callback method to the delegate. The Adjust SDK calls this method after receiving a deferred deep link.
- Set your deep link handling code.
- Set the return value of the
false. This indicates whether you want the Adjust SDK to call the
open(_:options:completionHandler:)method to open the deep link after your deep link handling code runs.
Adjust’s LinkMe solution is an optional feature that ensures robust deferred deep linking performance by enabling your app to read deep link information from the device pasteboard.
When a user clicks on a LinkMe URL they have the option to copy the link information to their system pasteboard. You can use the Adjust SDK to read the system pasteboard for deep link inforfmation. If deep link information is present, the Adjust SDK forwards the user to the correct page in your app.
To enable pasteboard checking in your app, pass a true value to the
setLinkMeEnabled method on your