Mailgun MCP

v1.0.0Communicationstable

A Model Context Protocol server implementation that enables AI assistants like Claude Desktop to interact with Mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language.

mailgun-mcp-servermcpai-integration
Share:
57
Stars
0
Downloads
0
Weekly
0/5

What is Mailgun MCP?

Mailgun MCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to model context protocol server implementation that enables ai assistants like claude desktop to interact with mailgun email services, allowing users to send emails and visualize email delivery statisti...

A Model Context Protocol server implementation that enables AI assistants like Claude Desktop to interact with Mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language.

This server falls under the Communication category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • A Model Context Protocol server implementation that enables

Use Cases

Send emails through Mailgun API via Claude Desktop.
Visualize email delivery statistics automatically.
Manage email operations with natural language.
mailgun

Maintainer

LicenseApache 2.0
Languagetypescript
Versionv1.0.0
UpdatedMay 19, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx mailgun-mcp-server

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Mailgun MCP

The Mailgun MCP Server is an official Mailgun integration for AI assistants that exposes the full breadth of Mailgun's email API through the Model Context Protocol, covering message sending and retrieval, domain verification, webhook management, template creation with versioning, analytics and delivery statistics, suppression list management, mailing lists, inbound routing rules, and dedicated IP pool configuration. It is maintained by Mailgun directly, ensuring the tools stay current with the API. Developers and marketing teams use it to send transactional emails, debug delivery issues, and analyze email engagement through natural language without writing API calls.

Prerequisites

  • Node.js 18+ with npm installed
  • A Mailgun account with at least one verified sending domain at https://app.mailgun.com
  • A Mailgun API key from the Mailgun dashboard (Settings > API Keys)
  • An MCP-compatible client such as Claude Desktop or Claude Code
1

Get your Mailgun API key

Log in to the Mailgun dashboard, navigate to Settings > API Keys, and copy your Private API key. Note your account region (US or EU) as it affects the API endpoint.

2

Add the server to your MCP client config

Edit your claude_desktop_config.json to register the Mailgun MCP server with your API key and region.

{
  "mcpServers": {
    "mailgun": {
      "command": "npx",
      "args": ["-y", "@mailgun/mcp-server"],
      "env": {
        "MAILGUN_API_KEY": "your-mailgun-api-key",
        "MAILGUN_API_REGION": "us"
      }
    }
  }
}
3

Optionally restrict to specific tool categories

Use the --tags flag in args to limit which tools are exposed. Valid tags are: send, validate, optimize, inspect. This reduces the tool list for focused use cases.

"args": ["-y", "@mailgun/mcp-server", "--tags", "send,inspect"]
4

Restart Claude Desktop

Fully quit and reopen Claude Desktop to activate the Mailgun server. On macOS the config is at ~/Library/Application Support/Claude/claude_desktop_config.json.

5

Send a test email

Ask Claude to send a test email through your verified Mailgun domain to confirm the integration is working end-to-end.

Mailgun MCP Examples

Client configuration

Full claude_desktop_config.json entry for the official Mailgun MCP server.

{
  "mcpServers": {
    "mailgun": {
      "command": "npx",
      "args": ["-y", "@mailgun/mcp-server"],
      "env": {
        "MAILGUN_API_KEY": "your-mailgun-private-api-key",
        "MAILGUN_API_REGION": "us"
      }
    }
  }
}

Prompts to try

Example natural language prompts for Mailgun operations.

- "Send an email to [email protected] with subject 'Your order has shipped' from [email protected]"
- "Show me a chart of email delivery statistics for yourdomain.com over the past 7 days"
- "Check DNS verification status for yourdomain.com and list any missing records"
- "Summarize all unsubscribes and complaints for yourdomain.com this month"
- "Create an email template called 'welcome' with a personalized greeting and a CTA button"

Troubleshooting Mailgun MCP

401 Unauthorized when sending emails

Verify MAILGUN_API_KEY is your Private API key, not your Public Validation key. Also confirm MAILGUN_API_REGION matches your account — EU accounts must use 'eu', not the default 'us'.

Emails not delivered (queued but no delivery event)

Confirm your sending domain is fully verified in the Mailgun dashboard. Check DNS records for SPF, DKIM, and MX. Ask Claude to use the domain verification tool to identify missing DNS entries.

Tool not found errors for specific Mailgun operations

If you used --tags to restrict tools, the requested tool may be excluded. Either remove the tag filter or add the relevant tag (e.g., 'send' for message operations) to the args array.

Frequently Asked Questions about Mailgun MCP

What is Mailgun MCP?

Mailgun MCP is a Model Context Protocol (MCP) server that model context protocol server implementation that enables ai assistants like claude desktop to interact with mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Mailgun MCP?

Follow the installation instructions on the Mailgun MCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Mailgun MCP?

Mailgun MCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Mailgun MCP free to use?

Yes, Mailgun MCP is open source and available under the Apache 2.0 license. You can use it freely in both personal and commercial projects.

Browse More Communication MCP Servers

Explore all communication servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "mailgun-mcp-server": { "command": "npx", "args": ["-y", "mailgun-mcp-server"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Mailgun MCP?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides