WhatsApp Chatbot: How it Works and How to Create One
WhatsApp is the preferred communication channel. Learn how a WhatsApp chatbot works in practice and why AI agents are the next step for high-performance enterprise operations.

Marlos Carmo
Founder of Tolky
Updated on November 15, 2026

Share
If you opened WhatsApp today to solve a problem with a company, there is a good chance a bot answered you. The WhatsApp chatbot is no longer a novelty: it is part of customer service in Brazil, where WhatsApp is among the most used messaging apps, with estimates of roughly 147 to 148 million users (Statista, via Forbes Brasil; eMarketer, via Carta Capital).
But "chatbot" now covers very different things. On one side, rigid rule-based bots: the numeric menus that frustrate customers who type something unexpected. On the other, conversational AI agents: systems that understand natural language, keep the context of the conversation and take actions, such as looking up a record or issuing a duplicate invoice. That difference separates a truly AI-powered chatbot from legacy solutions.
In this guide you will see how the technology works, a six-step process to build yours, and where Tolky fits in.
How a WhatsApp chatbot works
A WhatsApp chatbot is software that receives customer messages, processes the content and returns an automatic reply. For that to be official, secure and scalable, everything depends on the type of connection you have with Meta (WhatsApp's owner). There are two main paths:
1. WhatsApp Business app (basic automation)
Designed for small businesses, the free app supports greeting messages, away messages and quick replies.
- How it works: the automation runs inside the app, on a phone.
- Limitations: no complex dynamic flows, no generative AI, and the operation is limited to a few linked devices (up to 4).
2. WhatsApp Business API (scalable, official automation)
For larger operations, the path is the official WhatsApp Business API. It has no chat interface of its own: it is a bridge that connects the company number to a service and automation platform.
- How it works: when a customer sends a message, Meta fires a webhook (a data notification) to the platform that runs the chatbot. The platform processes the text, decides the reply and sends it back to Meta through the API.
- Advantages: several simultaneous agents, system integrations, generative AI automation and outbound messages through message templates (templates approved by Meta). Note: using the API does not remove the risk of restrictions. Poor opt-in, low quality and customer complaints can limit your number even on the API.
| Feature | WhatsApp Business app | WhatsApp Business API (official) |
|---|---|---|
| Target audience | Micro businesses and freelancers | Mid-size and large companies |
| Agents | Up to 4 linked devices | No app device limit (number of users depends on the platform plan) |
| System integration | None (manual) | Via webhooks and APIs |
| Costs | Free | Charged per delivered message, by category (see new pricing) |
| Generative AI / agents | Not natively supported | Integrable through a platform |
What does it cost? Since 07/01/2025 Meta charges per delivered message (Marketing, Utility and Authentication) and, since 10/01/2026, Service messages too, with 1,000 free Service messages per number each month. See the details and use the pricing simulator to estimate your volume; the full explanation is in WhatsApp Business new pricing.
Step by step: how to build a WhatsApp chatbot
Building a chatbot on the official API involves steps with Meta and steps of experience design. Following the right order avoids rework and blocks.
Step 1: Business portfolio and verification
- Go to Meta Business Suite and create or open your company's business portfolio.
- Complete Business Verification (company tax ID and supporting documents). The messaging limit is set per business portfolio, not per number: it starts at 250 unique contacts per day and, with verification, can reach 2,000, then scales automatically with volume and quality.
Step 2: Choose how to connect the number
- New (or migrated) number: the number lives on the API and leaves the app. If it was already in the app, you need to migrate it.
- Coexistence: in some cases the same number can be used in the WhatsApp Business app and on the Cloud API at the same time, syncing up to 180 days of individual-chat history. Some app features are lost (groups, broadcast lists and calls, for example) and throughput is fixed at 20 messages per second. Availability depends on your number and country: confirm before planning.
Step 3: Connect through a platform
Since the API has no interface of its own, you need a platform to manage contacts and design replies. Tolky connects your official number to the AI agent and the service interface, so you do not have to build the infrastructure.
Want to start without building infrastructure? Talk to Tolky.
Step 4: Templates, opt-in and customer identification
- Create and submit for approval the message templates for outbound messages (outside the 24-hour window only approved templates can be sent) and record customer opt-in.
- Define intents, data to collect (tax ID, order number) and frequently asked questions.
- Think about customer identification: with WhatsApp usernames, a customer may arrive identified by a BSUID rather than a phone number. See BSUID and usernames: what changes.
Step 5: End-to-end test
Before opening to customers, validate: the webhook receives and replies; a conversation inside the 24-hour window; a template sent outside the window; and the handoff to a human agent with the conversation context. A bot should never be a dead end.
Step 6: Measure and improve
Track resolution, handoffs, response time and cost per message category. Review conversations transferred to humans and fill gaps in the knowledge base.
From rule-based chatbots to artificial intelligence
The traditional button chatbot works on a closed decision tree ("Press 1 for Sales, 2 for Support"). If the customer writes "I want to buy product X", the rule-based bot breaks because it only expects the number "1". Generative AI (LLMs) analyzes the intent of the message instead of predicting every phrasing.

What AI changes
- Natural language: customers can write with slang, abbreviations or typos. "I want to pay my invoice" and "where do I get a copy of my bill" lead to the same action.
- Context memory: if the customer says "the tracking code doesn't work" and then "and where do I see the delivery?", the AI understands that "the delivery" refers to the code mentioned before.
- Answers generated from your own base: instead of canned phrases, the agent consults company documentation and writes a reply that fits the case.
For the full comparison, read Conversational AI is not a chatbot.
Beyond the chatbot: Tolky's operational vision
A chatbot only talks. An efficient operation needs to solve problems. That is why Tolky works as an operational layer of AI agents connected to your company's channels (WhatsApp, webchat, Microsoft Teams and voice today; other channels appear as "coming soon" on tolky.to).
1. Agents that act
Instead of just explaining where to click to get a duplicate invoice, the agent can query the system and deliver the document. This uses function calling: the AI understands the need and calls APIs to run the task. Example conversation:
| Who | Message |
|---|---|
| Customer | "I need a copy of the October invoice." |
| Tolky agent | Identifies the customer, queries billing and replies: "I found the October invoice. Here is the PDF and the payment code." |
| Customer | "Thanks!" |
2. Integration with your systems
To solve real requests, AI needs up-to-date data. Tolky connects to CRMs, management systems and databases through integrations and APIs. Ask the Tolky team which integrations are available for your case.
3. Answers grounded in your base (RAG)
The usual fear with generative AI is hallucination, when the bot makes things up. Tolky uses RAG (Retrieval-Augmented Generation): answers are grounded in the manuals and knowledge bases you load into the platform, which greatly reduces that risk. No AI is infallible, so the right design includes handoff to a human when confidence is low.
4. Handoff with a summary for the agent
When a conversation calls for sensitivity or negotiation, the agent hands off to a human with a summary of what was already said. The agent does not need to read dozens of messages to take over. The knowledge base is edited by the business team itself, without code.
The impact on results
- Costs: in operations with many repetitive questions, the share that can be automated depends on your contact base. Measure your own deflection (conversations resolved without a human) before and after instead of assuming a market figure.
- Availability: immediate service 24 hours a day, including holidays and weekends.
- Resolution time: transactional questions solved on the spot, freeing the human queue for complex cases.
- Sales: the faster the first reply, the better the chance of qualifying a lead. A classic Harvard Business Review study compares replies within an hour with slower ones (The Short Life of Online Sales Leads, HBR, 2011).
If your company still sees WhatsApp as a channel for an agent with five tabs open or a numeric-tree bot, the opportunity cost grows every month. The future of customer service is an intelligent assistant that solves problems and knows when to hand over to a person.
Ready to turn your WhatsApp into an intelligent operation? Talk to Tolky, see plans and pricing or compare in alternatives.
Share
Tags
- whatsapp chatbot
- how to create whatsapp chatbot
- #artificial intelligence
- #ai agents
- #whatsapp customer service
- meta api
About the author

Marlos Carmo
Founder of Tolky
Marlos Carmo is an AI entrepreneur and founder of Tolky, the conversational-era infrastructure and AI CRM that unifies intelligent service, multi-channel support (such as WhatsApp and voice), live CRM, and operational intelligence in a single ecosystem. He is a finalist for the SXSW Innovation Awards and a member of Francesco's Economy, a global network of young entrepreneurs focused on innovation and social impact. He works connecting Artificial Intelligence and digital transformation in projects for large organizations.
Next step
Want to bring this to your operation?
Tati, Tolky's AI assistant, understands your scenario in a few questions, suggests the best path and connects you with someone from the team, with full context.


