Mixpanel

    Airbridge supports integration with Amplitude. With the integration, you can send attribution data from Airbridge to Miaxpanel and uncover insights into how users interact with your product in Amplitude.

    Integration

    To implement the server-to-server integration, the Device ID of the Amplitude SDK should be set as the device alias of the Airbridge SDK.

    Minimum SDK version required

    • Airbridge Android SDK: v.2.19.5

    • Airbridge iOS SDK: v.1.18.0

    • Airbridge Web SDK Loader: v.1.3.0

    • Airbridge React Native SDK: v.1.5.0

    • Airbridge Cordova SDK: v.2.0.2

    • Airbridge Flutter SDK: v.3.0.2

    • Airbridge Unity SDK: v.1.9.0

    SDK setup

    Attention

    Once the SDK setup is complete, make sure to complete the required setup process in the Airbridge dashboard to implement the integration successfully.

    Add the codes below to the Airbridge SDK. Without adding the codes, Mixpanel won't be properly integrated with Airbridge even if the necessary setup is completed in the Airbridge dashboard.

    Android

    123456789101112131415
    // MainApplication.kt
    override fun onCreate() {
        super.onCreate()
        // Initialize Airbridge SDK
        val config = AirbridgeConfig.Builder("YOUR_APP_NAME", "YOUR_APP_SDK_TOKEN")
            // Make Airbridge SDK explicitly start tracking
            .setAutoStartTrackingEnabled(false)
            .build()
        Airbridge.init(this, config)
    
        // Set device alias into Airbridge SDK
        Airbridge.setDeviceAlias("mixpanel_device_id", mixpanel.distinctId)
        // Explicitly start tracking
        Airbridge.startTracking()
    }

    iOS

    1234567891011
    // AppDelegate.swift
    func application(
      _ application: UIApplication,
      didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]?
    ) {
        AirBridge.setAutoStartTrackingEnabled(false)
        AirBridge.getInstance("YOUR_APP_TOKEN", appName:"YOUR_APP_NAME", withLaunchOptions:launchOptions)
    
        AirBridge.state()?.setDeviceAlias(withKey:"mixpanel_device_id", value:Mixpanel.mainInstance().distinctId)
        AirBridge.startTracking()
    }

    Web

    123456
    airbridge.init({
        ...
      autoStartTrackingEnabled: false,
    })
    airbridge.setDeviceAlias('mixpanel_device_id', mixpanel.get_distinct_id())
    airbridge.startTracking()

    React Native

    Set autoStartTrackingEnabled to false in the airbridge.json.

    12
    Airbridge.state.setDeviceAlias("mixpanel_device_id", await Mixpanel.getDistinctId())
    Airbirdge.state.startTracking()

    Cordova

    Set autoStartTrackingEnabled to false in the .

    12
    Airbridge.state.setDeviceAlias("mixpanel_device_id", mixpanel.get_distinct_id())
    Airbirdge.state.startTracking()

    Flutter

    Set autoStartTrackingEnabled to false in the airbridge.json.

    12
    Airbridge.state.setDeviceAlias("mixpanel_device_id", await mixpanel.getDistinctId())
    Airbirdge.state.startTracking()

    Unity

    Set Auto Start Tracking Enabled to false in the project settings.

    12
    AirbridgeUnity.SetDeviceAlias("mixpanel_device_id", Mixpanel.DistinctId);
    AirbridgeUnity.StartTracking()

    Airbridge dashboard setup

    The Airbridge dashboard setup must be completed to implement the integration. For detailed instructions, refer to the user guide below.

    このページは役に立ちましたか?

    ご質問やご提案はありますか?