WhatsApp Business API for AI Agents
Let AI agents send, receive, schedule, automate and analyze WhatsApp communication through MCP or REST API — on the official, Meta-approved WhatsApp Business API.
More than sending messages
There is a difference between an AI that can send a WhatsApp message and an AI that can understand and operate your WhatsApp channel. Gambot exposes the whole business workflow around WhatsApp — messaging, templates, contacts, conversations, campaigns, scheduling, automations and analytics — not just a single send endpoint.
Business facts and state (is the 24-hour window open? is a template required? which contact matched?) come back from the API as structured, machine-readable fields. The Gambot MCP server turns those states into next-action guidance, so an agent recovers intelligently instead of failing on a raw error.
Real agent workflows
Ask in natural language; the agent uses the safest appropriate Gambot workflow.
You How many WhatsApp messages did we receive today?
Agent 147 messages were received today. 32 were new leads. 11 conversations are waiting for a response. (Illustrative example — real numbers come from your analytics endpoints.)
You Send a follow-up to every lead that hasn't replied in 48 hours.
You Schedule this WhatsApp campaign for tomorrow at 10 AM.
You Summarize today's customer service conversations.
You Which conversations need human attention?
You How did yesterday’s campaign perform?
Example figures above are illustrative, not Gambot statistics. Real values are computed from your own account’s data.
Capabilities exposed to agents
Send
Free-text (inside the 24h window) and approved templates to one recipient — via messages/send-text & send-template.
Receive
List conversations, read message history, and inbound webhooks for real-time events.
Schedule
One-time or recurring campaigns that run automatically at the scheduled time.
Campaign
Broadcasts to tags, lists, CRM segments or spreadsheets, with opt-out & consent handled for you.
Analyze
Message volume, conversations waiting for reply, leads, cases, tasks and campaign results.
Automate
Keyword auto-replies, menu bots and template-button flows created programmatically.
Customer service
Conversation status, SLA (who is waiting and for how long), notes and case management.
Human handoff
Flag conversations that need a person and route by owner, status or category.
Your AI agent understands WhatsApp rules
When an agent tries to send a free-form message and the 24-hour customer-service window is closed, Gambot does not just return a generic Meta error. It returns a normalized state: code: CONVERSATION_WINDOW_CLOSED with data: { canSendFreeText: false, canSendTemplate: true }.
Through MCP, that becomes an actionable recommendation — use an approved template to (re)open the conversation — so the agent picks the correct next step automatically. The same pattern applies to missing template variables, ambiguous or missing contacts, invalid phone numbers, rate limits and confirmation-required broadcasts.
Two ways to connect
- MCP (Model Context Protocol) — the fastest path for AI clients. Add the Gambot MCP server to ChatGPT, Claude, Gemini or Cursor and the agent gets WhatsApp tools instantly.
- REST API — build your own agent or backend against the WhatsApp Business API for developers. Same business logic, machine-readable states and error codes.
- Wondering whether to build on Meta’s Cloud API yourself? See Gambot vs building on Meta’s Cloud API directly — same official API, none of the infrastructure to build.
Build with Gambot
Create a free account, connect WhatsApp, and give your AI agent a real WhatsApp Business API to operate.
Frequently asked questions
Can an AI agent both send and understand WhatsApp activity?
Yes. Beyond sending messages and templates, agents can read conversations, query analytics (messages received/sent, conversations waiting for a reply, leads, campaign results) and manage CRM data — so they can reason about the operation, not just push messages.
How do agents recover from errors like a closed 24-hour window?
The API returns a machine-readable code (e.g. CONVERSATION_WINDOW_CLOSED) plus state flags (canSendFreeText, canSendTemplate). The Gambot MCP layer converts this into a recommended next action — for example, send an approved template — so the agent recovers without guessing.
Will an agent message the wrong person if a name is ambiguous?
No. Gambot returns structured results for lookups and does not silently pick a recipient when there is ambiguity; the agent is guided to disambiguate first.
Is this the official WhatsApp Business API?
Yes. Gambot is an official Meta Business Solution Provider, so agents operate on the authorized WhatsApp Business (Cloud) API.
Which AI clients are supported?
Any MCP-compatible client — including ChatGPT, Claude, Gemini and Cursor — plus any custom agent or backend via the REST API.