NewWhatsApp, Instagram, Messenger, email, SMS and website chat, now in one inbox
CAT Engage 360

Errors and limits

Every failure has the same shape and a stable code, so your code can tell what went wrong without reading the wording.

The error shape#

Error
{
  "error": {
    "code": "forbidden",
    "message": "This API key is missing the 'messages:send' scope"
  }
}

code never changes, so branch on it. message is written for people and may be reworded. The HTTP status matches the kind of problem.

Codes#

CodeStatusWhat to do
bad_request400Fix the request. The message names the field, for example 'to' is required.
template_not_found400Check the name, then run Sync from Meta in Settings → Templates.
template_not_approved400Wait for Meta to approve the template, or use another one.
whatsapp_not_configured400An admin connects (or reconnects) WhatsApp in Settings → WhatsApp.
unauthorized401Check the key. Missing, wrong, revoked and expired keys all look the same.
forbidden403Give the key the scope named in the message, or create a key that has it.
account_not_approved403Sending starts once the business is approved. Reads and contacts already work.
account_suspended403Messaging is paused for the business. Contact support.
plan_limit403The plan’s contact limit is reached. Upgrade the plan or remove old contacts.
not_found404The id doesn’t exist in this business.
rate_limited429Slow down: wait the seconds in Retry-After, then try again.
internal500Something failed on our side. Try again; if it keeps happening, contact support with the time of the call.
meta_error502WhatsApp refused the message. The message carries Meta’s reason, for example the 24-hour window has closed.

Rate limits#

Each key can make 120 requests a minute. Past that you get 429 rate_limited with these headers:

HeaderMeaning
Retry-AfterSeconds to wait before trying again.
X-RateLimit-LimitRequests allowed per minute.
X-RateLimit-RemainingRequests left in this minute.
X-RateLimit-ResetWhen the minute resets, in Unix seconds.

Sending to many people

Use Send a broadcast for bulk messages: up to 1,000 numbers per request, sent at a steady pace for you, so you never need to rush the limit.

Other limits#

  • Lists return up to 100 items per page (50 by default). Follow meta.next_cursor for more.
  • Broadcasts take up to 1,000 recipients per request, each with up to 60 template values.
  • Media captions are up to 1,024 characters. Media links must be https.
  • A business can have up to 50 active API keys and 20 webhook endpoints.
  • Contacts take up to 50 tags in one request; tag names up to 64 characters.

Retrying safely#

  • Retry 429, 500 and network errors after a pause. Don't retry 400, 401, 403 or 404; they fail the same way again.
  • Adding a contact is safe to repeat: the same phone number returns the same contact.
  • Sending is not: repeating a send sends the message again. Only retry a send that got no answer after checking the conversation's messages.