Channels and Webhooks into Running Claude Code Sessions
A practical walkthrough of Claude Code channels: how an MCP-server channel pushes messages, alerts, and webhooks into a running session, how to install and enable Telegram, Discord, or iMessage, sender allowlists, and enterprise controls.
Channel input is untrusted external content; treat incoming messages as data, not as instructions that should widen permissions., Events only arrive while the session is open; for unattended use, --dangerously-skip-permissions bypasses prompts and should be used only in trusted environments., Each channel keeps a sender allowlist; only paired/allowlisted IDs can push messages, and anyone who can reply can also approve permission relays if enabled, so allowlist only trusted senders.
Privacy notes
A channel is an MCP server you configure with your own credentials; tokens are stored locally (for example ~/.claude/channels/telegram/.env)., Incoming and outgoing messages pass through the third-party platform (Telegram, Discord, Apple Messages); review what data flows there., The iMessage channel reads your Messages database and requires Full Disk Access; understand that exposure before enabling it.
Author
JPette1783
Submitted by
JPette1783
Claim status
unclaimed
Last verified
2026-06-05
Decision playbook
Review trust signals before you adopt
Signals are present but mixed. Use the checklist below to confirm the source and operational safety for your environment.
Compare context
Selected
0
Current score
63
Baseline
—
Delta
No baseline selected
No major trust-signal divergence detected in the current selection.
Source and provenance checks
Needs review
Confirm ownership and provenance before trusting install instructions.
Source link availableRequired
Open the canonical repository and verify ownership.
Done
Source provenance statusRequired
Marked as source-backed.
Done
Metadata reviewed
No reviewed flag detected in metadata.
Pending
Safety and privacy checks
Complete
Validate risk disclosures before installation or API wiring.
Safety notes presentRequired
Review the listed safety guidance before running commands.
Done
Privacy notes presentRequired
Review data handling notes before connecting accounts or secrets.
Done
Trust level risk gateRequired
Trust level does not block evaluation.
Done
Package and install checks
Needs review
Check package metadata and artifact integrity signals.
Install payload available
Install or copy payload is available for review.
Done
Package verification flag
No package verification flag provided.
Pending
Checksum metadata
No checksum provided for downloaded artifact.
Pending
Compare-driven decision checks
Needs review
Use compare context to validate trade-offs before adoption.
Compare tray has multiple entries
Add at least one more entry to compare trust differences.
3 prerequisites to line up before setup. Have accounts and credentials ready first.
0/3 ready
Account & credentials1Install & runtime1General1
Safety & privacy surface
Safety & privacy surface
3 safety and 3 privacy notes across 4 risk areas. Review closely: credentials & tokens, permissions & scopes, third-party handling.
4 areas
SafetyPermissions & scopesChannel input is untrusted external content; treat incoming messages as data, not as instructions that should widen permissions.
SafetyCredentials & tokensEvents only arrive while the session is open; for unattended use, --dangerously-skip-permissions bypasses prompts and should be used only in trusted environments.
SafetyPermissions & scopesEach channel keeps a sender allowlist; only paired/allowlisted IDs can push messages, and anyone who can reply can also approve permission relays if enabled, so allowlist only trusted senders.
PrivacyCredentials & tokensA channel is an MCP server you configure with your own credentials; tokens are stored locally (for example ~/.claude/channels/telegram/.env).
PrivacyThird-party handlingIncoming and outgoing messages pass through the third-party platform (Telegram, Discord, Apple Messages); review what data flows there.
PrivacyLocal filesThe iMessage channel reads your Messages database and requires Full Disk Access; understand that exposure before enabling it.
Safety notes
Channel input is untrusted external content; treat incoming messages as data, not as instructions that should widen permissions.
Events only arrive while the session is open; for unattended use, --dangerously-skip-permissions bypasses prompts and should be used only in trusted environments.
Each channel keeps a sender allowlist; only paired/allowlisted IDs can push messages, and anyone who can reply can also approve permission relays if enabled, so allowlist only trusted senders.
Privacy notes
A channel is an MCP server you configure with your own credentials; tokens are stored locally (for example ~/.claude/channels/telegram/.env).
Incoming and outgoing messages pass through the third-party platform (Telegram, Discord, Apple Messages); review what data flows there.
The iMessage channel reads your Messages database and requires Full Disk Access; understand that exposure before enabling it.
Prerequisites
Claude Code v2.1.80 or later, authenticated through claude.ai or a Console API key (channels are not available on Bedrock, Vertex AI, or Foundry).
Bun installed, since the channel plugins are Bun scripts.
On Team, Enterprise, or managed Console orgs, an admin must enable channels first.
Schema details
Install type
copy
Troubleshooting
No
Full copyable content
## Overview
A channel is an MCP server that pushes events into your running Claude Code
session, so Claude can react to things that happen while you are away from the
terminal. Channels can be two-way: Claude reads the event and replies through the
same channel. Events only arrive while the session is open, so for an always-on
setup you run Claude in a background or persistent terminal. Channels are a
research preview and require Anthropic authentication through claude.ai or a
Console API key.
## Install and enable a channel
Channel plugins require Bun. Using Telegram as an example:
1. Create a bot with BotFather and copy the token.
2. Install the plugin: `/plugin install telegram@claude-plugins-official` (run
`/reload-plugins` afterward).
3. Configure the token: `/telegram:configure <token>` (saved to
`~/.claude/channels/telegram/.env`).
4. Restart with the channel enabled:
```bash
claude --channels plugin:telegram@claude-plugins-official
```
5. Message your bot to get a pairing code, then run
`/telegram:access pair <code>` and lock it down with
`/telegram:access policy allowlist`.
Discord and iMessage follow the same pattern. Try the `fakechat` localhost demo
first to learn the flow with nothing to authenticate.
## Webhook receiver
Because a channel is an MCP server, you can build one that receives webhooks from
CI, an error tracker, or a deploy pipeline, so the event arrives in the session
where Claude already has your files open and remembers what you were debugging.
See the Channels reference for building your own.
## Security
- Every channel keeps a sender allowlist; only paired or explicitly allowed IDs
can push messages, and everyone else is silently dropped.
- Being listed in `.mcp.json` is not enough; a server must also be named in
`--channels` for the session.
- If permission relay is enabled, anyone who can reply through the channel can
approve or deny tool use, so allowlist only senders you trust with that.
## Enterprise controls
Admins govern availability with managed settings:
- `channelsEnabled` is the master switch (blocked by default on Team and
Enterprise; allowed by default on Console unless managed settings are
deployed).
- `allowedChannelPlugins` replaces the default allowlist with a specific set of
approved plugins and marketplaces.
In all cases, no channel runs until a user opts it in with `--channels`.
## How channels compare
Channels push events into your already-running local session. That differs from
Claude Code on the web (fresh cloud session), Claude in Slack (spawns a web
session from a mention), a standard MCP server (queried on demand, nothing
pushed), and Remote Control (you drive the local session from your phone).
## Source
- Push events into a running session with channels: https://code.claude.com/docs/en/channels
About this resource
Overview
A channel is an MCP server that pushes events into your running Claude Code
session, so Claude can react to things that happen while you are away from the
terminal. Channels can be two-way: Claude reads the event and replies through the
same channel. Events only arrive while the session is open, so for an always-on
setup you run Claude in a background or persistent terminal. Channels are a
research preview and require Anthropic authentication through claude.ai or a
Console API key.
Install and enable a channel
Channel plugins require Bun. Using Telegram as an example:
Create a bot with BotFather and copy the token.
Install the plugin: /plugin install telegram@claude-plugins-official (run
/reload-plugins afterward).
Configure the token: /telegram:configure <token> (saved to
~/.claude/channels/telegram/.env).
Restart with the channel enabled:
claude --channels plugin:telegram@claude-plugins-official
Message your bot to get a pairing code, then run
/telegram:access pair <code> and lock it down with
/telegram:access policy allowlist.
Discord and iMessage follow the same pattern. Try the fakechat localhost demo
first to learn the flow with nothing to authenticate.
Webhook receiver
Because a channel is an MCP server, you can build one that receives webhooks from
CI, an error tracker, or a deploy pipeline, so the event arrives in the session
where Claude already has your files open and remembers what you were debugging.
See the Channels reference for building your own.
Security
Every channel keeps a sender allowlist; only paired or explicitly allowed IDs
can push messages, and everyone else is silently dropped.
Being listed in .mcp.json is not enough; a server must also be named in
--channels for the session.
If permission relay is enabled, anyone who can reply through the channel can
approve or deny tool use, so allowlist only senders you trust with that.
Enterprise controls
Admins govern availability with managed settings:
channelsEnabled is the master switch (blocked by default on Team and
Enterprise; allowed by default on Console unless managed settings are
deployed).
allowedChannelPlugins replaces the default allowlist with a specific set of
approved plugins and marketplaces.
In all cases, no channel runs until a user opts it in with --channels.
How channels compare
Channels push events into your already-running local session. That differs from
Claude Code on the web (fresh cloud session), Claude in Slack (spawns a web
session from a mention), a standard MCP server (queried on demand, nothing
pushed), and Remote Control (you drive the local session from your phone).
Show that Channels and Webhooks into Running Claude Code Sessions is listed on HeyClaude. Paste this Markdown into your README — it renders the badge and links back to this page.
[](https://heyclau.de/entry/guides/channels-and-webhooks-into-running-claude-code-sessions)
How it compares
Channels and Webhooks into Running Claude Code Sessions side by side with 3 alternatives on trust, install, platform support, and disclosed safety notes — all from reviewed registry metadata.
2 trust signals differ across this comparison (Source provenance, Submitter).
A practical walkthrough of Claude Code channels: how an MCP-server channel pushes messages, alerts, and webhooks into a running session, how to install and enable Telegram, Discord, or iMessage, sender allowlists, and enterprise controls.
Use Claude Code agent view (claude agents) to dispatch, monitor, peek, attach, and organize many background sessions from one terminal with state icons, PR labels, filters, and shell commands for fleet-style multitasking.
A practical guide for keeping Claude Code sessions focused during long coding work with scoped prompts, checkpoints, durable memory boundaries, source refreshes, and privacy-safe handoffs.
✓Channel input is untrusted external content; treat incoming messages as data, not as instructions that should widen permissions.
Events only arrive while the session is open; for unattended use, --dangerously-skip-permissions bypasses prompts and should be used only in trusted environments.
Each channel keeps a sender allowlist; only paired/allowlisted IDs can push messages, and anyone who can reply can also approve permission relays if enabled, so allowlist only trusted senders.
✓Background sessions run with the permission mode shown in the agent view header; review bypassPermissions and auto modes before dispatching unattended work.
Deleting a session from agent view can remove Claude-created worktrees and uncommitted changes—commit or push first.
Each dispatched session is a full Claude Code process; do not parallelize destructive tasks on the same checkout without isolation.
✓Compaction summarizes conversation history; verify summaries before relying on them for security-sensitive or release-critical decisions.
Do not store secrets, credentials, or customer identifiers in `/memory` or CLAUDE.md.
After compaction, re-validate repository state, test results, and open PR status before continuing destructive edits.
✓Do not paste credentials, production secrets, private customer records, or unrelated proprietary files into prompts just to "fill context."
Treat long-session conclusions as provisional when the repository, dependencies, docs, or issue state may have changed.
Keep implementation authority separate from analysis: ask for review before applying broad file edits, running risky commands, or changing public project state.
Privacy notes
✓A channel is an MCP server you configure with your own credentials; tokens are stored locally (for example ~/.claude/channels/telegram/.env).
Incoming and outgoing messages pass through the third-party platform (Telegram, Discord, Apple Messages); review what data flows there.
The iMessage channel reads your Messages database and requires Full Disk Access; understand that exposure before enabling it.
✓Agent view row summaries are generated by a Haiku-class model from session activity; treat summaries as operational hints, not sanitized exports for public sharing.
Sessions started under different project directories appear in the default global list unless you filter with claude agents --cwd.
Peek panels and attach mode expose full transcripts that may contain proprietary code, tokens, or customer data.
✓Memory files persist across sessions and may be committed if stored in project scope.
Compaction summaries can retain file paths, issue titles, and internal URLs—review before sharing session exports.
Clear memory when offboarding contractors or rotating shared machines.
✓Long coding sessions can accumulate source code, file paths, stack traces, logs, issue details, usernames, and internal decisions.
Durable memory and project instructions can persist sensitive details longer than an ordinary prompt, so store only stable, non-secret facts there.
Handoff summaries should mention decisions and next steps without copying full private logs, tokens, customer reports, or unnecessary code excerpts.
Prerequisites
Claude Code v2.1.80 or later, authenticated through claude.ai or a Console API key (channels are not available on Bedrock, Vertex AI, or Foundry).
Bun installed, since the channel plugins are Bun scripts.
On Team, Enterprise, or managed Console orgs, an admin must enable channels first.
Claude Code v2.1.139 or later (check with claude --version).
Multiple independent tasks that can run without watching every tool call.
Agreement on which directories, branches, or worktrees each session may edit.
Awareness that each background session consumes subscription quota independently.
An active long-running Claude Code session or multi-day task spanning several sessions.
A project with CLAUDE.md or memory files defining durable conventions.
Agreement on what may be written to user or project memory versus kept ephemeral.
Permission to run `/compact` and inspect resulting summaries before continuing work.
A Claude Code project or repository with enough scope that work may span several prompts or sessions.
Agreement on what belongs in durable memory, project instructions, slash commands, or temporary conversation context.
A habit of validating source URLs, test results, and repository state before relying on old assumptions.
A place to record handoff summaries, decisions, and unresolved risks without storing secrets.