Skip to main content

Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection

Workflow preview

Workflow preview
100%
Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Purpose and Audience This n8n workflow automates the entire lead nurturing process from initial contact through a 3 email follow up sequence, with intelligent reply detection and personalized AI ge...

Best for

  • Lead Nurturing automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.telegramtrigger, @n8n/n8n-nodes-langchain.chainllm, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.datatable, n8n-nodes-base.set, n8n-nodes-base.emailsend, n8n-nodes-base.telegram

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Malik Hashir.

Original n8n.io source

1.1 Workflow description

Title
Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection
Workflow name
Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection

Purpose and Audience

This n8n workflow automates the entire lead nurturing process from initial contact through a 3-email follow-up sequence, with intelligent reply detection and personalized AI-generated content. It's designed to save sales teams countless hours while maintaining a personal touch in every interaction.

What It Does

This workflow orchestrates a comprehensive lead management system that:

  1. Captures leads via Telegram: Sales agents submit lead information (name, company, email, notes) through a Telegram bot after phone calls
  2. Generates personalized emails: Uses AI (Google Gemini) to create contextually relevant, personalized emails based on conversation notes and sequence position
  3. Sends automated follow-ups: Delivers a 3-email nurture sequence with strategic timing (initial email, 24-hour follow-up, final follow-up)
  4. Tracks engagement: Monitors email opens and replies in real-time
  5. Detects responses: Automatically checks Gmail daily for lead replies and stops the sequence when detected
  6. Updates lead status: Maintains accurate lead status throughout the journey (active → 2nd follow-up sent → 3rd follow-up sent → replied)
  7. Provides real-time notifications: Sends Telegram alerts to agents when emails are sent, replies are received, or sequences complete
  8. Stores all communications: Archives email content and metadata in a structured data table for reference and analysis

The workflow intelligently adapts email tone and content based on sequence position—warm and conversational for first contact, value-adding for second follow-up, and brief yet respectful for the final touchpoint.

Who Is It For

This workflow is perfect for:

  • Sales teams managing multiple leads and needing consistent follow-up without manual effort
  • Small businesses looking to professionalize their outreach without hiring additional staff
  • Account executives who want to focus on conversations rather than email scheduling
  • Founders and solopreneurs juggling sales alongside other responsibilities
  • Marketing agencies managing client outreach campaigns
  • Anyone who has promising leads but struggles with timely, personalized follow-up

How to Setup

Prerequisites Before implementing this workflow, ensure you have:

  • Telegram Bot (for lead submission and notifications)
  • SMTP Connection (for sending emails)
  • Gmail Node Connection (for reply detection)
  • Data Table with the following columns: name email company notes status emailSequenceNumber lastSentDate first_email_content first_email_sbjct second_email_content second_email_sbjct third_email_content third_email_sbjct (Table name: leads_test)
  • Gemini API Key (for AI-powered email generation)

Setup Instructions

Once you have all prerequisites ready, follow the provided setup tutorials for complete setup and configuration.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Telegram Input - Agent Submits Lead

Type / Role
n8n-nodes-base.telegramTrigger - telegramTrigger
Config choices
Version 1.2

Block 2 - AI - Parse Lead Data

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.6

Block 3 - Gemini Model - Parser

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 4 - JSON Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.2

Block 5 - Insert row

Type / Role
n8n-nodes-base.dataTable - dataTable
Config choices
Version 1

Block 6 - Initialize Lead Tracking

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 7 - AI - Generate Personalized Email

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.6

Block 8 - Gemini Model - Email Generator

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 9 - Email JSON Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.2

Block 10 - Set Email

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 11 - Send email

Type / Role
n8n-nodes-base.emailSend - emailSend
Config choices
Version 2.1

Block 12 - Update row(s)

Type / Role
n8n-nodes-base.dataTable - dataTable
Config choices
Version 1

Block 13 - Notify Agent - Email Sent

Type / Role
n8n-nodes-base.telegram - telegram
Config choices
Version 1.2

Block 14 - Is This a Reply from Lead?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 15 - Notify Agent - Reply Received

Type / Role
n8n-nodes-base.telegram - telegram
Config choices
Version 1.2

Block 16 - Mark Lead as Replied

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 17 - Daily Reply Check (9 AM)

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 18 - Get row(s)

Type / Role
n8n-nodes-base.dataTable - dataTable
Config choices
Version 1

Block 19 - Get many messages

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 20 - Mark As Replied

Type / Role
n8n-nodes-base.dataTable - dataTable
Config choices
Version 1

Block 21 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 22 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 23 - Daily Follow-up Check (10 AM)

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 24 - Get row(s)1

Type / Role
n8n-nodes-base.dataTable - dataTable
Config choices
Version 1

Showing the first 24 of 47 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection
Complexity advanced
Nodes 47
Categories Lead Nurturing, Multimodal AI
Author Malik Hashir
Published 28 Nov 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/11337/11337.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Automated lead nurturing with Gemini AI, Telegram, and Gmail reply detection do?

Purpose and Audience This n8n workflow automates the entire lead nurturing process from initial contact through a 3 email follow up sequence, with intelligent reply detection and personalized AI ge...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Lead Nurturing, Multimodal AI use case.