InterAgentMail
The InterAgentMail MCP server enables durable inter-agent messaging and chat for local Codex project agents, along with system management features.
Identity & Mailbox Discovery: Retrieve the current project's mailbox identity (
iam_whoami) and list all known mailbox addresses (iam_list_mailboxes).Inbox Management: List recent messages, optionally filtering for unread (
iam_inbox); read a specific message by ID, optionally marking it as read (iam_read); archive fully handled messages to remove them from the inbox (iam_archive).Composing Messages: Send new messages with recipients, subject, body, CC, references, and attachments (
iam_send); reply to existing messages, preserving thread metadata (iam_reply).Chat Channels: List public and private channels (
iam_list_channels); read recent messages from a channel with date filtering and line limit, respecting private channel membership (iam_chat_tail); post messages to channels, optionally creating private DM channels with another agent (iam_chat_post); mark messages as seen (iam_chat_seen).Project Registration & Configuration: Register Codex projects, initialize durable mailboxes, record project directories and safety policies, and integrate with Codex MCP configuration.
Service Control & Status: Start, stop, and restart mail delivery services; query status of services, projects, and pinned thread IDs; run health checks.
Support & Diagnostics: Generate privacy-sanitized support reports with installation details, service health, and log statistics for troubleshooting.
Provides durable mailboxes and MCP tools for sending messages between OpenAI Codex agents, with automatic wake-up delivery and persistent message storage.
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., "@InterAgentMailSend mail to SecurityReviewer: please review the latest PR for security issues."
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.
InterAgentMail
InterAgentMail gives local Codex project agents durable mailboxes, MCP tools, and automatic wake-up delivery. Messages are stored as JSON on disk, so they remain queued while Codex or the receiving agent is offline.
One shared Codex app-server and one background InterAgentMail supervisor manage every registered project. Users do not need a bridge terminal, a port per agent, or copied Codex session IDs.
Requirements
Python 3.10 or newer
The OpenAI Codex CLI installed, available on
PATH, and signed inWindows, macOS, or Linux; background operation is tested most heavily on Windows
Related MCP server: backchannel
Install
Install the isolated command-line application from PyPI with pipx:
pipx install cgl-interagentmailRegister one or more Codex projects, then start delivery:
iam setup "C:\Projects\MainApp" "C:\Projects\SecurityReviewer" "C:\Projects\UXReviewer"
iam startOpen the correct agent from any registered project:
cd C:\Projects\SecurityReviewer
iam openThe complete Windows, macOS, Linux, upgrade, troubleshooting, and uninstall instructions are in docs/INSTALL.md.
Source code, releases, and issue tracking are hosted at https://github.com/cerberusgamelabs/cgl-interagentmail.
Everyday commands
iam status
iam doctor
iam report
iam open [PROJECT]
iam restart
iam stop
iam stop --all
iam register [PROJECT ...]
iam unregister [PROJECT ...]
iam capabilities --jsoniam statusshows services, projects, and pinned thread IDs;--jsonprovides stable schema 1.0 output.iam doctorruns read-only health checks for IAM, Codex, services, project registration, MCP configuration, mailboxes, safety policy, and resumable threads.iam reportcreates a privacy-sanitized Markdown support report under the IAM data directory.iam openresumes the exact thread owned by the current or named project.iam stopstops mail delivery but leaves the shared app-server running.iam stop --allstops both IAM-managed background services.iam unregisterremoves IAM's managed MCP block and project registration while preserving mailbox data.
Setup behavior
iam setup is safe to run again. It:
Initializes the project's durable mailbox.
Records its project directory and safety policy.
Adds a clearly marked
mcp_servers.interagentmailblock to.codex/config.toml.Establishes the existing-inbox baseline so old mail does not unexpectedly trigger work.
Use iam setup --process-existing when existing inbox messages should be delivered immediately.
Installed releases keep data under %LOCALAPPDATA%\InterAgentMail on Windows or ~/.local/share/interagentmail on macOS/Linux. Set INTERAGENTMAIL_HOME before setup to use another shared data directory.
Project folder basenames become mailbox addresses. IAM records mailbox ownership and refuses to register two different project roots with the same address before changing either project or mailbox.
Automation and reviewer platforms
Version 1.2 adds a stable JSON interface for tools that create reviewer projects or manage agent fleets:
iam capabilities --json
iam register "C:\Projects\SecurityReviewer" --json
iam status --json
iam doctor --project "C:\Projects\SecurityReviewer" --json
iam unregister "C:\Projects\SecurityReviewer" --jsoniam register is the automation-oriented alias for iam setup and is safe to repeat while delivery is running. Human-facing identity remains optional: --display-name supplies a label, but IAM does not force a persona. See docs/INTEGRATION.md for the versioned envelope, stable errors, collision behavior, identity ownership, and full lifecycle contract.
Diagnostics and support reports
Run a read-only installation check at any time:
iam doctorWarnings describe optional or currently stopped components. Failures produce a nonzero exit status and identify configuration that needs attention.
Create a report suitable for attaching to a support issue:
iam reportThe report contains software versions, operating-system information, service health, registered-project checks, mailbox counts, and bounded log statistics. It replaces project names, display names, project paths, user paths, email addresses, thread IDs, message IDs, and common credential formats. It never reads message bodies or chat contents into the report and deliberately omits raw app-server logs because those logs can contain source code or private instructions.
Use iam report --stdout to inspect or pipe the report, iam report --output PATH to choose its location, and iam report --log-lines N to change how many trailing log lines are counted. Existing output files are preserved unless --force is supplied. Automated sanitization is intentionally conservative, but review any report before sharing it publicly.
Safety
New agents use workspace-write with on-request approvals. The unattended supervisor rejects interactive approval requests instead of granting them. A task that needs approval remains uncompleted until a person opens that agent.
Only for a trusted project that genuinely requires unrestricted filesystem and network access:
iam setup "C:\Projects\SecurityReviewer" --full-accessInterAgentMail is a local coordination mechanism, not an authentication boundary. Any local process that can write to its data directory can inject or modify mail. Do not share that directory with untrusted users or accept untrusted message content as instructions.
Sending mail
Agents normally use the project-bound InterAgentMail MCP tools. People and fallback workflows can use the CLI:
interagentmail send --project-root "C:\Projects\MainApp" --to SecurityReviewer --subject "Security review" --body "Review the current release and send back actionable findings."The receiving supervisor wakes the correct Codex thread. The agent reads the message through MCP, performs the work, sends a substantive reply when appropriate, and archives the message only after it is handled.
Protocol and low-level bridge details are in SYSTEM.md. Release history is in CHANGELOG.md.
Support
InterAgentMail is free and open source. If it helps your agents work together, you can support Cerberus Game Labs on Ko-fi.
License
InterAgentMail is open-source software released under the MIT License. Use it, modify it, distribute it, and build on it. Copyright 2026 Cerberus Game Labs.
Contributions are welcome; see CONTRIBUTING.md.
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
- Alicense-qualityFmaintenanceEnables file-based agent-to-agent communication between Claude Code instances on the same machine, using MCP channels and plain JSON files.Last updated2013MIT
- Alicense-qualityBmaintenanceMCP server for async messaging between AI coding agents, enabling cross-harness and cross-machine communication with Slack-like semantics and mail-shaped delivery.Last updated2MIT
- Alicense-qualityCmaintenanceLocal inter-agent messaging for AI coding agents via filesystem relay.Last updated2MIT
- Alicense-qualityCmaintenanceFile-based MCP server for AI coding agents to coordinate via inbox messaging and human escalation.Last updatedMIT
Related MCP Connectors
Hosted email MCP for AI agents with inboxes, send/receive, memory, recovery, and credits.
Durable agent-to-agent handoffs and shared scratchpad for multi-agent workflows.
Private-by-default, local-first memory/context/task orchestrator for MCP apps and agents.
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/cerberusgamelabs/cgl-interagentmail'
If you have feedback or need assistance with the MCP directory API, please join our Discord server