Skip to main content
PATCH
/
campaigns
/
{campaign_id}
curl --request PATCH \
  --url https://api-{dc}.moengage.com/core-services/v1/campaigns/{campaign_id} \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --header 'MOE-APPKEY: <moe-appkey>' \
  --data '
{
  "request_id": "push_update_12345",
  "updated_by": "[email protected]",
  "campaign_content": {
    "content": {
      "push": {
        "android": {
          "template_type": "BASIC",
          "basic_details": {
            "notification_channel": "general",
            "title": "Updated Title - Flash Sale!",
            "message": "Updated Message - Only 2 hours left!",
            "default_click_action": "DEEPLINKING",
            "default_click_action_value": "https://example.com/flash-sale"
          }
        },
        "ios": {
          "template_type": "BASIC",
          "basic_details": {
            "title": "Updated Title - Flash Sale!",
            "message": "Updated Message - Only 2 hours left!",
            "default_click_action": "DEEPLINKING",
            "default_click_action_value": "https://example.com/flash-sale"
          }
        }
      }
    }
  }
}
'
{
  "error": {
    "code": "400 Bad Request",
    "message": "request_id key is mandatory field",
    "target": "request_id",
    "details": [
      {
        "target": "request_id",
        "message": "request_id key is mandatory field"
      }
    ],
    "request_id": "11"
  }
}
Update RestrictionsYou cannot update campaigns when in Stopped or Archived state.For Scheduled Campaigns
  • You can edit all fields except scheduling type for One-Time campaigns.
  • You can edit all fields except scheduling type for Periodic/Event-Triggered campaigns if no instance has been sent yet.
For Active Campaigns, you cannot edit the following fields:
  • Trigger Condition
  • Segmentation Details
  • Conversion Goal Details
  • Scheduling Type
  • Scheduling Start Date
For Event-Triggered campaigns, updated content is cached and takes up to 30 minutes to take effect.

Authorizations

Authorization
string
header
required

Authentication is done via Basic Auth. This requires a base64-encoded string of your credentials in the format 'username:password'.

  • Username: Use your MoEngage workspace ID (also known as the App ID). You can find it in the MoEngage dashboard at Settings > Account > APIs > Workspace ID (earlier app id).
  • Password: Use your API Key, which you can find within the Campaign report/Business events/Custom templates/Catalog API/Inform Report tile.

For more information on authentication and getting your credentials, refer here.

Headers

MOE-APPKEY
string
required

This is the Workspace ID of your MoEngage account that must be passed with the request. You can find it in the MoEngage dashboard at Settings > Account > APIs > Workspace ID (earlier app id).

Path Parameters

campaign_id
string
required

The unique ID of the campaign to update.

You can fetch the campaign ID using the Get Campaign Details API by filtering with campaign name, channel, or other criteria.

Body

application/json

In this payload, you can include the fields you want to update.

Notes:

  • Pass only the fields you want to update. You don't need to send the complete payload.
  • If updating a field within an object, you must pass the complete object.
  • If updating a nested field, you must pass the complete parent object. For example, to update the title of a Push notification, pass the complete campaign_content object.
  • Use the tabs below to select your campaign type. The schema will adapt based on the selected channel.
request_id
string
required

A unique identifier for this campaign update request.

Example:

"push_update_12345"

updated_by
string<email>
required

The email ID of the user updating this campaign.

channel
enum<string>

The communication channel (automatically set to PUSH for this tab).

Available options:
PUSH
basic_details
object

Contains the basic information about the Push campaign.

trigger_condition
object

Trigger condition details for Push event-triggered campaigns.

Required for EVENT_TRIGGERED campaigns.

campaign_content
object

Contains the content and variations for the Push campaign.

segmentation_details
object

Defines the target audience for the campaign.

scheduling_details
object

Defines when the campaign should be sent.

delivery_controls
object

Controls for Push campaign delivery behavior.

advanced
object

Advanced campaign settings.

conversion_goal_details
object

Configuration for tracking campaign conversion goals.

control_group_details
object

Configuration for control groups.

utm_params
object

UTM parameters for tracking campaign performance.

Response

Campaign updated successfully. The server successfully processed the request but is not returning any content.