Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.1to1ai.com/llms.txt

Use this file to discover all available pages before exploring further.

This guide takes you from zero to your first WhatsApp message sent through the API.
1

Get your API key

The API key is issued from the dashboard, under Settings → API. It has the sk_1to1_ prefix.
The API key grants full access to your business’s conversations. Treat it as a secret — never put it in client-side code or commit it to a repository.
2

Identify your business

Every endpoint hangs off a base URL that includes your business’s {slug}:
https://app.1to1.ai/api/v1/public/{slug}
The {slug} is also in the API settings. The key and the slug must belong to the same business.
3

Send your first message

A POST to the text endpoint, with the conversation identified by phone:
curl -X POST "https://app.1to1.ai/api/v1/public/{slug}/conversation/messages/text" \
  -H "Authorization: Bearer sk_1to1_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "conversation": { "phone": "+5215512345678" },
    "body": "Hi 👋, how can I help you?"
  }'
4

Handle the response

A 201 response confirms the send:
{ "message_uuid": "...", "wamid": "..." }
Errors return { code, message? } with a 4xx or 5xx status. Switch on code (stable), never on message (which may change):
{ "code": "WINDOW_CLOSED", "message": "..." }
Rate limit: 60 requests per minute per API key. When exceeded you get a 429 with the Retry-After header. See Rate limits.

Next steps

Conversations

How to identify a conversation and the 24h window.

Messages

The four ways to send a message.