← Back

BOTON API

Integrate BOTON with your CRM, server, or any automation. Send WhatsApp messages, read conversations, and configure your bot — all via REST API.

Authentication

Each business has its own token. Generate it in Dashboard → API Access.

Include in every request: Authorization: Bearer <token>

GET /api/v1/status

Connection status and bot configuration
# Example
curl -H "Authorization: Bearer YOUR_TOKEN" \
  https://boton.kilazi.com/api/v1/status
// Response
{
  "business": "Mi Negocio",
  "connected": true,
  "phone": "5491138620812",
  "botPurpose": "attend",
  "botNewChats": false,
  "activeBotChats": 12,
  "untouchableChats": 2
}

GET /api/v1/chats

Paginated chat list
page
Page (from 0)
pageSize
Items per page (max 50, default 20)
curl -H "Authorization: Bearer YOUR_TOKEN" \
  https://boton.kilazi.com/api/v1/chats?page=0&pageSize=20
// Response
{
  "chats": [
    {
      "jid": "5491112345678@s.whatsapp.net",
      "name": "Juan",
      "lastMessage": { "text": "hola", "direction": "incoming", "timestamp": "..." },
      "messageCount": 8,
      "botEnabled": true
    }
  ],
  "total": 45, "page": 0, "hasMore": true
}

GET /api/v1/chats/:jid/messages

Messages from a specific chat
limit
Number of messages (max 200, default 50)
curl -H "Authorization: Bearer YOUR_TOKEN" \
  https://boton.kilazi.com/api/v1/chats/5491112345678@s.whatsapp.net/messages
// Response
{
  "jid": "5491112345678@s.whatsapp.net",
  "messages": [
    { "text": "hola", "direction": "incoming", "timestamp": "...", "botGenerated": false }
  ]
}

POST /api/v1/send

Send message to one or multiple numbers. Use message for direct text, or instruction to have the bot start the conversation with an instruction.
# Direct message
curl -X POST -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"to":"5491112345678","message":"Hola, tu turno es manana a las 15hs"}' \
  https://boton.kilazi.com/api/v1/send
# Send to multiple + bot instruction
curl -X POST -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"to":["5491112345678","5491198765432"],"instruction":"Ofrece turno para manana"}' \
  https://boton.kilazi.com/api/v1/send
to
Number or array of numbers (with country code, no +)
message
Text to send directly
instruction
Instruction for the bot — enables bot for that chat

POST /api/v1/config

Configure the assistant (all fields optional)
curl -X POST -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"botPurpose":"attend","botNewChats":true,"customInstructions":"Responde solo en espanol"}' \
  https://boton.kilazi.com/api/v1/config
businessName
Business name
businessDescription
Description
botPurpose
attend | schedule | support | sell
guardrails
Bot rules
customInstructions
Additional instructions
botNewChats
Bot handles new chats automatically (true/false)
Webhook from your server: Use POST /api/v1/send from your CRM, calendar, or any system to send messages automatically. For example, when a customer books an appointment, your server can call BOTON to send the confirmation via WhatsApp.