claude-session-bus
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@claude-session-busbroadcast I'm rebasing the main branch"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
claude-session-bus
A tiny Claude Code plugin that lets separate Claude sessions working the same project pass each other short messages: "holding the dev server on :1420", "editing dynamics.rs", "branch X pushed, safe to rebase".
Send = an MCP tool (
broadcast) the calling session invokes.Receive = a
UserPromptSubmithook that prepends new peer messages to the other session's context before its next turn.Transport = one append-only JSONL mailbox per project, under
${CLAUDE_PROJECT_DIR}/.claude/.session-bus/.
Broadcast-to-all, one-way, fire-and-forget. Advisory: it announces, it does not enforce. Project-agnostic - the same install only ever bridges sessions that share a project root.
Full design: docs/specs/2026-06-29-claude-session-bus-design.md.
Layout
claude-session-bus/
├── .claude-plugin/
│ ├── plugin.json # plugin manifest: hooks + mcpServers
│ └── marketplace.json # lets you add this dir as a local marketplace
├── server/index.mjs # MCP stdio server: broadcast(), inbox()
├── scripts/drain.mjs # UserPromptSubmit hook (the receive half)
├── scripts/selftest.mjs # offline smoke test of the mailbox primitives
├── lib/bus.mjs # shared: paths, identity, locking, message shape
├── hooks/hooks.json # declares the UserPromptSubmit hook
└── package.json # type:module, no runtime depsRelated MCP server: claude-intercom
Quick start
Clone the repo:
git clone https://github.com/exalsch/claude-session-bus.git cd claude-session-busSmoke-test the primitives (no Claude needed):
node scripts/selftest.mjs # expect: selftest OK - { ... }Install as a local plugin, then enable it:
/plugin marketplace add /path/to/claude-session-bus # the directory you just cloned /plugin install claude-session-bus@session-bus-devRestart Claude Code so the MCP server + hook load. Verify the
broadcastandinboxtools appear, and that thesession-busMCP server is connected.Use it. From any session:
broadcast("holding the dev server on :1420", kind="lock")inbox()to re-read peer messages on demand.
The other session in the same project sees the message prepended to its context the next time you submit a prompt there.
End-to-end test
Open two terminals, both cd into the same project (e.g. ~/projects/your-app):
In session A: ask it to
broadcast("test from A").In session B: submit any prompt. B should report a
[session-bus]line from A.In session A: submit any prompt. A should not see its own message (origin filter).
If A does see its own message, the ppid correlation did not hold (see Risks in the
spec) - the fallback is to render own posts tagged "(you)" instead of filtering them.
Config
SESSION_BUS_BACKFILL_MIN(default0) - minutes of backlog a session sees on its first prompt.0= forward-only (a new session only sees what arrives after it joins).Retention (
MAX_LINES,MAX_AGE_MS) lives inlib/bus.mjs.
Status & next steps
v0.1. The headline risk - ppid correlation on Windows - was tested and did not
hold: Claude Code spawns the UserPromptSubmit hook through a shell, so the hook's
parent PID is a transient shell, never the directly-spawned MCP server's PID. Sessions
now correlate on CLAUDE_CODE_SESSION_ID (an env var both halves inherit from
claude.exe) instead of process.ppid, with a ppid fallback where that var is
absent. Verified end-to-end across two live sessions and covered by
scripts/test-origin.mjs (unit) and scripts/test-drain.mjs (integration);
npm test runs the full suite.
Out of scope today: cross-project messaging. The mailbox lives inside each project
(${CLAUDE_PROJECT_DIR}/.claude/.session-bus/), so only sessions sharing a project root
bridge. A global bus would need a shared mailbox path plus a proj field per message.
This is dev tooling - it must never live inside a product repo.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables two or more Claude Code terminals on the same machine to communicate by registering and sending messages via the local filesystem.Last updated51MIT
- Alicense-qualityDmaintenanceEnables real-time messaging between Claude Code instances, allowing agents to send, receive, and reply to messages instantly via file-based communication with auto-notification.Last updated1MIT
- Alicense-qualityFmaintenanceEnables file-based agent-to-agent communication between Claude Code instances on the same machine, using MCP channels and plain JSON files.Last updated113MIT
- Alicense-qualityBmaintenanceEnables multiple Claude Code sessions to communicate and coordinate through broadcast and peer-to-peer messaging.Last updated21MIT
Related MCP Connectors
User-owned memory for AI agents, Copilot, Claude, IDEs, CLIs, and chat apps over remote MCP.
The team layer for AI coding agents: shared contracts, collision alerts, E2EE sessions.
Read and write your Fresh Jots notes from Claude, Cursor, and any MCP client.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/exalsch/claude-session-bus'
If you have feedback or need assistance with the MCP directory API, please join our Discord server