Prompt file imported from azaidi94/claude-mobile-bridge (
.claude/commands/setup-relay.md). Copyright stays with the author.
Set up the channel-relay MCP server so desktop Claude sessions can communicate with the Telegram bot.
Steps
-
Find the repo root by looking for
src/mcp/channel-relay/server.tsrelative to this project directory. -
Check if already registered:
claude mcp list 2>/dev/null | grep channel-relayIf already registered, tell the user and skip to step 4.
-
Register the relay as a global MCP server:
claude mcp add -s user channel-relay -- bun run <REPO_ROOT>/src/mcp/channel-relay/server.tsReplace
<REPO_ROOT>with the actual absolute path to this repo. -
Ask the user if they'd like a shell launcher added for the relay flags. If yes, detect the shell config (
~/.zshrc,~/.bashrc, or~/.bash_profile), skip if the name already exists, else append and tell them tosourceit:- Plain
cc(simplest):alias cc='claude --dangerously-skip-permissions --dangerously-load-development-channels server:channel-relay' - tmux
cct(recommended — enablestmux send-keysinjection, the/tmuxpanel,/peek, and multiple sessions per folder). Append a function with the absolute repo path:
Multi-session routing also needs the SessionStart identity hook (cct() { source "<REPO_ROOT>/scripts/tmux/launch.sh" cc_tmux_launch "$#" --dangerously-skip-permissions \ --dangerously-load-development-channels server:channel-relay "$@" }bun run install-hooks).
- Plain
-
Verify by running
claude mcp listand confirmingchannel-relayappears. -
Print a summary of what was done and how to use it:
- Start a session with
cc(orcctfor the tmux launcher, or the full command) - The bot auto-discovers relay sessions via
/list - Use
/watchto stream live, type messages to send via relay
- Start a session with