> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

# MCP Quickstart

> Connect Mailofly to your AI editor in 60 seconds. Send emails, inspect logs, and manage audiences directly from natural language.

# Quickstart

Supercharge your AI assistant with native email infrastructure capabilities. Once connected, your AI can compose emails, query sending quotas, inspect delivery logs, and manage subscriber audiences directly within your conversational flow.

***

**1. Get your Mailofly API Key**

Generate an API key with send or full access permissions from the [Mailofly Dashboard](https://www.mailofly.com/user/settings/api-keys).

```bash theme={null}
mf_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxx
```

> [!TIP]
>
> Keep your API key secure. We recommend storing it as an environment variable or referencing your secrets manager in production configurations.

**2. Add Mailofly to your AI Assistant**

Mailofly offers two ways to connect — pick the one your client supports:

> [tab] Hosted URL (Zero-install)
>
> For clients that accept an MCP server URL (Claude.ai, Smithery, and any SSE-compatible client):
>
> ```
> https://mcp.mailofly.com/sse
> ```
>
> Append your API key as a query parameter:
>
> ```
> https://mcp.mailofly.com/sse?key=mf_live_your_api_key_here
> ```
>
> > [!TIP]
> >
> > No Node.js or local installation needed. The hosted server runs on Fly.io across Singapore and London for low-latency access worldwide.

> [tab] Cursor
>
> [![Install in Cursor](https://img.shields.io/badge/Install%20in%20Cursor-000000?style=for-the-badge\&logo=cursor\&logoColor=white)](cursor://anysphere.cursor-deeplink/mcp/install?name=mailofly\&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBtYWlsb2ZseS9tY3AiXSwiZW52Ijp7Ik1BSUxPRkxZX0FQSV9LRVkiOiJZT1VSX0FQSV9LRVkifX0=)
>
> Or add to `.cursor/mcp.json` (or **Cursor Settings** > **Features** > **MCP**):
>
> ```json theme={null}
> {
>   "mcpServers": {
>     "mailofly": {
>       "command": "npx",
>       "args": ["-y", "@mailofly/mcp"],
>       "env": {
>         "MAILOFLY_API_KEY": "mf_live_your_api_key_here"
>       }
>     }
>   }
> }
> ```

> [tab] Google Antigravity
>
> Install with a single CLI command:
>
> ```bash theme={null}
> agy mcp add mailofly -- npx -y @mailofly/mcp
> ```
>
> Or add to your `.gemini/antigravity-ide/mcp_config.json` or `~/.gemini/config/mcp_config.json`:
>
> ```json theme={null}
> {
>   "mcpServers": {
>     "mailofly": {
>       "command": "npx",
>       "args": ["-y", "@mailofly/mcp"],
>       "env": {
>         "MAILOFLY_API_KEY": "mf_live_your_api_key_here"
>       }
>     }
>   }
> }
> ```

> [tab] Claude Desktop
>
> Open your Claude Desktop configuration file:
>
> * **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
> * **Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
>
> Add the `mailofly` entry under `mcpServers`:
>
> ```json theme={null}
> {
>   "mcpServers": {
>     "mailofly": {
>       "command": "npx",
>       "args": ["-y", "@mailofly/mcp"],
>       "env": {
>         "MAILOFLY_API_KEY": "mf_live_your_api_key_here"
>       }
>     }
>   }
> }
> ```

> [tab] Windsurf
>
> In Windsurf, open **Settings** > **Cascade** > **MCP Servers**, or update `~/.codeium/windsurf/mcp_config.json`:
>
> ```json theme={null}
> {
>   "mcpServers": {
>     "mailofly": {
>       "command": "npx",
>       "args": ["-y", "@mailofly/mcp"],
>       "env": {
>         "MAILOFLY_API_KEY": "mf_live_your_api_key_here"
>       }
>     }
>   }
> }
> ```

**3. Verify the connection**

Restart your editor or reload MCP servers. Ask your AI assistant to check your account status:

```text theme={null}
Check my Mailofly email sending quota and verified domains.
```

Your AI will call `mailofly_get_usage` and `mailofly_list_domains`, returning your plan limits, current usage, and DNS verification statuses in seconds.

***

## What you can ask your AI

Here are a few real-world examples you can paste directly into your AI chat:

> [accordion] Send a transactional or test email
>
> ```text theme={null}
> Send a test welcome email from alex@yourdomain.com to user@example.com
> with the subject 'Welcome to our platform' and a clean HTML card welcoming them.
> ```

> [accordion] Inspect delivery status and logs
>
> ```text theme={null}
> Look up the delivery status and error logs for the email sent to alex@example.com.
> ```

> [accordion] Manage audiences and subscribers
>
> ```text theme={null}
> Add sarah@example.com to our 'Beta Testers' audience segment with the tag 'vip'.
> ```

> [accordion] Check domain DNS and authentication
>
> ```text theme={null}
> Show the SPF, DKIM, and DMARC verification status for yourdomain.com.
> ```

***

## Interactive Debugging (MCP Inspector)

If you'd like to test tools and inspect parameters in a graphical browser interface outside your editor:

**Via npx (local):**

```bash theme={null}
MAILOFLY_API_KEY=mf_live_your_api_key npx @modelcontextprotocol/inspector npx -y @mailofly/mcp
```

*(On Windows PowerShell):*

```powershell theme={null}
$env:MAILOFLY_API_KEY="mf_live_your_api_key"; npx @modelcontextprotocol/inspector npx -y @mailofly/mcp
```

**Via hosted URL:**

```bash theme={null}
npx @modelcontextprotocol/inspector https://mcp.mailofly.com/sse?key=mf_live_your_api_key
```

This launches the official web-based MCP Inspector, allowing you to manually trigger tools, preview resource payloads, and inspect schema responses.

***

## Next Steps

> [card] [Client Setup](/docs/mcp-server/clients.md)
>
> Detailed configuration instructions for Cursor, Claude, Antigravity, Windsurf, Zed, and Cline.

> [card] [Available Tools](/docs/mcp-server/tools.md)
>
> Explore all 19 tools with parameter references and practical prompt examples.

> [card] [MCP Resources](/docs/mcp-server/resources.md)
>
> Understand how AI assistants use live URI resources for automatic context grounding.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.