Opens a brand new conversation with a contact on WhatsApp and sends an approved template as its first
message. This is the only way to reach a contact that never wrote to you, or that has been silent for
more than 24 hours: outside that window Meta only accepts template messages.
The list of templates you can send, and the variables each one expects, is returned by
GET /v2/whatsapp/templates. Only text-only templates are supported.
Choosing the contact
polymorphic_contact_id accepts the usual contact identifiers: a numeric ID ("12345"), a custom user
ID ("cuid:user_123"), a custom lead ID ("clid:lead_456"), an email ("uem:[email protected]" or
"lem:[email protected]"), or a WhatsApp number ("wa:+1234567890").
The contact must already exist and must have a WhatsApp number on its profile. Create it first with
POST /v2/contacts when it does not.
Choosing the sender and the assignee
account_id is the account the template is sent as. It is recorded as the author of the message in the
Customerly inbox and drives the send attribution; the contact only ever sees the WhatsApp business number,
never the account. It defaults to the account owning the access token.
assignee_type and assignee_id decide who the new conversation is assigned to, and must be provided
together. assignee_type is "account" or "team". When omitted, the conversation is assigned to the
sender account.
Choosing the sender number
whatsapp_business_number selects which of your connected WhatsApp Business numbers sends the message.
It can be omitted when your project has a single connected number. The template must belong to the same
WhatsApp Business Account (WABA) as the number, otherwise the request is rejected with
whatsapp_template_waba_mismatch.
Example request
{
"polymorphic_contact_id": "wa:+1234567890",
"whatsapp_template_id": 42,
"whatsapp_business_number": "+1555000111",
"account_id": 123,
"assignee_type": "team",
"assignee_id": 7,
"parameters": {
"name": "John",
"order_id": "A-19822"
}
}The message is handed over to WhatsApp asynchronously: a 201 means the conversation was created and the
template accepted, not that it has already been delivered to the phone. Delivery is reported on the
message itself (GET /v2/conversations/{conversation_id}/messages).
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
401Authentication required
402The WhatsApp feature is not available on the current plan
403Permission denied
404Contact, account, team, template or WhatsApp number not found
422Validation failed
500Internal server error