Search documentation...

K

MoEngage

Build more robust campaigns on MoEngage with up-to-date customer data from your data warehouse

Overview

Providing relevant and timely campaigns relies on fresh and accurate data in your MoEngage account. By automatically syncing customer data from your data warehouse into MoEngage, you don't need to worry about data consistency or staleness. Instead, you can focus on building world-class customer experiences.

Getting started

Connect to MoEngage

Retrieve your API Token from MoEngage.

  1. Log in to MoEngage.
  2. Visit MoEngage's API Settings Page.
  3. Copy your Data API ID and your Data API Key.

The API key on the MoEngage dashboard

Add MoEngage as a destination in Hightouch

  1. Log in to Hightouch or create a free Hightouch account
  2. Click on Destinations in the left sidebar
  3. Click on Add destination in the top right corner
  4. Select MoEngage in the destination catalog and click Continue to proceed
  5. Paste your Data API ID and your Data API Key into their respective fields and click Continue to proceed
  6. Give your destination a name and unique slug (for example, MoEngage Production” and MoEngage-production)
  7. Click Finish to create your MoEngage destination.

Connect to your data source

Hightouch sits on top of your data warehouse and can read from Snowflake, Redshift, BigQuery, Databricks, Postgres, MySQL, and many other data sources. You can even fetch data from Google Sheets and Airtable. Hightouch can help activate your data wherever it resides.

We've written dedicated guides for each supported data source. Take your pick:

If you're missing the credentials necessary to connect to your data source, try inviting your teammates to Hightouch. You can have unlimited collaborators in your workspace.

Connect to a sample database instead

Waiting for credentials to your data warehouse? No problem. You can connect to one of our sample databases to get started right away. For the rest of this tutorial, we'll use our demo Postgres database, which contains a users table with names, emails, locations, and other user attributes. This sample source is available when you log in for the first time—no setup required.

Next, we'll write a SQL query to define which users should be synced to our MoEngage customers resource. You can follow the same pattern to sync to other support MoEngage resources,

Create a model

In Hightouch, a model represents a query that filters or transforms the records in your data source. Models are used to determine exactly which records to sync between sources and destinations.

When you connect to a data warehouse, your models will probably be written in SQL. You can also import models from tools like dbt and Looker.

In this example, we'll keep it simple. Suppose you want to sync all your customers to MoEngage. To accomplish this, you'll want to create a model that looks like this:

SELECT * FROM users;
  1. Click on Models in the left sidebar.
  2. Click on Add model in the top right corner.
  3. Select Demo Database as your source and click Continue to proceed.
  4. Select SQL Editor as your modeling method.
  5. Paste the SQL query from above into the editor on the left side of the page.
  6. Click Preview to execute the query.
  7. Click Continue to proceed.
  8. Give your model a name and unique slug (for example, "All Users" and all-users).
  9. Select ID as the primary key for your model.
  10. Click Finish to create your model.

We just created a model using a SQL query that retrieves all our current users. Next, we'll configure our sync to add these users to MoEngage.

Create a sync

  1. Click on Syncs in the left sidebar.
  2. Click on Add sync in the top right corner.
  3. Select All Users as your model and click Continue to proceed.
  4. Select MoEngage as your destination and click Continue to proceed.

Sync configuration

Syncing customers object

Object selection

Hightouch supports syncing to the following MoEngage resources:

  • Customers

Sync modes

This integration supports Upsert.

In Upsert mode, records that aren't found in MoEngage given the provided identifier will be inserted. And existing records will be updated.

Record matching

Records can be matched from your source to your MoEngage workspace by MoEngage Id.

Field mapping

Hightouch allows you to sync columns from your source to the supported MoEngage resources.

Custom field mapping

Hightouch allows you to set custom attributes. Any mappings from this section will be synced as additional attributes. MoEngage expects custom properties to follow a snake_case format.

Delete records

When the Hightouch sync engine recognizes that a record has been removed from your source, you can either:

  • Do Nothing.
  • Clear fields that are being synced in the destination.

Syncing customer events

When syncing events, Hightouch treats any records added to your source as new events and sends them to MoEngage when your sync runs.

To ensure syncs send each event, use a hash function for the event model's primary key . The hash should combine all columns, including member ID, timestamp, etc. See the event sync documentation for more information.

Setting an event name

When creating a sync for events, you can specify the name of the event being tracked. You can either input a static name, or use a column from your model.

Setting an event timestamp

Select a column that is used as the timestamp of when the event happened. If this field is empty, Hightouch will use the time of when the event arrives at the server.

Record matching

Records can be matched from your source to your MoEngage workspace by MoEngage Id.

Field mapping

Hightouch allows you to sync columns from your source to the supported MoEngage resources.

Custom field mapping

Any mappings from this section will be synced as attributes in the event. MoEngage expects custom properties to follow a snake_case format.

Troubleshooting

Common errors

To date, our customers haven't experienced any errors while using the MoEngage destination. If you run into any issues, please reach out to us. We're here to help.

Use the Hightouch debugger

Hightouch provides full visibility into the MoEngage API calls made during each of your sync runs. We recommend reading our article on debugging tips and tricks.

Set up sync alerts

Hightouch can alert you of any sync issues via Slack, PagerDuty, SMS, and/or email. For details, please visit our article on alerting.

Ready to get started?

Jump right in or a book a demo. Your first destination is always free.

Book a demoSign upBook a demo

Need help?

Our team is relentlessly focused on your success. Don't hesitate to reach out!

Feature requests?

We'd love to hear your suggestions for integrations and other features.

On this page

OverviewGetting startedConnect to MoEngageConnect to your data sourceCreate a modelCreate a syncSync configurationSyncing customers objectSyncing customer eventsTroubleshootingCommon errorsUse the Hightouch debuggerSet up sync alerts

Was this page helpful?