# Mailinator MCP

> Mailinator lets you test email workflows using temporary, disposable inboxes. It catches messages—emails and SMS—without ever touching real addresses or production mailboxes. You manage everything from browsing message lists to checking webhooks, all through your AI client's conversational tools.

## Overview
- **Category:** productivity
- **Price:** Free
- **Tags:** disposable-email, qa-testing, webhook-testing, sms-testing, inbox-inspection, automation-testing

## Description

You're testing complex email flows—the kind where a webhook triggers an SMS response, which then requires another follow-up email. You don't want to mess with live accounts or risk sending junk to actual users. This MCP server lets you test all that stuff safely using disposable mailboxes and webhooks.

You connect your AI client to this server, and it gives your agent the tools to handle every step of debugging a messaging sequence. You can pull messages from public inboxes with `list_inbox_messages`, getting a quick summary count, subject line, and sender for everything that hits the mailbox. When you need the full picture on a specific email, call `get_message_content` to read the complete body text, check all the headers, and pull out any attached files.

Need to know what's in those attachments? Use `list_message_attachments` to get a clean list of file names for any message you’re looking at. If an email has clickable links embedded in the text, run `extract_message_links`, and it pulls out every single URL so your agent can process them.

Want to test how a system reacts when an email drops into a specific staging environment? You'll use `inject_test_message` to simulate an incoming email right into a disposable inbox for immediate testing. You can also send simulated SMS messages by checking the list of private messages with `list_private_sms`, or listing out all your dedicated test environments using `list_private_domains`. These tools let you manage everything from multiple isolated domains and delete any message that gets in the way—just use `remove_message` to keep the sandbox clean.

For advanced testing, you'll need to monitor what happens when other services try to talk to your test environment. Use `list_active_webhooks` to retrieve a list of all configured webhook endpoints and see their current status. If you’re building complex logic for how messages should be handled before they even hit the inbox, check out `list_routing_rules`, which displays all forwarding settings and routing decisions for your test accounts. You can also confirm what domains are available to you by calling `list_private_domains` or see how mail is routed using `list_routing_rules`. 

Don't forget about usage tracking. To monitor API consumption, check the metrics with `get_usage_statistics`; it tells you exactly how many calls you've made and monitors your rate limits for the entire test environment. You manage every piece of data—from reading headers via `get_message_content` to confirming a domain exists with `list_private_domains`, or checking all incoming API traffic through `list_active_webhooks`. It’s a complete sandbox for making sure your messaging logic holds up under pressure.

## Tools

### remove_message
Deletes a specific message from an inbox to keep the testing environment clean.

### list_message_attachments
Gets a list of file names attached to an email message.

### get_domain_details
Retrieves metadata and configuration details for a specific test domain.

### extract_message_links
Pulls all clickable URLs from the text of an email message.

### get_message_content
Reads the full body, headers, and attachments of an email message in the inbox.

### get_usage_statistics
Checks API usage metrics to monitor rate limits and total calls made.

### inject_test_message
Sends a simulated email directly into a chosen disposable inbox for testing purposes.

### list_private_domains
Shows all the custom test domains you have set up for isolated testing environments.

### list_inbox_messages
Lists a summary count, subject, and sender for all messages in a specified inbox.

### list_routing_rules
Displays all configured email forwarding rules and routing logic for your test accounts.

### list_private_sms
Retrieves a list of messages received in your dedicated SMS testing inbox.

### list_active_webhooks
Retrieves the list and current status of all configured webhook endpoints.

## Prompt Examples

**Prompt:** 
```
Check the inbox for test@privateteam.testinator.com and read the latest message.
```

**Response:** 
```
Inbox: test@privateteam.testinator.com. Messages: 5. Latest: Subject: 'Password Reset Confirmation'. From: noreply@app.com. Received: 2 min ago. Body: 'Hi Test, click the link below to reset your password: https://app.com/reset?token=abc123. This link expires in 30 minutes.' Headers: SPF ✅, DKIM ✅, Content-Type: text/html.
```

**Prompt:** 
```
Show all private domains and their inbox counts.
```

**Response:** 
```
Private domains: 3. 'privateteam.testinator.com' (12 inboxes, 45 messages). 'staging.myapp.io' (8 inboxes, 23 messages). 'qa.testing.dev' (5 inboxes, 18 messages). Total: 25 inboxes, 86 messages. Rules: 4 active forwarding rules. Oldest message: 7 days (auto-purge: 24h for free, 30d for team).
```

**Prompt:** 
```
Check SMS inbox and show webhook test results.
```

**Response:** 
```
SMS inbox: +1-555-0123. Messages: 3. Latest: 'Your verification code is 847293' (from: MYAPP, 5 min ago). '2FA code: 123456' (from: AUTHSVC, 1h ago). Webhooks received (24h): 8 total. POST /webhook/stripe (3, all 200 ✅). POST /webhook/twilio (5, 4x 200, 1x 500 ❌ payload error).
```

## Capabilities

### Read full message content
Calls `get_message_content` to retrieve the complete body, headers, and attachments of any test email.

### Inject simulated messages
Uses `inject_test_message` to simulate an incoming email into a specific disposable inbox for immediate testing.

### Monitor webhooks and payloads
Lists active webhook configurations and monitors incoming POST requests using `list_active_webhooks`.

### Manage private inboxes and domains
Allows you to list, check, or even delete messages across multiple dedicated test domains via `list_private_domains` and `remove_message`.

### Check usage metrics
Calls `get_usage_statistics` to track API consumption and monitor billing limits for your test environment.

## Use Cases

### Debugging a payment webhook failure
A developer suspects the Stripe webhook isn't firing correctly. Instead of manually checking logs, they prompt their agent: 'Check for webhooks from Stripe in the last hour.' The agent runs `list_active_webhooks` and identifies 3 recent POST requests. It then uses `get_message_content` to verify if a message was generated upon failure.

### Validating password reset emails
A QA engineer needs to confirm that the 'Forgot Password' flow works for multiple users. They use `list_private_domains` to select three distinct test accounts, then run `inject_test_message` against each one, confirming that all three receive a unique message payload.

### Checking SMS alerts from an app
The team needs to confirm 2FA codes are delivered correctly. They ask the agent to check `list_private_sms`. The agent pulls the latest messages, confirming the sender ID and checking if the message body matches the expected format.

### Auditing email forwarding rules
A DevOps team member needs to ensure that critical emails always go to a backup address. They run `list_routing_rules` to see all configured forwarders and use `get_domain_details` to verify the source domain's current status.

## Benefits

- **Validate complex email logic.** Use `inject_test_message` to simulate real-world triggers—like a password reset attempt or an order confirmation—and immediately check the results using `list_inbox_messages`.
- **See all data in one place.** Don't just read the body; use `get_message_content` to access crucial headers and attachments, letting your agent verify things like SPF/DKIM status automatically.
- **Manage multiple test accounts.** List domains with `list_private_domains` and switch between isolated environments (e.g., 'staging' vs. 'qa') without affecting production systems.
- **Debug real-time callbacks.** Monitor webhooks using `list_active_webhooks`. Your agent can confirm if a POST request hit the right endpoint, even if the payload failed.
- **Clean up your test data.** After testing is done, use `remove_message` to delete specific emails. This keeps your inboxes clean and prevents unnecessary message accumulation.

## How It Works

The bottom line is, you get a conversational interface for managing complex email infrastructure tasks without touching live data.

1. First, connect your AI client to the Mailinator MCP Server using a valid API token.
2. Next, prompt your agent with an action (e.g., 'Read the latest message in the QA inbox').
3. The server executes the tool call (`get_message_content`), and the result is passed back to your AI client for natural language review.

## Frequently Asked Questions

**How do I check if my webhook endpoints are working with Mailinator MCP Server?**
Use the `list_active_webhooks` tool. This shows all your configured webhooks and logs recent attempts, letting you confirm if data is hitting the right endpoint.

**Can I check SMS messages using the list_private_sms tool?**
Yes, `list_private_sms` lets you access dedicated phone number inboxes. This means you can test 2FA or verification code flows alongside regular email testing.

**What is the difference between list_inbox_messages and get_message_content?**
`list_inbox_messages` gives you a quick summary—it lists counts, subjects, and senders. You must use `get_message_content` to actually read the full body, headers, or attachments.

**How do I make sure my test emails don't interfere with real accounts?**
Mailinator uses disposable inboxes and private domains. You use `list_private_domains` to manage these segregated environments. Nothing you do here touches your production mail.

**How do I monitor my API usage and prevent hitting rate limits using `get_usage_statistics`?**
This tool reports your current consumption metrics. It gives you hard counts on request volume, letting you plan for high-volume testing sessions without hitting service limitations.

**If an email has attachments, how do I retrieve them using `list_message_attachments`?**
The tool returns metadata and direct download links for all attached files. It's crucial for QA when you need to verify file delivery or test specific MIME types.

**Before I start, how can I use `get_domain_details` to verify a domain's metadata?**
This function pulls core technical metadata about your private domains. You confirm if the domain is correctly provisioned and ready for simulated traffic before running full system tests.

**Once testing is done, how do I delete old test emails using `remove_message`?**
`remove_message` lets you target and permanently delete specific messages. This keeps your disposable inboxes clean and prevents data clutter after a long cycle of automated testing.

**Can I browse inboxes and read emails?**
Yes. Browse public and private inboxes, read full email content including HTML, headers, and attachments.

**How does Mailinator authentication work?**
Mailinator uses a custom **Token** header for authentication against `api.mailinator.com/api/v2`.

**Can I test SMS messages too?**
Yes. Access SMS inboxes and read SMS messages for phone number-based testing.