Skip to main content
This quickstart takes you from an empty integration to a first WhatsApp message sent through the API. You need a Shortext company with at least one connected WhatsApp number.
1

Create an API key

In the dashboard, open Developer > API Keys and create a key. Give it a name (for example “CRM integration”) and choose its permissions. To follow this quickstart, keep Send messages checked; add Manage integrations if your integration also manages agents, channels or webhooks.The key is shown once. Store it in a secret manager or an environment variable, for example SHORTEXT_API_KEY.
An API key gives access to your company’s data. Never put it in a mobile app, a web page or a public repository.
2

Check the key with GET /me

Every request sends the key as a bearer token. GET /me tells you which company and which key you are using.
Response
The HTTP status is always 200: read success and code to know the outcome. See API introduction.
3

Find your channel and a template

GET /channels?type=whatsapp lists your WhatsApp numbers. The id of a channel is the channel_id you send messages from.WhatsApp only lets a business write first with an approved template. GET /templates?channel_id={id}&status=APPROVED lists the templates this number can send, with their variables.
4

Send your first message

POST /conversations sends a first message to a contact and opens (or continues) the conversation.
The response holds the conversation and the sent message. Keep conversation.id: you use it to reply, take the conversation over or read its messages.
5

Receive the replies

When the contact answers, the agent attached to the channel replies automatically. To follow the conversation from your system, create a webhook endpoint subscribed to message.*.

Next steps

Authentication

API keys and their permissions.

Message format

Text, templates, interactive messages and media.

Webhooks

Receive signed events in real time.

The 24-hour rule

When WhatsApp accepts free text, and when it needs a template.