MoEngage
Contents
Objective
Forwarding events from MoEngage to PostHog.
Why is this useful?
MoEngage is a customer engagement platform that helps you understand customer behavior and engage with them across multiple channels. By integrating MoEngage with PostHog, you can:
- Forward events tracked in MoEngage to your PostHog dashboard
- Analyze customer engagement data alongside your product analytics
- Create a unified view of customer interactions across platforms
- Build cohorts and analyze user behavior based on MoEngage engagement events
Prerequisites
To follow this tutorial, you should:
- Have a PostHog account (Cloud or self-hosted)
- Have a MoEngage account with access to Connector Campaigns
Step-by-step instructions
Creating a Connector Campaign in MoEngage
- Log in to your MoEngage dashboard.
- Navigate to Create Campaign > Connectors > Custom.
- Choose the delivery type that suits your needs:
- Event Triggered: Fires when a specific event occurs
- Periodic: Runs on a schedule
- Select the event that will trigger the campaign (e.g., "Purchased", "App Opened").
Configuring the PostHog connector
In the connector configuration, set up the HTTP request:
- Method:
POST - URL: Your PostHog capture endpoint
- PostHog Cloud US:
https://us.posthog.com/capture/ - PostHog Cloud EU:
https://eu.posthog.com/capture/ - Self-hosted:
https://your-instance.com/capture/
- PostHog Cloud US:
- Method:
Add the following headers:
- Content-Type:
application/json
- Content-Type:
Configure the request body with your event data:
Replace the placeholders:
{{user_id}}: MoEngage user attribute for the distinct ID{{campaign_name}}: The MoEngage campaign name variable{{email}}: User's email address (or other relevant attributes)
Mapping event data
You can include any MoEngage user attributes or event properties in your PostHog event. Common mappings include:
| MoEngage Variable | PostHog Property | Description |
|---|---|---|
{{user_id}} | distinct_id | Unique user identifier |
{{email}} | properties.email | User email |
{{first_name}} | properties.first_name | User's first name |
{{event_name}} | event | Name of the triggered event |
{{campaign_name}} | properties.campaign_name | MoEngage campaign name |
Testing the integration
- In MoEngage, use the Test feature to send a test event.
- Verify the event appears in your PostHog Activity tab.
- Check that all properties are correctly mapped.
- Once confirmed, activate the campaign.
Example: Tracking purchase events
To forward purchase events from MoEngage to PostHog:
- Create an Event Triggered Connector Campaign.
- Set the trigger to the "Purchased" event.
- Configure the request body:
Sending user properties
To update user properties in PostHog, you can also send identify calls:
FAQ
Where can I find out more?
Check PostHog's API documentation for more information on the capture endpoint. Further information about the integration is available in MoEngage's documentation.
Who maintains this integration?
This integration uses MoEngage's Connector Campaigns feature with PostHog's API. If you have issues with the integration, please let us know!
What if I have feedback on this integration?
We love feature requests and feedback! Please tell us what you think!
Can I use this with a self-hosted PostHog instance?
Yes! Simply use your self-hosted instance URL as the capture endpoint in the connector configuration.
What if my question isn't answered above?
We love answering questions. Ask us anything via our community forum, or drop us a message.