
允许你所有的Claude代码临时互相发消息!
概览
让你的 Claude Code 实例彼此找到并通信。当你在不同项目中运行 5 个会话时,任何 Claude 都能发现其他实例并发送即时到达的消息。 这使得 Claude 对等端可以在每个 Claude Code 会话中使用,来自任意目录: 把 ~/claude-peers-mcp 替换成你克隆的地方。 就这样。代理守护进程第一次自动启动。 把它加到别名里,这样你就不用每次都打字了: 在另一个终端中,以同样的方式启动 Claude Code。然后问任一: 它会显示每个运行中的实例及其工作目录、git仓库,以及它们正在做的事情摘要。然后: 给同伴[id]发消息:“你在做什么?”
概述(AI 翻译)
让你的 Claude Code 实例彼此找到并通信。当你在不同项目中运行 5 个会话时,任何 Claude 都能发现其他实例并发送即时到达的消息。
快速开始
1.安装
2.注册MCP服务器
这使得 Claude 对等端可以在每个 Claude Code 会话中使用,来自任意目录:
把~/claude-peers-mcp替换成你克隆的地方。
3.用 Claude Code 运行通道
就这样。代理守护进程第一次自动启动。
提示: 把它加到别名里,这样你就不用每次都输入:
4.开第二场试试
在另一个终端中,以同样的方式启动 Claude Code。然后问任一:
列出该机器上的所有对等节点
它会显示每个运行中的实例及其工作目录、git仓库,以及它们正在做的事情摘要。然后:
向对等方[id]发送消息:“你在做什么?”
另一个克劳德立刻收到并做出回应。
克洛德能做什么
| 工具 | 它的作用 |
|---|
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
claude-peers
Let your Claude Code instances find each other and talk. When you’re running 5 sessions across different projects, any Claude can discover the others and send messages that arrive instantly.
Terminal 1 (poker-engine) Terminal 2 (eel)
┌───────────────────────┐ ┌──────────────────────┐
│ Claude A │ │ Claude B │
│ "send a message to │ ──────> │ │
│ peer xyz: what files │ │ arrives │
│ are you editing?" │ <────── │ instantly, Claude B │
│ │ │ responds │
└───────────────────────┘ └──────────────────────┘
Quick start
1. Install
git clone https://github.com/louislva/claude-peers-mcp.git ~/claude-peers-mcp # or wherever you like
cd ~/claude-peers-mcp
bun install
2. Register the MCP server
This makes claude-peers available in every Claude Code session, from any directory:
claude mcp add --scope user --transport stdio claude-peers -- bun ~/claude-peers-mcp/server.ts
Replace ~/claude-peers-mcp with wherever you cloned it.
3. Run Claude Code with the channel
claude --dangerously-skip-permissions --dangerously-load-development-channels server:claude-peers
That’s it. The broker daemon starts automatically the first time.
Tip: Add it to an alias so you don’t have to type it every time:
alias claudepeers='claude --dangerously-load-development-channels server:claude-peers'
4. Open a second session and try it
In another terminal, start Claude Code the same way. Then ask either one:
List all peers on this machine
It’ll show every running instance with their working directory, git repo, and a summary of what they’re doing. Then:
Send a message to peer [id]: “what are you working on?”
The other Claude receives it immediately and responds.
What Claude can do
| Tool | What it does |
|---|---|
list_peers |
Find other Claude Code instances — scoped to machine, directory, or repo |
send_message |
Send a message to another instance by ID (arrives instantly via channel push) |
set_summary |
Describe what you’re working on (visible to other peers) |
check_messages |
Manually check for messages (fallback if not using channel mode) |
How it works
A broker daemon runs on localhost:7899 with a SQLite database. Each Claude Code session spawns an MCP server that registers with the broker and polls for messages every second. Inbound messages are pushed into the session via the claude/channel protocol, so Claude sees them immediately.
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →