Skip to main content

Overview

The MoEngage Cohort Sync API allows you to synchronize cohorts or audiences created in your own ecosystem directly with MoEngage. This server-to-server integration enables you to add or remove users from custom segments dynamically, ensuring your marketing campaigns always target the most relevant audience. The Cohort Sync API performs the following functions:
  • Automated Segment Creation: Automatically creates a custom segment in MoEngage if it doesn’t already exist.
  • Dynamic Membership: Real-time updates to segments so that scheduled campaigns engage the latest set of users.
  • No Middleware Needed: Direct server-to-server calls remove the need for manual CSV uploads or hosting external URLs.
The Cohort Sync API only matches users already present in MoEngage based on the User ID (uid) provided. This API does not create new user profiles.

Cohort Sync Endpoints

The Cohort Sync suite provides a single, high-performance endpoint for membership management:

User Resolution

The API identifies existing user profiles in MoEngage using the following logic:
  • Primary Identifier: The API relies on the User ID (uid).
  • Profile Matching: The uid in your request must match the Unique User ID set in MoEngage (typically the ID used for logged-in users).
  • Cross-Device Consistency: Since devices are associated with a single User ID, updates apply to the user profile regardless of the device they are using.

Constraints & Limits

To ensure optimal performance, please adhere to the following technical constraints:
ConstraintLimit
Request Frequency300 requests per minute (RPM)
Max Payload Size128 KB
BatchingOne cohort action per request (multiple UIDs supported)

Implementation Notes

Cohort Naming Convention:Ensure your cohort_name starts with a period (.) and does not contain restricted characters such as |, *, ?, \, :, <, >, =, $, or ".Payload Efficiency:This API is designed for high-frequency, smaller batches. If you need to sync millions of users at once, consider using the MoEngage Bulk Upload features.

FAQs

The Cohort Sync API enables the creation of segments without needing separate files or CSVs, eliminating the requirement for a separate path or URL as seen in the File Segment API. Segment creation can be initiated by making a direct server-to-server call, eliminating the additional steps required for generating user files.
The Cohort Sync API does not create new users in MoEngage. Instead, it resolves existing users in MoEngage based on predefined user identifiers and assigns them to the corresponding custom segment created through Cohort Sync.

Postman Collections

We have made it easy for you to test the Cohort Sync APIs. View Postman Collection →