n8n + Telegram Integration: Build Powerful Bot Automations
The n8n Telegram integration is one of the most versatile connections you can set up in your automation stack. Telegram's Bot API is fast, free, and incredibly flexible — and when you wire it into n8n's workflow engine, you get a real-time messaging layer that can trigger actions, deliver alerts, collect user input, and route conversations across your entire tool stack. Whether you're building internal DevOps alerts or a customer-facing support bot, this combination handles it elegantly.
Why Connect Telegram to n8n?
Telegram stands out among messaging platforms for automation because of its Bot API. Unlike Slack or Discord, creating a Telegram bot is instant — you message @BotFather, get an API token, and you're live. There are no app review processes, no OAuth scopes to negotiate, and no rate limits that get in the way of reasonable usage.
Here's what makes the pairing powerful:
- Real-time triggers: n8n's Telegram Trigger node uses webhooks, so your workflows fire instantly when a message arrives — no polling delays.
- Two-way communication: You can both receive messages (trigger node) and send messages (action node), enabling full conversational workflows.
- Rich message formats: Send text, photos, documents, videos, location pins, and inline keyboards — all from n8n nodes.
- Group and channel support: Post to groups, channels, or individual chats — useful for team alerts, community updates, or one-on-one support.
- No cost: Telegram's Bot API is completely free regardless of message volume.
For teams already using Telegram internally, plugging it into n8n turns it from a chat app into an automation control center.
Setting Up the Telegram Node in n8n
Getting the Telegram node connected takes about five minutes. Here's the process:
Step 1: Create your bot with BotFather. Open Telegram, search for @BotFather, and send /newbot. Follow the prompts to name your bot. BotFather will return an API token — copy this.
Step 2: Add Telegram credentials in n8n. In your n8n instance, go to Credentials → New → Telegram API. Paste your bot token. Save. That's the entire authentication setup.
Step 3: Get your Chat ID. For sending messages, you need the target chat ID. The easiest method: add your bot to the target group or start a conversation with it, send a message, then use the Telegram Trigger node in n8n to capture the incoming message — the chat ID will be in the payload at message.chat.id.
Step 4: Choose your node. n8n provides two Telegram nodes:
- Telegram Trigger: Starts a workflow when a message, command, callback query, or other update arrives.
- Telegram: The action node — sends messages, photos, documents, edits messages, answers callback queries, and more.
Tip: If you're running n8n on n8nautomation.cloud, webhook URLs work out of the box with HTTPS — no need to configure reverse proxies or SSL certificates yourself.
5 Telegram Automation Workflows You Can Build Today
These are real, practical workflows using actual n8n nodes. Each one can be built in under 30 minutes.
1. Server Monitoring Alerts
Use a Schedule Trigger node to ping your services every 5 minutes with an HTTP Request node. Add an IF node to check for non-200 status codes. When something's down, fire a message to your ops Telegram group via the Telegram node with the service name, status code, and timestamp. Simple, effective, and faster than waiting for an email alert.
2. Form Submission Notifications
Connect a Webhook node to your website's contact form. When a submission comes in, use a Set node to format the data cleanly, then send a summary to your sales team's Telegram group. Include an inline keyboard with buttons like "Respond" and "Mark as Spam" — handle button presses with a separate workflow using the Telegram Trigger's callback query event.
3. Daily Digest Bot
Set up a Schedule Trigger for 8 AM daily. Pull data from multiple sources — open tickets from your project management tool using the relevant API node, revenue numbers from a Google Sheets node, and deployment status via the GitHub node. Merge everything with a Code node that formats a clean daily summary, then send it to your team channel.
4. Two-Way Support Bot
Use the Telegram Trigger node to capture incoming customer messages. Route them through a Switch node based on keywords — billing questions go to one path, technical issues to another. Create tickets automatically in your helpdesk using an HTTP Request node, and send the customer an acknowledgment with a ticket number. When agents respond in the helpdesk, a separate webhook-triggered workflow pushes the reply back to Telegram.
5. RSS-to-Telegram Content Feed
Use the RSS Feed Read node to check industry blogs on a schedule. Filter for relevant keywords with an IF node, then post curated links to your Telegram channel. Add a Summarize node powered by an AI model to generate a one-line summary for each article before posting. Your channel gets a curated, AI-summarized news feed on autopilot.
Working with Telegram Bot Commands in n8n
Telegram bots support slash commands like /start, /help, and custom commands you define. In n8n, the Telegram Trigger node can filter for specific updates, including messages that contain commands.
Here's how to build a command-driven bot:
Set up your Telegram Trigger node with the "message" update type. After the trigger, add a Switch node that checks the value of {{ $json.message.text }}. Create outputs for each command:
/status— queries your monitoring stack and returns current system health/deploy— triggers a deployment pipeline via a webhook to your CI/CD system/report— generates and sends a PDF report from your analytics database/help— sends a formatted message listing all available commands
For commands that need parameters (like /deploy production), use a Code node to parse the message text:
const parts = $input.first().json.message.text.split(' ');
const command = parts[0];
const args = parts.slice(1);
return [{ command, args, chatId: $input.first().json.message.chat.id }];
This gives you a lightweight ChatOps interface without building a full application. Teams use this pattern to control deployments, query databases, manage feature flags, and run ad-hoc reports — all from their phone.
Handling Media and Files in Telegram Workflows
The Telegram node in n8n supports sending and receiving various media types. This opens up workflows beyond simple text messaging.
Sending files: The Telegram action node supports operations like "Send Photo," "Send Document," "Send Video," and "Send Audio." You can pass binary data from previous nodes — for example, generate a chart image with an HTTP Request node calling a chart API, then pipe the binary output directly to the Telegram node's "Send Photo" operation.
Receiving files: When users send photos or documents to your bot, the Telegram Trigger captures the file metadata including a file_id. Use an HTTP Request node to call Telegram's getFile API endpoint, then download the file and pass it to other nodes — upload it to cloud storage, process it with an AI vision model, or attach it to a helpdesk ticket.
Inline keyboards: These are buttons that appear below your messages. Define them in the Telegram node's "Reply Markup" field using JSON. When a user clicks a button, it fires a callback query that your Telegram Trigger can catch. This lets you build interactive menus, approval workflows, and multi-step forms entirely within the chat interface.
/setprivacy command.Error Handling and Best Practices
Telegram workflows run in real-time, so reliability matters. Here are the practices that keep your Telegram automations solid:
Use n8n's built-in error handling. Add an Error Trigger workflow that sends Telegram messages when any of your workflows fail. This creates a meta-alert system — your Telegram bot tells you when your Telegram bot (or any other workflow) breaks.
Validate incoming data. Not every message will have the fields you expect. Use IF nodes to check for the existence of message.text, message.photo, or callback_query before processing. This prevents workflows from crashing on unexpected message types.
Rate limit outgoing messages. While Telegram's limits are generous (30 messages per second to different chats, 1 per second to the same chat), burst sending can hit them. If you're broadcasting to many users, add a Wait node with a short delay between batches using the SplitInBatches node.
Keep bot tokens secure. Store your bot token only in n8n credentials — never hardcode it in Code nodes or expose it in webhook URLs. If you're running your n8n instance on n8nautomation.cloud, credentials are encrypted at rest automatically.
Test with a private chat first. Before deploying a bot to a group or channel, test the entire workflow in a one-on-one conversation with the bot. This lets you iterate quickly without spamming your team.
Getting Started with n8n and Telegram
The fastest path from idea to working Telegram bot is straightforward: create a bot via BotFather, connect it to n8n, and start with a simple alert workflow. Once that's running, layer on complexity — add commands, inline keyboards, media handling, and multi-step conversations.
n8n's visual builder makes it easy to see exactly how messages flow through your logic. You can test each node individually, inspect payloads at every step, and iterate without redeploying anything. The Telegram Trigger node's webhook approach means your bot responds in real-time — no delays, no cron jobs checking for new messages.
If you want to skip the infrastructure setup entirely, n8nautomation.cloud gives you a dedicated n8n instance with HTTPS webhooks ready to go — your Telegram bot can be live within minutes of signing up. Instances start at $15/month with automatic backups and zero server management.
Start with one workflow that solves a real problem — a deployment alert, a form notification, a daily digest — and expand from there. Telegram bots built on n8n have a way of becoming indispensable once your team realizes they can trigger anything from a chat message.