Developer docs

IotaBot WhatsApp API

Send and receive WhatsApp messages from your code — on every number you connected.

Get an API key

WhatsApp API error codes

Refused before anything reaches WhatsApp — branch on error.code.

CodeStatusWhat to do
window_closed422More than 24 hours since the customer last wrote. On WhatsApp send an approved template; on Instagram you must wait for them to write.
template_not_approved422No approved template with that name and language on this number (GET /whatsapp/templates).
template_not_marketing422POST /whatsapp/marketing-messages sends MARKETING templates only. Send utility and authentication templates with POST /messages.
recipient_opted_out422The customer opted out of this channel (they replied STOP, or the contact is marked opted out). Nothing can be sent to them there.
invalid_phone400Give phone numbers with their country code, e.g. +919812345678.
whatsapp_account_required400The key reaches several WhatsApp numbers — say which with whatsapp_account_id.
no_whatsapp_account422This key cannot reach any connected WhatsApp number.
integration_paused409An agent paused integration replies on this conversation. Stop retrying; a conversation.updated event tells you when it resumes.
api_quota_exceeded429The workspace used its monthly API messages. It resets on the 1st; the plan sets the limit.
rate_limited429Over the key's rate limit (20 a second and 300 a minute on paid plans). Wait for Retry-After seconds.
idempotency_key_reused422The Idempotency-Key was already used with a different request.
idempotency_in_progress409A request with this Idempotency-Key is still being processed. Retry shortly.