Skip to main content
POST

Authorizations

Authorization
string
header
required

Wavix API key. Pass as Authorization: Bearer <api_key>. Keys support per-resource scopes (none / read / write). See Restricted keys and scopes.

Scopes

whatsapp:write

Body

application/json

Attributes of the message to send.

Attributes of a WhatsApp message to send. Send exactly one of template and content. Use content only while the 24-hour service window of the recipient is open. Consumed by whatsapp_messages_send.

from
string
required

Phone number of a sender registered on your account, in E.164 format, as returned by whatsapp_senders_list. The leading + is optional.

Pattern: ^\+?\d{6,20}$
Example:

"+14155550100"

to
string
required

Recipient's phone number in E.164 format. The leading + is optional.

Pattern: ^\+?\d{6,20}$
Example:

"+447537151866"

idempotency_key
string

Key that makes the send safe to retry, unique per account. Matching is exact, so case and accents are significant - ORDER-1 and order-1 are two different keys and both are sent. Printable ASCII only. Must not begin with campaign:, a prefix reserved for campaign messages. A request with a key in that namespace is rejected.

Maximum string length: 128
Pattern: ^[\x20-\x7e]*$
Example:

"order-1001-shipped"

template
WhatsAppSendTemplate · object

The template to send and the values for its dynamic parts. Consumed in template by whatsapp_messages_send.

content
WhatsAppSendTextContent · object

Content of a message without a template that is text. Consumed in content of Send a WhatsApp message.

Response

The message created by the earlier send with the same idempotency_key.

Returned by whatsapp_messages_send.

message
WhatsAppMessage · object
required

A WhatsApp message you sent. Returned by whatsapp_messages_send.