basic_details, which carries identifying metadata, platform targeting, and platform-specific delivery flags, and campaign_content, which defines the message payload per channel, platform, and template type, including multi-locale and A/B variation support. Both components are used by Create Campaign and Update Campaign.
For audience targeting, scheduling, and delivery controls, see Audience and delivery reference.
The OpenAPI spec at
/api/campaigns/campaign-draft.yaml is the authoritative source for field types, enums, and required markers. This page adds runnable variants and conditional rules not expressible in inline schema descriptions.Quick start
The minimum content payload is a single channel-platform-template combination undercampaign_content.content.push (Push) or an html_content or custom_template_id value under campaign_content.content.email (Email).
Page contents
| Section | Location in request body |
|---|---|
| Push campaign metadata | basic_details on a Push request |
| Email campaign metadata | basic_details on an Email request |
| Content payload structure | campaign_content.content |
| Android push content | campaign_content.content.push.android |
| iOS push content | campaign_content.content.push.ios |
| Web push content | campaign_content.content.push.web |
| Email content | campaign_content.content.email |
| A/B test variations | campaign_content.variation_details |
| Email delivery connector | connector (Email requests only) |
| Validation rules | Cross-cutting rules enforced at validate or publish |
| Updating an existing campaign | Per-state restrictions for PATCH /v5/campaigns/{campaign_id} |
Push campaign metadata
Thebasic_details object on a Push campaign carries identifying metadata, platform targeting, and platform-specific delivery flags. All fields are optional at creation. A subset becomes required based on campaign_delivery_type.
| Field | Type | Notes |
|---|---|---|
name | string | The campaign name shown in the dashboard. |
business_event | string | The business event mapped to the campaign. Required when campaign_delivery_type is BUSINESS_EVENT_TRIGGERED. |
tags | array of string | Free-form context tags. |
team | string | The team collaborating on the campaign. See Teams in MoEngage. |
platforms | array of string | Target platforms. Enum: ANDROID, IOS, WEB. |
broadcast_live_activity_id | string | The broadcast Live Activity ID for iOS Live Activities. BROADCAST_LIVE_ACTIVITY is not supported through draft creation. Refer to Validation rules. |
geofences | object | Required when campaign_delivery_type is LOCATION_TRIGGERED. The full schema is at Geofence targeting. |
send_to_triggered_platform_only | boolean | Applicable to event-triggered campaigns. When true, the campaign sends only to the platform that fired the trigger. |
platform_specific_details | object | Platform-level delivery flags. See Platform-specific delivery flags. |
Platform-specific delivery flags
Theplatform_specific_details object carries per-platform delivery flags for Push campaigns.
- Android
- iOS
A single Push Amp+ flag is defined for Android.
| Field | Type | Default | Notes |
|---|---|---|---|
push_amp_plus_enabled | boolean | false | Whether Push Amp+ is enabled for the campaign. |
Email campaign metadata
Thebasic_details object on an Email campaign carries identifying metadata, subscription category, and the recipient-email attribute.
| Field | Type | Notes |
|---|---|---|
name | string | The campaign name. |
business_event | string | The business event mapped to the campaign. Required when campaign_delivery_type is BUSINESS_EVENT_TRIGGERED. |
content_type | string | The type of content. Enum: PROMOTIONAL, TRANSACTIONAL. |
subscription_category | string | The subscription category for promotional emails. Required when content_type is PROMOTIONAL. |
tags | array of string | Free-form context tags. |
team | string | The team collaborating on the campaign. |
user_attribute_identifier | string | The user attribute that stores the recipient email address. Default: Email (Standard). The internal identifier MOE_EMAIL_ID is also accepted. |
Content payload structure
Thecampaign_content.content object accepts two shapes. The shape depends on whether locales or A/B test variations are configured on the campaign.
Flat shape (no locales, no variations)
A flat object directly undercontent: push for Push campaigns, email for Email campaigns.
Locale-keyed and variation-keyed shape
When locales or A/B test variations are configured,content is keyed first by locale name and then by variation name. The shape is content[locale_name][variation_name] = { push: { ... } } for Push, and content[locale_name][variation_name] = { email: { ... } } for Email.
- The
"default"locale key is always required. It serves as the fallback for users not matched to a named locale. - Additional locale keys must each match a value listed in
campaign_content.locales(for example,"en-US","es-ES"). The"default"locale is implicitly present and must not be listed incampaign_content.locales. - The variation key (for example,
"variation_1") corresponds to the count invariation_details.no_of_variations. When no A/B test is configured,"variation_1"is used as the only key.
Android push content
campaign_content.content.push.android (flat shape) or content[locale][variation].push.android (locale/variation shape). Accepted template_type values for Android:
BASIC, STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT, TIMER, TIMER_WITH_PROGRESS_BAR, Custom.
| Sub-object | Schema | When used |
|---|---|---|
basic_details | Android basic details fields | Always. Title, message, image, click action, and template-specific fields. |
timer | Android timer fields | Required for TIMER and TIMER_WITH_PROGRESS_BAR. |
buttons | array of Android button fields | Optional. Action buttons. |
advanced | Android advanced fields | Optional. TTL, sticky/dismiss behavior, group key. |
template_backup | Android template backup fields | Required for STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT, TIMER, TIMER_WITH_PROGRESS_BAR. |
custom_template_id | string | Required when template_type is Custom. |
custom_template_version | integer | Optional. The custom template version. |
Android template variants
- BASIC
- STYLIZED_BASIC
- SIMPLE_IMAGE_CAROUSEL
- TIMER
- TIMER_WITH_PROGRESS_BAR
- Custom
The default template. Carries title, message, and an optional image or GIF.
input_gif_url is supported on BASIC to render a GIF in place of a static image.Android basic details fields
AndroidBasicDetails collects template-specific styling and click-action fields. Several fields apply only to specific templates.
| Field | Type | Supported templates |
|---|---|---|
notification_channel | string | All. The Android notification channel where the push is delivered. |
title | string | All. The notification title. |
message | string | All. The body. HTML formatting is allowed. |
summary | string | All. Summary text below the body. |
image_url | URI | All (where supported by the template). |
input_gif_url | URI | BASIC. A GIF rendered in the notification body. |
default_click_action | enum | All. DEEPLINKING, NAVIGATE_TO_A_SCREEN, or RICH_LANDING. |
default_click_action_value | string | All. The URL or deep link target for the click action. |
key_value_pairs | array of { key, value } | All. Custom payload keys forwarded to the SDK. |
background_color_code | hex string | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT. |
app_name_color_code | hex string | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT. |
notification_control_color | enum | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT. LIGHT or DARK. |
apply_background_color_in_text_editor | boolean | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT. |
include_app_name_and_time | boolean | IMAGE_BANNER_WITH_TEXT. Renders the app name and timestamp on the banner. |
include_title_and_message | boolean | IMAGE_BANNER_WITH_TEXT. Overlays the title and message on the banner. |
banner_image_url | URI | Required for IMAGE_BANNER_WITH_TEXT. |
collapsed_push_notification | string | IMAGE_BANNER_WITH_TEXT. Configuration for the collapsed view. |
image_scaling | enum | SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT. FIT_INSIDE_IMAGE_CONTAINER or FILL_IMAGE_CONTAINER. |
carousel_content | object | Required for SIMPLE_IMAGE_CAROUSEL. See Android carousel content. |
Android carousel content
Configuration for the image carousel used bySIMPLE_IMAGE_CAROUSEL on Android.
| Field | Type | Notes |
|---|---|---|
slider_transition | enum | manual or automatic (lowercase). |
slide_data[].image_url | URI | The image for the slide. |
slide_data[].image_click_action | enum | DEEPLINKING, RICH_LANDING, or NAVIGATE_TO_A_SCREEN. |
slide_data[].image_click_action_value | string | Required when image_click_action is provided. |
slide_data[].key_value_pairs | array of { key, value } | Optional per-slide custom payload keys. |
Android timer fields
AndroidTimer is required for TIMER and TIMER_WITH_PROGRESS_BAR.
| Field | Type | Notes |
|---|---|---|
timer_ends_at | enum | DURATION, SPECIFIC_TIME_USER_TIMEZONE, or SPECIFIC_TIME_CAMPAIGN_TIMEZONE. |
specific_time | date-time | Required when personalized_value is true. |
time_period | string | Required when timer_ends_at is SPECIFIC_TIME_USER_TIMEZONE or SPECIFIC_TIME_CAMPAIGN_TIMEZONE. |
personalized_value | boolean | When false, the same duration applies to all users. |
duration_hour | string | The number of hours the timer runs. Required when personalized_value is false. |
duration_minute | string | The additional number of minutes the timer runs. Required when personalized_value is false. |
Android button fields
Each entry inbuttons is an AndroidButton.
| Field | Type | Notes |
|---|---|---|
btn_name | string | The visible button label. |
click_action_type | enum | One of DEEPLINKING, NAVIGATE_TO_A_SCREEN, RICH_LANDING, CALL, SHARE, COPY, SET_USER_ATTRIBUTE, TRACK_EVENT, CUSTOM_ACTION, SNOOZE, REMIND_LATER. |
click_action_name | string | The named action for SET_USER_ATTRIBUTE, TRACK_EVENT, or CUSTOM_ACTION. |
click_action_value | string | The URL, deep link, attribute value, or event name (depending on click_action_type). |
key_value_pairs | array of { key, value } | Per-button custom payload keys. |
Android advanced fields
AndroidAdvanced collects platform-level delivery flags.
| Field | Type | Notes |
|---|---|---|
coupon_code | string | Coupon code carried in the payload. |
icon_type_in_notification | string | The icon type label. |
use_large_icon | boolean | Whether to use the large icon. |
make_notification_sticky | boolean | When true, the user cannot swipe the notification away. |
dismiss_button_text | string | Required when make_notification_sticky is true or auto_dismiss_notification is true. |
auto_dismiss_notification | boolean | Whether the notification can be auto-dismissed. |
auto_dismiss_notification_time_value | integer | Required when auto_dismiss_notification is true. |
auto_dismiss_notification_time_granularity | enum | DAYS, HOURS, or MINUTES. Required when auto_dismiss_notification is true. |
group_key | string | The group key for related notifications. MoEngage truncates to 45 characters and strips non-Latin scripts, special characters, and spaces. |
collapse_replace_key | string | The update key for notifications that replace each other. |
Android template backup fields
AndroidTemplateBackup defines the fallback notification rendered when the template cannot be displayed (for example, on older Android versions). Required for STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT, TIMER, and TIMER_WITH_PROGRESS_BAR.
| Field | Type | Notes |
|---|---|---|
title | string | Fallback title. |
message | string | Fallback body. |
summary | string | Fallback summary. |
image_url | URI | Fallback image. |
default_click_action | enum | DEEPLINKING, NAVIGATE_TO_A_SCREEN, or RICH_LANDING. |
default_click_action_value | string | Fallback click action target. |
key_value_pairs | array of { key, value } | Per-fallback custom payload keys. |
iOS push content
campaign_content.content.push.ios. Accepted template_type values for iOS:
BASIC, STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, Custom.
| Sub-object | Schema | When used |
|---|---|---|
basic_details | iOS basic details fields | Always. |
buttons | array of iOS button fields | Optional. iOS button categories. |
advanced | iOS advanced fields | Optional. Custom sound, badge, group key. |
template_backup | iOS template backup fields | Required for STYLIZED_BASIC and SIMPLE_IMAGE_CAROUSEL. |
custom_template_id | string | Required when template_type is Custom. |
custom_template_version | integer | Optional. |
iOS template variants
- BASIC
- STYLIZED_BASIC
- SIMPLE_IMAGE_CAROUSEL
- Custom
rich_media_type (Image, Video, or GIF, in title case) with rich_media_value (the URL). input_gif_url is supported on BASIC and STYLIZED_BASIC.iOS basic details fields
| Field | Type | Supported templates |
|---|---|---|
title | string | All. |
message | string | All. |
subtitle | string | All. Rendered below the title. |
default_click_action | enum | All. DEEPLINKING, NAVIGATE_TO_A_SCREEN, or RICH_LANDING. |
default_click_action_value | string | All. |
key_value_pairs | array of { key, value } | All. |
allow_bg_refresh | boolean | All. Whether the app can be woken in the background to refresh content. |
rich_media_type | enum | BASIC. Image, Video, or GIF (title case). |
rich_media_value | URI | BASIC. The media asset URL. |
input_gif_url | URI | BASIC, STYLIZED_BASIC. A GIF URL. |
image_url | URI | All. Required when template_type is SIMPLE_IMAGE_CAROUSEL. |
background_color_code | hex string | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL. |
apply_background_color_in_text_editor | boolean | STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL. |
carousel_content | object | Required for SIMPLE_IMAGE_CAROUSEL. See iOS carousel content. |
iOS carousel content
| Field | Type | Notes |
|---|---|---|
slider_transition | enum | MANUAL or AUTOMATIC (uppercase, differs from Android). |
slide_data[].image_url | URI | The image for the slide. |
slide_data[].image_click_action | enum | DEEPLINKING, RICH_LANDING, or NAVIGATE_TO_A_SCREEN. |
slide_data[].image_click_action_value | string | The target for the slide click. |
slide_data[].key_value_pairs | array of { key, value } | Per-slide custom payload keys. |
iOS button fields
iOS buttons use a category-based model. Buttons are pre-defined in the app, and the campaign references the category by name.| Field | Type | Notes |
|---|---|---|
button_category | string | The pre-defined category name configured in the app (for example, MOE_PUSH_TEMPLATE). |
iOS advanced fields
| Field | Type | Notes |
|---|---|---|
coupon_code | string | Coupon code carried in the payload. |
sound_file | string | The name of a custom sound file in the app bundle. |
enable_ios_badge | boolean | Whether the campaign increments the app’s badge count. |
group_key | string | The group key for related notifications. Truncated to 45 characters; non-Latin scripts, special characters, and spaces are stripped. |
collapse_replace_key | string | The update key for notifications that replace each other. |
iOS template backup fields
Required forSTYLIZED_BASIC and SIMPLE_IMAGE_CAROUSEL.
| Field | Type | Notes |
|---|---|---|
title | string | Fallback title. |
message | string | Fallback body. |
subtitle | string | Fallback subtitle. |
allow_bg_refresh | boolean | Whether to enable background app refresh for the fallback. |
rich_media_type | enum | Image, Video, or GIF. |
rich_media_value | URI | The media URL. |
default_click_action | enum | DEEPLINKING, NAVIGATE_TO_A_SCREEN, or RICH_LANDING. |
default_click_action_value | string | The click target. |
key_value_pairs | array of { key, value } | Per-fallback custom payload keys. |
Web push content
campaign_content.content.push.web. Web push currently supports only template_type: BASIC.
Web basic details fields
| Field | Type | Notes |
|---|---|---|
title | string | The notification title. |
message | string | The notification body. |
redirect_url | URI | The URL opened on click of the notification body. |
image_url | URI | Optional large image. |
auto_dismiss_notification | boolean | Whether the notification auto-dismisses. |
Web button fields
Each entry inbuttons is a WebButton.
| Field | Type | Notes |
|---|---|---|
title | string | The button label. |
icon_url | URI | Optional icon displayed next to the label. |
url | URI | The destination opened on click of the button. |
Web advanced fields
| Field | Type | Notes |
|---|---|---|
icon_image_type | enum | DEFAULT or ICON_URL. |
icon_url | URI | The custom icon URL. Required when icon_image_type is ICON_URL. |
Email content
campaign_content.content.email carries the email message. Two mutually compatible content sources are supported: raw HTML in html_content, or a saved template referenced by custom_template_id. At least one of these must be present.
| Field | Type | Notes |
|---|---|---|
subject | string | The subject line. |
preview_text | string | The preview text shown in inbox listings. |
sender_name | string | The display name of the sender. |
from_address | The sender email address. | |
reply_to_address | The reply-to address. | |
cc_ids | array of email | CC recipients. |
bcc_ids | array of email | BCC recipients. |
html_content | string | The raw HTML body. Optional when custom_template_id is provided. |
email_editor | enum | Froala Editor or Ace Editor. Required when the campaign uses Ace Editor. |
custom_template_id | string | A saved email template ID. When provided, subject, preview_text, and sender_name are not required. |
custom_template_version | integer | Optional template version. |
attachments | array of { file_type, url } | See Email attachments. |
Email content variants
- HTML content
- Saved template
- Ace Editor
- CC and BCC
Email attachments
Each entry inattachments is { file_type, url }.
file_type | Behavior |
|---|---|
URL | A static file hosted at a fixed URL. Every recipient receives the same file. |
PERSONALIZED_ATTACHMENT | A personalized file generated per recipient via a URL that includes personalization expressions. |
A/B test variations
campaign_content.variation_details configures A/B testing.
| Field | Type | Notes |
|---|---|---|
distribution_type | enum | MANUAL or SHERPA. |
no_of_variations | integer (≥ 1) | The number of variations. |
manual_distribution_percentage | object | A map of variation name to integer percentage. Values must be positive integers that sum to 100. Required when distribution_type is MANUAL. |
sherpa_campaign_duration | integer (hours) | The window over which Sherpa collects performance data before declaring a winning variation. Required when distribution_type is SHERPA. |
sherpa_distribution_metric | enum | OPEN RATE, CLICK RATE, or BOTH. Required when distribution_type is SHERPA. |
variation_details is set, campaign_content.content must use the locale-keyed and variation-keyed shape. See Content payload structure.
- MANUAL (50/50)
- SHERPA (auto-optimized)
Email delivery connector
Theconnector object is part of the Email request body (not the Email campaign_content) and identifies the delivery provider configured in the workspace.
connector is required on Email Create requests and Email inline test requests. It is not part of the Push request body.| Field | Type | Notes |
|---|---|---|
connector_type | string | The connector service (for example, SENDGRID, AWS SES). |
connector_name | string | The connector configuration name in the MoEngage workspace. |
Validation rules
The following rules span multiple sub-objects on this page. Each is enforced at validate or publish time.| Rule | Source |
|---|---|
For Push template_type: Custom, custom_template_id is required (Android, iOS). | AndroidPushContent.custom_template_id, IOSPushContent.custom_template_id |
iOS supports only BASIC, STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, and Custom. Submitting IMAGE_BANNER_WITH_TEXT, TIMER, or TIMER_WITH_PROGRESS_BAR for iOS fails. | IOSPushContent.template_type enum |
Web push supports only BASIC. | WebPushContent.template_type enum |
For Android STYLIZED_BASIC, SIMPLE_IMAGE_CAROUSEL, IMAGE_BANNER_WITH_TEXT, TIMER, and TIMER_WITH_PROGRESS_BAR, template_backup is required. | AndroidTemplateBackup description |
For iOS STYLIZED_BASIC and SIMPLE_IMAGE_CAROUSEL, template_backup is required. | IOSTemplateBackup description |
For Android IMAGE_BANNER_WITH_TEXT, banner_image_url is required. | AndroidBasicDetails.banner_image_url |
For iOS SIMPLE_IMAGE_CAROUSEL, image_url is required (used as the cover image before the carousel loads). | IOSBasicDetails.image_url |
For Android TIMER and TIMER_WITH_PROGRESS_BAR, timer is required. When personalized_value is false, both duration_hour and duration_minute are required. When personalized_value is true, specific_time is required. | AndroidTimer.duration_hour, AndroidTimer.duration_minute, AndroidTimer.specific_time |
For Android STYLIZED_BASIC and SIMPLE_IMAGE_CAROUSEL, the slider transition is lowercase (manual or automatic). For iOS SIMPLE_IMAGE_CAROUSEL, the slider transition is uppercase (MANUAL or AUTOMATIC). Mismatched casing fails validation. | CarouselContent.slider_transition, IOSCarouselContent.slider_transition |
For Android, when make_notification_sticky is true or auto_dismiss_notification is true, dismiss_button_text is required. When auto_dismiss_notification is true, auto_dismiss_notification_time_value and auto_dismiss_notification_time_granularity are also required. | AndroidAdvanced.dismiss_button_text |
For iOS, exactly one of send_to_all_eligible_device, exclude_provisional_push_devices, or send_to_only_provisional_push_enabled_devices must be true inside basic_details.platform_specific_details.ios. | PlatformSpecificDetails.ios description |
For Email content_type: PROMOTIONAL, subscription_category is required. | EmailBasicDetailsV5.subscription_category |
For Email, html_content is optional when custom_template_id is provided. When custom_template_id is provided, subject, preview_text, and sender_name are not required. | EmailContent.html_content, EmailContent.custom_template_id |
For an A/B test with distribution_type: MANUAL, manual_distribution_percentage values must sum to 100. For SHERPA, sherpa_campaign_duration and sherpa_distribution_metric are both required. | VariationDetails description |
For multi-locale or multi-variation campaigns, the "default" locale key is always required and serves as the fallback. Additional locale keys must match values listed in campaign_content.locales. | PushCampaignContent.content, EmailCampaignContent.content |
connector is required on Email Create requests and Email inline test requests. | Connector description |
BROADCAST_LIVE_ACTIVITY is not supported through draft creation. The V1 Campaigns API is used to send a Live Activity broadcast. | PushCampaignCreateV5Request.campaign_delivery_type description |
business_event (inside basic_details) is required when campaign_delivery_type is BUSINESS_EVENT_TRIGGERED. | PushBasicDetailsV5.business_event, EmailBasicDetailsV5.business_event |
geofences (inside basic_details) is required when campaign_delivery_type is LOCATION_TRIGGERED. The full schema is at Geofence targeting. | Geofences description |
Updating an existing campaign
PATCH /v5/campaigns/{campaign_id} reuses every schema on this page. Additional rules apply for updates.
- When a field inside a nested object is updated, the complete parent object must be included in the request. For example, to change only the title of an Android push, the full
campaign_content.content.push.androidblock is included. - The Update request body includes
updated_by(the editing user’s email, for audit purposes). When omitted, the update is attributed to the authenticated API credential. - For campaigns in
ACTIVEstate, the following fields cannot be edited:trigger_condition,segmentation_details,conversion_goal_details, the scheduling type, and the scheduling start date.campaign_contentandbasic_details.platformscan be edited. The full per-state matrix is at Update Campaign. - Updates to
campaign_contenton event-triggered campaigns can take up to 30 minutes to propagate due to content caching. - The Update Push schema accepts
BROADCAST_LIVE_ACTIVITYas acampaign_delivery_typevalue, but draft creation does not. A draft cannot be transitioned to a Live Activity campaign through V5.
- campaign_content (Push)
- campaign_content (Email)
- platform_specific_details
- control_group_details (Push)
- control_group_details (Email)
See also
- Audience and delivery reference —
trigger_condition,segmentation_details,scheduling_details,delivery_controls,conversion_goal_details,control_group_details,utm_params,campaign_audience_limit,advanced, andgeofences. - Create Campaign — required fields, happy-path cURLs, error responses.
- Update Campaign — per-state edit restrictions, publish action.
- Update Campaign Status —
STOP,PAUSE,RESUMEtransitions. - Validate Campaign — pre-publish validation check.
- Campaign drafts overview — lifecycle, channels, supported delivery types.