🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

WhatsApp meets Telegram for organized customer threads

Lisa Granqvist Partner Workflow Automation Expert

Your WhatsApp inbox gets messy fast. One customer sends three messages, another changes their number format, and suddenly your team is scrolling, guessing, and accidentally replying out of context.

This WhatsApp Telegram automation hits support leads first, but e-commerce founders and ops folks feel it too. You get one clean Telegram topic per customer, so handoffs stop breaking and “who replied to this?” stops being a daily question.

Below, you’ll see how the workflow routes incoming WhatsApp messages into the right Telegram thread, then sends agent replies back to WhatsApp automatically.

How This Automation Works

Here’s the complete workflow you’ll be setting up:

n8n Workflow Template: WhatsApp meets Telegram for organized customer threads

Why This Matters: WhatsApp Support Turns Into Inbox Chaos

If you’re handling more than a handful of WhatsApp conversations per day, the cracks show quickly. A single “inbox” is not a system. Agents jump between chats, copy-paste order numbers into internal notes, and lose context the moment a customer sends “any update?” three days later. It’s not just time wasted. It’s mental load, duplicated work, and those small mistakes that create refunds, escalations, and bad reviews. Honestly, the worst part is that you can’t scale it with headcount alone because the chaos scales too.

The friction compounds. Here’s where it breaks down in real teams.

  • Important messages get buried when multiple agents share one WhatsApp inbox or device.
  • Handoffs are fragile because the “history” lives in someone’s scrolling finger, not a structured thread.
  • Customers resend details, so you spend time re-asking questions you already had yesterday.
  • Managers can’t easily audit what’s happening without reading an endless chat log.

What You’ll Build: Two-Way WhatsApp ↔ Telegram Topics Sync

This workflow turns WhatsApp into your customer-facing channel and Telegram into your internal “case management” space, without building a new app. When a WhatsApp message arrives, n8n checks a mapping table (stored in Supabase/Postgres) to see if that phone number already has a Telegram topic. If it exists, the message is posted into that topic so the conversation stays contained. If it’s a new customer, the workflow creates a fresh Telegram forum topic, saves the mapping (phone number ↔ topic ID), and then posts the message there. On the other side, when an agent replies inside the Telegram topic, the workflow validates it’s a topic reply, looks up the linked WhatsApp number, and sends the response back through the WhatsApp Cloud API.

The workflow starts from two triggers: an inbound WhatsApp webhook and an inbound Telegram webhook. In the middle, it uses lookups, merge steps, and message formatting (plus optional AI) to keep context clean. Finally, it posts to the right Telegram topic and dispatches the right WhatsApp reply automatically.

What You’re Building

Expected Results

Say your team handles about 200 WhatsApp conversations a day. If agents spend even 2 minutes per conversation finding history, confirming the latest update, and figuring out who owns it, that’s roughly 6 hours of pure “where are we at?” time daily. With this workflow, each customer lands in their own Telegram topic automatically, so context is already there. Replies go out from Telegram with no copy-paste, which usually gives teams a few hours back every day once volume ramps.

Before You Start

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • WhatsApp Cloud API for receiving and sending customer messages
  • Telegram Bot + Supergroup with Topics to host customer threads internally
  • Supabase/Postgres credentials (get them from your Supabase project settings or Postgres host)

Skill level: Intermediate. You’ll be comfortable editing HTTP request steps, adding credentials, and testing webhooks end-to-end.

Want someone to build this for you? Talk to an automation expert (free 15-minute consultation).

Step by Step

A WhatsApp message arrives. The workflow is triggered by your WhatsApp webhook. n8n grabs the sender phone number and the message content, then prepares it for lookup and posting.

The workflow checks for an existing customer thread. It queries your Supabase/Postgres table (the thread mapping) to see if this phone number already has a Telegram topic ID. A quick conditional decides which path to take.

It posts into Telegram in the right place. If the topic exists, the workflow posts the message into that existing topic via HTTP request. If not, it creates a new Telegram topic, stores the new mapping, and then posts the first message into the new thread.

An agent reply goes back to WhatsApp. A Telegram trigger listens for replies, validates they are topic messages (not random group chatter), looks up the mapped phone number, and dispatches the WhatsApp response automatically.

You can easily modify the customer label formatting to include order status or priority tags based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Telegram Trigger

Set up the Telegram intake so replies from your supergroup can be captured and validated before forwarding to WhatsApp.

  1. Add and open Incoming Telegram Trigger.
  2. Credential Required: Connect your telegramApi credentials.
  3. In Updates, keep message selected.
  4. Open Extract Reply Messages and set superGroupID to [YOUR_ID].
  5. In Extract Reply Messages, set message to {{ $json.message.text }}.
  6. Configure Validate Incoming Topic with both conditions: {{ $('Incoming Telegram Trigger').item.json.message.chat.id }} equals {{ $json.superGroupID }} and {{ $json.message }} exists.

⚠️ Common Pitfall: The superGroupID in Extract Reply Messages must match your Telegram supergroup ID or Validate Incoming Topic will block the flow.

Step 2: Connect WhatsApp and Supabase Services

Connect the inbound WhatsApp trigger and database nodes that map WhatsApp numbers to Telegram topics.

  1. Open Inbound WhatsApp Trigger and select Credential Required: Connect your whatsAppTriggerApi credentials.
  2. Open Fetch Thread Mapping and set Table to wa_tg_threads, Operation to get, and filter telegram_topic_id with {{ $('Incoming Telegram Trigger').item.json.message.message_thread_id }}.
  3. Credential Required: Connect your supabaseApi credentials to Fetch Thread Mapping, Insert Thread Mapping, Retrieve Existing Threads, and Lookup Order By Phone.
  4. In Retrieve Existing Threads, set filters for phone_e164 to {{ $json.customerPhone }} and supergroup_id to [YOUR_ID].
  5. In Lookup Order By Phone, set Table to orders and filter phone_number with {{ $('When Executed by Another Workflow').item.json.customerPhone }}.

Tip: Keep the Supabase table names and column IDs exactly as shown (wa_tg_threads, orders, phone_e164, telegram_topic_id) to avoid empty lookups.

Step 3: Set Up Data Mapping and Parallel Enrichment

This workflow enriches WhatsApp messages with customer details and order lookup data, then composes a label for Telegram topics.

  1. Configure Assign Supergroup ID with superGroupID set to [YOUR_ID].
  2. Note the parallel branch: Assign Supergroup ID outputs to both Lookup Order By Phone and Map Customer Details in parallel.
  3. In Map Customer Details, set customerName to {{ $('When Executed by Another Workflow').item.json.customerName }} and CustomerPhone to {{ $('When Executed by Another Workflow').item.json.customerPhone }}.
  4. In Blend Order Lookup, set Join Mode to {{ $items("Lookup Order By Phone").length > 0 ? "enrichInput1" : "enrichInput2" }} and map fields CustomerPhonephone_number.
  5. In Compose Customer Label, set CustomerName to {{ $items("Lookup Order By Phone").length > 0 ? $items("Lookup Order By Phone")[0].json.customer_name + " (" + $items("Lookup Order By Phone")[0].json.phone_number + ")" : $json.customerName + " (" + $items("Map Customer Details")[0].json.CustomerPhone + ")" }}.
  6. In Combine Customer Data, set Join Mode to {{ $items("Retrieve Existing Threads").length > 0 ? "enrichInput1" : "enrichInput2" }} and map customerPhonephone_e164.

Tip: The merge nodes rely on exact field names (CustomerPhone, phone_number, customerPhone, phone_e164)—keep casing consistent.

Step 4: Configure WhatsApp Reply Dispatch

When a Telegram reply is validated, the workflow looks up the WhatsApp mapping and sends the response back to the customer.

  1. Open Fetch Thread Mapping and confirm it runs after Validate Incoming Topic.
  2. Open Dispatch WhatsApp Reply and set Operation to send.
  3. Credential Required: Connect your whatsAppApi credentials.
  4. Set phoneNumberId to [YOUR_ID].
  5. Set textBody to {{ $('Extract Reply Messages').item.json.message }} and recipientPhoneNumber to {{ $json.phone_e164 }}.

⚠️ Common Pitfall: If Fetch Thread Mapping doesn’t return phone_e164, Dispatch WhatsApp Reply will fail—ensure the mapping exists in wa_tg_threads.

Step 5: Route WhatsApp Messages to Telegram Topics

This section posts incoming WhatsApp messages into an existing Telegram topic or creates a new one if no thread exists.

  1. Confirm Inbound WhatsApp Trigger flows into Retrieve Existing Threads and then Combine Customer DataAssign Supergroup ID.
  2. In Check Prior Conversation, keep the condition {{ $items('Retrieve Existing Threads').length > 0 }} set to true for the existing-thread branch.
  3. Open Post to Existing Topic and set URL to https://api.telegram.org/bot[CONFIGURE_YOUR_TOKEN]/sendMessage with body parameters: chat_id = {{ $('Assign Supergroup ID').item.json.superGroupID }}, message_thread_id = {{ $items("Retrieve Existing Threads").last().json.telegram_topic_id }}, text = {{ $('When Executed by Another Workflow').item.json.customerMessage }}.
  4. Open Generate Telegram Topic and set URL to https://api.telegram.org/bot[CONFIGURE_YOUR_TOKEN]/createForumTopic with body parameters chat_id = {{ $('Assign Supergroup ID').item.json.superGroupID }} and name = {{ $('Compose Customer Label').item.json.CustomerName }}.
  5. Open Insert Thread Mapping and set fields phone_e164 = {{ $('Map Customer Details').item.json.CustomerPhone }}, telegram_topic_id = {{ $json.result.message_thread_id }}, supergroup_id = {{ $('Assign Supergroup ID').item.json.superGroupID }}.
  6. Open Post to New Topic and set URL to https://api.telegram.org/bot[CONFIGURE_YOUR_TOKEN]/sendMessage with body parameters: chat_id = {{ $('Assign Supergroup ID').item.json.superGroupID }}, message_thread_id = {{ $('Generate Telegram Topic').item.json.result.message_thread_id }}, text = {{ $('When Executed by Another Workflow').item.json.customerMessage }}.

⚠️ Common Pitfall: Replace [CONFIGURE_YOUR_TOKEN] in all Telegram HTTP URLs or requests will fail with authorization errors.

Step 6: Test and Activate Your Workflow

Validate both Telegram-to-WhatsApp replies and WhatsApp-to-Telegram topic posting before enabling the workflow.

  1. Click Execute Workflow and send a Telegram message in the target supergroup to trigger Incoming Telegram Trigger.
  2. Confirm the reply passes Validate Incoming Topic and that Dispatch WhatsApp Reply sends a message to the mapped WhatsApp number.
  3. Send a WhatsApp message to the connected number to trigger Inbound WhatsApp Trigger and verify it posts to an existing topic or creates a new one via Generate Telegram Topic and Post to New Topic.
  4. Verify Supabase records are created or retrieved correctly in wa_tg_threads after the run.
  5. When successful, switch the workflow to Active to run in production.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Troubleshooting Tips

  • WhatsApp Cloud API credentials can expire or need specific permissions. If things break, check your Meta Developer access token and phone number ID configuration first.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Telegram bot permissions matter more than people expect. Make sure the bot can post in the supergroup and create/send messages in Topics, or the “create topic” HTTP request will fail silently.

Quick Answers

What’s the setup time for this WhatsApp Telegram automation?

About 1–2 hours once your WhatsApp and Telegram credentials are ready.

Is coding required for this WhatsApp Telegram automation?

No. You will mostly connect accounts and edit a few request fields. The only “technical” part is copying API values into the right n8n credential slots.

Is n8n free to use for this WhatsApp Telegram automation workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in WhatsApp Cloud API usage costs from Meta and any OpenAI usage if you enable the AI Agent nodes.

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I modify this WhatsApp Telegram automation workflow for different use cases?

Yes, and you should. You can change how topics are named by editing the “Compose Customer Label” Set node, and you can swap the database behind “Retrieve Existing Threads” and “Insert Thread Mapping” if you prefer a different Postgres setup. Common customizations include routing VIP customers to a dedicated supergroup, attaching order status from your order lookup step, and adding an “after-hours” auto-reply when no agents are online.

Why is my WhatsApp connection failing in this workflow?

Most of the time it’s an expired Meta access token or the wrong phone number ID. Refresh the token in your WhatsApp Cloud API credentials, then confirm your webhook is still subscribed to message events. If failures happen only during high volume, you may also be hitting rate limits, which means you’ll want retry logic or a queue.

What volume can this WhatsApp Telegram automation workflow process?

On n8n Cloud, your limit is based on plan executions per month, so higher message volume usually means a higher tier. If you self-host, there’s no fixed execution cap, but your server size and database performance become the real limit. Practically, this workflow is lightweight per message (a couple of lookups and sends), so most teams can run hundreds of conversations per day without breaking a sweat. If you’re pushing into the thousands daily, tune your database indexes on phone numbers and add basic retry handling on the HTTP request steps.

Is this WhatsApp Telegram automation better than using Zapier or Make?

For this workflow, n8n has a few advantages: more complex logic with unlimited branching at no extra cost, a self-hosting option for unlimited executions, and native database-style workflows (lookups, merges, conditional routing) that get awkward fast in simpler builders. Zapier or Make can work for basic forwarding, sure, but the “topic per customer” mapping is the part that usually needs real control. If you care about auditability, you’ll like having the mapping table in Supabase/Postgres. If you care about scale, you’ll like not paying per tiny step. Talk to an automation expert if you want help choosing the simplest option for your volume.

Once this is running, every customer gets a real thread and your team gets real breathing room. The workflow keeps the context organized so you can focus on solving problems, not hunting for them.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal