Which headers report my usage?
| Name | Type | Description |
|---|---|---|
X-RateLimit-Limit | integer | Requests allowed in the current one-minute window. |
X-RateLimit-Remaining | integer | Requests left in the current window. |
X-RateLimit-Reset | unix timestamp | When the current window resets, in seconds since the epoch. |
Retry-After | seconds | Only on 429 responses: how long to wait before retrying. |
429 Too Many Requests
HTTP/1.1 429 Too Many Requests
Retry-After: 23
X-RateLimit-Limit: 120
X-RateLimit-Remaining: 0
X-RateLimit-Reset: 1768469460
{
"error": {
"code": "rate_limited",
"message": "Rate limit of 120 requests per minute exceeded.",
"request_id": "req_8f2c1a9d03b44e7a1c5d"
}
}Is this the limit on messages per minute?
No. The rate limit counts API requests. Sending is also capped at 60 messages per minute per session (429 rate_limited), and WhatsApp has its own, unpublished limits on how fast a number can message people, so stay far below that cap. To send to many people, use bulk sending, which spaces messages out for you, instead of looping over send-text.
How should I retry?
Wait for Retry-After seconds and retry. For 502 upstream_error, retry with exponential backoff and jitter. Do not blindly retry sends that may have gone through, since the API has no idempotency keys: check the chat history first.