Skip to main content

Build a text & image responding Telegram bot with Google Gemini 2.5 Flash

Workflow preview

Workflow preview
100%
Build a text & image responding Telegram bot with Google Gemini 2.5 Flash preview
Open on n8n.io

Important notice

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

1. Workflow Overview

Telegram AI Bot Workflow An intelligent Telegram bot powered by Google Gemini AI that provides smart responses to both text messages and images. Features Multi Modal Input : Handles both text messa...

Best for

  • Support Chatbot automation workflows
  • AI Chatbot automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.agent, @n8n/n8n-nodes-langchain.memorybufferwindow, n8n-nodes-base.set, n8n-nodes-base.switch, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.googlegemini, n8n-nodes-base.telegramtrigger

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Build a text & image responding Telegram bot with Google Gemini 2.5 Flash
Workflow name
Build a text & image responding Telegram bot with Google Gemini 2.5 Flash

Telegram AI Bot Workflow

An intelligent Telegram bot powered by Google Gemini AI that provides smart responses to both text messages and images.

Features

  • Multi-Modal Input: Handles both text messages and image uploads
  • AI-Powered Responses: Uses Google Gemini 2.5 Flash for intelligent reply generation
  • Image Analysis: Automatically analyzes uploaded images and responds with descriptions
  • Conversation Memory: Maintains context across 20 messages per conversation
  • Formatted Output: Delivers well-structured, Telegram-friendly responses

How It Works

  1. User sends a message (text or image) to the Telegram bot
  2. Workflow routes the input based on message type
  3. Images are downloaded and analyzed using Gemini Vision AI
  4. AI agent processes the input with conversation context
  5. Formatted response is sent back to the user instantly

Requirements

  • Telegram Bot Token (from @BotFather)
  • Google Gemini API Key
  • n8n instance with webhook capability

Perfect for building interactive AI assistants, customer support bots, or educational tools on Telegram.

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 - Sticky Note

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

Block 2 - Sticky Note1

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

Block 3 - Sticky Note2

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

Block 4 - Sticky Note3

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

Block 5 - Sticky Note4

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

Block 6 - Knowledge Base Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 1.9

Block 7 - Simple Memory

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 8 - Map image prompt

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

Block 9 - Map text prompt

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

Block 10 - Route Types

Type / Role
n8n-nodes-base.switch - switch
Config choices
Version 3.2

Block 11 - Google Gemini Chat Model

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

Block 12 - Analyze image

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

Block 13 - Telegram Trigger

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

Block 14 - Get a file

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

Block 15 - Send a text message

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

3. Summary Table

Workflow Build a text & image responding Telegram bot with Google Gemini 2.5 Flash
Complexity advanced
Nodes 15
Categories Support Chatbot, AI Chatbot
Author Ahmed Sherif
Published 04 Oct 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/9265/9265.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 Build a text & image responding Telegram bot with Google Gemini 2.5 Flash do?

Telegram AI Bot Workflow An intelligent Telegram bot powered by Google Gemini AI that provides smart responses to both text messages and images. Features Multi Modal Input : Handles both text messa...

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 Support Chatbot, AI Chatbot use case.