Android In-App Marketing Setup

Current Android SDK Version 4.10.2


  1. TUNE recommends having a PROD and DEBUG app in our system. You can switch between builds automatically by using debug macros. Create separate App IDs for the development and production builds of your app so that changes to your development build do not affect your production build (until you’re ready to push them to your production app audience). You need to have two apps in In-App Marketing for each one of your apps if you support two platforms. One platform is for production and one for development.
    Tune tune = Tune.init(this, "your_advertiser_id", "your_conversion_key", true);
    if (BuildConfig.DEBUG) {
     For more information about creating unique App IDs/package names, please visit Creating Unique Package Names.
  2. Implement version 4.8+ of the SDK. If you need to update to this version, please consult the update guide. In-App Marketing is supported with Tune SDK versions 4.0 and above. If you would like to use a Tune SDK version older than 4.8.0 see our In-App Marketing Setup Instructions 4.0 - 4.7 Guide.

Enabling In-App Marketing

To enable In-App Marketing:

In your Application onCreate, call Tune.init with the extra argument turnOnIAM = true

public class MyApplication extends TuneApplication {
    public void onCreate() {
        Tune tune = Tune.init(this, TUNE_ADVERTISER_ID, TUNE_CONVERSION_KEY, true);

Set Up Push Notifications

Across all platforms, it is important to establish push notifications after your initial SDK install.
For more information on how to set up push notifications and configure campaigns to send out targeted push messages, see our Push Notifications article.

Push Notifications Icons

In Android Lollipop (Android OS developed by Google, spanning versions between 5.0 and 5.1.1) all push notification icons are updated to the new material standards:
The platform only respects icons with no color and only alpha levels. Old icons rendered in material display as a white square, for example:


If you are supporting versions both before and after Lollipop, verify at runtime which icon to use.

You can accomplish this by:

TuneNotificationBuilder builder
if (Build.VERSION.SDK_INT >= 21)
{     builder = new TuneNotificationBuilder(R.drawable.lollipop_icon)                       .setColor(Color.BLUE); }
{     builder = new TuneNotificationBuilder(R.drawable.pre_lollipop_icon); }
Have a Question? Please contact for technical support.