Test Campaign
Send a test campaign to specific users or identifiers before launching it to your entire audience.
- PUSH: Test Push notification campaigns
- EMAIL: Test Email campaigns
- You can only test campaigns created via the API, not campaigns created through the MoEngage Dashboard
- For Email: Maximum 10 users can be tested at a time
- If using EMAIL identifier, content will not be personalized with user profile data
- When you pass personalization_details, MoEngage uses those values instead of the user’s actual profile data
- The same personalization values apply to all test recipients
- If you pass only a subset of attributes, remaining values are picked from the user profile
Authorizations
Authentication is done via Basic Auth. The username is your Workspace ID (earlier APP ID) and the password is your API Key. The value is a base64 encoding of 'username:password'.
How to obtain credentials:
- Navigate to Settings → Account → APIs in the MoEngage Dashboard
- Username: Copy the Workspace ID (earlier app id)
- Password: Copy the API key from the Campaign report/Business events/Custom templates tile
Headers
This is the workspace ID (earlier APP ID) of your MoEngage workspace.
You can find your MoEngage Workspace ID in the MoEngage Dashboard: Settings → Account → APIs → Workspace ID (earlier app id)
Body
Test campaign configuration including content and target test users.
- Push Campaign
- Email Campaign
A unique identifier for this test request.
"test_push_12345"
The communication channel (automatically set to PUSH for this tab).
PUSH Contains the basic information about the Push campaign.
Contains the content and variations for the Push campaign.
Metadata for specifying test recipients for Push campaigns.
Override values for personalizing campaign content during testing.
Important
When you pass personalization details, MoEngage uses these values to personalize user/event attributes in the content instead of using actual user profile data.
Response
Test campaign sent successfully
Response after successfully sending a test campaign.
Object containing test results for each identifier.
Each key is an identifier value with its delivery status.
{
"user_12345": { "status": "success" },
"user_67890": {
"status": "failed",
"failure_reason": "User not found"
}
}
A success message.
"Test campaign created successfully"