MM

mailtrap/mailtrap-mcp

开发工具官方

本页由 AI 翻译,技术细节请以原文为准。 查看原文

66 stars 13 forks 质量 88 趋势 20MIT

mailtrap/mailtrap-mcp 是从 https://github.com/mailtrap/mailtrap-mcp. 导入的 MCP 候选服务器

概览

mailtrap/mailtrap-mcp 是从 https://github.com/mailtrap/mailtrap-mcp. 导入的 MCP 候选服务器

概述(AI 翻译)

Mailtrap 的官方 MCP 服务器——电子邮件投递平台。它将你的 Mailtrap 账户连接到 Claude、Cursor、VS Code 及其他兼容 MCP 的 AI 助手。

发送事务性邮件和批量邮件,安全测试邮件沙盒,管理模板、联系人、发送域名和webhook,检查邮件日志和投递统计,排查可达性问题,管理账户资源——所有这些都使用自然语言提示。

能力

  • 电子邮件API和SMTP — 发送事务性和批量邮件,包括批处理和模板邮件。
  • 电子邮件测试 — 在邮件沙箱中测试邮件,检查内容、头部、附件、垃圾邮件评分及HTML客户端兼容性。
  • 投递监控 — 搜索邮件日志,检查事件历史,分析投递、退信、打开、点击和垃圾邮件率。
  • 电子邮件基础设施 — 管理发送域名、DNS验证、webhook和抑制。
  • 联系人 — 管理联系人、列表、自定义字段和事件,支持导入和导出。
  • 账户管理 — 审查计费使用情况,管理访问权限、权限、API令牌和子账户。

支持的MCP客户端

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Official Mailtrap MCP Server

The official MCP server for Mailtrap — the email delivery platform. It connects your Mailtrap account to Claude, Cursor, VS Code, and other MCP-compatible AI assistants.

Send transactional and bulk email, test messages safely in Email Sandbox, manage templates, contacts, domains, and webhooks, inspect email logs and delivery statistics, troubleshoot deliverability, and manage account resources — all using natural-language prompts.

Capabilities

  • Email API and SMTP — Send transactional and bulk email, including batch and template-based messages.
  • Email testing — Test messages in Email Sandbox and inspect content, headers, attachments, spam scores, and HTML client compatibility.
  • Delivery monitoring — Search email logs, inspect event history, and analyze delivery, bounce, open, click, and spam rates.
  • Email infrastructure — Manage domains, DNS verification, webhooks, and suppressions.
  • Contacts — Manage contacts, lists, custom fields, and events, with imports and exports.
  • Account management — Review billing usage and manage access, permissions, API tokens, and sub-accounts.

Supported MCP Clients

Works with Claude Desktop, Claude Code, Cursor, VS Code, and any other MCP-compatible client. Setup instructions for each are below.

Prerequisites

Before using this MCP server, you need to:

  1. Create a Mailtrap account
  2. Verify your domain
  3. Get your API token from Mailtrap API settings
  4. Get your Account ID from Mailtrap account management
  5. Install Node.js 22 or later, unless you run the Docker image

Required Environment Variables:

  • MAILTRAP_API_TOKEN - Required for all functionality
  • MAILTRAP_ACCOUNT_ID - Required for templates, get-sending-stats, email logs, sandbox list/show, domains, and suppressions. Optional only for the send tools (send-email, send-sandbox-email, and the batch-send-* tools), the email campaign tools, get-marketing-stats, the company info tools, the tracking opt-out tools, and list-accounts.

Optional (can be passed as tool parameters instead):

  • DEFAULT_FROM_EMAIL - Default sender email when from is not provided to send-email, send-sandbox-email, or the batch-send-* tools (where it fills base.from). Enables switching sender per call via the from parameter.
在 GitHub 查看完整 README

安装

npx -y mcp-mailtrap
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "mailtrap": { "command": "npx", "args": ["-y", "mcp-mailtrap"], "env": { "MAILTRAP_API_TOKEN": "your_mailtrap_api_token", "DEFAULT_FROM_EMAIL": "[email protected]", "MAILTRAP_ACCOUNT_ID": "your_account_id", "MAILTRAP_SANDBOX_ID": "your_sandbox_id" } } } }