Launch campaign
launch_campaignLaunch a draft campaign so real emails begin sending. An unconfirmed request returns a preview, confirmation_token, approval_url, and removed counts from the launch-time recipient recheck. After a person approves, Layrcake runs it itself when the result's approval block says execution: server (a launch starts at its first-send time); otherwise, repeat the call with that token and a stable idempotency_key. Repeating is always safe and never runs it twice. Calling again without a token while the same request is still waiting for a decision returns that approval and sends no second email; after it was declined, expired or cancelled, calling again without a token asks again with a new confirmation_token. Requires active sending capacity and campaign:launch. Suppression and active do-not-contact entries are rechecked and provider removals fail closed before activation. dry_run: true returns an advisory estimate as of evaluated_at, reserves nothing, and may differ from a later execution plan.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dry_run | No | ||
| supersedes | No | The confirmation_token of the approval this request replaces. Needed only when that approval was already approved and hasn't started yet; one still waiting for a decision is replaced automatically. Only where Layrcake runs approved actions itself (the result's approval block says execution: server); anywhere else it is refused. A dry run doesn't check it, so it refuses it: send it on the call itself. | |
| campaign_id | Yes | ||
| idempotency_key | No | A payment_required refusal means services are stopped for unpaid billing; direct the owner to the billing link in the error. Campaigns stay paused after payment until restarted. Optional for search and enrichment tools: supply one so a retry returns the original result without paying again; if that call failed with provider_unavailable, rate_limited or insufficient_credits (after a top-up), a retry runs it once more after its cooldown (30 s, or a longer retry_after_seconds; insufficient_credits as soon as the balance covers it), unless its provider may already have done the work. Required for tools that create an external side effect; reuse the same value after a timeout or an approval. A stored failure comes back with details.replayed: true; with retry_after_seconds, retry the same value after that. | |
| daily_send_limit | No | ||
| confirmation_token | No | ||
| first_send_not_before | No | The earliest the first emails may go out (ISO 8601). They start at the first sending-window opening at least 60 minutes after a person approves, and not before this time. It can't be later than the approval's lifetime after this request (7 days by default); a later time is refused. Only where Layrcake runs approved actions itself (the result's approval block says execution: server); anywhere else it is refused. A dry run doesn't check it, so it refuses it: send it on the call itself. |