An AI agent on WhatsApp for business: two setups and when to use each
Customers writing to your WhatsApp Business number, or you talking to your own flows from your phone: how each setup works, what it can answer, and what to avoid.
Part of the guide AI employees
An AI agent on WhatsApp for business comes in two shapes. In the first, your customers write to your own WhatsApp Business number and an agent answers them in the same chat, looking things up as it goes. In the second, only you write, from your own phone to xMap's WhatsApp number, and one of your own flows answers you. Both use the same AI agent block; what differs is who is on the other end and which number carries the messages.
This article is for owners and operations teams deciding which of the two they need, and how to set it up so the answers are short, correct and safe. It is not about managing your AI employees by message (changing a schedule or pausing a flow): that is Ask xMap's job, covered in changing an AI employee from WhatsApp.
Setup one: customers write to your number
Here the flow starts with the WhatsApp Business message event. Every message a customer sends becomes one run: an item with what they wrote and who wrote it. An AI agent reads it, decides whether it needs to look anything up, and writes an answer. A Reply block at the end sends that answer back into the same conversation, through the same account. Reply works out the channel by itself from the block that started the run, so there is nothing to address.
The agent's usefulness comes from its tools: the blocks you link to the purple Tools dot under it. Typical ones on WhatsApp:
- Nearby places with its point written as {{agent: where to look}}, so a customer who says near the mall in Makati gets the closest few places with their phone and rating.
- My data or Look things up in for your own branches, opening hours, price list or delivery zones, so answers come from your documents rather than the AI's guesses.
- Weather forecast or Traffic incidents when people ask whether a trip or a delivery makes sense today.
Memory set to Per conversation keeps each customer's last messages, keyed by their phone number, so a follow-up such as and the one on Ayala Avenue? is understood.
Setup two: you talk to your own flow
Start a flow with the Chat block instead and switch on Chat from my WhatsApp. Once your number is confirmed in Settings, Your WhatsApp, what you write to xMap's number can reach that flow, with nothing to connect. Only the flow's owner can use it, and only while the flow is live.
On xMap's number, Ask xMap answers you first. Write @ and the flow's name before a question to ask your flow once, or talk to and its name to keep it answering, and talk to xMap to go back. This suits a sales lead who wants a pocket research assistant built on live location data, not a customer service line.
| Customers on your number | You on xMap's number | |
|---|---|---|
| Starts with | WhatsApp Business message event | Chat, with Chat from my WhatsApp on |
| Who writes | Anyone who messages your business | Only the flow's owner |
| Account needed | Your WhatsApp Business account, connected | Nothing to connect; your number confirmed |
| Answer goes back through | Reply, on your account | xMap's number |
The two setups side by side.
A worked example (made up)
Say a chain of laundromats in Manila gets the same three questions all day: where is the nearest branch, is it open now, and how much is a wash and fold. The owner builds this flow:
- Connect the WhatsApp Business account under Connections.
- Start the flow with its message event.
- Add an AI agent. Instructions: You answer customers of our laundromats. Find their nearest branch, say whether it is open, quote prices only from the price list, and keep answers under four lines.
- Set Look things up in to the price list file and the branches table, and link a My data tool holding the branch addresses.
- Under Protection, set Stay on these topics to branches, opening hours, prices, services.
- End with Reply, its text {{reply}}, then Deploy.
A customer writes open now near Quezon Avenue?. The agent looks up the branches, finds the two closest, checks their hours and replies with both and their addresses. The next day the same customer asks how much for a duvet?; the agent quotes the line from the price list and nothing else.
Mistakes to avoid
- Shared memory for customers. Memory set to Shared by the whole flow is one conversation for everyone, so one customer could be told what another wrote. Keep Per conversation for customer chats.
- Prices from thin air. If the price list is not a file the agent can search, it will improvise. Give it the document and tell it to quote only from it.
- A schedule at the start. Reply needs someone to answer. A flow started by a Schedule has nobody on the other end: send by Email or an app block instead.
- Sending tools with no check. If the agent can add a row to a sheet or send an email, link an Approval after it so those sends wait for a person while the customer still gets an answer at once.
- No topic limits. Without Protection, a public number will be asked about anything. Narrow topics and the refusal of attempts to change its rules keep it on the job.
What it costs and what you can see
Each message is one run. The agent's thinking steps and each tool it calls are charged like the same blocks in any flow, and an answer through an app counts as one message. A test run tries the flow on an example message and only shows the answer; Run once and the live flow reply for real. Afterwards the flow's ... menu, Conversations, lists who wrote and what was said, and each run's See how it answered shows which tools the agent used and what came back.
Questions
Can the agent answer on my existing business number?
Yes, when that number is a WhatsApp Business account you connect under Connections. The flow then starts from its message event and Reply answers through it.
Can my customers use Chat from my WhatsApp?
No. That switch only lets the flow's owner talk to the flow through xMap's number. Customers write to your own business number.
Does it remember a customer who comes back next week?
With Memory set to Per conversation it keeps the last 20 messages of each conversation for 30 days, and with Remember about each person on it also keeps short notes about the person.
What if a customer asks something the agent cannot answer?
Tell it in its instructions what to say then, such as offering a phone number or a person, and set Stay on these topics so off-topic questions get a polite no.
Templates that do this
Read next
More on ai employees and automation · Every article · Templates