Send a WhatsApp template message

Sends a pre-approved WhatsApp template message. Templates must be approved by Meta before use. Use this to initiate conversations outside the 24-hour window. As with `POST /v1/messages`, the `status` field is `sent` (synchronous) or `queued` when the send is accepted onto the carrier-safe priority lane (paced within the sender's daily conversation cap). A `queued` template is sent as soon as there is headroom; track delivery via `message.*` webhooks.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

This endpoint expects an object.
agent_idstringRequired
from_numberstringRequired
to_numberstringRequired
template_namestringRequired
language_codestringOptionalDefaults to en
parameterslist of stringsOptional

Response

Template message queued
message_idstring
conversation_idstring
agent_idstring
channelenum
directionenum
from_numberstring
to_numberstring
bodystring
statusenum
segmentsinteger

Number of SMS segments the message was split into. Populated for SMS channel only; null for WhatsApp.

created_atdatetime
is_sandboxboolean

True when the message was created with a pk_test_ (sandbox) API key. Omitted when false.

Errors

400
Send Template Request Bad Request Error