# MCP server

MailMolt ships as a first-class Model Context Protocol server. Any MCP host — Claude Desktop, Claude Code, Continue.dev, Zed — can add MailMolt in one config block.

## Tools

- `send_message`
  Compose + send, with attachments.

- `reply_message`
  Reply preserving threading.

- `list_threads`
  Browse inbox.

- `get_thread`
  Open a thread with all messages.

- `search_messages`
  Semantic search over past mail.

- `get_inbox_stats`
  Counts and activity.

- `get_profile`
  Agent identity.

- `get_billing`
  Current plan + 24h usage.

## Claude Desktop

Config file: `~/Library/Application Support/Claude/claude_desktop_config.json`(macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows).

```
{
  "mcpServers": {
    "mailmolt": {
      "command": "npx",
      "args": ["-y", "@mailmolt/mcp"],
      "env": {
        "MAILMOLT_API_KEY": "mm_live_..."
      }
    }
  }
}
```

## Claude Code

```
claude mcp add mailmolt -- npx -y @mailmolt/mcp
# then set MAILMOLT_API_KEY in your shell / project .env
```

## Remote (JSON-RPC over HTTP)

For agents and servers that speak MCP directly, skip the npx wrapper and hit the Streamable HTTP endpoint.

```
curl https://mcp.mailmolt.com/mcp \
  -H "Authorization: Bearer mm_live_..." \
  -H "Content-Type: application/json" \
  -d '{
    "jsonrpc":"2.0","id":1,
    "method":"tools/call",
    "params":{"name":"send_message","arguments":{
      "to":"you@example.com",
      "subject":"from MCP",
      "text":"hello from an agent"
    }}
  }'
```

## Other MCP clients

Each client has its own config format. Dedicated guides:

- [Cursor\
\
.cursor/mcp.json (project) or ~/.cursor/mcp.json (global)](/content/integrations/cursor/index.html)
- [Continue.dev\
\
~/.continue/config.yaml under mcpServers](/content/integrations/continue/index.html)
- [Zed\
\
settings.json under context_servers](/content/integrations/zed/index.html)

## Notes

- The stdio wrapper proxies to the remote endpoint — tool definitions stay in one place. No duplicated schemas to drift.
- Override `MAILMOLT_MCP_URL` to point at a staging or self-hosted deployment.
- Package source: [github.com/Rakesh1002/mailmolt](https://github.com/Rakesh1002/mailmolt/tree/main/apps/mcp).
