Send SMS Batch (v2)
POST/api/v2/sms/batches
Accepts up to 1000 messages in one request and sends them in the background.
The batch is accepted as a whole or not at all: one invalid message rejects the request with 422 and points at it (messages.3.msisdn), and a balance that does not cover the whole batch returns 402. An accepted batch returns 202 with status pending and a price estimate; the amount is reserved when the batch is processed, usually within seconds. Follow progress and per-message results with GET /api/v2/sms/batches/{id}.
If the balance is used up between acceptance and processing, the batch ends as rejected with failure_reason: insufficient_funds - nothing is sent or charged, and you can send it again.
Request
Responses
- 202
- 400
- 401
- 402
- 403
- 409
- 422
- 429
Batch accepted (or replayed for the same Idempotency-Key).
Response Headers
URL of the created resource.
true when this response replays an earlier request with the same Idempotency-Key.
The request body is not a JSON object.
Missing or invalid API key.
Not enough prepaid balance or free postpaid limit (for a batch: for the whole batch).
SMS sending is not active on this account (service not activated, suspended or billing unavailable).
The Idempotency-Key was already used for a request with a different body.
At least one message is invalid; nothing was accepted. fields points at every invalid message.
Too many requests for this API key, or too many failed authentication attempts from your address. Retry after the number of seconds in Retry-After.
Response Headers
Seconds until the limit resets.