Templates / Telegram AI bot-to-human handoff for sales calls

Telegram AI bot-to-human handoff for sales calls

Needs changes

by Jimleuk ✓ · 17,905 views · created 2025-03-29 · Lead Nurturing, AI Chatbot

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 30 nodes and runs on Telegram events (message) (plus 1 other trigger). Along the way it connects Telegram, Redis, OpenAI Chat Model and Redis Chat Memory.

How it runs

Trigger: On Telegram events (message) (plus 1 other trigger).

  1. Get Interaction State (Redis): get
  2. Notify user (Telegram): uses Telegram
  3. Switch: routes items into 2 branches
  4. Set Interaction to Human (Redis): set
  5. Get Canned Response (Telegram): uses Telegram
  6. After Sales Agent (AI Agent): runs an AI agent, with model: Model; 1 tool (Handoff Tool); memory: Memory
  7. Onboarding Agent (AI Agent): runs an AI agent, with model: Model; memory: Memory
  8. Human Handoff using Send and Wait (Telegram): send and wait for a reply
  9. Send Response (Telegram): uses Telegram
  10. Get Onboarding Chat History (Redis): get

…plus 10 more steps. See the full node list below.

Services it uses

TelegramRedisOpenAI Chat ModelRedis Chat Memory

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • AI Agent v1 (old agent modes) in Onboarding Agent (v1.8), After Sales Agent (v1.8): replace with Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.
Removed in 3.0Replace with
AI Agent v1 (old agent modes)
Onboarding Agent (v1.8), After Sales Agent (v1.8)
Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.

Nodes used (14)

From the author

This n8n template demonstrates an approach to perform bot-to-human handoff using Human-in-the-loop functionality as a switch. In this experiment, we play with the idea of states we want our agent to be in which controls it's interacton with the user. First…

Excerpt from Jimleuk's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.