Segment integration
Combine your behavioral analytics with your financial data by connecting Mantle with Segment. This connection allows you to send app activity and customer events to your Segment dashboard, giving you a detailed and consolidated view of your customer events.
You can also send data from Segment to Mantle, allowing you to consolidate all of your customer usage data in one place.
Benefits of Usage Events in Mantle
By connecting Mantle with Segment, you can leverage various usage events to gain deeper insights and enhance your operations:
- Customer insights: Track detailed customer interactions and behaviors in Mantle’s Customer View, alongside all other data, providing comprehensive visibility and powerful insights.
- Enhanced reporting: Access consolidated usage data reports for better analysis.
- Automated billing: Use usage data for automated billing processes, such as charging based on usage or triggering plan upgrades.
- Custom metrics: Create custom metrics from usage events for comprehensive analysis.
Sending events from Segment to Mantle
Setting source and destination
To send usage events, you’ll need to configure:
- Source: Any source you’d like to use for collecting your usage data. If you’re using Segment already, you likely have a source set up. If you haven’t, here is how to set up a source in Segment.
- Destination: Set your Mantle account as the destination by adding it here.
After adding Mantle as the destination, you’ll be prompted to select the data source from which you want to send events:
Once you select your data source, you’ll be prompted to enter your Mantle API credentials to connect your Mantle account:
If you already have a Mantle App ID and API key, add them. If not, follow these steps to create one:
- Log into your Mantle account.
- Select the app for which you want to create an API key.
- Go to Settings.
- Click Add on the API keys card.
Once set up, your Segment connection screen should display your source connected to your Mantle account as the destination:
Mappings
Now that the source and destination are set, ensure you correctly map the fields between the two datasets so they match when being pushed.
Navigate to Destinations and click Mappings, from there click New Mapping.
Mapping configuration:
- Set the event type for the mapping to Track.
- The event field from the source should map automatically to Event Name for the destination.
- Map shop from the source (properties.shop) to Customer ID in Mantle to ensure correct customer matching.
- The messageid from the source should map automatically to Event ID.
Once these mappings are set, send a test event at the bottom of the page to ensure everything is working correctly.
If the test event works, you should start seeing new events in your Mantle account under Usage metrics -> Usage events:
Sending events from Mantle to Segment
You can send several events to Segment, including customer installations, uninstalls, reactivations, and subscription changes:
Categories | Activities |
---|---|
App activities | Customer installed app |
Customer uninstalled app | |
Customer installation was deactivated/frozen | |
Customer installation was reactivated | |
Customer reviewed app | |
Subscription activities | Customer subscribed to plan |
Customer unsubscribed from plan | |
Customer upgraded plan | |
Customer downgraded plan | |
Subscription was frozen | |
Subscription was unfrozen |
Configuration steps
- Go to Settings -> Integrations and select Segment.
- Enter your unique Segment write key in the Write key section.
- Choose the specific apps that will trigger notifications.
- Save your configurations to activate the Segment notifications.
- (Optional) To send a custom field from Mantle as the user ID, check the box and select the custom field you want to use.
Once completed, the events you selected will be pushed to your Segment Source associated with the Write key you provided.