MailGate
v1.1.1Self-hosted Cloudflare Workers OTP and magic-link email inbox MCP server for E2E auth testing.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
mailgate_health
Check whether the configured MailGate Worker is reachable and healthy.
mailgate_wait_for_otp
Poll a MailGate inbox until a verification/OTP code arrives. Pass `since` (ISO timestamp) to ignore stale OTPs from earlier tests.
| Parameter | Type | Description |
|---|---|---|
email * | string | Recipient inbox address (e.g. qa-login@example.com). |
password | string | Optional inbox password if the inbox is locked. |
pollIntervalMs | number | Polling interval in milliseconds (default: 1500). |
sender | string | Optional substring filter on sender address (e.g. github.com). |
since | string | ISO 8601 timestamp; only consider emails received at or after this time. |
timeoutMs | number | Maximum wait time in milliseconds (default: 30000). |
mailgate_wait_for_email
Poll a MailGate inbox until a matching email arrives and return its subject, text body, OTP code, and extracted magic/verification link.
| Parameter | Type | Description |
|---|---|---|
email * | string | Recipient inbox address. |
password | string | Optional inbox password if locked. |
pollIntervalMs | number | Polling interval in milliseconds (default: 1500). |
sender | string | Optional sender address substring filter. |
since | string | ISO 8601 timestamp filter. |
subjectIncludes | string | Optional case-insensitive subject substring filter. |
timeoutMs | number | Maximum wait time in milliseconds (default: 30000). |
mailgate_list_messages
List recent messages stored in a MailGate inbox.
| Parameter | Type | Description |
|---|---|---|
email * | string | Recipient inbox address. |
limit | number | Max number of messages to return (1-100, default: 20). |
password | string | Optional inbox password if locked. |
sender | string | Optional sender address substring filter. |
since | string | Optional ISO 8601 timestamp filter. |
mailgate_create_inbox
Allowlist a new inbox address on MailGate (requires MAILGATE_ADMIN_TOKEN).
| Parameter | Type | Description |
|---|---|---|
email_address * | string | Email address to allowlist. |
label | string | Optional descriptive label. |
password | string | Optional password (>= 4 chars) to lock the inbox. |
mailgate_clear_messages
Delete all stored messages for an inbox before starting a fresh test run (requires MAILGATE_ADMIN_TOKEN).
| Parameter | Type | Description |
|---|---|---|
email * | string | Recipient inbox address to purge. |
mailgate_simulate_email
Inject a simulated RFC822 message through the live MIME parser and OTP extractor (requires MAILGATE_ADMIN_TOKEN and ALLOW_SIMULATE=true).
| Parameter | Type | Description |
|---|---|---|
to * | string | Allowlisted recipient inbox address. |
body_text | string | Optional plain-text body. |
from | string | Optional sender address. |
from_name | string | Optional sender display name. |
subject | string | Optional email subject (defaults to random OTP). |