This workflow turns your WhatsApp Business number into a 24/7 AI-powered customer assistant — without any third-party chatbot platform. It receives incoming WhatsApp messages via Evolution API, understands the customer's intent, generates a conversational response using Claude AI, and sends it back — all within seconds.
When the conversation requires human attention, the bot alerts you on Telegram and automatically pauses itself for that contact in your Notion CRM so you can take over seamlessly.
This is a production-ready workflow built to handle real inbound traffic. It has been tested with cold outreach leads, inbound inquiries, and voice messages.
Multi-modal input
Handles both text messages and voice notes. Voice messages are transcribed via OpenAI Whisper before being processed by the AI.
Smart auto-reply filter
A Sentiment Analysis node detects automatic replies (out-of-office bots, delivery confirmations) and silently discards them before the AI agent triggers — preventing the bot from responding to other bots.
Notion CRM integration
Every incoming message is matched against your Notion database by phone number. Known leads get their status updated. New contacts are created automatically. The bot also checks a WA ChatBot Status field (Active/Paused) before responding — so you can pause the bot per contact directly from Notion.
Outreach-aware responses
If you use WhatsApp for cold outreach (paired with an outreach workflow), this bot reads the lead's personalization_note and pain_point from Notion and uses them to personalize replies. The AI knows who contacted whom first and adjusts its tone accordingly.
Human-in-the-loop escalation
When the AI detects buying intent, frustration, or a request it cannot handle, it:
WA ChatBot Status = Paused in Notion for that leadDynamic knowledge base (Google Sheets)
Business info, products/services, and FAQs live in a Google Sheet with 3 tabs. Update your sheet — the bot adapts instantly. No redeployment needed.
Format Cleaner
AI responses are automatically stripped of markdown before sending (WhatsApp renders **bold** as literal asterisks — this node fixes that).
Conversation memory
Uses n8n's buffer window memory with phone number as session key. Remembers the last 10 message exchanges per contact.
WhatsApp Message
↓
Evolution API Webhook
↓
Detect Message Type (normalize payload)
↓
Skip Event? (groups, fromMe, empty text) → skip silently
↓
Is Voice? → Prepare Audio → Transcribe (Whisper)
↓
Sentiment Analysis → Automatic Reply? → skip silently
↓
Check Leads (Notion DB lookup by phone)
↓
Normalize & Match → is_known_lead, bot_status, outreach context
↓
Bot Status = Paused? → skip silently
↓
Information Extractor (intent, reply_sentiment, urgency, needs_human)
↓
Read Business Info + Products + FAQs (Google Sheets)
↓
Build Context (combines KB + lead context)
↓
Wait 10s (avoids responding before user finishes typing)
↓
Generate Response (Claude Haiku, conversation memory)
↓
Format Cleaner (strip markdown)
↓
Send WhatsApp Reply (Evolution API)
↓
Format for Log → Log Conversation (Google Sheets)
↓
Alert Owner? → IF needs_human:
→ Telegram alert
→ Pause ChatBot (Notion update: WA ChatBot Status = Paused)
↓
Phone Match (known lead?)
→ Update Lead Status (Last Contact + WA Status)
→ Create New Lead (if new contact)
↓
Respond 200 OK
| Credential | Used for |
|---|---|
| Anthropic API | Information Extractor + Response Generation (Claude Haiku) |
| OpenAI API | Voice transcription (Whisper) — optional if no audio support needed |
| Google Sheets OAuth2 | Knowledge base reads + conversation log |
| Notion API | Lead lookup, BotStatus check, lead update/create |
| Telegram Bot | Human-in-the-loop alerts |
Copy the template sheet and fill in your data:
Get your FREE Sheets Template
Business_Info (columns: business_info, value)
Rows: business_name, business_description, website, email, hours, coverage_area, booking_url, response_tone
Products (columns: product_id, name, description, category, available, highlight)
FAQs (columns: question, answer, category)
Conversation_Log (columns: timestamp, channel, user_id, username, user_name, message_type, message, response, intent, needs_human)
| Field | Type |
|---|---|
| Name (title) | Title |
| Phone | Phone number |
| Status | Status |
| WA ChatBot Status | Select (options: Active, Paused) |
| WA Status | Select (options: Positive Reply, Negative Reply, Neutral Reply) |
| Lead Source | Select |
| Last Contact | Date |
| Personalization Note | Rich text |
| Pain Point | Rich text |
💡 A ready-to-use Notion CRM template pre-configured for this workflow is available separately.
https://YOUR-EVOLUTION-DOMAIN/message/sendText/YOUR-INSTANCE-NAMEhttps://YOUR-N8N-URL/webhook/evo-inbound, events: MESSAGES_UPSERT + CONNECTION_UPDATE, Base64: ON, webhookByEvents: OFFThe system prompt in the Generate Response node is where you define your bot's personality and conversation rules. It already includes:
Edit it to match your industry, tone, and specific business logic.
This chatbot is designed to work as the inbound layer of a complete WhatsApp automation stack:
When all three are connected, your entire WhatsApp funnel runs on autopilot.
Check Leads node fetches all leads with a phone number from Notion and matches in JavaScript. This works well for databases up to ~1,000 leads. For larger CRMs, consider filtering by phone number directly in the Notion query.Is Voice? branch entirely.Mark Cifral — System Sales Engineer turned automation founder. I build production-grade n8n workflows for B2B lead enrichment, WhatsApp AI agents, and proposal automation. Founder @ Cifral Solutions (cifral.io).