What is Claude Code Channels and How Does It Work with Telegram and Discord?
Problem
I was at a coffee shop when I got an urgent message. A production bug needed fixing immediately. But I only had my phone - no laptop, no terminal access.
Before Claude Code Channels, I had two options:
- Drive home to fix it (not ideal at 2 AM)
- Use OpenClaw - but that requires a dedicated Mac Mini, Docker, Node.js 22+, WebSocket gateway, and significant setup
Then I discovered Claude Code Channels. One flag, one bot token, and I could message my AI coding assistant from anywhere.
What is Claude Code Channels?
Claude Code Channels is a research preview feature that connects my Claude Code terminal session to Telegram or Discord through an MCP (Model Context Protocol) plugin.
When I enable it with the --channels flag, Claude Code spins up a polling service that monitors a messaging platform. I can then message my bot from my phone, Claude Code receives the instruction, executes it, and replies back in chat.
Here’s the basic flow:
+-------------+ +-------------+ +-------------+| Phone | | MCP | | Claude || Telegram |---->| Plugin |---->| Code || Discord | | (Bun) | | Session |+-------------+ +-------------+ +-------------+ | v +-------------+ | File | | System | +-------------+How It Works
The architecture is straightforward. When I start Claude Code with Channels enabled:
# Start Claude Code with Channelsclaude --channelsThe system does this:
- Spins up a polling service - Monitors the messaging platform for new messages
- Connects via MCP plugin - Uses Bun runtime for the connection layer
- Provides full tool access - File edits, test runs, git operations, all available from chat
I tried sending a simple command from Telegram:
"Edit src/auth.ts to add rate limiting"Claude Code received it, made the edit, and sent back a summary. The whole process took about 30 seconds.
Setting Up Telegram
I went through the Telegram bot setup. It’s surprisingly simple:
Step 1: Create a Bot
1. Open Telegram, search @BotFather2. Send /newbot command3. Follow prompts to name your bot4. Copy the bot token (looks like: 1234567890:ABCdefGHI...)Step 2: Connect to Claude Code
When I ran claude --channels, Claude Code prompted me for the bot token. I pasted it, scanned the QR code that appeared, and the connection was established.
Step 3: Test It
From my phone, I sent:
"What files are in the current directory?""Run npm test and show me failures""Create a new file called test.js with a hello world function"Each command executed and returned results within seconds.
Setting Up Discord
Discord setup follows a similar pattern but with more steps:
Step 1: Create Discord Application
1. Go to Discord Developer Portal2. Create New Application3. Navigate to Bot section4. Click "Add Bot"5. Copy the bot tokenStep 2: Invite Bot to Server
1. Go to OAuth2 section in Developer Portal2. Select "bot" scope3. Select permissions: Send Messages, Read Messages4. Copy and open the generated URL5. Select server to add botStep 3: Connect
Same as Telegram - provide the token when Claude Code prompts, and the connection is ready.
The OpenClaw Comparison
I had previously tried OpenClaw for remote Claude access. The comparison is stark:
Claude Code Channels: - Flag: --channels - Token: One bot token - Time: ~5 minutes
OpenClaw: - Hardware: Dedicated Mac Mini - Software: Docker, Node.js 22+ - Infrastructure: WebSocket gateway - Dependencies: 70+ packages - Time: Hours of configurationVentureBeat even called Channels the “OpenClaw killer.” While that might be hyperbolic, the difference in setup effort is real.
Here’s a feature comparison:
| Feature | Claude Code Channels | OpenClaw |
|---|---|---|
| Setup | --channels flag | Dedicated Mac Mini + Docker |
| Dependencies | Plugin + bot token | 70+ dependencies |
| Platforms | Telegram, Discord, custom | 20+ platforms |
| Models | Claude only | 500+ via KiloClaw |
| Always-on | Requires running session | Designed for always-on |
| Cost | $20-200/mo subscription | Free, self-hosted |
Important Limitations
I learned about these limitations the hard way.
Session Must Be Active
Channels is NOT always-on. I need an active Claude Code session running on my computer for the bot to respond. If my laptop sleeps or the terminal closes, the connection dies.
This differs from OpenClaw, which is designed for 24/7 operation on dedicated hardware.
Permission Prompts Block Execution
When Claude Code hits a permission prompt while I’m away, the session pauses until I approve locally. This means:
# This works - no permission needed"Show me the contents of package.json"
# This pauses - needs local approval"Delete the dist folder"The Dangerous Flag
There’s a flag for fully unattended use:
# For trusted environments only!claude --dangerously-skip-permissions --channelsI used this once. Then I read the horror stories about deleted files and broken environments. Now I only use it inside Docker containers where nothing matters.
Subscription Requirements
Not everyone can use Channels. It requires:
| Tier | Price | Channels Access |
|---|---|---|
| Free | $0/mo | No |
| Pro | $20/mo | Yes |
| Max | $100-200/mo | Yes |
This is a research preview feature, so availability might change.
Real-World Use Cases
After using Channels for a few weeks, I found these scenarios most valuable:
1. Push Hotfixes from Anywhere
Me (at dinner): "Run tests for auth module"Bot: "All 23 tests passed"Me: "Commit with message 'fix: rate limiting edge case'"Bot: "Committed successfully to main"2. Quick Code Reviews
During my commute, I reviewed a pull request:
"What changed in the last commit?""Show me the diff for src/api/users.ts""Any security concerns in the auth changes?"3. Debugging Remotely
When a teammate reported a bug:
"Check the logs for errors in the last hour""Find all occurrences of 'ValidationError' in the codebase""Show me the function that handles user registration"Security Considerations
Bot tokens grant full access to my Claude Code session. I treat them like API keys:
DO:- Use private bots only- Use private Discord servers only- Revoke tokens when compromised- Store tokens in password manager
DON'T:- Commit tokens to git- Share bots publicly- Use --dangerously-skip-permissions on important machines- Leave sessions running unattended in public placesCommon Mistakes
I made these mistakes so you don’t have to:
Mistake 1: Expecting Always-On
I left my laptop closed and expected the bot to respond. It didn’t. Channels requires an active session.
Mistake 2: Using —dangerously-skip-permissions Recklessly
I enabled this flag on my main development machine. Claude deleted some test files I was still using. Never again.
Mistake 3: Treating Bot Tokens Casually
I almost committed a bot token to GitHub. The token would have given anyone access to run arbitrary commands on my machine. I now use environment variables.
Mistake 4: Expecting Push Notifications
Channels is request-response, not push-based. I can’t configure Claude to proactively message me when tests fail or deployments complete. I have to ask.
Custom Platform Integration
The MCP architecture supports custom platforms. While Telegram and Discord are built-in, I can build my own:
+-------------+| Custom || Platform |+------+------+ | v+-------------+ +-------------+| MCP | | Claude || Plugin |---->| Code |+-------------+ +-------------+The sample code for creating new channels is available in the Claude Code documentation. This means Slack, WhatsApp, or any messaging platform with an API could potentially integrate.
Summary
Claude Code Channels solved my “fix bugs from coffee shop” problem. Instead of maintaining a complex OpenClaw setup, I now use a single flag and a bot token.
The trade-offs are clear:
- Pros: Simple setup, full tool access, works from phone
- Cons: Requires active session, not always-on, needs Pro subscription
For developers who need occasional remote access to their coding environment, Channels is the simpler choice. For 24/7 always-on operations, OpenClaw still has its place.
The key insight: Channels is for “I need to push a quick fix from my phone,” not “I want Claude running unattended for days.”
Final Words + More Resources
My intention with this article was to help others share my knowledge and experience. If you want to contact me, you can contact by email: Email me
Here are also the most important links from this article along with some further resources that will help you in this scope:
- 👨💻 Claude Code Official Documentation
- 👨💻 Reddit: Claude Shipped Insane Features This Week
- 👨💻 Model Context Protocol
- 👨💻 Telegram BotFather
- 👨💻 Discord Developer Portal
Oh, and if you found these resources useful, don’t forget to support me by starring the repo on GitHub!
Comments