---
title: "Update a draft campaign"
method: PUT
path: "/campaigns/{campaignId}"
tags: ["Campaigns"]
---

# Update a draft campaign

`PUT /campaigns/{campaignId}`

Update a draft campaign's name, labels, content, reply-to settings, or campaign personalization data.

## Path parameters

- `campaignId` string, required

## Request body

- object
  - `name` string — Updated campaign name
  - `subject` string — Updated email subject line
  - `trackingCode` string, nullable — Campaign tracking code available to UTM templates as `{{campaign.trackingCode}}`. Send an empty string or null to clear it.
  - `html` string — Updated email HTML content. Mutually exclusive with `blocks`.
  - `blocks` object[] — Updated Sequenzy email blocks. Mutually exclusive with `html`. Put visual styling under styles; top-level style keys such as backgroundColor, backgroundOpacity, borderColor, borderWidth, and borderRadius are normalized into styles.
  - `replyTo` string, email — Existing reply profile email for this company. Mutually exclusive with `replyProfileId`.
  - `replyProfileId` string — Reply profile ID for this company. Mutually exclusive with `replyTo`.
  - `labels` string[] — Replacement label names. Send an empty array to clear labels. Missing labels are created automatically.
  - `label` string[] — Compatibility alias for labels.
  - `campaignData` object, nullable — Campaign-scoped JSON data available while rendering this campaign. Top-level arrays can contain up to 500 items. Set to null to clear it.
  - `computedLists` object[] — Personalized list definitions computed from campaignData. Keys can use letters, numbers, underscores, and dots. Use maxItems to cap each subscriber's list length. Pass an empty array to clear computed lists.

## Response `200`

Campaign updated successfully

- object
  - `success` boolean, required
  - `campaign` object, required
    - `id` string
    - `name` string
    - `subject` string
    - `status` string
    - `labels` string[]
    - `replyProfileId` string, nullable
    - `replyToName` string, nullable
    - `replyToEmail` string, email, nullable
    - `url` string, uri
    - `previewUrl` string, uri

## Other responses

- `400` — Validation error
- `401` — Unauthorized
- `404` — Campaign not found
- `422` — Request body failed schema validation

## Changes

- **2026-05-19** `1a51a400be50` — 1 info
  - added the new optional request property `trackingCode`
- **2026-05-15** `b040bb8c6608` — 2 info
  - added the optional property `campaign/previewUrl` to the response with the `200` status
  - added the optional property `campaign/url` to the response with the `200` status
- **2026-05-13** `9a89cb9ec599` — 4 info
  - added the new optional request property `label`
  - added the new optional request property `labels`
  - the request property `campaignData` became nullable
  - added the optional property `campaign/labels` to the response with the `200` status
- **2026-05-11** `ee7b7111c55b` — 3 info
  - api operation id `updateCampaign` was added
  - added the new optional request property `campaignData`
  - added the new optional request property `computedLists`
- **2026-04-16** `3e7678233a4e` — 1 info
  - added the new optional request property `blocks`

[Full history](https://skmtc.dev/sequenzy/apis/sequenzy-api/changes/campaigns/:campaignId/put.md)

---

[API](https://skmtc.dev/sequenzy/apis/sequenzy-api.md) · [All operations](https://skmtc.dev/sequenzy/apis/sequenzy-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/sequenzy/sequenzy-api/revisions/a7ebcc2a87e4/schema)
