Skip to main content
POST
/
api
/
v1
/
campaigns
Create Campaign
curl --request POST \
  --url https://api.sequenzy.com/api/v1/campaigns \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "subject": "<string>",
  "trackingCode": "<string>",
  "status": "<string>",
  "sentAt": "<string>",
  "html": "<string>",
  "blocks": [
    {}
  ],
  "labels": [
    {}
  ],
  "campaignData": {},
  "computedLists": [
    {}
  ]
}
'
{
  "success": true,
  "campaign": {
    "id": "camp_abc123",
    "name": "April Launch",
    "subject": "A quick update",
    "status": "draft",
    "trackingCode": null,
    "labels": ["edm", "launch"],
    "sentAt": null,
    "url": "https://sequenzy.com/dashboard/company/comp_abc123/campaign/camp_abc123",
    "previewUrl": "https://sequenzy.com/dashboard/company/comp_abc123/campaign/camp_abc123?step=review"
  }
}
Create a campaign and linked email. Campaigns are created as drafts by default. For migrations, pass status: "sent" to archive an already-sent campaign without sending email or creating delivery history. You must have at least one sender profile configured before creating campaigns through the API.

Request

name
string
required
Campaign name.
subject
string
required
Email subject line.
trackingCode
string
Optional campaign tracking code available to UTM templates as {{campaign.trackingCode}}. Empty strings are stored as null.
status
string
Initial status. Use draft or sent; defaults to draft. sent is for imported/already-sent campaigns only.
sentAt
string
ISO date-time for an imported/already-sent campaign. Only valid with status: "sent"; defaults to the current time when omitted.
html
string
Raw HTML body. Sequenzy converts this into email blocks. Use this or blocks, not both.
blocks
array
Sequenzy email blocks. Use this or html, not both. Put block styling under styles; top-level style keys like backgroundColor, backgroundOpacity, borderColor, borderWidth, and borderRadius are normalized into styles.
labels
array
Label names to assign to the campaign. Missing labels are created automatically. The API also accepts label as a compatibility alias.
campaignData
object
Campaign-scoped JSON data available while rendering this campaign.
computedLists
array
Personalized list definitions computed from campaignData.
curl -X POST "https://api.sequenzy.com/api/v1/campaigns" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "April Launch",
    "subject": "A quick update",
    "labels": ["edm", "launch"],
    "html": "<p>Hello there!</p>"
  }'
curl -X POST "https://api.sequenzy.com/api/v1/campaigns" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Imported April Launch",
    "subject": "A quick update",
    "status": "sent",
    "sentAt": "2026-05-01T14:00:00Z",
    "html": "<p>Hello there!</p>"
  }'

Responses

{
  "success": true,
  "campaign": {
    "id": "camp_abc123",
    "name": "April Launch",
    "subject": "A quick update",
    "status": "draft",
    "trackingCode": null,
    "labels": ["edm", "launch"],
    "sentAt": null,
    "url": "https://sequenzy.com/dashboard/company/comp_abc123/campaign/camp_abc123",
    "previewUrl": "https://sequenzy.com/dashboard/company/comp_abc123/campaign/camp_abc123?step=review"
  }
}