Skip to main content

POST /sms/lines/{line}/scheduled

Schedule a message

Scopesms:send
Role permissionPhone numbers — line must be one of theirs
CostTHIS SPENDS MONEY — later.

Why this needs sms:send, not sms:write: a scheduled message is a send that has not happened yet. It is priced now and charged when it goes out, so it requires the same money-spending consent a live send does — otherwise sms:write would be a way to bill the account tomorrow for something it cannot bill today.

The price is fixed at the moment you schedule. A later rate-card change does not re-price a message you already committed to.

The STOP list is checked at dispatch, not now: a recipient can opt out between scheduling and sending, and clearing them now would let the message reach someone who has since said stop.

Path parameters

NameTypeRequiredExampleDescription
linestringyes12125550188One of your account's numbers. Digits.

Request body

FieldTypeRequiredDescription
tostring[]yes
messagestringnoRequired unless media is set.
subjectstringno
mediastring[]noHosted URLs, not inline file content — a scheduled MMS references files that already exist rather than carrying megabytes that must be stored until the send time.
sendAtstring (RFC 3339)yesWhen to send it, RFC 3339. Must be in the future — a past time is almost always a timezone bug in the caller, so it is rejected rather than sent immediately.
{
"to": [
"13475550123"
],
"message": "Reminder: your appointment is tomorrow at 2pm.",
"sendAt": "2026-08-20T14:30:00Z"
}

Responses

201

Queued.

FieldTypeDescription
idinteger
linestring
recipientsstring[]
subjectstring
textstring
mediastring[]
sendAtstring (RFC 3339)
pricenumberWhat it will cost, fixed at the moment it was scheduled. A later rate-card change does not re-price a message you already committed to; the charge lands when it goes out.
currencyUSD

Errors

StatusMeaning
400invalid_request — a missing or malformed field, an unknown enum value, or an unknown field in the body. Nothing was charged.
401unauthenticated — no credential, or one that is invalid, revoked or expired. The WWW-Authenticate header names the scope the endpoint wanted.
403Two different failures share this status, and the type tells them apart:
422A destination is not on the account's rate card, so it cannot be priced. Nothing was queued.
500internal_error — something failed on our side. For a send, nothing was charged, guaranteed, which is what makes a retry safe.

See Errors for the full catalog and what to do about each.

Example

curl -X POST 'https://api.account.telebroad.com/api/public/v1/sms/lines/12125550188/scheduled' \
-H "Authorization: Bearer $TB_KEY" \
-H 'Content-Type: application/json' \
-d '{"to":["13475550123"],"message":"Reminder: your appointment is tomorrow at 2pm.","sendAt":"2026-08-20T14:30:00Z"}'

Try it in the playground →