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
Custom Access Roles API
Data Planning 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
Direct URL Routing FAQ
Web
Android
iOS
Cordova Plugin
Identity
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
Getting Started
Identity
Initialization
Configuration
Content Security Policy
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
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
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
Data Hosting Locations
Glossary
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
Organize Dashboards
Dashboard Filters
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 Audiences Overview
Using Predictive Audiences
Predictive Attributes Overview
Create Predictive Attributes
Assess and Troubleshoot Predictions
Use Predictive Attributes in Campaigns
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
Snowplow Schema Overview
Snowflake (Snowplow Schema)
Snowflake (Define Your Own Schema)
Aliasing
Although the majority of mParticle event integrations are entirely server-side, the mParticle SDK does do some client-side data forwarding. The mParticle SDK works with latest versions of these kits, but just as with other integrations, you are not required to write any client-side code to leverage them.
mParticle supports several kinds of client-side kits:
Partner-hosted kits that have been tested and are fully supported by mParticle:
Refer to the iOS SDK GitHub repository for configuring mParticle-hosted kits with the mParticle SDK into your app.
If you need to access or use a kit method or functionality not covered by the mParticle SDK, you can obtain the respective internal instance by calling the kitInstance
method, passing an enum with the instance you are interested. The method will return the instance in question, or nil/null if the kit is not active.
For the cases where a kit is implemented with class methods, you can call those class methods directly.
#import <AppboyKit.h>
- (void)refreshFeed {
Appboy *appboy = [[MParticle sharedInstance] kitInstance:MPKitInstanceAppboy];
if (appboy) {
[appboy requestFeedRefresh];
}
}
The mParticle SDK only instantiates kits that are configured for your app. Since services can be turned on and off dynamically, if you need to access a kit API directly, you must make sure that the given service is currently active.
You can also verify at any given moment if a kit is active and enabled to be used in your app.
if ([[MParticle sharedInstance] isKitActive:MPKitInstanceAppboy]) {
// Do something
}
The mParticle SDK also allows you to listen for notifications asynchronously, avoiding the need to repeatedly check if a kit is active or inactive.
- (void)awakeFromNib {
[super awakeFromNib];
NSNotificationCenter *notificationCenter = [NSNotificationCenter defaultCenter];
[notificationCenter addObserver:self
selector:@selector(handleKitDidBecomeActive:)
name:mParticleKitDidBecomeActiveNotification
object:nil];
[notificationCenter addObserver:self
selector:@selector(handleKitDidBecomeInactive:)
name:mParticleKitDidBecomeInactiveNotification
object:nil];
}
- (void)dealloc {
NSNotificationCenter *notificationCenter = [NSNotificationCenter defaultCenter];
[notificationCenter removeObserver:self
name:mParticleKitDidBecomeActiveNotification
object:nil];
[notificationCenter removeObserver:self
name:mParticleKitDidBecomeInactiveNotification
object:nil];
}
- (void)handleKitDidBecomeActive:(NSNotification *)notification {
NSDictionary *userInfo = [notification userInfo];
NSNumber *kitNumber = userInfo[mParticleKitInstanceKey];
MPKitInstance kitInstance = (MPKitInstance)[kitNumber integerValue];
if (kitInstance == MPKitInstanceAppboy) {
NSLog(@"Appboy is available for use.");
}
}
- (void)handleKitDidBecomeInactive:(NSNotification *)notification {
NSDictionary *userInfo = [notification userInfo];
NSNumber *kitNumber = userInfo[mParticleKitInstanceKey];
MPKitInstance kitInstance = (MPKitInstance)[kitNumber integerValue];
if (kitInstance == MPKitInstanceAppboy) {
NSLog(@"Appboy is unavailable for use.");
}
}
Several integrations support the creation and attribution of deep links to install and open an app. A deep link will typically contain some additional information to be used when the user ultimately opens your application, so that you can properly route the user to the appropriate content, or otherwise customize their experience.
As at version 7, the mParticle SDKs offer an integration-agnostic Attribution Listener API that lets you query your integrations at runtime to determine if the given user arrived by way of a deep link.
The following integrations support deep linking:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
MParticleOptions *options = [MParticleOptions optionsWithKey:@"<<Your app key>>" secret:@"<<Your app secret>>"];
options.onAttributionComplete = ^void (MPAttributionResult *_Nullable attributionResult, NSError * _Nullable error) {
if (error) {
NSLog(@"Attribution fetching for kitCode=%@ failed with error=%@", error.userInfo[mParticleKitInstanceKey], error);
return;
}
NSLog(@"Attribution fetching for kitCode=%@ completed with linkInfo: %@", attributionResult.kitCode, attributionResult.linkInfo);
}
[[MParticle sharedInstance] startWithOptions:options];
return YES;
}
The types of questions most users have about kits are:
These are two different questions. mParticle defines “support” as - if you can build an app/site with the mParticle SDK and the app compiles, it’s supported.
Therefore, we do not manually test every single version of every single kit.
We only verify that they compile. If the partner breaks their SDK, or our integration with it, it’s possible that we will not know it.
If a partner breaks their SDK/our integration, it typically means they’ve also broken anyone who is directly integrating.
For the Apple SDK, we push version tags of each kit. So every time we release the Apple SDK version x.y.z:
Depending on how customers configure their builds (Cocoapods, Carthage, manual, and variations within each), they could end up mixing different versions of kits - so watch out for that.
However, in the vast majority of cases - if a customer is on x.y.z of the core, they are likely/hopefully on x.y.z of each kit.
Given version x.y.z of a kit, to find the partner SDK version supported, do the following:
Look for the s.ios.dependency line towards the bottom of the file (example). Generally, We depend on the latest minor version of a kit. So the customer can choose which version of the SDK will be used:
Read more about Cocoapod versions here.
In the linked example above, it shows that our SDK, version 7.10.0, supports version ~> 10.1
of the Airship SDK. Per the above rules this means we “support” version 10.1 and later up to but not including 11.0.
Cartfiles are generally very short and easy to read. Look for the partner’s SDK version see this example. Similar to Cocoapods, we will typically pull in the latest minor version. There are some minor differences that you can read about here.
In the linked example above, it shows that our SDK, version 7.10.0, supports version ~> 2.1
of the Radar SDK. This means we “support” version 2.1 and later up to but not including 3.0.
Kits are generally added and configured via the mParticle UI settings. When initializing the app, the mParticle SDK receives the configuration settings from our servers and initializes each kit. When you send events to the mParticle Apple SDK, they are routed to each kit and mapped to a partner SDK method, ultimately arriving in our partners’ dashboards for your analysis. The kits in our UI are either built by mParticle or by partners. When partners build kits, we require careful coordination and updates to our database in order for their kits to work properly within our ecosystem.
However, there may be cases where you’d like to build a custom kit, whether to debug or to quickly send data to a partner SDK for which we do not have an official kit. We support the ability to build your own kit which can receive events without needing any configuration in our UI or database. We call these sideloaded kits. When sideloaded kits are included in your app, they remove the need for settings from our server because you configure the kit yourself and then include it using a public API we provide.
Remember that while mParticle fully supports all official kits located in the “mparticle-integrations” GitHub organization as well as official kits created by our partners, you are responsible for any sideloaded kit you write yourself or include from a third-party source. This responsibility includes the correct handling and protection of user profiles and identities both within your own system as well as any third-party service you may forward that data to.
Be especially cautious with sideloaded kits you may find from third-party repositories. They will potentially receive all events that you log via the mParticle SDK, so you are responsible for ensuring that they handle that data correctly and safely.
Keep in mind that sideloaded kits are completely client-side, so things like data filtering are configured client-side and these options will not be available in the mParticle dashboard. This also means that event forwarding and filtering metrics from sideloaded kits will not be included in the metrics displayed in the mParticle dashboard as they would for official kits.
Our official support channels will be unable to help with issues you may have with your sideloaded kit such as data unavailable downstream, crashes, or unsupported functionality. mParticle support will only be able to help in cases where there is an issue with the mParticle SDK sideloaded kit feature in general.
On iOS/tvOS a sideloaded kit is essentially just a class that implements the MPKitProtocol
protocol. A simple example written in Swift can be found here and the MPKitProtocol
definition can be found here.
There are a few things to keep in mind when developing your kit:
kitCode
must be implemented as it is marked as required in the MPKitProtocol
, however is only used for official mParticle kits. It is unused for sideloaded kits and can return any number, though -1
is recommended for clarity.MPKitProtocol
, Sideloaded kits must implement the sideloadedKitCode
property. In sideloaded kits, this property is used in place of the kitCode
method. If using Swift, it can be initialized to any value as it will be overwritten by the SDK on initialization, though 0
is recommended for clarity. Make sure not to write to this property later as the value is used internally to forward messages to the kit.The sideloaded kit can be included directly in your application’s source code, or can be included as a framework using your favorite package manager such as CocoaPods or SPM.
To register the sideloaded kit, all that’s needed is to create an instance and pass it to the sideloadedKits
property of the MParticleOptions
object:
MParticleOptions *options = [MParticleOptions optionsWithKey:key secret:secret];
SideloadedKit *kit = [[SideloadedKit alloc] init];
options.sideloadedKits = @[kit];
[MParticle.sharedInstance startWithOptions:options];
let options = MParticleOptions(key: key, secret: secret)
let kit = SideloadedKit()
options.sideloadedKits = [kit]
MParticle.sharedInstance().start(with: options)
Note that you may use multiple instances of the same sideloaded kit class, perhaps initialized with different parameters. Each sideloaded kit does not need to be a unique class, only a unique instance.
To add filters to a sideloaded kit you must call the corresponding methods on the SideloadedKit
instance.
Each method allows you to add a different type of filter and each SideLoadedKit
will accept any number or combination of filters.
MParticleOptions *options = [MParticleOptions optionsWithKey:key secret:secret];
SideloadedKit *kit = [[SideloadedKit alloc] init];
[kit addEventTypeFilterWithEventType:MPEventTypeNavigation];
options.sideloadedKits = @[kit];
[MParticle.sharedInstance startWithOptions:options];
let options = MParticleOptions(key: key, secret: secret)
let kit = SideloadedKit()
kit.addEventTypeFilterWithEventType(MPEventTypeNavigation)
options.sideloadedKits = [kit]
MParticle.sharedInstance().start(with: options)
Was this page helpful?