5 steps
WhatsApp & Telegram AI chatbot
When a customer writes on WhatsApp or Telegram, the AI Chatbot answers from your knowledge base and, at the right moment, asks for contact details and creates a lead. When it isn't sure, or the customer asks for a person, the conversation is handed to your team.
Required integrations
Budget cap: At most $0.5 per run
What this template does
This template hands every incoming message to the AI Chatbot. The bot first reads the conversation history, then searches your knowledge base and writes a short, chat-sized reply in the customer's language. Product, price, shipping, return and opening-hours facts come only from the knowledge base; when it can't find an answer, it says it will check with the team instead of making one up.
With every reply the bot returns a confidence score between 0 and 1 and a handoff decision. If confidence drops below 0.4, the customer asks for a person, or a complaint, refund or legal topic comes up, the conversation is handed to your team; otherwise the reply goes out right away on the same channel. You answer handed-off chats from the Inbox and click Give back to bot when you're done.
Because Collect contact details is on, customers who show purchase or booking intent are asked for their name and email or phone at a natural point and saved as leads. The run budget is $0.50; since every message is a separate run, choosing an economy model at high volume lowers costs noticeably.
Step-by-step flow
- 01
Message received
Message receivedStarts the workflow when a message arrives at the WhatsApp number or Telegram bot connected to your project. It doesn't fire for conversations a teammate has taken over, so the bot never talks over you.
Reads the conversation history, searches the knowledge base and writes a 1–3 sentence reply in the customer's language. When it sees purchase or booking intent it asks for contact details and creates a lead; every reply carries a confidence score and a handoff decision.
- 03
Human needed?
IfAn If node checks the bot's handoff decision (
{{ $json.handoff === true }}). The “true” branch goes to Hand off to human, the “false” branch to Send reply.- if yes → Hand off to human
- if no → Send reply
- 04
Hand off to human
Hand off to humanSets the conversation to “Human”, pauses the bot for that chat and notifies the team in-app and by email with the handoff reason. This node doesn't message the customer on its own; you reply from the Inbox.
- 05
Send reply
Send messageSends the bot's reply to the same channel and contact the message came from. Since the customer has just written to you, WhatsApp's 24-hour free-form window is open and no template is needed.
How to customise it
- Pick the Knowledge base the bot should answer from on the AI Chatbot node. Indexing documents requires an OpenAI key (the platform's or your own).
- Fill in Team working hours, e.g.
09:00-18:00 Europe/Istanbul, so the handoff message tells customers when to expect an answer. - To tell the customer about a handoff, add a second Send message after Hand off to human; in that case the bot's reply says a teammate will take over.
- To add channels, select Slack, Discord, Messenger or SMS (Twilio) on the trigger; the account must be connected to the same project.
- If the bot hands off too often, lower the Hand-off threshold to 0.3 and enrich the knowledge base; if it rarely does, raise it to 0.5.
Agents used
Frequently asked questions
What kind of WhatsApp account do I need?
A number on Meta's WhatsApp Business Platform (Cloud API). If the number is currently registered in the WhatsApp or WhatsApp Business app, you have to delete that account first; most businesses get a new number for the bot.
What does the bot say when it doesn't know the answer?
It doesn't guess: it says it will check with the team and marks its confidence as low. When the score falls below the threshold, the conversation is handed to you automatically.
Can I message a customer after 24 hours?
On WhatsApp, once 24 hours have passed since the customer's last message, only Meta-approved templates can be sent. This template replies right after the customer writes, so the window is open; for later messages use the template field on the Send message node.
Does the same bot work on WhatsApp and Telegram?
Yes. One workflow listens to both channels and replies on whichever channel the message came from.
How do I test it before going live?
The Test button in the editor fires the trigger with a sample message; in a test run the Send message node doesn't send anything and you see the reply in the Output tab. Then activate the workflow and text it from your own phone.
Get started with OrqLabs
Build your first workflow today
Start on the free plan: connect your accounts, pick a template and stay in control with approval steps. No credit card required.