Skip to main content
Adds a route: the channels a message is tried on, in order, and what counts as done on each. A message names it by route. Making it the default unsets the previous default.
Needs the routes:write scope.

Body

Each step is {"channel", "succeed_on", "within"}: channel is sms, whatsapp, rcs or firetone (Voice) — the channels your account has; succeed_on is sent, delivered (the default), read or answered — only what that channel reports (SMS reports delivery, WhatsApp and RCS delivery and reads, Voice whether the call was answered); within is how many seconds to wait for it, from 30 to 604800 (default 900). A route has 1 to 6 steps. Send an Idempotency-Key header to make a retry safe: the same key with the same body is answered once, and the first answer repeated (with Idempotent-Replayed: true).

Request

Response

201 Created

Errors

Every refusal is {"error": {"code", "message", "field"}}; field is there when one input is at fault. Any request can also be refused for its key, its account or its rate (key_required, invalid_key, account_suspended, plan_excludes_api, address_not_allowed, rate_limited); see the overview.