Skip to main content
EmailVersion: v3

Campaigns

Documentation for emails API

πŸ“„οΈCreate Email Campaign

Create a draft email campaign: an email you intend to send to contacts, in the code (`html`), plain-text (`text`) or design (`builder`) editor: blank, from an existing template (`templateId`), or with initial `editorContent`. Then set content, subject and sender with Update Email Campaign and send with Schedule Campaign. For a reusable design that is not sent by itself, or when the user asks for a template, use Create an email template instead; a campaign can later start from it with `templateId`. A/B versions of a campaign are made with Upsert A/B Variation, not by creating another campaign.

πŸ“„οΈList Email Campaigns

Get list of email campaigns for a location. Status lifecycle: `draft` (created, editable) β†’ Schedule Campaign β†’ `scheduled` (waiting for `sendAt` or the next batch) β†’ `processing` (sending) β†’ `sent`. RSS campaigns have no `scheduled` state: while active, including between feed checks, they report `processing` or the status of their latest send. `failed` = sending errored. Pause Email Campaign: `scheduled`/`processing` β†’ `paused`; Resume Email Campaign: `paused` β†’ `processing`. Cancel Email Campaign: `scheduled`/`processing`/`paused` β†’ `cancelled`. `draft`, `paused` and `cancelled` campaigns can be (re)scheduled with Schedule Campaign. `archived` = archived campaign (any underlying status).

πŸ“„οΈGet Email Campaign by ID

Get a single email campaign by its ID. Pass `includeContent=true` to get the current `editorContent` (version A). `abVersions` lists its A/B versions B, C, ... Status lifecycle: `draft` (created, editable) β†’ Schedule Campaign β†’ `scheduled` (waiting for `sendAt` or the next batch) β†’ `processing` (sending) β†’ `sent`. RSS campaigns have no `scheduled` state: while active, including between feed checks, they report `processing` or the status of their latest send. `failed` = sending errored. Pause Email Campaign: `scheduled`/`processing` β†’ `paused`; Resume Email Campaign: `paused` β†’ `processing`. Cancel Email Campaign: `scheduled`/`processing`/`paused` β†’ `cancelled`. `draft`, `paused` and `cancelled` campaigns can be (re)scheduled with Schedule Campaign. `archived` = archived campaign (any underlying status).

πŸ“„οΈEstimate Recipients

Count how many contacts match an audience right now (contact, tag, segment, smart_list, custom_segment or all) and get a one-line summary to confirm with the user before scheduling. The count is before send-time suppression: do-not-disturb, unsubscribed and contacts without a valid email are skipped at send, so tell the user it is the most that can receive the campaign, not a delivery count. Returns the count only, never contact ids. Write-scoped because an exact count for any filter would otherwise let a read-only token enumerate contacts.