Update from v2.x to v4.0
Check the information below when updating the Airbridge Android SDK to v4.0. All changes are listed.List of all changes
List of all changes
SDK Initialization
Airbridge.init(Application, AirbridgeConfig) has been changed to Airbridge.initializeSDK(Application, AirbridgeOption).
AirbridgeConfig has been changed to AirbridgeOption. AirbridgeConfig.Builderhas been changed to AirbridgeOptionBuilder. Some function names in the AirbridgeOptionBuilder have been changed or deleted.
Refer to the example below.
Deep Link
The function name has been changed fromgetDeeplink() to handleDeeplink(). AirbridgeCallback has been removed. The OnSuccess and OnFailure listener have been added. You can check whether the function worked by its return value.
listener to make screen transitions more convenient. The previous method of adding a listener has been removed. Instead, you can receive deferred deep links through the Airbridge interface.
Required: Deferred deep link processing
Required: Deferred deep link processing
- You can call
handleDeeplinkand its value from the activity configuration. - You can check with the result value whether the deferred deep links can be handled.
- Deferred deep links are designed to be acquired only once after the app install. If the value is already acquired or called first, the result is
false.
Set up custom domain
The method of specifying custom domain URLs in theres/values/airbridge.xml file, used in version 2.x, has been changed. You can now add custom domain links by using the setTrackingLinkCustomDomains function during Airbridge SDK initialization.
In-app events and user data
The following APIs have been deleted. Also,StandardEventCategory, SemanticAttributes, and Product have been removed.
trackEvent(category: StandardEventCategory, action: String? = null, label: String? = null, value: Number? = null, customAttributes: Map<String, Any?>? = null, semanticAttributes: Map<String, Any?>? = null)trackEvent(category: String, action: String? = null, label: String? = null, value: Number? = null, customAttributes: Map<String, Any?>? = null, semanticAttributes: Map<String, Any?>? = null)trackEvent(event: Event)
trackEvent(category: String, semanticAttributes: Map<String, Any>? = null, customAttributes: Map<String, Any>? = null)AirbridgeCategoryhas been added. The event category string is predefined.- The function override and objects (
SemanticAttributes,Product) for passing additional information were deleted. - Instead, it has been modified to transmit attributes through a map. The key value of the map is predefined in
AirbridgeAttributeas a string. Custom attributes can be sent directly as a string.
trackEvent function below.
Event Category of Standard Events provided by the SDK (AirbridgeCategory)
Event Category of Standard Events provided by the SDK (AirbridgeCategory)
Semantic Attributes provided by the SDK (AirbridgeAttribute)
Semantic Attributes provided by the SDK (AirbridgeAttribute)
Example) trackEvent function
Example) trackEvent function
AirbridgeUser has been deleted. You can now access the interface through the Airbridge interface that was previously accessible through AirbridgeUser.
Required: Airbridge interface
Required: Airbridge interface
Instead of accessing the code through
Airbridge.getUserInfo(), you need to replace it with the following Airbridge interface.AirbridgeDeviceInfo has been deleted. The interface that was accessed through AirbridgeDeviceInfo has been modified so that it can now be accessed through the Airbridge interface.
AirbridgeCallback has been deleted and OnSuccess, OnFailure listener has been added. You can receive the success status through this listener.
Required: OnSuccess, OnFailure
Required: OnSuccess, OnFailure
You need to replace the codes that enables access through Airbridge.getDeviceInfo() with the following Airbridge interface.
Device UUID
Install referrer
fetch Google Install referrer
fetch Huawei Install referrer
fetch Galaxy store Install referrer
fetch Meta Install referrer
Advertising ID
fetch Google Advertising ID
fetch Huawei Advertising ID
AirbridgeDeviceInfo has been deleted. There is no function to receive the attribution result through the Airbridge interface. However, it can be received through the listener of AirbridgeOption, which is an existing method.
AirbridgeCallback has been deleted and OnSuccess, OnFailure listeners have been added. You can check the operation status of the function through the return value.
Example) click and impression functions
Example) click and impression functions
click
impression
Hybrid app integration
The function name has been changed fromsetJavascriptInterface() to setWebInterface().
Update within v2.x
This section describes the major changes in each version of the Android SDK.v2.24.0
For apps registered with Airbridge after September 4, 2023, we’ve resolved the issue where the deep-link URL provided in the deep-link callback was decoding the content entered in the Airbridge dashboard twice. This issue occurred in Android SDK from v2.22.0 to v2.23.0.v2.21.2
An initialization option has been added to stop sending events when the app is in the background.- You can use the
AirbridgeConfig#setTransmitEventOnBackgroundEnabledfunction to stop sending events when the app is in the background. - The default value is
true. Whentrue, the remaining events are sent even when the app is in the background.
v2.21.1
deeplink.page has been deprecated. From v2.21.1 onwards, we recommend writing code using the abr.ge deep link domain.
deeplink.page is still supported and operates for backward compatibility.
v2.19.1
- Changes have been made so that
ORGANIC_REOPEN,FOREGROUNDevents that occur within the session time are not collected by default. - BACKGROUND events have been removed.
v2.18.0
Deeplink Pageview events will only be collected whenAirbridge.click is called.