By akram012388
Coordinate parallel Claude Code sessions via peer-to-peer direct messaging over a shared SQLite bus. Send DMs, broadcasts, active checks, and project-scoped messages between sessions on the same machine. Install live TUI viewer for monitoring. Register sessions with names and roles. On macOS, automate iMessage for reading conversations, sending texts, searching history, and handling attachments via local Bun server.
npx claudepluginhub akram012388/cc-dm --plugin cc-dmSend and receive direct messages between active Claude Code sessions on this machine. Use when the user asks to dm, message, notify, broadcast, check who is active, or manage project-scoped messaging across sessions.
Install or check cc-dm-stream, the live TUI viewer for cc-dm messages. Use when the user asks to install stream, install cc-dm-stream, set up stream viewer, get cc-dm-stream, or check if cc-dm-stream is installed.
Register this session with cc-dm — sets your session name, role, and optional project tag for project-scoped messaging. Auto-invoked on first interaction if session name or role is missing. Use when the user asks to register, set name, change role, or set/change project.
Admin access level
Server config contains admin-level keywords
Share bugs, ideas, or general feedback.
Peer-to-peer communication between Claude Code sessions on the same machine
Inter-agent communication for Claude Code and Codex CLI sessions via threads and messages
IRC-style commands for managing Claude Code sessions
Inter-session communication for Claude Code — session registry, messaging, and coordination
Launch, control, and monitor other Claude Code sessions as workers via tmux
Write SQL, explore datasets, and generate insights faster. Build visualizations and dashboards, and turn raw data into clear stories for stakeholders.
Peer-to-peer direct messaging between Claude Code sessions.
Running multiple Claude Code sessions in parallel — a planner, a backend worker, a test runner — means context constantly needs to move between terminals. The default workflow is copy-paste: pull text from one session, switch windows, paste into another, lose formatting, lose thread.
cc-dm lets any session DM any other session on the same machine. Messages are delivered as native <channel> events within 500ms via the Claude Code Channels protocol, landing directly in the receiving session's context window.
Session A (planner) ──┐
Session B (backend) ──┼──→ ~/.cc-dm/bus.db (SQLite WAL)
Session C (tests) ──┘ ↑
500ms poll per session
→ <channel> event pushed into context
Each session spawns a cc-dm channel server via stdio. The server connects to a shared SQLite database at ~/.cc-dm/bus.db. When a session sends a message, it writes a row to the bus. Every other session's server polls the bus every 500ms, picks up messages addressed to it, and pushes them as <channel> events into its parent session. No daemon, no ports, no network. Just a shared file and a poll loop.
Start a new Claude Code session and enter the following commands:
/plugin marketplace add cc-dm-marketplace
/plugin install cc-dm
Restart Claude Code. The cc-dm tools and skills will be available in all sessions.
Via npm (requires Bun):
npm install cc-dm
The npm package contains the full plugin source. After installing, follow the Quick Start above to register the plugin with Claude Code.
Note: cc-dm is a Claude Code channel plugin, not a standalone library. The npm package exists for discoverability and as a distribution mirror — the primary install method is the plugin marketplace above.
Via curl:
curl -fsSL https://raw.githubusercontent.com/Akram012388/cc-dm/main/install.sh | bash
Add this to your ~/.zshrc or ~/.bashrc:
alias cc-dm='claude --dangerously-skip-permissions --dangerously-load-development-channels plugin:cc-dm@cc-dm-marketplace'
Then launch sessions with:
CC_DM_SESSION_NAME=planner CC_DM_SESSION_ROLE=orchestrator CC_DM_SESSION_PROJECT=myapp cc-dm
Or just cc-dm and register interactively via /cc-dm:register.
Note:
--dangerously-skip-permissionsbypasses all tool permission prompts for the session, not just cc-dm's. Use with awareness.
Start a session without the alias:
CC_DM_SESSION_NAME=planner CC_DM_SESSION_ROLE=orchestrator CC_DM_SESSION_PROJECT=myapp \
claude --dangerously-load-development-channels plugin:cc-dm@cc-dm-marketplace
Once inside, use natural language:
"Register this session as planner"
"DM the backend session: auth spec is ready"
"Who is active in cc-dm?"
"Broadcast to all sessions: wrapping up in 10"
Open two or more terminals and launch Claude Code with different session identities:
Terminal 1 — Planner:
CC_DM_SESSION_NAME=planner CC_DM_SESSION_ROLE=orchestrator CC_DM_SESSION_PROJECT=myapp claude --dangerously-load-development-channels plugin:cc-dm@cc-dm-marketplace
Terminal 2 — Backend:
CC_DM_SESSION_NAME=backend CC_DM_SESSION_ROLE=worker CC_DM_SESSION_PROJECT=myapp claude --dangerously-load-development-channels plugin:cc-dm@cc-dm-marketplace
Or skip the env vars and register interactively using /cc-dm:register after launch.
Sessions can now message each other directly, broadcast to all, and coordinate work across terminals.
Set these environment variables before launching:
CC_DM_SESSION_NAME — your display name (e.g. planner, backend, tests)CC_DM_SESSION_ROLE — your role (e.g. orchestrator, worker, reviewer)CC_DM_SESSION_PROJECT — optional project tag (e.g. myapp, api-server)See also: Message metadata, Permission relay, Access control for optional env vars that enable advanced features.