Support Home > SDK Integration > SDK – KochavaTracker Xamarin

SDK – KochavaTracker Xamarin


KochavaTracker Xamarin

A lightweight and easy to integrate SDK written in C# that wraps the native Android and iOS SDKs, providing first-class integration with Kochava’s installation attribution and analytics platform.

Our Xamarin SDK supports all Mono frameworks including MonoGame.

Please use our Windows SDK directly if targeting a windows platform.



  • Android
  • iOS



  • Android API 14
  • Xcode 8.0


  1. Add the SDK into your project.


    Xamarin Component:

    The typical way to include the Kochava SDK is through the Kochava Xamarin Component

    1. Right click the Components folder in your project and click Get More Components.
    2. Search for Kochava and Select Add to App.

    Directly Importing the DLL:

    The SDK can also be included by downloading the DLL from the version badge above and including it directly. This must be done individually for iOS and Android in their respective projects.

    1. Right click the References folder in your project and Click Edit References.
    2. Select the .Net Assembly tab and Click Browse.
    3. Locate and Select the KochavaXamarin DLL and import it.


  2. Add Dependencies.
    The following items are for Android only. If using iOS only proceed to Step 3.

    1. (Required) Add the Google Play Services Analytics Component:
    2. (Optional) To gather location add the Google Play Services Location Component: and check ACCESS_COARSE_LOCATION and/or ACCESS_FINE_LOCATION.
    3. (Optional) To gather email accounts check GET_ACCOUNTS.
    4. (Optional) To gather paired and connected bluetooth devices check BLUETOOTH.


  3. Configure a Tracker


    • To configure it, first create a trackerParametersDictionary, and then perform the configuration using the designated configuration instance method configure(withParametersDictionary:delegate:). It is recommended that you call this in your UIApplicationDelegate instance method application(_:didFinishLaunchingWithOptions:).

    • To configure the Tracker, first create a Tracker.Configuration object, and then perform the configuration using the configuration method Tracker.configure(Com.Kochava.Base.Tracker.Configuration). It is recommended that you call this in your Application.OnCreate method.

Using the SDK

Sending Events:

More than basic analytics, the events you send to Kochava are associated with your install attribution data, so that you can understand how the users who came to you through a particular ad went on to use the various features within your app.


  • For more information, refer to Class – KochavaEvent.

  • For more information, refer to Tracker.Event.

Setting Identity Link:

You can link additional identifying information with a install, where it can be integrated with your analytics. For more information see:

Getting Attribution:

You can retrieve Kochava’s attribution information within your app. For more information see:

Getting the Device ID:

You can get the unique device identifier used by the tracker. For more information see:

Adjusting the Log Level:

You can specify the types of entries which the tracker prints to the log. For more information see:

Push Notifications:

If you’ve configured your app to use the Kochava Push Notification service, you can use the SDK to send remote notification device tokens, as well as push open events. For more information see:

Intelligent Consent Management:

When intelligent consent management is enabled and configured within your Kochava dashboard, the SDK will indicate when the user should be prompted for consent. It will also not gather, persist, or transmit data which requires consent unless consent has been granted. For more information see:

See Also

The Xamarin SDK is a thin wrapper over the native Android and iOS SDKs. The reference documentation for those platforms is available for more advanced usage.



Last Modified: Oct 17, 2018 at 1:32 pm