Skip to main content

Android

The Airbridge Unity SDK for Android initializes automatically through Content Provider. For proper initialization, the following XML tag must be correctly placed in “Project → Plugins → Android → AndroidManifest.xml”.
The Airbridge Unity SDK uses custom activities in “UnityPlayerActivity” to get deep link data. If you are using your own custom activity class, please override the following codes inside your custom activity class.
The “AndroidManifest Merger” that the Airbridge Unity SDK provides is a simple component that merges “Project → Plugins → Android → AndroidManifest.xml” and “Project → Plugins → Airbridge → Android → AndroidManifest.xml”. The merge may not satisfy all cases, and you will have to separately merge your “AndroidManifest.xml” file with reference to “Project → Plugins → Airbridge → Android → AndroidManifest.xml”.
Due to the addition of Android 11’s Package Visibility policy, applications should be properly informed by <queries> inside the manifest file about which packages are used in order to properly interact with another applications.The Airbridge SDK is compliant with the policy and requires Gradle v5.6.4+ and Android Gradle Plugin v3.6.0+ to support the <queries> tag.Please refer to this page for information on which version of Gradle is used by Unity.
No further action is required because the necessary Gradle and Android Gradle plugin exists.
The following customization is supported only on Unity 2019.3 patch 7 and later.
  1. Go to the Gradle Build Tool page and download Gradle v5.6.4 or higher
  2. Go to “Preferences → External Tools” to uncheck “Gradle Installed with Unity (recommended)” and set the path to the downloaded Gradle file as below.
09-en-dev-unity-sdk
  1. Go to “Project Settings → Player → Android Tab → Publishing Settings → Build” and select the following options:
    1. Custom Main Gradle Template
    2. Custom Launcher Gradle Template
10-en-dev-unity-sdk
  1. Please change both of the following auto-generated files as follows
    1. Assets/Plugins/Android/mainTemplate.gradle
    2. Assets/Plugins/Android/launcherTemplate.gradle
  1. Go to the Gradle Build Tool page and download Gradle v5.6.4 or higher.
  2. Go to “Preferences → External Tools” to uncheck “Gradle Installed with Unity (recommended)” and set the path to the downloaded Gradle file as below.
11-en-dev-unity-sdk
  1. Go to “Project Settings → Player → Android Tab → Publishing Settings → Build” and select “Custom Gradle Template”.
12-en-dev-unity-sdk
  1. Go to the auto generated “Assets/Plugins/Android/MainTemplate.gradle” file and make the following changes.
The following customization is supported only on Unity 2018.4 patch 24 and later
  1. Go to the Gradle Build Tool page and download Gradle v5.6.4 or higher.
  2. Go to “Build Settings → Android” and set “Build System” to “Gradle” to use a custom version of Gradle.
13-en-dev-unity-sdk
  1. Go to “Preferences → External Tools”, uncheck “Gradle Installed with Unity (recommended)” and set the path to the downloaded “Gradle” file.
14-en-dev-unity-sdk
  1. Go to “Project Settings → Player → Android Tab → Publishing Settings → Build” and select the “Custom Gradle Template” option.
15-en-dev-unity-sdk
  1. Go to the auto generated “Assets/Plugins/Android/MainTemplate.gradle” file and make the following changes.
Gradle customizations are not supported on these versions of Unity and are not compatible with the necessary changes to support Android 11 (API level 30).
If you are experiencing build errors caused by overlapping of the Airbridge SDK backup rules and third-party SDK backup rules, please refer to the workaround below.e.g) If you have an Airbridge SDK backup rule and an Appsflyer SDK backup rule that overlap, you will see the build error below.
To resolve this issue, please set up as follows.
  1. Create an Android Library project (Assets/Plugins/Android/res.androidlib) to store your resource files.
  2. Add an AndroidManifest.xml file in the created Android Library Project as follows.
  1. Create a res/xml folder inside the created Android Library Project.
  2. Create a file (e.g. custom_backup_rules.xml) within the created xml folder.
  3. Add the data backup rules defined by the Airbridge SDK as follows.
Apply the data backup rules to the Android App Manifest file (Assets/Plugins/Android/AndroidManifest.xml) as follows.
For more guidance, refer to the articles below.

iOS

Airbridge Unity SDK uses IMPL_APP_CONTROLLER_SUBCLASS to create a custom AppController. If you are using your own custom AppController, add the following code to your custom AppController.
  • Please remove the “Assets → Plugins → Airbridge → iOS → Delegate → AUAppController.mm” file once the above change has been made.
Text
If you are using Airbridge Unity SDK version 1.14.1 or 1.16.2, Please update to version 1.16.3.
Text
If you can’t find a compatible AirBridge version on iOS, execute the command below to update the source repository.
After updating your source repository, run the pod search AirBrdige command to verify that the correct AirBridge version exists in your repository, and then proceed with the iOS build.