Skip to main content
Tips

practitioner tip

Drive Claude Code From Telegram or Discord With Channels

AIErudit angle: Channels turns any chat app into a secure command line for your agent — text a task, it runs with full tools and replies in the same thread. A sender allowlist plus pairing code keeps this powerful async delivery surface locked to you, which matters as chat-driven ops become a real attack surface.

channelsmcpclaude-codetips
Tip visual

Published: Mar 21, 2026 Updated: 2026-06-01

Original: https://wmedia.es/en/tips/claude-code-channels-control-from-telegram

TL;DR Claude Code now accepts messages from Telegram and Discord while working in your terminal. Text it from your phone, it executes, and replies through the same channel. Bidirectional, secure (sender allowlist), activated with --channels.

Channels is a system that pushes external events into your Claude Code session via an MCP server. Telegram, Discord, iMessage, or any service you implement. Claude reads the message, acts with all its tools (bash, editing, reading, subagents), and replies through the same channel.

If this sounds like what OpenClaw does — an AI assistant that lives in your chat apps and executes tasks on your machine — it's no coincidence. Anthropic is building that same vision, but integrated natively into Claude Code: with access to hooks, skills, subagents, and MCP.

Result — you text your Telegram bot:

You (Telegram): Are any tests failing in the project?

Claude Code (terminal): runs npm test, analyzes results

Claude Code (Telegram): 2 tests failing in auth.test.ts:
  - testLoginExpiredToken: expected 401, got 500
  - testRefreshToken: timeout after 5s

Setup (Telegram)

1. Create a Telegram bot

Open BotFather in Telegram, send /newbot, give it a name, and copy the token.

2. Install the plugin

/plugin install telegram@claude-plugins-official

3. Configure the token

/telegram:configure <your-token>

4. Restart with channels enabled

claude --channels plugin:telegram@claude-plugins-official

5. Pair your account

Send any message to your bot in Telegram. It replies with a pairing code. In Claude Code:

/telegram:access pair <code>
/telegram:access policy allowlist

The second line locks access to your account only.

Reference

AspectDetail
What it isMCP server that pushes events into your session
Supported channelsTelegram, Discord, iMessage, fakechat (localhost demo)
DirectionBidirectional — Claude reads and replies through the same channel
SecuritySender allowlist + pairing code
Activation flag--channels plugin:<name>@claude-plugins-official
Session requiredClaude Code must be running (not a persistent service)
PermissionsPermission prompts pause the session until you approve locally
StatusResearch preview (v2.1.80+)
Authenticationclaude.ai or a Console API key (not on Bedrock/Vertex/Foundry)
EnterpriseDisabled by default — admin must enable channelsEnabled

Official docs: Channels — Push events into a running session

Requirements

  • Claude Code v2.1.80+
  • Bun installed (bun --version to verify)
  • claude.ai login or a Console API key (enabled by default on Console)
  • Team/Enterprise: admin must enable channels in managed settings

Related: Channels as an event receiver: CI, deploys, and webhooks · Computer use — when the terminal is not enough · Remote control from your phone