Braze (formerly Appboy) integration for the mParticle Android SDK
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Braze (formerly Appboy) Kit Integration

This repository contains the Braze integration for the mParticle Android SDK.

Example App

This repository contains an example app showing how to implement mParticle, Braze, and Firebase Cloud Messaging. The key changes you need to make to your app are below, and please also reference mParticle and Braze's documentation:

1. Adding the integration

See a full build.gradle example here

  1. The Braze Kit requires that you add Braze's Maven server to your buildscript:

    repositories {
        maven { url "" }
        //Braze's library depends on the Google Support Library
  2. Add the kit dependency to your app's build.gradle:

    dependencies {
        compile 'com.mparticle:android-appboy-kit:5+'

2. Registering for Push

mParticle's SDK takes care of registering for push notifications and passing tokens or instance IDs to the Braze SDK. Follow the mParticle push notification documentation to instrument the SDK for push registration. You can skip over this section of Braze's documentation.

3. Displaying Push

See a full example of an AndroidManifest.xml here.

mParticle's SDK also takes care of capturing incoming push notifications and passing the resulting Intent to Braze's AppboyFcmReceiver. Follow the mParticle push notification documentation to ensure you add the correct services and receivers to your app's AndroidManifest.xml.

4. Reacting to Push and Deeplinking

There are a wide variety of implementation options available in Braze to deeplink a user when they tap a notification. There are two specific requirements to ensure automatic deeplinking works as intended.

  • AppboyFcmReceiver

    Whereas up until now you should have nothing Braze-specific in your AndroidManifest.xml, using Braze's automatic deeplinking does require you to add their AppboyFcmReceiver. Note that you do not need to specify any Intent filters (for example to receive push tokens, since mParticle takes care of that). You just need to add the following:

      <receiver android:name="com.appboy.AppboyFcmReceiver" />
  • appboy.xml

    For automatic deep-linking, you need to add a boolean resource named com_appboy_handle_push_deep_links_automatically. This can be in any resource file, or you can name it appboy.xml:

    <?xml version="1.0" encoding="utf-8"?>
        <bool name="com_appboy_handle_push_deep_links_automatically">true</bool>

From here you should be able to successfully test push via Braze! Braze offers many client-side configurable options via xml resources and otherwise. Please see review the rest of their documentation here for more information.


Apache License 2.0