AI Agents

Build intelligent Telegram bot with AI reasoning

8 nodes 367 211 Automatic trigger
Download

Workflow Description

Automation that connects Telegram to OpenAI through an intelligent agent. The bot receives messages, processes them with memory-aware reasoning, executes HTTP tools when needed, and sends responses automatically.

How it works

  1. 1.Activate Telegram trigger to listen for incoming messages
  2. 2.Route message to AI agent connected to OpenAI
  3. 3.Maintain conversation history using sliding window memory
  4. 4.Execute HTTP requests to fetch external data when required
  5. 5.Send generated response back to user via Telegram

Use cases

  • Customer support bot that answers questions with conversation context
  • Personal assistant that gathers web data and provides summaries
  • Marketing bot delivering personalized recommendations based on chat history

Requirements

  • OpenAI API key with suitable model access
  • Telegram bot token from BotFather
  • Stable internet connection

Service Value

Ideal as a smart automation service combining integrations and AI to produce ready-to-use results.

Apps Used

OpenAI Memory Telegram HTTP Request AI Agent

Details

Trigger Automatic trigger
Nodes 8
Apps 5
Views 367
Downloads 211

How to Use

  1. 1.Click "Download Template"
  2. 2.Open your n8n dashboard
  3. 3.Go to Workflows > Import from File
  4. 4.Select downloaded file and configure credentials

Nodes Used (8)

OpenAI Chat Model

OpenAI

#1

Window Buffer Memory

Memory Buffer Window

#2

Listen for incoming events

Set

#3

Sticky Note

Sticky Note

#4

Send final reply

Set

#5

Send back an image

Set

#6

Generate image in Dalle

HTTP Request

#7

AI Agent

Agent

#8