Skip to content
This repository has been archived by the owner on Jan 25, 2024. It is now read-only.

mparticle-integrations/mparticle-apple-integration-tune

Repository files navigation

Tune Kit Integration

The Tune kit is no longer supported

The Tune kit for the mParticle iOS SDK has been deprecated and is no longer supported.


Deprecated

This repository contains the Tune integration for the mParticle Apple SDK.

Adding the integration

  1. Add the kit dependency to your app's Podfile or Cartfile:

    pod 'mParticle-Tune', '~> 8'
    

    OR

    github "mparticle-integrations/mparticle-apple-integration-tune" ~> 8.0
    
  2. Follow the mParticle iOS SDK quick-start, then rebuild and launch your app, and verify that you see "Included kits: { Tune }" in your Xcode console

(This requires your mParticle log level to be at least Debug)

  1. Reference mParticle's integration docs below to enable the integration.

Deep-linking

Set the property onAttributionComplete: on MParticleOptions when initializing the mParticle SDK. A copy of your block will be invoked to provide the respective information:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
    MParticleOptions *options = [MParticleOptions optionsWithKey:@"<<Your app key>>" secret:@"<<Your app secret>>"];
    options.onAttributionComplete = ^void (MPAttributionResult *_Nullable attributionResult, NSError * _Nullable error) {
        if (error) {
            NSLog(@"Attribution fetching for kitCode=%@ failed with error=%@", error.userInfo[mParticleKitInstanceKey], error);
            return;
        }

        NSLog(@"Attribution fetching for kitCode=%@ completed with linkInfo: %@", attributionResult.kitCode, attributionResult.linkInfo);

    }
    [[MParticle sharedInstance] startWithOptions:options];

    return YES;
}

Documentation

Tune integration

License

Apache License 2.0