Blog

    AI Chatbots for WhatsApp: Opt-In, the Customer Service Window and Template Messages

    By GauravSeptember 10, 20269 mins read
    On this page

    AI chatbots for WhatsApp let a business answer customers in an app they already use, but WhatsApp sets firm rules on who a business may message, when and how. A bot that ignores opt-in, the customer service window or template approval will see messages fail and puts the business account at risk.

    Startup founders and product and engineering leaders will find how opt-in works, what the 24-hour window allows, when templates are needed, where AI fits under Meta's terms and how to hand a chat to a person.

    How do AI chatbots for WhatsApp work within Meta's rules?

    AI chatbots for WhatsApp answer customers through the WhatsApp Business Platform, replying freely inside the 24-hour customer service window and using approved templates outside it, only for people who opted in. Agnotic Technologies builds these bots so the AI handles routine questions within those rules and hands the conversation to a person when it should.

    Planning an AI chatbot on WhatsApp?

    We build the bot, the rules layer for windows and templates, and the handoff to your team.

    The platform sets the boundaries and the AI works inside them. Most design decisions follow from three rules: who you may message, when you may message freely and what happens when a person asks for a human.

    What does the customer service window allow?

    The customer service window allows free-form replies for a limited time after the customer last wrote, and that window is where a bot does most of its work.

    Inside the window, the AI can answer questions, ask follow-ups and send order details in free-form messages. Outside it, the system needs a template.

    • Track the window per conversation: store the time of the customer's last message and work out when the window closes.
    • Check before sending: every outbound message from the bot or an agent is checked against the window first.
    • Switch to templates: once the window has closed, the system offers only approved templates.
    • Show the window to agents: a person picking up a chat sees how long they can still reply freely.

    When do you need template messages?

    You need template messages whenever the business starts a conversation or replies after the customer service window has closed. Templates are written in advance and approved before use.

    • Order and delivery updates sent after the customer's last message has aged out of the window.
    • Appointment reminders and booking confirmations.
    • A follow-up when an agent could not answer inside the window.
    • Marketing messages, only for people who agreed to receive them.

    Templates are not written by the AI at send time. The bot can choose which approved template to send and fill its variables, such as a name or an order number, but the wording stays fixed.

    How should opt-in and opt-out work?

    Opt-in and opt-out should work as records your system checks before every proactive message, because WhatsApp's policy makes consent a condition of contact.

    The WhatsApp Business Messaging Policy lets a business contact people only if they gave it their number and agreed to hear from it on WhatsApp, requires it to respect every request to block, stop or opt out, and requires automated experiences to offer prompt, clear and direct escalation paths such as a human agent, phone, email or a support form.

    • Capture: where and when the person agreed, the business name they agreed to hear from and the wording they saw.
    • Scope: which kinds of messages they agreed to, such as order updates only or marketing as well.
    • Opt-out: a stop request in the chat or through any other channel updates the record straight away.
    • Check: every template send checks the opt-in record for that person and message type first.

    Where does AI fit under Meta's terms?

    AI fits under Meta's terms when it supports the business's own service, and the terms restrict platforms whose main offering is general-purpose AI.

    For most businesses the AI is incidental to their service: it answers questions about their own orders, bookings or products. A general-purpose assistant offered on WhatsApp as the product itself is a different case, so check the current terms against your plan before you build.

    Design the bot around your business tasks. Ground its answers in your own data, such as order status, policies and catalog, and keep it from drifting into open-ended conversation unrelated to your service.

    Handing a chat to a person

    The bot should hand a chat to a person when the customer asks, when it cannot answer with confidence, or when the topic needs human judgment, and the handoff should carry the conversation so far.

    • Triggers: the customer asks for a person, repeats a question, or raises a complaint, refund or safety issue.
    • Context: the agent sees the transcript, the customer's orders and what the bot already tried.
    • Window: if the handoff comes late, the agent sees the time left and the template to use afterwards.
    • Out of hours: the bot says when a person will reply, and the next staff message may need a template.

    How do teams build a WhatsApp AI chatbot step by step?

    Teams build a WhatsApp AI chatbot by setting up the platform account, defining the bot's tasks and building the rules layer before tuning the AI.

    • Step 1, set up: a WhatsApp Business Platform account through Meta's Cloud API or a solution provider, with a verified business and phone number.
    • Step 2, define tasks: list the questions and actions the bot handles, and those it must hand over.
    • Step 3, connect data: the order, booking or account systems the bot reads to answer.
    • Step 4, write templates: draft and submit the templates you will need outside the window.
    • Step 5, build the rules layer: window tracking, opt-in checks and handoff triggers around the AI.
    • Step 6, test: real conversations from your support history, including angry, off-topic and unclear ones.
    • Step 7, launch in stages: a share of incoming chats first, with agents reading transcripts.

    Grounding answers in your own data

    Grounding keeps the AI answering from your systems instead of guessing. The bot retrieves the facts it needs for each reply and is told to say when it does not know.

    • Order status, delivery dates and refund state come from your systems by API at the moment of the question.
    • Policies and product details come from an approved, versioned knowledge base.
    • Answers that commit the business, such as a refund decision, go to a person or follow a fixed rule.
    • Every bot reply is logged with the data it used, so a wrong answer can be traced.

    Measuring the bot after launch

    Measure the bot by whether customers get answers and how often people have to step in, not by message counts.

    • Handoff rate and reasons: which topics the bot passes to people, and why.
    • Repeat contacts: customers who come back with the same question soon after the bot answered.
    • Failed sends: messages rejected because the window had closed or a template was missing.
    • Transcript reviews: a weekly sample read by a support lead, with fixes fed into the knowledge base.

    Template performance matters too. If customers rarely reply to a template, its wording or timing may need to change, and each new version needs approval again before it can be sent.

    What are the common mistakes with AI chatbots on WhatsApp?

    The common mistakes with AI chatbots on WhatsApp come from building the AI first and the platform rules second.

    • Free-form messages after the window closes: they fail, and the customer hears nothing.
    • A website form treated as opt-in for everything: marketing reaches people who agreed to order updates only.
    • No real handoff: the bot loops when a customer asks for a person.
    • An AI that promises refunds or dates it cannot check.
    • Opt-out requests made outside the chat, such as by email or phone, are ignored.

    What does a WhatsApp AI chatbot mean for your build plan?

    A WhatsApp AI chatbot needs the platform setup, a rules layer for window, opt-in and templates, the AI with access to your data, an agent inbox for handoffs, and logging. The rules layer is small, but everything depends on it.

    • Decide which tasks the bot owns and which go straight to people.
    • List the templates you need and plan their approval before launch.
    • Choose the agent inbox, your current help desk or a new one, and how chats move into it.
    • Agree how conversations are stored and for how long, under your privacy rules.

    How does Agnotic build WhatsApp AI chatbots?

    Agnotic builds the WhatsApp integration, the rules layer for opt-in, windows and templates, the AI grounded in your systems, the handoff into your agent inbox and the logs behind every reply. We design the bot around your customers' real questions and Meta's current policies.

    A WhatsApp bot that follows the rules

    Opt-in checked, windows tracked, templates ready and a person one message away.

    Sources

    Frequently Asked Questions

    No. Free-form replies are allowed inside the 24-hour customer service window. Outside it, the business can send only pre-approved template messages, and only to people who opted in.

    Talk to an engineer about your project

    Tell us what your customers ask on WhatsApp today. We will map the tasks, the templates and the handoff before any AI is tuned.