SDK changelog



  • Added a package query entry in AndroidManifest.xml for to make Play Store detection work more accurately on Huawei devices.


  • Fix in-app campaigns cache being unreadable.


  • Fixed an issue where builtin event track action would not be able to parse dates on Lollipop and lower.



  • Fixed a memory leak due to Batch retaining the first activity that appeared on screen.


  • Fixed a bug where batch.user.event would fail is no event label was specified. This aligns the behaviour with iOS' implementation.


  • Tracking an event with an empty label now behaves as if the label was null. Event labels that are only composed of whitespaces are unchanged for compatibility.


  • Caching has been disabled on the WebView format.



  • Added a package query entry in AndroidManifest.xml for com.huawei.appmarket to enable detection of the Huawei AppGallery.
  • Added missing android:exported manifest attributes in preparation for Android 12.


  • Added batch.rating, which asks the user to review your app using the Google Play In-App Review API. To enable in-app review, add the dependency to your project. If the library is missing or fails, the SDK will open the Play Store/Huawei AppGallery.
  • Added batch.clipboard, which can copy text to the clipboard.


  • Added support for a new UI format: WebView. See documentation for more info.
  • Added onBatchMessageCancelledByError on Batch.Messaging.LifecycleListener, called when a message could not be loaded due to an error when loading the message's content.
  • Added onBatchMessageWebViewActionTriggered on Batch.Messaging.LifecycleListener, called when a in-app webview format action has been triggered.
  • In-App campaign cache is now cleared on server errors


  • Important change: Push open pending intents are now created with FLAG_IMMUTABLE on Android M and higher in preparation for Android 12.
    This also applies to PendingIntent instances returned by Batch.Push.makePendingIntent*() methods.

Event Dispatchers

  • Added the new event types MESSAGING_CLOSE_ERROR and MESSAGING_WEBVIEW_CLICK. See javadoc for more info.


This release backports changes from 1.17.2

  • Fix in-app campaigns cache being unreadable.


This release backports changes from 1.17.1


  • Fixed a memory leak due to Batch retaining the first activity that appeared on screen.


  • Fixed a bug where batch.user.event would fail is no event label was specified. This aligns the behaviour with iOS' implementation.


  • Tracking an event with an empty label now behaves as if the label was null. Event labels that are only composed of whitespaces are unchanged for compatibility.



  • Fix an issue where Batch might lose some module configuration (such as the push small icon) when an activity is destroyed and no other is on screen.


  • Fix a bug where query parameters of rich push media URLs were escaped twice, making use of non URL safe characters impossible.



  • Fix in-app campaigns cache being unreadable. This caused an issue where in-app campaigns with a NEW_SESSION trigger would not work if Android or the user killed the application process.



  • Fixed a crash that happened when using Messaging (In-App messages/Mobile landings) or the Debug view. It was due to the removal of a default proguard rule, resulting in broken R references.



  • Batch is now built using the Android 11 (API Level 30) SDK, and targets it. Android 11 is fully supported.
  • Batch is now built using R8 rather than proguard.
  • Add support for Push/Advertising ID plugins.
  • Support for TLS versions older than 1.2 has been disabled for devices on Lollipop and higher. Devices on 4.1 to 4.4 might still use TLS 1.1 for compatiblity.
  • Should to fix an issue where Google would report a security issue in due to our usage of an ECB cipher. We've always used standard HTTPS for our network communication: the weak encryption is only used for an additional layer of security on disk and during transport.


  • Enhanced the way the SDK fetchs notifications from the servers to greatly reduce bandwidth usage. No public API change.


  • Fixed an issue where In-App messages might not survive rotation with newer AndroidX core versions.
  • Fixed an issue where rotating an autoclosable In-App message would not show the right countdown.
  • Fixed an issue where LeakCanary would temporarily report a leak with autoclosable messages. This was due to a delayed callback that eventually went away: Batch now cancels it sooner.
  • Auto closable In-App messages won't attempt to dismiss themselves in the background anymore: they'll check if they should have been in onStart.



  • Fixed a crash where the app would crash if the user rotated an automatically dismissing fullscreen/modal/image template.


  • Added support for Date in BatchEventData.
  • BatchEventData now supports up to 15 attributes (used to be 10).
  • BatchUserAttribute now has a public constructor for easier mocking.



  • Tweaked how the log levels work to be more like how logcat works. The default logger level is now VERBOSE and INTERNAL implies all other log levels. Breaking: LoggerLevel.isGreaterOrEqual has been renamed to LoggerLevel.canLog


  • The "Registration ID/Push Token" log has been accidentally set as internal in 1.15.0. It is now public again.



  • Migrated to AndroidX. Batch now explicitely depends on androidx core. The SDK now explicitly depends on androidx.core:core:1.0.0. Please upgrade your version of the support library accordingly.
  • BatchNotificationAction.getSupportActions no longer throws exception, as androidx.core is now an explicit dependency.


  • Fix an exception that occurred when the <application> entry in the manifest had no <meta-data> children.
  • Improved In-App view tracker error handling.
  • Added support for external analytics using EventDispatcher. See the documentation for more details.
  • Added a new feature for developers: a debug view is now available using Batch.Debug.startDebugActivity.
  • Remove obfuscation on BatchOptOutResultListener.ErrorPolicy enum.
  • Added the ability to change the logger level using Config.


  • Added an interface BatchDeeplinkInterceptor to override some aspects of a deeplink that Batch wants to open.


  • Improved accessibility of all message formats
  • Fixed an issue where an Image/Modal format set to auto close would crash if the user moved to another app before the countdown was elapsed.


  • System notification authorization is now reported to Batch's servers.
    This includes channels support: the default channel override is used to measure the status if set, otherwise Batch's default channel is used.
  • Batch.Push.setNotificationsColor() now explicitly takes a ColorInt
  • Batch.Push.setSmallIconResourceId() now explicitly takes a DrawableRes
  • The notification default color will now be the value of your theme's colorPrimary attribute rather than black.
  • If no small icon has been set when configuring Batch, the SDK will now fallback on Firebase's


  • Added the markAsDeleted method on BatchInboxFetcher, allowing the deletion of notifications


  • Saving a UserDataEditor before Batch is started now enqueues the changes instead of failing. If Batch is not started before the process dies, changes will be lost. This change does not affect BatchUserProfile, which has been deprecated for a while.



  • Fix a crash that could occur on resume if the application process was killed after backgrounding the app on a messaging activity.



  • Fix a crash that could occur when the activity backing the "Image" format is stopped.



  • Fix grace periods greater than 119 hours not working


  • Fixed wrong visiblity and obfuscation of methods in BatchUserAttribute
  • Added @NonNull annotations to BatchAttributesFetchListener and BatchTagCollectionsFetchListener


  • Switched back to Proguard from R8. This should fix an issue with Firebase Performance.
  • Notifications using BigPictureStyle will now show the big picture as the large icon when collapsed, if no other large icon was set. Note: this feature requires androidx.core
  • All SDK XML resources have been marked as private and will not show up in code completion anymore.


BREAKING: Batch now requires Java 1.8 source support.
You may need to enable desugaring to make Batch work with your project by adding the following in your build.gradle:

android {
  compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_8
    targetCompatibility JavaVersion.VERSION_1_8

NOTE: This release is one of the last supporting the legacy Android support libraries. Please start migrating to AndroidX to ensure a smooth upgrade experience in the future.


  • Requires Android Studio 3.0 or higher with d8 enabled.
  • Fix some potential bugs with BatchActions in some locales.
  • Batch will not catch RuntimeExceptions occurring in implementations of BatchNotificationInterceptor: they will now crash your app as they should have.
  • Batch.push.setGCMSenderId() has been deprecated: Please migrate to FCM as soon as possible. GCM and GCM-legacy support will be removed from the SDK in a later release.
  • Synchronization of user attributes and tags is now more optimized, resulting in less network requests.
  • Other various bugfixes.$
  • Included new license information in the release zips and the artifact metadata. If you integrate using maven central, licenses will be picked up by


  • High level data (language/region/custom user id) can now be read back.
  • User data (attributes and tags) can now be read back. [Documentation]/android/custom-data/custom-attributes#_reading-attributes-and-tag-collections)


  • Notification content is now visible on the lockscreen by default, even when locked. Use a notification interceptor if you want to override the visibility when showing sensitive content.


  • Added support for two new UI formats: Modal, and Image. See the documentation for more information.

  • Added support for GIFs in Mobile Landings and In-App messages.

  • Added support for rich text.

  • Added support for text scrolling in all formats. Banners will now have a maximum body height of ~160pt, and their text will scroll.

  • Support for opening deeplinks from In-App Messaging and Mobile Landings into a Custom Tab

  • Added new methods on Batch.Messaging.LifecycleListener allowing you to track more information such as close/autoclose and button presses. More info in the Mobile Landings documentation.

  • Batch.Messaging.LifecycleListener methods are no longer called on each rotation



  • SDK is now built with the Pie SDK, and targets API Level 28.

  • Opting-out from the SDK now sends an event notifying the server of this. If a data wipe has been asked, the request will also be forwarded to the server. New methods have been introduced to be informed of the status of the request to update your UI accordingly, and possibly revert the opt-out if the network is unreachable.


  • Exposed the tag Batch uses to display notifications in the constant Batch.NOTIFICATION_TAG. You can use this to cancel notifications, or use other APIs that require finding notifications by ID and tag.

  • Added Batch.Messaging.setShowForegroundLandings(). It allows you to disable Batch's default behaviour to forward push messages containing landings to the app if it is in the foreground. Call this method with false will result in notifications always being posted no matter what the application state is.


Event data support has been overhauled. As a result:

  • Introduced BatchEventData. Use this class to attach attributes and tags to an event. See this class' documentation for more information about limits.
  • Batch.User.trackEvent(String name, Stringlabel, JSONObject data) has been deprecated
  • Calls to this method will log deprecation warnings in the console
  • Legacy data (JSONObject) will be converted to BatchEventData. Same data format restrictions apply: Any key/value entry that can't be converted will be ignored, and logged. Tags are not supported
  • Introduced Batch.User.trackEvent(String name, Stringlabel, BatchEventData data), replacing the deprecated method.

More info in the event documentation.


  • FCM registration errors are now more explicitly logged
  • Fix an error when a "null" registration ID could be logged
  • Add support for server-side Sender ID detection. The Sender ID has also been included in the registration broadcast introduced in 1.12.0


  • Batch now fully supports Firebase Cloud Messaging. Note that existing Batch integrations will NOT automatically be migrated to FCM. You should follow the [migration steps]/android/advanced/fcm-migration.html) before April 2019.

  • Added methods to handle opting-out from Batch, and wiping user data.
    Please see Batch.optOut(), Batch.optOutAndWipeData() and Batch.optIn().
    You can control whether Batch is opted out from by default using a manifest meta-data entry:
    <meta-data android:name="batch_opted_out_by_default" android:value="false" />
    For compatibility reasons, Batch will be enabled by default.
    More info in our documentation.

  • When a push registration identifier has successfully been fetched, Batch will now broadcast it as the action definied by Batch.ACTION_REGISTRATION_IDENTIFIER_OBTAINED. More info in the documentation.

  • Banners now correctly track their display, and trigger a onBatchMessageShown() call on your LifecycleListener if one is set.

  • Displaying a banner will dismiss any currently displayed banner

  • Deprecated Config.setCanUseAndroidID: Android id is never collected anymore.

  • Deprecated Config.setCanUseInstanceID: users should migrate to FCM.

  • Added android.permission.INTERNET, android.permission.WAKE_LOCK and android.permission.VIBRATE in Batch's manifest, meaning that your app will automatically require them with no additional manifest changes. This should not impact you as they're required by many libraries, including Google's, and have always been required for Batch to work. If you didn't have them already, this might trigger a permission request on pre Marshmallow devices: please look at the manifest merger output to see if this impacts you.

  • Fixed some rare crashes that could happen on some Android emulators that broadcast malformed Google Play Services intents.

  • Various javadoc fixes

Note: This version is the last one supporting Android Studio 2.x. Batch 1.13 will ONLY support Android Studio 3.x and later.


  • Added support for Banners in In-App Messaging

    If your app uses the Mobile Landing/In-App Messaging manual mode, you need to update your implementation to support banners. Please check the [updated manual mode documentation]/android/mobile-landings.html) for more information.

  • Fix an issue where an exception could be thrown if an invalid deeplink was supplied when setting up an In-App Message's buttons.

  • The SDK will now log the current Installation ID on start


  • Unobfuscated InAppMessageUserActionSource, which is implemented by BatchInAppMessage
  • Fixed an exception that could be thrown when using the Inbox APIs in the background. While it will not throw an exception anymore, the fetcher will still not work in these conditions if used in 'user identifier' mode: In order to fix this, please use Batch.Inbox.getFetcher(Context, String, String) rather than Batch.Inbox.getFetcher(String, String).
  • Fix a bug where the image of an In-App message could be distorted after a double rotation.
  • Added a method getNotificationIdentifier() on BatchInboxNotificationContent, which allows you to retrieve a unique identifier for this specific notification.
  • Added a variant of Batch.Push.appendBatchData() compatible with BatchNotificationInterceptor implementations
  • Added Batch.Push.makePendingIntent(Intent), to generate a valid PendingIntent from an Intent, suitable for a Notification's builder. Please note that it will override the intent's action. If you rely on a custom action, you will have to make your own PendingIntent.
  • Added Batch.Push.makePendingIntentForDeeplink(String), to generate a valid PendingIntent for a deeplink string, suitable for a Notification's builder, using Batch's action activity.
  • Improve builtin proguard rules. The number of library classes kept because of Batch is now much lower.
  • Added detection for invalid sender IDs, and overall better error reporting when FCM/GCM registration fails.


  • Improved handling of new Android O backgrounding limitations
  • Fixed Do Not Disturb mode not working properly
  • Fixed a bug where activities opened by a push using a deeplink did not contain the Batch.Push.PAYLOAD_KEY extra
  • Fixed an issue with Android Oreo channels
  • Added APIs to copy Batch's data from an intent to another. See Batch.copyBatchExtras
  • Added a method on BatchInAppMessage, allowing you to fetch the visual content of the message. See BatchInAppMessage.getContent for more info
  • Added proguard rules to exclude support-v4 NotificationCompat related classes


  • Introduced In-App Campaigns
  • Added a Do Not Disturb mode on Batch.Messaging, allowing easier control of when landings will be shown


  • Batch is now available on Maven Central!
  • Unofbuscated classes that have been wrongly obfuscated before. BatchNotificationAction is now available.
  • Introducing BatchNotificationInterceptor, which allows you to change the generated notificationId or change the NotificationCompat.Builder instance that Batch uses to display notifications. This allows you to add features such as a Wear extender, etc.


  • Batch SDK is now built with and targets API 26
  • Added support for Android 8.0 Notification Channels

   See Batch.Push.getChannelsManager() and our channels documentation to tweak how Batch handles them.

  • Batch requires support-v4 26.0.0, for notifications to work with Android 8.0. (As of writing, only 26.0.0-beta2 is available)
  • Eclipse support had been dropped


  • Added the Inbox module, allowing you to fetch previously received notifications from your code. More info: Inbox documentation


  • BREAKING CHANGE: Removed Batch.Ads and Batch.Unlock methods and related classes.
  • Added Batch.User.trackLocation, allowing you to natively track user position updates
  • Added global notification sound override using Batch.Push.setSound(Uri)
  • Un-obfuscated the exception returned by some of BatchPushPayload's methods
  • Deprecated Batch.isRunningInDevMode. It is useless, as DEV API Keys always start with "DEV"


  • Fix a bug where the delegate set on BatchMessaging was never called.


  • Fixed a bug that could cause notifications to open the wrong deeplink if multiple notifications were present in the notification shade


  • Fixed a bug where events would stop working after rotation in some cases
  • Fixed a bug where Batch wouldn't work properly with translucent/floating activities


  • Fixed a bug where mobile landings buttons could be misplaced



  • Batch now requires Android 4.0.3 (API Level 15)
  • Batch now targets Android 7 (API Level 24), and should only be used in apps that compile with that SDK version. You should also use a v24 support-v4 library with it.
  • Updated notification behaviour to be more adapted to changes introduced in Nougat
  • setCanUseAdvancedDeviceInformation() has been introduced on the Config object to reduce the quantity of device information Batch will use. Note that disabling this will limit several dashboard features.
  • BatchPushData has been deprecated in favour of BatchPushPayload, which is easier to use and will allow you to read anything used by Batch's standard push receiver. It's also easier to instanciate from an intent/bundle, and easier to serialize.
  • InstanceID support has been merged into the main SDK. If migrating from an older SDK, you'll need to add a new service in your manifest, as described in the push setup.
  • The overall method count has been reduced.


  • Fix a rare memory leak for the last activity
  • Internal bugfixes


  • Added Batch.Push.getNotificationsType()
  • Threads used by Batch are now named
  • Batch.User.getEditor() has been renamed: Please use Batch.User.editor(). The old method will still work, but has been deprecated
  • Additional intent flags can now be set for the activity started when opening a Push using Batch.Push.setAdditionalIntentFlags(int)
  • Added "BatchActivityLifecycleHelper", an implementation of the "Application.ActivityLifecycleCallbacks" interface to use with "registerActivityLifecycleCallbacks()"



  • Fix JSON issues on Android 4.3 and below



  • Fix a bug where clearTagCollection incorrectly cleared all attributes



  • Custom user data (attributes, tags and events)
  • Added an API to retrieve Batch's unique installation identifier
  • Deprecated BatchUserProfile
  • Added ability to start Batch in a service


Batch Ads has been discontinued

Added a method to get the last known push token

Minor push bugfixes



New Manual Push helper.



Introduced Manual Push mode.

Other Push improvements and minor bug fixes



Introduced Native Ads.

Deprecated legacy Ads methods in order to prevent confusion between Native and Interstitial Ads. More info in the 1.2 to 1.3 migration guide



Fixed a bug that prevented a push notification from showing up in rare scenarios



Fixed bug that caused conflicts if an ad was accidentally reused a second time.



We reduced the SDK method count by 25%, decreasing the SDK size to 664kb.



Fixed error that affected use of Unlock daily capping.



Batch Ads (interstitials) released.



Added big text to push notifications.



Batch Push released.



Batch out of beta testing and 1.0 published.