How to update an email campaign

Intro

Modify an email campaign's settings, audience, schedule, or email design. Draft campaigns can be edited directly. Sent or scheduled campaigns must first be copied to create a new draft, which you can then edit and resend.

See API reference: Campaigns | Email Content

Prerequisites

  • An API key with campaigns.write scope (and email-templates.write if updating the email design)
  • A campaign ID. See How to send an email campaign for creating one

Step 1: Retrieve the campaign

Fetch the campaign to check its status and get the content.email.contentID, which you need to update the email design.

See endpoint: Get campaign

curl -X GET 'https://api.omnisend.com/api/campaigns/CAMPAIGN_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview'

The response includes the campaign's current status, all settings, and the content.email.contentID field. The next step depends on the campaign status:

Option A: Edit a draft campaign

Draft campaigns can be edited directly. You can update campaign settings (subject line, audience, schedule) through the Campaigns API, and replace the email design through the Email Content API.

Update campaign settings

Use the update endpoint to change the campaign name, email settings, audience, or sending schedule. Only the fields you include in the request body are updated — omitted fields remain unchanged.

See endpoint: Update campaign

Change the subject line and sender name

curl -X PATCH 'https://api.omnisend.com/api/campaigns/CAMPAIGN_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview' \
  -H 'Content-Type: application/json' \
  -d '{
    "content": {
      "email": {
        "subject": "Updated: Summer Sale — 60% Off!",
        "senderName": "My Store Team"
      }
    }
  }'

Change the audience

curl -X PATCH 'https://api.omnisend.com/api/campaigns/CAMPAIGN_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview' \
  -H 'Content-Type: application/json' \
  -d '{
    "audience": {
      "includedSegmentIDs": ["111111111111111111111111"],
      "excludedSegmentIDs": ["222222222222222222222222"]
    }
  }'

Note: Included and excluded segment IDs must not overlap. Omitting audience or leaving includedSegmentIDs empty targets all subscribers.

Change the sending schedule

curl -X PATCH 'https://api.omnisend.com/api/campaigns/CAMPAIGN_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview' \
  -H 'Content-Type: application/json' \
  -d '{
    "sendingSettings": {
      "strategy": "scheduled",
      "scheduledAt": "2026-07-01T09:00:00Z",
      "isTZOptimizationEnabled": false
    }
  }'

Warning: sendingSettings uses full object replacement. You must provide all fields (strategy, scheduledAt, isTZOptimizationEnabled) every time — omitted fields reset to defaults. For example, switching from scheduled to immediate still requires explicitly setting "strategy": "immediate".

Edit email content

To change the visual layout of the email — text, images, buttons, sections — use the Email Content API. Use the content.email.contentID value from Step 1 as the content ID.

Read the current content

Retrieve the existing email content to use as a base for your changes.

See endpoint: Get email content

curl -X GET 'https://api.omnisend.com/api/email-content/CONTENT_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview'

The response contains the full generalSettings and sections array. See Email Content API reference for details on the content structure.

Replace the content

Modify the JSON from the previous response and send it back as a full replacement. The example below shows a content body with a heading, promotional text, a call-to-action button, and a footer with unsubscribe link.

See endpoint: Update email content

curl -X PUT 'https://api.omnisend.com/api/email-content/CONTENT_ID' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview' \
  -H 'Content-Type: application/json' \
  -d '{
    "generalSettings": {
      "content": {
        "backgroundColor": "#FFFFFF",
        "width": "600px",
        "fontFamily": "Arial, sans-serif",
        "fontSize": "16px",
        "color": "#212121"
      },
      "body": {
        "backgroundColor": "#EDEEF0"
      }
    },
    "sections": [
      {
        "id": "sec000000000000000000001",
        "rows": [{
          "id": "row000000000000000000001",
          "columns": [{
            "id": "col000000000000000000001",
            "width": "600px",
            "blocks": [
              {
                "id": "blk000000000000000000001",
                "type": "text",
                "text": "<h1>Summer Sale — Now 60% Off!</h1><p>Our biggest sale just got bigger. Shop the updated deals before they expire.</p>"
              },
              {
                "id": "blk000000000000000000002",
                "type": "button",
                "text": "Shop the sale",
                "url": "https://example.com/summer-sale",
                "stylePresetID": "primary_button"
              }
            ]
          }]
        }],
        "styleProperties": {
          "backgroundColor": "#FFFFFF",
          "paddingTop": "24px",
          "paddingBottom": "24px",
          "paddingLeft": "24px",
          "paddingRight": "24px"
        }
      },
      {
        "id": "sec000000000000000000002",
        "rows": [{
          "id": "row000000000000000000002",
          "columns": [{
            "id": "col000000000000000000002",
            "width": "600px",
            "blocks": [{
              "id": "blk000000000000000000003",
              "type": "text",
              "text": "<p style=\"text-align: center;\"><a href=\"[[unsubscribe_link]]\">Unsubscribe</a></p>"
            }]
          }]
        }],
        "styleProperties": {
          "paddingTop": "12px",
          "paddingBottom": "12px"
        }
      }
    ]
  }'

Warning: PUT replaces the entire content. Omitted sections are deleted. Always start from the GET response and modify only the parts you need to change.

Note: At least one text or HTML block must contain [[unsubscribe_link]]. If you provide buttonPresets, all three required presets (primary_button, secondary_button, tertiary_button) must be included. See Email Content API reference for the full content structure.

Option B: Edit a sent campaign

This approach is best when you want to reuse existing content — such as the email design, audience, or settings — instead of creating a new campaign from scratch. Campaigns in any non-draft status (sent, scheduled, started, etc.) cannot be modified directly — the API returns 409 Conflict. To make changes, copy the campaign to create a new draft, then edit and resend it.

Copy the campaign

See endpoint: Copy campaign

curl -X POST 'https://api.omnisend.com/api/campaigns/CAMPAIGN_ID/copy' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Omnisend-Version: 2026-preview'

The response returns a new campaign in draft status with its own id and content.email.contentID. The copy includes the original campaign's content, audience, and settings. The name is prefixed with "Copy of: ".

Edit and resend

Use the new campaign's ID to apply changes following Option A, then send it using How to send an email campaign.

Note: The copy is a fully independent campaign. Changes to it do not affect the original. If the original campaign is no longer needed, cancel it if it hasn't been sent already to prevent duplicate sends.

Troubleshooting

  • 409 Conflict on campaign update: The campaign is not in draft status. Only drafts can be edited. Use Copy campaign to create a new editable draft from any campaign.
  • 409 Conflict on content update: The email content is locked because the campaign has started or finished sending. Copy the campaign to get a new editable draft with its own content.
  • sendingSettings partially reset: You provided only some sendingSettings fields. This object uses full replacement — always include strategy, scheduledAt (when scheduled), and isTZOptimizationEnabled together.
  • Sender email rejected: The senderEmail must belong to a verified brand domain. Verify it in Store Settings → Email Addresses.

Related resources