MoEngage (Actions) Destination

Introduction

Segment is a customer data platform that helps you collect, clean, and activate your customer data.

If you are already using MoEngage as a Destination on Segment - MoEngage (Actions) Destination provides significant improvements over the Classic Destination.

Benefits of MoEngage (Actions) vs MoEngage Classic

MoEngage (Actions) provides the following benefits over the MoEngage Classic destination:

  • Data Consistency. Data consistency between device-mode and cloud-mode. Earlier, data sent from device and cloud-mode would sometimes be mismatched with duplicated properties - this has now been fixed.
  • Mapping Support. Using MoEngage Actions, you can now map incompatible properties with MoEngage-compatible properties. This significantly reduces your development bandwidth.
  • Region Support. Support across all data clusters. MoEngage provides an option to choose your Data Region where your app is present.
  • Better Configuration. There are additional configurations for the JavaScript integration like custom Service Worker.

Integration

library_add_check

Prerequisites

  • Login credentials for MoEngage and Segment.
  • Installed source and Segment source libraries- The origin of any data sent into Segment, such as mobile apps, websites, or backend servers. You must install the libraries into your app, site, or server before being able to set up a successful Source > Destination flow.

Step 1: Add MoEngage as a destination

  1. Login to your segment app.
  2. On your Segment App Dashboard, click on "Add Destination".
  3. From the Destinations Catalog, search for "MoEngage (Actions)" and click on it.
  4. On the App Description Page, click on "Configure MoEngage (Actions)" button.Step1.png
  5. Select a Data Source and click Next.
  6. On the Setup Page, enter a Destination name, and select how you want to set it up. Click Save when done.Step2.png
    • If you have already integrated with the MoEngage destination before, you can choose to copy the previous settings here.
  7. On the Settings tab, enter the details of your MoEngage App.Step3.png
Field Description
Name Name of the MoEngage destination such as MoEngage prod, MoEngage test, etc
App ID Copy and paste the Workspace ID. The Workspace ID of your MoEngage account is available in the following navigations in the revamped and old UIs:
  1. Revamped UI:  Settings -> Account -> APIs -> Workspace ID.
  2. Old UI: You can find this by navigating to Settings -> App Settings -> APIs -> Data API Settings.

The Data API ID and the Workspace ID of your MoEngage account are the same.

App Key

Copy and paste the App Key. The Data API key of your MoEngage account is available in the following navigations in the revamped and old UIs:

  1. Revamped UI:  Settings -> App Settings -> APIs -> API Keys -> Data
  2. Old UI: You can find this by navigating to Settings -> App Settings -> APIs -> Data API Settings.
End point region

This is your MoEngage data center. Read more.

  1. Enable the toggle option to Enable destination and click Save changes.

Step 2 - Enable mappings - Track and Identify

MoEngage (Actions) Destination now has support for Data Mapping which improves on classic destinations by enabling you to see and control how Segment sends the event data it receives from your sources to MoEngage. Each Action in MoEngage (Actions) Destination lists the event data it requires, and the event data that is optional.

You can also choose which event types, event names, or event property values trigger an Action. These Triggers and mappings make it possible to send different versions of the Action, depending on the context from which it is triggered.

Read more about the difference between Classic Destinations and Destination Actions here.

Step4.png

To use mappings, go to the Mappings tab and click on New Mapping.

MoEngage (Actions) provides two Actions: Identify and Track.

Add Identify User mapping

info

Info

MoEngage supports importing both Registered and Anonymous Users via Cloud Mode. Make sure to pass at least one of User ID or Anonymous ID.

  1. Select Identify User
    Step5.png
  2. You can define the event triggers as per your need, or keep the default condition MoEngage has provided.
  3. You can click on "Test Event" and Segment will try to fetch a recent event that matches your trigger conditions.
  4. In the "Define mappings" step, MoEngage provides preset values for all mappings - so you can scroll down and optionally test your connection. Click save when you're sure everything works properly. Make sure that these values remain the same:
    Step6.png

Update existing users only

When making an Identity call, you have the option to choose whether to create new users in MoEngage or not. If you select the 'Update existing users only' option and the forwarded user is not already present in MoEngage, then a new user will not be created. If set to "Yes" (true), only the properties of existing users will be updated.

Add Track Event Action

Under the Mappings tab, click on "New Mapping" and select "Track Event".

Step7.png

  1. You can define the event triggers as per your need, or keep the default condition MoEngage has provided.
  2. You can click on "Test Event" and Segment will try to fetch a recent event that matches your trigger conditions.
  3. In the "Define mappings" step, MoEngage provides preset values for all mappings - so you can scroll down and optionally test your connection. Click save when you're sure everything works properly. Make sure that these values remain the same:
    Step6.png

Make sure that status is Enabled for both the mappings. If not, you can enable these by changing the toggle in the status column.

Step8.png

Step 3 - Test integration

  1. Go to Event Tester tab on the segment dashboard 
  2. Test for Track and Identify methods and make sure that you are getting success status here.Step9.png
  3. If successful the data would start flowing into your MoEngage account in 3-5 minutes. You can log in to your MoEngage dashboard and go to Test & Debug >> Recent events to verify.

Migration from the classic MoEngage destination

warning

Segment's Analytics.js 2.0 Required

MoEngage (Actions) Destination requires features found in Segment's Analytics.js 2.0. If you are using Web actions and have connected MoEngage (Actions) Destination to a javascript Source, upgrade your Analytics.js (provided by Segment) to ensure compatibility.

 

Previous

Next

Was this article helpful?
0 out of 0 found this helpful

How can we improve this article?