MCP server
by railsware
Send transactional emails easily using Mailtrap Email API. Reliable email delivery, flexible features, and secure integr
Sends transactional emails through the Mailtrap Email API. Manage email templates and send both production and sandbox test emails.
Mailtrap Email API is an official MCP server published by railsware that provides AI assistants with tools and capabilities via the Model Context Protocol. Send transactional emails easily using Mailtrap Email API. Reliable email delivery, flexible features, and secure integr It is categorized under communication.
You can install Mailtrap Email API in your AI client of choice. Use the install panel on this page to get one-click setup for Cursor, Claude Desktop, VS Code, and other MCP-compatible clients. This server runs locally on your machine via the stdio transport.
MIT
Mailtrap Email API is released under the MIT license. This is a permissive open-source license, meaning you can freely use, modify, and distribute the software.
Add new capabilities to Claude beyond text generation
Example
Access external data sources, execute code, interact with tools and services
Transform Claude from chatbot to action-taking agent
Provide Claude with access to relevant context and data
Example
Load project documentation, access knowledge bases, query databases
Get more accurate, context-aware responses
Automate multi-step workflows combining AI and external tools
Example
Research → Summarize → Create document → Send notification
Complete complex tasks end-to-end without manual steps
Share your MCP server with the developer community
Mailtrap Email API is among the better-indexed MCP projects we tried; the explainx.ai summary tracks the official description.
I recommend Mailtrap Email API for teams standardizing on MCP; the explainx.ai page compares cleanly with sibling servers.
We evaluated Mailtrap Email API against two servers with overlapping tools; this profile had the clearer scope statement.
We evaluated Mailtrap Email API against two servers with overlapping tools; this profile had the clearer scope statement.
Useful MCP listing: Mailtrap Email API is the kind of server we cite when onboarding engineers to host + tool permissions.
We wired Mailtrap Email API into a staging workspace; the listing’s GitHub and npm pointers saved time versus hunting across READMEs.
Strong directory entry: Mailtrap Email API surfaces stars and publisher context so we could sanity-check maintenance before adopting.
Useful MCP listing: Mailtrap Email API is the kind of server we cite when onboarding engineers to host + tool permissions.
We evaluated Mailtrap Email API against two servers with overlapping tools; this profile had the clearer scope statement.
Mailtrap Email API has been reliable for tool-calling workflows; the MCP profile page is a good permalink for internal docs.
showing 1-10 of 74
An MCP server that provides tools for sending transactional emails and managing email templates via Mailtrap
Before using this MCP server, you need to:
Required Environment Variables:
MAILTRAP_API_TOKEN - Required for all functionalityDEFAULT_FROM_EMAIL - Required for all email sending operationsMAILTRAP_ACCOUNT_ID - Required for template management operationsMAILTRAP_TEST_INBOX_ID - Only required for sandbox email functionalitySmithery is a registry installer and manager for MCP servers that works with all AI clients.
npx @smithery/cli install mailtrap
Smithery automatically handles client configuration and provides an interactive setup process. It's the easiest way to get started with MCP servers locally.
Use MCPB to install the Mailtrap server. You can find those files in Releases. <br>Download .MCPB file and open it. If you have Claude Desktop - it will open it and suggest to configure.
Add the following configuration:
{
"mcpServers": {
"mailtrap": {
"command": "npx",
"args": ["-y", "mcp-mailtrap"],
"env": {
"MAILTRAP_API_TOKEN": "your_mailtrap_api_token",
"DEFAULT_FROM_EMAIL": "your_sender@example.com",
"MAILTRAP_ACCOUNT_ID": "your_account_id",
"MAILTRAP_TEST_INBOX_ID": "your_test_inbox_id"
}
}
}
}
If you are using asdf for managing Node.js you must use absolute path to executable (example for Mac)
{
"mcpServers": {
"mailtrap": {
"command": "/Users/<username>/.asdf/shims/npx",
"args": ["-y", "mcp-mailtrap"],
"env": {
"PATH": "/Users/<username>/.asdf/shims:/usr/bin:/bin",
"ASDF_DIR": "/opt/homebrew/opt/asdf/libexec",
"ASDF_DATA_DIR": "/Users/<username>/.asdf",
"ASDF_NODEJS_VERSION": "20.6.1",
"MAILTRAP_API_TOKEN": "your_mailtrap_api_token",
"DEFAULT_FROM_EMAIL": "your_sender@example.com",
"MAILTRAP_ACCOUNT_ID": "your_account_id",
"MAILTRAP_TEST_INBOX_ID": "your_test_inbox_id"
}
}
}
}
Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Mac: ~/.cursor/mcp.json
Windows: %USERPROFILE%\.cursor\mcp.json
Run in Command Palette: Preferences: Open User Settings (JSON)
Then, in the settings file, add the following configuration:
{
"mcp": {
"servers": {
"mailtrap": {
"command": "npx",
"args": ["-y", "mcp-mailtrap"],
"env": {
"MAILTRAP_API_TOKEN": "your_mailtrap_api_token",
"DEFAULT_FROM_EMAIL": "your_sender@example.com",
"MAILTRAP_ACCOUNT_ID": "your_account_id",
"MAILTRAP_TEST_INBOX_ID": "your_test_inbox_id"
}
}
}
}
}
[!TIP] Don't forget to restart your MCP server after changing the "env" section.
For easy installation in hosts that support MCP Bundles, you can distribute an .mcpb bundle file.
# Build TypeScript and pack the MCPB bundle
npm run mcpb:pack
# Inspect bundle metadata
npm run mcpb:info
# Sign the bundle for distribution (optional)
npm run mcpb:sign
This creates mailtrap-mcp.mcpb using the repository manifest.json and built artifacts in dist/.
Once configured, you can ask agent to send emails and manage templates, for example:
Email Operations:
Sandbox Operations:
Template Operations:
Sends a transactional email through Mailtrap.
Parameters:
to (required): Email address(es) of the recipient(s) - can be a single email or array of emailssubject (required): Email subject linefrom (optional): Email address of the sender, if not provided "DEFAULT_FROM_EMAIL" will be usedtext (optional): Email body text, required if "html" is emptyhtml (optional): HTML version of the email body, required if "text" is emptycc (optional): Array of CC recipient email addressesbcc (optional): Array of BCC recipient email addressescategory (required): Email category for tracking and analyticsSends an email to your Mailtrap test inbox for development and testing purposes. This is perfect for testing email templates without sending emails to real recipients.
Parameters:
to (required): Email address(es) of the recipient(s) - can be a single email or array of emails (will be delivered to your test inbox)subject (required): Email subject linefrom (optional): Email address of the sender, if not provided "DEFAULT_FROM_EMAIL" will be usedtext (optional): Email body text, required if "html" is emptyhtml (optional): HTML version of the email body, required if "text" is emptycc (optional): Array of CC recipient email addressesbcc (optional): Array of BCC recipient email addressescategory (optional): Email category for tracking[!NOTE] The
MAILTRAP_TEST_INBOX_IDenvironment variable must be configured for sandbox emails to work. This variable is only required for sandbox functionality and is not needed for regular transactional emails or template management.
Retrieves a list of messages from your Mailtrap test inbox. Useful for checking what emails have been received in your sandbox during testing.
Parameters:
page (optional): Page number for pagination (minimum: 1)last_id (optional): Pagination using last message ID. Returns messages after the specified message ID (minimum: 1)search (optional): Search query to filter messages[!NOTE] All parameters are optional. If none are provided, the first page of messages from the inbox will be returned. Use page for traditional pagination, last_id for cursor-based pagination, or search to filter messages by content.
Shows detailed information and content of a specific email message from your Mailtrap test inbox, including HTML and text body content.
Parameters:
message_id (required): ID of the sandbox email message to retrieve[!NOTE] Use
get-sandbox-messagesfirst to get the list of messages and their IDs, then use this tool to view the full content of a specific message.
Creates a new email template in your Mailtrap account.
Parameters:
name (required): Name of the templatesubject (required): Email subject linehtml (or text is required): HTML content of the templatetext (or html is required): Plain text versionPrerequisites
Time Estimate
15-60 minutes depending on server complexity
Steps
Troubleshooting
✓ Do
✗ Don't
💡 Pro Tips
Architecture
Model Context Protocol standardizes how AI hosts (Claude, Cursor) communicate with external tools and data sources through server implementations.
Protocols
Compatibility
✓ Use when
Use when you need Claude to access external data, execute actions, or integrate with tools. Best for extending AI capabilities beyond conversation.
✗ Avoid when
Avoid when native integrations exist (use official APIs directly), for real-time critical systems, or when security/compliance requires zero external dependencies.