Create a campaign
Creates a new campaign. To schedule a blast send, follow up with PATCH /:campaignId setting state: "scheduled" and send_at.
Idempotent — pass an Idempotency-Key header to make safely retryable. On a replay the original response is returned with Idempotent-Replayed: true. See the API conventions guide for the full state machine, TTL, and mismatch behaviour.
Authorizations
Project-scoped secret API key (sk_…). Pass in the Authorization: Bearer <key> header. Grants access to the project the key was issued for.
Body
Create a new campaign. Subscription, provider, and target lists are required to send.
blast campaigns send to every user in the target lists. trigger campaigns fire per-user when an event matches.
blast, trigger 1Delivery channel the campaign sends through.
email, text, push, webhook, in_app Response
The newly created campaign.
A one-off (blast) or per-user (trigger) send across one channel.
Numeric campaign identifier.
24
blast campaigns send to every user in the target lists. trigger campaigns fire per-user when an event matches.
blast, trigger Delivery channel the campaign sends through.
email, text, push, webhook, in_app Subscription type a user must be opted in to in order to receive this campaign.
Delivery provider used to send the campaign.
Campaign lifecycle state. Set state: "scheduled" (with send_at) to send a blast; set state: "aborted" to cancel.
draft, scheduled, loading, running, finished, aborting, aborted IDs of the lists targeted by the campaign.
IDs of lists whose members should be excluded from the campaign.
Hydrated subscription type referenced by subscription_id.
Hydrated delivery provider referenced by provider_id. Returned in the redacted public shape — see Provider schema. Credentials (data, auth, API keys, tokens) are NEVER included.
Aggregated delivery counters for the campaign.
When true, send_at is interpreted as a wall-clock time in each user’s local timezone.
When the campaign should send. ISO 8601 string accepted on input.
Optional override of the project’s default tracking and from-address domain.
Admin who created the campaign. Null for system- or API-key-created campaigns.
Safe display details for created_by, or null when the creator is system/API-key-created or no longer belongs to the project.
Internal-only description for the audit trail. Never shown to recipients.