Adding Your Bot to Telegram Groups & Channels
Table of Contents
By default, Telegram bots can only receive direct messages. When added to a group or channel, they won't see most messages. This guide covers how to set up your bot in both groups (where members chat) and channels (where admins broadcast to subscribers).
Prerequisites
- Your agent is running and Telegram is connected
- You have access to the Telegram account that created the bot (for BotFather)
Groups vs Channels
Telegram has two types of multi-user chats, and bots behave differently in each:
| Groups | Channels | |
|---|---|---|
| Purpose | Members chat with each other | Admins broadcast to subscribers |
| Who can post | All members | Only admins |
| Bot role | Regular member or admin | Must be added as admin |
| Privacy Mode | Applies (blocks messages by default) | Does not apply (admins see everything) |
| Mention behavior | Configurable in Agento | Not applicable (bot reads all channel posts) |
Adding Your Bot to Groups
Step 1: Disable Privacy Mode in BotFather
Privacy Mode controls what messages your bot receives in groups. When enabled (the default), your bot only sees:
- Messages that @mention the bot
- Replies to the bot's own messages
- Service messages (member joined, etc.)
To let your bot see all group messages, turn this off:
- Open Telegram and search for @BotFather
- Send
/mybots - Select your bot
- Tap Bot Settings
- Tap Group Privacy
- Tap Turn off
You'll see a confirmation: "Privacy mode is disabled."
Important: This only takes effect in groups the bot joins after the change. For groups the bot is already in, remove it and add it back.
Alternative: If you make the bot a group admin, it receives all messages regardless of the privacy mode setting.
Step 2: Add the Bot to a Group
- Open the Telegram group (public or private, both work the same)
- Tap the group name to open settings
- Tap Add Members
- Search for your bot's username (e.g.
@my_agento_bot) - Add it to the group
The bot will appear in the member list and start receiving messages.
Step 3: Configure Group Behavior in Agento
Open the Agento dashboard, go to your agent's Manage tab, and scroll to Telegram Access Control. You'll see a Group Chats section with two settings:
Group Policy
| Policy | Behavior |
|---|---|
| Open (default) | Bot responds in any group it's added to |
| Disabled | Bot ignores all group messages, DMs only |
Require @mention
When group policy is set to Open, you can toggle Require @mention:
- On (default): The bot only responds when someone @mentions it or replies to one of its messages. All other group messages are ignored.
- Off: The bot responds to every message in the group.
For most use cases, leave this on. It keeps the bot from jumping into every conversation.
After changing settings, click Save. The agent restarts to apply the new configuration.
Adding Your Bot to Channels
Channels work differently from groups. Since only admins can post in a channel, your bot must be added as an admin to read and respond to channel posts.
Step 1: Add the Bot as a Channel Admin
- Open the Telegram channel
- Tap the channel name to open settings
- Tap Administrators
- Tap Add Admin
- Search for your bot's username and select it
- Grant at least the Post Messages permission
- Tap Save
Privacy Mode does not apply to channels. Once the bot is an admin, it automatically receives all channel posts.
Step 2: How the Bot Responds
When someone posts in the channel, your agent receives the message and can reply. The bot's response will appear as a separate post in the channel (from the bot's admin account).
The Require @mention and Group Policy settings in Agento do not affect channels. The bot reads all channel posts as long as it's an admin.
Testing
In a group with Require @mention enabled (default):
- Send a regular message: bot stays quiet
- Send a message with
@your_bot_name: bot responds - Reply to the bot's message: bot responds
In a group with Require @mention disabled:
- Any message in the group: bot responds
In a channel:
- Post any message: bot receives it and responds
Quick Reference
| Step | Where | What |
|---|---|---|
| Disable Privacy Mode | BotFather: /mybots > Bot Settings > Group Privacy > Turn off |
Required for groups (not channels) |
| Add bot to group | Group > Add Members > search bot username | Works for public and private groups |
| Add bot to channel | Channel > Administrators > Add Admin > search bot username | Grant "Post Messages" permission |
| Set group policy | Agento > Manage > Telegram Access Control > Group Chats | Open (respond in groups) or Disabled (DMs only) |
| Set mention behavior | Agento > Manage > Telegram Access Control > Require @mention | On = @mentions and replies only; Off = all messages |
Troubleshooting
Bot doesn't respond in a group: Make sure Privacy Mode is disabled in BotFather. If you changed it after the bot was already in the group, remove the bot and re-add it.
Bot doesn't respond in a channel: Make sure the bot is added as an admin with the "Post Messages" permission.
Bot responds to everything in a group: Check the Require @mention toggle in the Agento dashboard. If it's off, the bot responds to all messages.
Bot only works in some groups: Privacy Mode changes only apply to groups joined after the change. Remove and re-add the bot to older groups.