Gallery Platform API
Reference

Schedule a campaign to send

Moves a draft campaign to `scheduled` — the send worker fans it out at `scheduled_at` (or on its next run when omitted). Rejected if the campaign has no subject, body, from-address, or audience.

POST
/gallery/campaigns/{id}/schedule

Moves a draft campaign to scheduled — the send worker fans it out at scheduled_at (or on its next run when omitted). Rejected if the campaign has no subject, body, from-address, or audience.

Authorization

bearerAuth campaigns:update
AuthorizationBearer <token>

A gallery API key, sent as Authorization: Bearer gpk_… (or the x-api-key header).

In: header

Scope: campaigns:update

Path Parameters

id*string

The campaign id.

Header Parameters

Idempotency-Key?string

Optional. Send a unique key per logical operation to make retries safe: a retry with the same key replays the stored success for 14 days instead of re-running the write. Reusing a key with a different body returns 400.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Schedule a draft campaign to send (at scheduled_at, or now).

Response Body

application/json

application/problem+json

application/problem+json

application/problem+json

application/problem+json

application/problem+json

application/problem+json

{  "id": "string",  "name": "string",  "status": "draft",  "subject": "string",  "preview_text": "string",  "from_name": "string",  "from_email": "string",  "reply_to": "string",  "sending_domain_ref": "string",  "audience_list_id": "string",  "design_json": null,  "html": "string",  "text_body": "string",  "ab_config": null,  "scheduled_at": "string",  "sent_at": "string",  "metadata": {    "property1": "string",    "property2": "string"  },  "created_at": "string",  "updated_at": "string"}