agent-jmap-mcp
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., "@agent-jmap-mcpFind the latest email from Alice and summarize it"
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.
agent-jmap-mcp
A stateless, production-grade JSON Meta Application Protocol (JMAP) client and Model Context Protocol (MCP) server for AI agents, automation pipelines, and developer workflows.
Compliant with RFC 8620 (JMAP Core) and RFC 8621 (JMAP Mail), agent-jmap-mcp allows language models (e.g. Claude, Hermes Agent, GPT-4, Cursor) to inspect mailboxes, search and retrieve messages, navigate conversation threads, download attachments, perform automated inbox triage, and compose/send emails atomically over pure HTTP.
Architecture
flowchart TD
subgraph Host["AI Agent / Host Application"]
Agent["AI Agent / LLM Client"]
end
subgraph MCP["agent-jmap-mcp Server"]
Server["FastMCP stdio Engine"]
Tools["Tools Interface<br/>(list, search, get, thread, download, send, triage)"]
TriageEng["Rule-Based Triage Engine"]
Converter["HTML-to-Markdown Engine"]
Client["RFC 8620/8621 JMAP Client"]
end
subgraph Upstream["JMAP Email Server"]
JMAPEndpoint["JMAP API Endpoint<br/>(Fastmail / Stalwart / Cyrus)"]
end
Agent <-->|"JSON-RPC / stdio"| Server
Server --> Tools
Tools --> TriageEng
Tools --> Converter
Tools --> Client
Client <-->|"Stateless HTTPS (JSON Batches / Binary Streams)"| JMAPEndpointRelated MCP server: mcp-imap
Key Capabilities
Stateless HTTP Architecture: Operates over standard HTTPS with bearer token authentication. Avoids persistent IMAP socket overhead and connection timeout state.
Atomic Operations: Executes message creation and dispatch in a single atomic transaction combining
Email/setandEmailSubmission/set.Conversation Threading (
Thread/get): Full RFC 8621 conversation thread retrieval aggregating multi-turn email dialogues chronologically.Binary Attachment Downloads: High-speed streaming downloads for PDF, image, and data attachments via session
downloadUrl.Rich HTML-to-Markdown Extraction: Automated markdown conversion for HTML-only newsletters and styled emails.
Session Auto-Discovery: Automatically queries
/.well-known/jmapto discover API endpoints, upload/download URLs, and primary account IDs.Zero-Footprint Model Context: Optimized JSON payloads structured specifically for minimal LLM context window consumption.
Automated Inbox Triage: Built-in heuristic classification for inbox sorting (Urgent, Action Required, Personal, Notifications, Newsletters).
Universal MCP Compatibility: Plugs directly into Claude Desktop, Hermes Agent, Cursor, Zed, and any MCP-compliant environment.
Installation
Using uv (Recommended)
uv tool install agent-jmap-mcpUsing pipx or pip
pipx install agent-jmap-mcp
# or
pip install agent-jmap-mcpConfiguration
Set the required environment variables:
Variable | Description | Example / Default |
| JMAP Session discovery URL |
|
| Bearer API token |
|
| Optional target account ID | Auto-discovered from session if omitted |
A .env.example template is provided in the repository.
MCP Server Integration
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"jmap": {
"command": "uvx",
"args": ["agent-jmap-mcp"],
"env": {
"JMAP_SESSION_URL": "https://api.fastmail.com/.well-known/jmap",
"JMAP_API_TOKEN": "YOUR_JMAP_API_TOKEN"
}
}
}
}Hermes Agent
Add to ~/.hermes/config.yaml:
mcp_servers:
jmap:
command: "uvx"
args: ["agent-jmap-mcp"]
env:
JMAP_SESSION_URL: "https://api.fastmail.com/.well-known/jmap"
JMAP_API_TOKEN: "${JMAP_API_TOKEN}"Cursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"jmap": {
"command": "uvx",
"args": ["agent-jmap-mcp"],
"env": {
"JMAP_SESSION_URL": "https://api.fastmail.com/.well-known/jmap",
"JMAP_API_TOKEN": "YOUR_JMAP_API_TOKEN"
}
}
}
}Zed Editor
Add to settings.json:
{
"context_servers": {
"jmap": {
"command": {
"path": "uvx",
"args": ["agent-jmap-mcp"],
"env": {
"JMAP_SESSION_URL": "https://api.fastmail.com/.well-known/jmap",
"JMAP_API_TOKEN": "YOUR_JMAP_API_TOKEN"
}
}
}
}
}Available MCP Tools
Tool Name | Parameters | Description |
| None | Returns metadata for all mailboxes (IDs, names, roles, unread/total counts). |
|
| Queries email headers with filtering, search conditions, and sorting. |
|
| Fetches full email body (converted to markdown if HTML), headers, and attachments. |
|
| Fetches full multi-message conversation thread chronologically. |
|
| Downloads binary attachment from JMAP server and saves to disk. |
|
| Atomically creates and submits an outgoing message (or saves to drafts). |
|
| Analyzes recent messages and returns categorization, priorities, and action items. |
Command Line Interface (CLI)
The package includes a standalone CLI tool agent-jmap:
# Start MCP server over stdio
agent-jmap serve
# List available mailboxes
agent-jmap mailboxes
# List recent emails
agent-jmap list --limit 10
agent-jmap list --unread --query "invoice"
# View specific email
agent-jmap get <email-id>
# View entire conversation thread
agent-jmap thread <thread-id>
# Download binary attachment
agent-jmap download <blob-id> --name report.pdf --output ./downloads
# Run inbox triage
agent-jmap triage --limit 20
# Send email from command line
agent-jmap send --to user@example.com --subject "Status Update" --body "Processing completed."Development and Testing
Setup Environment
git clone https://github.com/ericmaddox/agent-jmap-mcp.git
cd agent-jmap-mcp
uv sync --extra devRunning Test Suite
uv run pytest -vCode Formatting and Linting
uv run ruff check .
uv run ruff format .Building Distribution Packages
uv buildRFC Compliance
License
MIT License. Copyright (c) 2026 Eric Maddox. See LICENSE for details.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
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 Connectors
Email infrastructure for AI agents — send, receive, search, and reply to email over MCP.
Email inboxes for AI agents: send, receive, reply, search, and manage threaded email over MCP.
Email for AI agents — send, receive as a webhook, manage domains, templates, routing.
Stateful email for AI agents — read inboxes, reply in-thread, draft with approval.
Related MCP Servers
- AlicenseAqualityFmaintenanceEnables AI assistants to read, search, compose, and send emails by connecting to any IMAP/SMTP provider. It supports comprehensive mailbox management, including draft handling and message deletion, directly through natural language.1021910MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to interact with email accounts via IMAP and SMTP, supporting mailbox listing, email search, retrieval, sending, and management.MIT
- AlicenseBqualityDmaintenanceEnables AI assistants to send, read, and manage emails via SMTP and IMAP, with support for attachments, threads, and mailbox organization.16421MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to manage Fastmail email accounts via JMAP, including reading, sending, organizing emails, and handling mailboxes, drafts, and masked emails.43MIT
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/ericmaddox/agent-jmap-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server