agent-mesh
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
agent-mesh
A tiny message bus and MCP server so AI coding agents can ask each other for work and review it.
Each agent gets three tools — agent_list, agent_send, agent_inbox — and a typed, auditable conversation:
question → delivery → review request → decision, optionally tied to a task id. Zero dependencies, ~300 lines of Node.
sequenceDiagram
participant P as planner (Claude / Codex / …)
participant B as broker (HTTP, localhost)
participant C as coder
participant R as reviewer
P->>B: agent_send(to=coder, type=pregunta, taskId)
C->>B: agent_inbox()
B-->>C: "Implement slugify…"
C->>B: agent_send(to=reviewer, type=pedido_revision)
R->>B: agent_inbox()
R->>B: agent_send(to=coder, type=respuesta, "rejected: accents")
C->>B: agent_send(to=reviewer, type=pedido_revision)
R->>B: agent_send(to=planner, type=entrega, "approved")
Note over B: audit log keeps every message, filterable by taskIdWhy
Multi-agent setups usually end up as "one agent shells out to another" with no record of who asked what. A broker
gives you the things you actually need when agents delegate to each other: identity (who is asking), typed
intent (a blocking question is not a status update), idempotent retries (clientRequestId), an inbox per
agent, and an audit trail per task you can read afterwards.
Related MCP server: AgentMesh
Run the demo (no LLM, no install)
node demo/three-agents.mjsplanner │ → coder: implement slugify(title)
coder │ → reviewer: attempt 1
reviewer │ → coder: rejected (accents and punctuation are not handled)
coder │ → reviewer: attempt 2
reviewer │ → planner: approved
audit trail for task-20261111-001: planner→coder(pregunta) coder→reviewer(pedido_revision) reviewer→coder(respuesta) coder→reviewer(pedido_revision) reviewer→planner(entrega)Use it with real agents (MCP)
node src/broker-server.mjs # 127.0.0.1:8750 (set MESH_TOKEN to require a bearer token)Add the same MCP server to each agent, changing only its identity (example for Claude Code / any MCP client):
{ "mcpServers": { "mesh": {
"command": "node", "args": ["/path/to/agent-mesh/src/mcp-server.mjs"],
"env": { "AGENT_ID": "coder", "AGENT_ROLE": "implements tickets", "MESH_URL": "http://127.0.0.1:8750" } } } }Tool | What it does |
| agents on the mesh and how many unread messages each has |
|
|
| read and clear your unread messages |
HTTP API (same broker): POST /agents, GET /agents, POST /send, GET /inbox?agent=, GET /audit?taskId=, GET /health.
Tests
npm test # 6 tests: delivery, idempotency, validation, audit, bearer auth, MCP toolsDesign notes and limits
State is in memory (restart = empty inboxes). Persisting the audit log to SQLite/JSONL is the obvious next step.
Delivery is at-most-once on read; the audit log is the source of truth.
Auth is a single shared bearer token — fine for one machine/team, not for multi-tenant use.
Message type names are Spanish (
pregunta,entrega, …) because that is the protocol this was extracted from.
Origin and licence
The protocol (agent_send / agent_list, typed messages, taskId, clientRequestId) comes from a fork of
T3 Code (MIT, © T3 Tools Inc.) where agents running in separate threads message
each other through an MCP server. That implementation is tied to T3's internals, so this repository is a clean,
standalone re-implementation of the idea, not a copy of its code. See NOTICE. Licensed under MIT.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Coordination hub for AI coding agents: message teammates, ask humans, audit every event.
Messaging and inboxes for AI agents: register, send signed messages, check your inbox, find agents.
Privacy-first coordination for autonomous agents: rooms, messaging, inbox, and per-agent memory.
End-to-end encrypted messaging and work coordination for autonomous AI agents.
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceA mail-like coordination layer for coding agents, providing identities, inbox/outbox, searchable threads, and advisory file reservations to prevent conflicts in multi-agent workflows.1MIT
- AlicenseNot gradedqualityBmaintenanceEnables already-running AI coding agents on the same project to register, discover one another, and exchange durable direct messages so they can share progress and avoid conflicting work.Apache 2.0
- AlicenseAqualityBmaintenanceLets separate coding-agent sessions coordinate through a shared, role-addressed mailbox instead of a human relaying every message, over a single local SQLite file or a hosted server with many isolated channels. Messages can be sent as tracked obligations that stay open until one side resolves and the other confirms, alongside threads, full-text search, work statuses, and an append-only versioned pin system where protected changes require recorded agreement from every declared role.41MIT
- AlicenseNot gradedqualityBmaintenanceLets AI agents exchange typed, schema-validated messages and coordinate asynchronously through a shared inbox, with tools to list, ask, send, and reply to other agents.MIT