mParticle Native Android Integration
Overview
You can integrate mParticle Android SDK with CleverTap to control the flow of information from the app SDK. You can send the following information to the CleverTap dashboard:
- Push User Profiles
- Push Events
- Integrate Push Notifications
Prerequisites
The following are the prerequisites for performing this integration:
- A CleverTap account
- An mParticle account
- A functional Android app
Integration
For CleverTap mParticle Android integration, the following are the major steps:
- Add Event Output.
- Connect the Input Feed and Output Event on the mParticle dashboard.
- Install SDK in the Native application.
- Initialize the mParticle client.
Add Event Output
To add an event output:
- Navigate to Setup > Output from the mParticle dashboard.
- Click Add Event Output and select CleverTap from the dropdown list.
After selecting, CleverTap Default Group is added under the Events tab of the Outputs page.
- Click the icon to add event configuration. The Output: Event Configuration popup opens.
- Enter the following details and click Save to save the details:
Field | Description |
---|---|
Configuration Name | Enter the name to identify your configuration uniquely. |
Use same settings for Development & Production | Select this option if you want to apply the same configuration settings for your production and development projects. ~ OR ~ Select PROD or DEV to apply these configuration settings to the respective project. |
Account ID, Account Passcode, and Account Token | Enter these details to authenticate your CleverTap account. You can obtain these details by navigating to the Settings > Project page from the CleverTap dashboard. |
Region | Enter the region of your CleverTap account. |
The Output Configuration Saved message is displayed at the top of the Output page.
Connect Input Feed and Output Event on mParticle Dashboard
To connect input feed and output event on the mParticle dashboard:
- Navigate to the Connections > Connect page from the mParticle dashboard.
- Select Android from the Available Inputs.
- Click Connect Output. The Connect Output popup opens.
- Select CleverTap and then select the Configuration Name that you want to connect.
- Toggle the Connection Status to forward data to the CleverTap dashboard.
- Select Customer ID from the User ID dropdown list.
- (Optional) Select the Min Platform Version.
- Click Add Connection and click Done.
- (Optional) Set up the forwarding rule for your output. This allows you to control the data you want to forward to the CleverTap dashboard.
- (Optional) Enter the percentage of the user base for which you want to event data to help control the cost.
- Click Save.
Install SDK in Native Application
To install Android SDK within the application, add the following dependency under dependencies within app/build.gradle
file:
implementation 'com.mparticle:android-clevertap-kit:5.41.1'
Initialize mParticle Client
To initialize the mParticle client:
- Refer to Initialize SDK under mParticle documentation for initializing the SDK.
- Call
ActivityLifecycleCallback.register(this);
beforesuper.onCreate()
in your custom application class.
Push User Information
After installing an app on a device, your user is assigned an anonymous profile. The first time when the application identifies the user on the device, the anonymous history on the device is associated with the newly identified user. To learn more about how user information is pushed to the mParticle dashboard, refer to Track Users under mParticle documentation.
Push Events
To learn how to push event data whenever you want to capture any user action in your application, refer to Track Events under mParticle documentation.
Integrate Push Notification in Android
For more information about integrating Push Notification in Android, refer to Android Push Notification.
Integrate In-App in Android
For more information about integrating In-App in Android, refer to Android In-App.
Integrate App Inbox in Android
For more information about integrating App Inbox in Android, refer to Android App Inbox.
Advanced Features
To add advanced features to your Android app, refer to Android Advanced Settings.
Updated 12 months ago