Playbook · 5 minute read
How to Build a WhatsApp AI Agent (Playbook)
To build a WhatsApp AI agent, set up the WhatsApp Business Platform with compliant opt-in and message templates, verify customer identity before disclosing account information, ground answers in approved knowledge with escalation to humans, expose actions through tools that require in-chat confirmation, handle media and language variety, log conversations under privacy rules, and evaluate accuracy and action safety before launch.
For many customers, WhatsApp is the preferred channel for talking to a business. Its rules on opt-in, templates, and messaging windows are strict, its conversations mix text, voice notes, and images, and its users expect fast, human-quality replies. A WhatsApp AI agent that succeeds respects the platform, verifies identity, stays grounded, and confirms before acting. This playbook covers the build, following FISTA's AI agents practice and the customer-service patterns in how to build an ai customer service agent. FISTA itself uses WhatsApp as its primary contact channel, so the constraints here are familiar.
What does the agent do?
| Capability | Requirement |
|---|---|
| Inbound conversations | Business platform integration; session management within messaging windows |
| Outbound notifications | Opt-in; approved templates |
| Answers | Grounded retrieval with citations; escalation on uncertainty |
| Account information | Identity verification first; user-scoped tools |
| Actions | Tools with in-chat confirmation; consequence gates |
| Media | Voice note transcription; image handling per use case |
| Handoff | Human agent with context |
Step 1: Set up the platform and policy compliance
Onboard to the WhatsApp Business Platform through the official API, establish opt-in capture for business-initiated messages, design and submit message templates for notifications, and design conversation flows around the customer service window rules. Confirm current platform policies with compliance before launch, since they evolve. Specification practice is in how to write an ai spec.
Step 2: Design identity verification
Treat the phone number as identification, not authentication. Before disclosing or changing account information, verify through a one-time code to a registered channel, an authenticated deep link, or knowledge checks according to your security policy, and bind the session to the verified identity for a bounded time. Verification gates all account tools. Design is in ai identity verification and ai access control.
Step 3: Ground answers and design escalation
Connect to the enterprise retrieval layer over approved customer-facing content with citations and refusal on missing evidence, and design escalation triggers: low confidence, complaints, legal or safety topics, repeated failure, or customer request. Handoff passes the transcript, context, and attempted actions to the human agent's tool and tells the customer a person is joining. Architecture is in the enterprise RAG reference architecture whitepaper and ai agent human oversight.
Step 4: Build actions with in-chat confirmation
Expose actions through tools with contracts and consequence levels. The agent proposes the action with details and asks for explicit confirmation in the chat; the tool executes under the verified identity; the result is confirmed back. Consequential actions such as payments or cancellations follow policy gates and may require additional verification. Tool design is in how to build tool use for llm agents.
Step 5: Handle media and languages
Transcribe voice notes with a speech pipeline and confirm understanding for consequential requests; handle images per use case (receipts, product photos) with extraction and validation; detect language and respond in it within the supported set, with glossaries for product terms. Speech and translation patterns are in how to build a speech-to-text pipeline and how to build an ai translation workflow.
Step 6: Enforce privacy and content rules
Store conversations under privacy policy with retention, redact sensitive data in logs, never disclose account information without verification, apply output validation against commitments and prohibited content, and provide clear notice that the customer is talking to an automated assistant with a path to a human. Guidance is in ai data privacy compliance and ai transparency notices.
Step 7: Evaluate
Build a golden set from real conversations across intents, languages, media types, and edge cases, including angry customers and adversarial attempts to extract information or trigger actions. Measure answer accuracy and groundedness, verification compliance, action correctness and confirmation, refusal and escalation correctness, leakage, and injection resistance. Harness design is in how to build an agent evaluation harness.
Step 8: Launch and monitor
Launch in agent-assist mode where human agents approve drafts, or to a limited customer segment with tight sampling; monitor accuracy on sampled conversations, verification and confirmation compliance, handoff rate and resolution, satisfaction, latency, and platform quality ratings; expand on evidence. Observability design is in the AI observability whitepaper.
Worked example: an appliance retailer
An appliance retailer deploys a WhatsApp agent for delivery scheduling, order status, and product questions. Opt-in is captured at checkout and templates are approved for delivery notifications. Product and policy questions are answered from the approved knowledge base with citations. Order status requires a one-time code to the registered email before disclosure; delivery rescheduling is proposed with the new slot and confirmed by the customer in chat before the tool updates the logistics system. Voice notes are transcribed and the agent confirms its understanding before acting. Complaints route to a human agent with the transcript. Evaluation confirms that a crafted message cannot extract another customer's order details and that rescheduling never executes without confirmation. After a segment pilot, resolution without handoff rises for scheduling and status intents while complaints continue to reach humans quickly.
What does it cost to run?
Cost scales with conversation volume, platform messaging fees, and model, retrieval, and transcription calls per conversation. Value is measured in cost per resolved conversation and satisfaction against the baseline. Drivers are in ai chatbot maintenance cost.
What are the common mistakes?
- Treating the phone number as authentication.
- Ignoring opt-in and template rules until the account is restricted.
- Answering from unapproved content.
- Actions without in-chat confirmation.
- Handoff that drops the customer into a queue with no context.
- Launching to all customers on day one.
This guide is general guidance, not legal advice; confirm messaging consent, platform policy, and privacy obligations with counsel before launch.
How FISTA Solutions builds WhatsApp agents
FISTA Solutions builds WhatsApp AI agents to this playbook: platform-compliant setup, identity verification before account access, grounded answers with escalation, tool-based actions with in-chat confirmation, media and language handling, privacy rules, golden-set evaluation with leakage and injection tests, and staged launch. The AI agents practice delivers the agent, AI enablement the retrieval, speech, and tool platform, and forward deployed engineers embed with your customer operations team. The record behind the work is 150+ projects with 99.9% uptime.
To scope a WhatsApp agent, message FISTA on WhatsApp, or read chatbot vs voice agent for channel comparisons.
Share-ready article cover
Download the generated social format.
Clear answers
Questions raised by this field note.
Straightforward guidance for evaluating scope, fit, and the next step.
01What can a WhatsApp AI agent do?
Answer product and policy questions from approved knowledge, check order and account status after verification, take routine actions such as rescheduling or address updates with in-chat confirmation, send templated notifications within platform rules, and hand off to human agents with context when needed.
02What are the compliance requirements for WhatsApp business messaging?
Customer opt-in for business-initiated messages, approved message templates for outbound notifications, respect for the customer service messaging window for free-form replies, clear business identification, and adherence to the platform's commerce and content policies. Requirements change; verify current policy before launch.
03How do you verify identity on WhatsApp?
Treat the phone number as a hint, not proof. Before disclosing or changing account information, verify through a one-time code to a registered channel, an authenticated link, or knowledge checks per your security policy, and scope the session to the verified identity.
04How does handoff to a human agent work?
Escalation triggers such as low confidence, complaints, or customer request route the conversation to a human agent in the contact center tool with the full transcript, retrieved context, and attempted actions, and the customer is told a person is joining. Measure handoff rate and resolution.
05How do you evaluate a WhatsApp agent?
With a golden set of real conversations covering intents, languages, media, and edge cases, measuring answer accuracy and groundedness, verification compliance, action correctness with confirmation, refusal and escalation correctness, leakage, and injection resistance, then monitoring satisfaction and resolution in production.
Continue exploring
Related capabilities
Start with the hard problem
Need the outcome owned, not merely analyzed?
Tell us where delivery is constrained. We’ll map the fastest credible path from intent to verified production.