Data Subject Request API Version 1 and 2
Data Subject Request API Version 3
Platform API Overview
Accounts
Apps
Audiences
Calculated Attributes
Data Points
Feeds
Field Transformations
Services
Users
Workspaces
Warehouse Sync API Overview
Warehouse Sync API Tutorial
Warehouse Sync API Reference
Data Mapping
Warehouse Sync SQL Reference
Warehouse Sync Troubleshooting Guide
ComposeID
Warehouse Sync API v2 Migration
Bulk Profile Deletion API Reference
Calculated Attributes Seeding API
Data Planning API
Custom Access Roles API
Group Identity API Reference
Pixel Service
Profile API
Events API
mParticle JSON Schema Reference
IDSync
AMP SDK
Initialization
Configuration
Network Security Configuration
Event Tracking
User Attributes
IDSync
Screen Events
Commerce Events
Location Tracking
Media
Kits
Application State and Session Management
Data Privacy Controls
Error Tracking
Opt Out
Push Notifications
WebView Integration
Logger
Preventing Blocked HTTP Traffic with CNAME
Linting Data Plans
Troubleshooting the Android SDK
API Reference
Upgrade to Version 5
Cordova Plugin
Identity
Direct URL Routing FAQ
Web
Android
iOS
Initialization
Configuration
Event Tracking
User Attributes
IDSync
Screen Tracking
Commerce Events
Location Tracking
Media
Kits
Application State and Session Management
Data Privacy Controls
Error Tracking
Opt Out
Push Notifications
Webview Integration
Upload Frequency
App Extensions
Preventing Blocked HTTP Traffic with CNAME
Linting Data Plans
Troubleshooting iOS SDK
Social Networks
iOS 14 Guide
iOS 15 FAQ
iOS 16 FAQ
iOS 17 FAQ
iOS 18 FAQ
API Reference
Upgrade to Version 7
Getting Started
Identity
Upload Frequency
Getting Started
Opt Out
Initialize the SDK
Event Tracking
Commerce Tracking
Error Tracking
Screen Tracking
Identity
Location Tracking
Session Management
Initialization
Content Security Policy
Configuration
Event Tracking
User Attributes
IDSync
Page View Tracking
Commerce Events
Location Tracking
Media
Kits
Application State and Session Management
Data Privacy Controls
Error Tracking
Opt Out
Custom Logger
Persistence
Native Web Views
Self-Hosting
Multiple Instances
Web SDK via Google Tag Manager
Preventing Blocked HTTP Traffic with CNAME
Facebook Instant Articles
Troubleshooting the Web SDK
Browser Compatibility
Linting Data Plans
API Reference
Upgrade to Version 2 of the SDK
Getting Started
Identity
Web
Alexa
Overview
Step 1. Create an input
Step 2. Verify your input
Step 3. Set up your output
Step 4. Create a connection
Step 5. Verify your connection
Step 6. Track events
Step 7. Track user data
Step 8. Create a data plan
Step 9. Test your local app
Overview
Step 1. Create an input
Step 2. Verify your input
Step 3. Set up your output
Step 4. Create a connection
Step 5. Verify your connection
Step 6. Track events
Step 7. Track user data
Step 8. Create a data plan
Overview
Step 1. Create an input
Step 2. Verify your input
Step 3. Set up your output
Step 4. Create a connection
Step 5. Verify your connection
Step 6. Track events
Step 7. Track user data
Step 8. Create a data plan
Step 1. Create an input
Step 2. Create an output
Step 3. Verify output
Node SDK
Go SDK
Python SDK
Ruby SDK
Java SDK
Introduction
Outbound Integrations
Firehose Java SDK
Inbound Integrations
Compose ID
Glossary
Data Hosting Locations
Migrate from Segment to mParticle
Migrate from Segment to Client-side mParticle
Migrate from Segment to Server-side mParticle
Segment-to-mParticle Migration Reference
Rules Developer Guide
API Credential Management
The Developer's Guided Journey to mParticle
Create an Input
Start capturing data
Connect an Event Output
Create an Audience
Connect an Audience Output
Transform and Enhance Your Data
The new mParticle Experience
The Overview Map
Introduction
Data Retention
Connections
Activity
Live Stream
Data Filter
Rules
Tiered Events
mParticle Users and Roles
Analytics Free Trial
Troubleshooting mParticle
Usage metering for value-based pricing (VBP)
Introduction
Sync and Activate Analytics User Segments in mParticle
User Segment Activation
Welcome Page Announcements
Project Settings
Roles and Teammates
Organization Settings
Global Project Filters
Portfolio Analytics
Analytics Data Manager Overview
Events
Event Properties
User Properties
Revenue Mapping
Export Data
UTM Guide
Data Dictionary
Query Builder Overview
Modify Filters With And/Or Clauses
Query-time Sampling
Query Notes
Filter Where Clauses
Event vs. User Properties
Group By Clauses
Annotations
Cross-tool Compatibility
Apply All for Filter Where Clauses
Date Range and Time Settings Overview
Understanding the Screen View Event
Analyses Introduction
Getting Started
Visualization Options
For Clauses
Date Range and Time Settings
Calculator
Numerical Settings
Assisted Analysis
Properties Explorer
Frequency in Segmentation
Trends in Segmentation
Did [not] Perform Clauses
Cumulative vs. Non-Cumulative Analysis in Segmentation
Total Count of vs. Users Who Performed
Save Your Segmentation Analysis
Export Results in Segmentation
Explore Users from Segmentation
Getting Started with Funnels
Group By Settings
Conversion Window
Tracking Properties
Date Range and Time Settings
Visualization Options
Interpreting a Funnel Analysis
Group By
Filters
Conversion over Time
Conversion Order
Trends
Funnel Direction
Multi-path Funnels
Analyze as Cohort from Funnel
Save a Funnel Analysis
Explore Users from a Funnel
Export Results from a Funnel
Saved Analyses
Manage Analyses in Dashboards
Dashboards––Getting Started
Manage Dashboards
Dashboard Filters
Organize Dashboards
Scheduled Reports
Favorites
Time and Interval Settings in Dashboards
Query Notes in Dashboards
User Aliasing
The Demo Environment
Keyboard Shortcuts
Analytics for Marketers
Analytics for Product Managers
Compare Conversion Across Acquisition Sources
Analyze Product Feature Usage
Identify Points of User Friction
Time-based Subscription Analysis
Dashboard Tips and Tricks
Understand Product Stickiness
Optimize User Flow with A/B Testing
User Segments
IDSync Overview
Use Cases for IDSync
Components of IDSync
Store and Organize User Data
Identify Users
Default IDSync Configuration
Profile Conversion Strategy
Profile Link Strategy
Profile Isolation Strategy
Best Match Strategy
Aliasing
Overview
Create and Manage Group Definitions
Introduction
Catalog
Live Stream
Data Plans
Blocked Data Backfill Guide
Predictive Attributes Overview
Create Predictive Attributes
Assess and Troubleshoot Predictions
Use Predictive Attributes in Campaigns
Predictive Audiences Overview
Using Predictive Audiences
Introduction
Profiles
Warehouse Sync
Data Privacy Controls
Data Subject Requests
Default Service Limits
Feeds
Cross-Account Audience Sharing
Approved Sub-Processors
Import Data with CSV Files
CSV File Reference
Glossary
Video Index
Single Sign-On (SSO)
Setup Examples
Introduction
Introduction
Introduction
Rudderstack
Google Tag Manager
Segment
Advanced Data Warehouse Settings
AWS Kinesis (Snowplow)
AWS Redshift (Define Your Own Schema)
AWS S3 Integration (Define Your Own Schema)
AWS S3 (Snowplow Schema)
BigQuery (Snowplow Schema)
BigQuery Firebase Schema
BigQuery (Define Your Own Schema)
GCP BigQuery Export
Snowflake (Snowplow Schema)
Snowplow Schema Overview
Snowflake (Define Your Own Schema)
Aliasing
Event
Event
Audience
Audience
Feed
Event
Audience
Cookie Sync
Event
Audience
Audience
Audience
Event
Event
Feed
Event
Audience
Event
Data Warehouse
Event
Event
Event
Event
Audience
Event
Event
Event
Event
Event
Event
Audience
Event
Event
Feed
Event
Event
Audience
Feed
Event
Event
Event
Custom Feed
Data Warehouse
Event
Event
Audience
Audience
Audience
Audience
Event
Event
Event
Event
Event
Event
Audience
Audience
Event
Audience
Data Warehouse
Event
Event
Audience
Cookie Sync
Event
Event
Event
Event
Event
Feed
Feed
Event
Event
Event
Audience
Event
Event
Audience
Event
Event
Event
Feed
Audience
Event
Event
Audience
Audience
Event
Audience
Audience
Audience
Event
Audience
Event
Event
Event
Event
Feed
Event
Event
Event
Event
Event
Feed
Audience
Event
Event
Event
Feed
Event
Event
Event
Event
Event
Feed
Audience
Event
Event
Event
Event
Custom Pixel
Feed
Event
Event
Event
Audience
Event
Event
Data Warehouse
Event
Event
Audience
Audience
Audience
Event
Audience
Audience
Cookie Sync
Event
Audience
Feed
Audience
Event
Event
Audience
Audience
Event
Event
Event
Event
Audience
Cookie Sync
Cookie Sync
Audience
Audience
Feed
Button is the mobile commerce platform that maximizes the value of every tap. Through higher-converting technology, Button embeds commerce inside publisher apps so that brands can grow their mobile business.
mParticle automatically sends all app and website install events, eCommerce events, as well as device and user ids to the Button API via a server-side integration. This allows any data to be sent to Button regardless of whether it originated from mParticle’s client-side SDKs or Events API. It’s common for mParticle customers to use mParticle’s client SDKs as well as server-api where it makes sense for their infrastructure.
However, the mParticle client SDKs will automatically collect the btn_ref
associated with a particular user session. This ID will be sent to Button alongside persistent user cookies and credentials, such that the Button platform can accurately attribute app and site actions to campaigns. For this reason, the Button integration requires the inclusion of the mParticle client SDKs in your apps.
For a complete integration with Button, you will need the following:
btn_ref
for the session as an integration attribute.Connect your iOS, Android, and/or web workspaces to Button. You will need to input your Button Application ID, which you can access from your organization’s Button dashboard (login required). For more information on setting up a new mParticle connection, see the Platform Guide.
Setting Name | Data Type | Default Value | Description |
---|---|---|---|
Application ID | string |
A Button specified unique key for each of your device types. |
Button requires the reporting of eCommerce orders via mParticle’s eCommerce APIs. mParticle’s integration with the Button API has similar requirements as documented by Button.
Follow the mParticle integration guides for your platform to learn how to collect eCommerce events:
mParticle will automatically forward all Commerce Event “product action” types to Button, but you should use the PURCHASE
product action to signify an order.
The following parameters are required:
The following are optional:
Individual Products: An array of line item details of your order, including:
Although the iOS and Android SDKs will automatically populate the button referrer token for you, on Web you will need to parse the referrer token from the URL and set it as an integration attribute, using mParticle’s setIntegrationAttribute()
method.
mParticle.setIntegrationAttribute(
"1022", // the mParticle module ID for Button
"srctok-XXX" // the Button referrer token
)
Using the same mParticle client or server APIs documented above, use the REFUND
product action to signify a cancellation.
The following parameters are required:
You can test the integration by performing the following actions in development mode, and following along in the mParticle live stream. You should see the following as both inbound and outbound data to Button, for each mParticle workspace connection:
btn_ref
within each Application State Transition message, specifically within the “launch referrer” property.In partnership with Button, mParticle also provides optional, add-on “kit” libraries for iOS and Android. The libraries serve two purposes:
btn_ref
of the current session. Querying for this should generally not be required, as mParticle will automatically send the current btn_ref
to the Button API for all events.mParticle publishes the Button kit as separate iOS and Android libraries which have a transitive dependency on the mParticle core libraries. You can add them to your app by via Cocoapods and Gradle:
# Sample Podfile
source 'https://github.com/CocoaPods/Specs.git'
target '<Your Target>' do
pod 'mParticle-Apple-SDK', '~> 6.15.4'
pod 'mParticle-Button', '~> 6.15.4'
end
// Sample build.gradle
dependencies {
// Ensure the Kit version matches that of the mParticle Core SDK that you're using
compile 'com.mparticle:android-button-kit:4.16.2'
}
For reference, the source code for the kits is available on Github:
The mParticle Android SDK provides a deep link API that you can use to query Button and customize your app experience based on the parameters of deep links. Refer to the deep linking section of the Android and iOS SDKs to learn how to use these APIs. Rather than making direct API calls to the Button SDK, this API let you write integration-agnostic apps that are easier to maintain.
In some cases, it may be necessary to collect the btn_ref
of the current session if present. See the code samples below for how to extract the token, which you can then forward along to your back-end and to Button’s API.
//at the time of a purchase
MPIButton *button = [[MParticle sharedInstance] kitInstance:MPKitInstanceButton];
if (button) {
//access the token
button.referrerToken
}
final ButtonKit button = (ButtonKit) MParticle.getInstance().getKitInstance(MParticle.ServiceProviders.BUTTON);
if (button != null) {
//access the token
button.getReferrerToken();
}