Skip to main content
POST
Send text message
The most basic endpoint of the API: sends text to a number (to) from a connected session (sessionId). The number uses international format without + (e.g. 5511999999999). Optional features:
  • linkPreview — generates link previews in the text.
  • mentionAll — mentions all participants (in groups).
  • contextInfo — replies to a message, mentions contacts or forwards, via the ContextInfo JSON.
To reply to a specific message, provide the original message’s stanzaId and participant inside contextInfo.

Authorizations

Authorization
string
header
required

API Key for authentication. Format: <API_KEY>

Body

sessionId
string
required
Minimum string length: 1
to
string
required
Minimum string length: 1
text
string
required
Minimum string length: 1
contextInfo
object

ContextInfo proto JSON. Supports mentions, replies (quotedMessage), forwarding, ads, and other metadata.

Example:
mentionAll
boolean
async
sequential

With async: true, sends to THIS recipient go out one at a time, in the order the API received them. Sends to other recipients still run in parallel. This order is the order of arrival at the backend: requests fired in parallel by the client have no order to preserve — send them serially. There is a limit on accumulated pending sends per recipient; when it is exceeded the API responds 429 and the client should retry later. Ignored without async: true and in Official API sessions (cloud_api), where sending is always synchronous.

Response

200

Successful response