Skip to content

Withdraw a send request that is awaiting approval

On this page
POST/v1/send-requests/{send_request_id}/cancelcancel_send_request
Riskwrite
AuthenticationAPI key or OAuth access token
Scopesmailings:write
Idempotencynatural: repeating the call gives the same result
Dry runnot applicable
Success status200
Response typeapplication/json

What it does#

  • Use when: You asked to send a mailing, the author has not decided yet, and you want to withdraw the request, for example to edit the draft.
  • Do not use when: the mailing is already sending or scheduled (call cancel_scheduled_mailing for a scheduled one).
  • Side effects: Marks the request canceled; nothing is sent.
  • Reversible: Yes, call request_send again with a new preview_token.
  • Required scope: mailings:write.
  • Idempotency: safe to repeat (same result).
  • Typical next step: call update_mailing_draft, then preview_send.

Scopes#

  • mailings:write: Create, edit and delete draft mailings, and ask for a send to be approved.

Side effects#

  • Marks the request canceled; nothing is sent

Request#

Path parameters#

FieldTypeDescription
send_request_idstring

Query parameters#

None.

Response#

FieldTypeRequiredDescription
idstringyessrq_...
mailing_idstringyes
stateone of "awaiting_approval", "approved", "executed", "refused", "declined", "canceled", "superseded", "expired"yes
modeone of "now", "scheduled"yes
scheduled_atstring or nullyes
recipient_countinteger, min -9007199254740991, max 9007199254740991yes
mailing_revisioninteger, min -9007199254740991, max 9007199254740991yesThe mailing revision this request is bound to. An edit supersedes the request.
requested_bystringyesThe key or app name the author sees.
reason_codesarray of stringyes
created_atstringyesRFC 3339 UTC timestamp.
expires_atstringyesAn undecided request expires after 7 days.
decided_atstring or nullyes
executed_atstring or nullyes
previewobject or nullyes

Examples#

canceled#

Request:

curl -X POST 'https://api.seemly.com/v1/send-requests/srq_7h2m9k4t8w3c5n6p1q0r2s4v/cancel' \
  -H "Authorization: Bearer $SEEMLY_API_KEY"

Response: 200:

JSON
{
  "id": "srq_7h2m9k4t8w3c5n6p1q0r2s4v",
  "mailing_id": "cmp_4d8x2p0q7r4d8x2p0q7r4d8x",
  "state": "canceled",
  "mode": "now",
  "scheduled_at": null,
  "recipient_count": 212,
  "mailing_revision": 3,
  "requested_by": "Launch agent",
  "reason_codes": [
    "canceled"
  ],
  "created_at": "2026-12-02T09:31:00Z",
  "expires_at": "2026-12-09T09:31:00Z",
  "decided_at": "2026-12-02T09:35:00Z",
  "executed_at": null,
  "preview": {
    "decision": "allow",
    "reasons": [],
    "tranche_sizes": [],
    "recipient_count": 212
  }
}

Errors#

Every error is an application/problem+json body with a code, a fix sentence and next_actions. See reading a problem response.

Typical next steps#

View this page as MarkdownReport a problem with this page

Type to search. Try a method and path, an operation name or an error code.