POST /v1/messages/raw
Escape hatch: forward an unmodified Meta Graph API body. Use only when no typed endpoint fits.
body as-is to Meta’s /{phone_number_id}/messages. Keebai adds the access token and the routing, and validates nothing inside body.
Reach for it only when Meta ships a message type Keebai has not exposed yet — and tell us, so we can add a typed endpoint.
Endpoint
Required scope
messages:send
Headers
Body
Example request
Response
202 Accepted
400 Bad Request
body missing or not an object, or an unknown top-level property. Nothing inside body is validated — a malformed Meta payload surfaces as a 502 instead.
401 Unauthorized
Missing, invalid, revoked, or expired token.403 Forbidden
The token does not have themessages:send scope.
502 Bad Gateway
Meta rejected the payload. The upstream error message is passed through, so read it carefully — it is your only debugging signal here.Operational notes
toinsidebodyhas no+. Meta’s raw format wants5491155555555; every typed Keebai endpoint wants+5491155555555. Mixing the two conventions is the most common mistake with this endpoint.messaging_product: "whatsapp"is mandatory in the raw body. Meta rejects the call without it.- You still get Keebai’s persistence: the message is stored against the conversation and reported through webhooks like any other, so
meta_datastill works for correlation.
Authorizations
Personal Access Token con prefijo kbai_pk_. Generar desde el portal con permiso developer.manage_tokens.
Body
Raw Meta Graph API messages body. Sent as-is to /{phone_number_id}/messages. Use only when POST /v1/messages has no matching type.
Keebai channel id. Optional when the tenant has exactly one active channel of the given type; required to disambiguate otherwise.
"665f1a2b3c4d5e6f70819234"
WhatsApp-only alias for channel_id: the Meta phone_number_id of the sending number. Ignored on other channels.
"100000000000001"
Free-form metadata persisted with the message. Returned on webhooks for correlation.