Build an advanced conversational Telegram bot using this powerful n8n workflow template. Integrates GPT-4o, persistent chat memory, and DALL-E for image generation.
Download this n8n workflow template and start using it instantly.
Markdown-formatted:
Automation specialists looking for advanced n8n templates integrating LangChain.
Developers wanting to deploy a feature-rich AI bot via Telegram.
Users seeking to implement contextual chat memory and external tools within an n8n workflow.
Anyone interested in seeing how the LangChain n8n node set enables complex AI agents.
This comprehensive n8n workflow provides a robust solution for deploying an intelligent, agentic AI assistant directly within Telegram. Unlike basic chatbots, this advanced system utilizes LangChain nodes to give the AI memory and external tool-use capability. The n8n workflow starts with a message from Telegram and routes it through a GPT-4o powered agent. When a user requests an image, the agent leverages a dedicated DALL-E generation tool configured within this n8n template, providing a seamless multi-modal experience. This is a crucial n8n workflow for showcasing the power of integrated AI services.
Markdown-formatted:
Markdown-formatted:
Markdown-formatted:
Listen for incoming events (Telegram Trigger): The starting n8n trigger. It listens for all updates () in the bot, initiating the n8n workflow upon receiving a user message.
OpenAI Chat Model (LangChain Node): Configured to use gpt-4o with a temperature of 0.7 and a slight frequencyPenalty of 0.2. It serves as the Large Language Model for the agent's core reasoning.
Window Buffer Memory (LangChain Node): Manages conversation history. It uses a dynamic sessionKey based on the Telegram chat.id to ensure unique, contextual memory for each user. It maintains a context window length of 10 messages.
AI Agent (LangChain Node): The orchestrator of this n8n workflow. It receives the user's message and the system message instructs it to address the user by their first name and to prioritize image generation if requested.
Generate image in Dalle (LangChain Tool): A crucial custom tool within the n8n workflow. It is configured as an HTTP POST request to the DALL-E API. The tool description explicitly guides the AI Agent to call this tool when the user asks to draw or generate an image.
Send back an image (Telegram Tool): Used specifically by the AI Agent to process the URL output from the DALL-E tool and send the resulting image document back to the user's chat ID.
Send final reply (Telegram Node): The concluding n8n node, responsible for sending the final text output (the conversation response or a notification) back to the user.
Automatically monitor competitor affiliate programs using this powerful n8n workflow. Scrape offer details, perform AI analysis, log data to Google Sheets, and send urgent Slack alerts.

Use this powerful n8n workflow to capture leads from your website form, standardize international phone numbers using a custom n8n node, manage duplicates in Pipedrive CRM, and initiate instant follow-up via WhatsApp.

Deploy a professional Telegram ticketing system using this comprehensive n8n workflow. Features include live chat, Redis user management, broadcasting, and rate limit handling.

Use this robust n8n workflow to automatically aggregate conversations from Slack, Teams, Gmail, and GitHub, analyze them using Anthropic's Claude 4.5, and update your Notion and Confluence documentation instantly. Save hours on manual knowledge transfer.








































