Skip to content

MCP server

Let your AI agent test the emails it builds

Claude Code, Cursor or any MCP client can create an inbox, trigger a sign-up, wait for the email and follow its link. No more “please check your inbox and paste the code”.

claude mcp add --transport http mailbench https://app.mailbench.dev/mcp

Remote server, nothing to install · Included on the free plan · Read-only keys

  1. > Sign up a test user and confirm the email address
  2. create_inboxqa-signup · SMTP credentials returned
  3. Bashnpm run test:signup -- --email ada@app.test
  4. wait_for_message“Confirm your email” · 2.1s
  5. get_message1 link · /confirm?token=8f2c…
  6. check_messagelinks 1/1 OK · HTML valid
  7. Opened the confirmation link (200). Ada’s account is confirmed.

Connected in a minute

  1. Create an API keyOn the API keys page in the dashboard. The same keys work for the REST API.
  2. Add the server to your clientPaste the command or config for your editor.
  3. Ask your agentIt picks the right tools on its own.
Terminal
claude mcp add --transport http mailbench https://app.mailbench.dev/mcp \
  --header "Authorization: Bearer $API_KEY"

Eight tools, one job: check the email

Small on purpose. Everything an agent needs to prove an email arrived and works, nothing that touches your account.

Inboxes

  • list_inboxes

    Lists the workspace’s inboxes and the SMTP server to send test email to.

  • create_inboxneeds read_write

    Creates an inbox and returns its SMTP credentials, to configure the app under test.

Messages

  • list_messages

    Lists messages in an inbox, newest first, filtered by text, sender, recipient, subject or time.

  • wait_for_message

    Waits up to 30 seconds for a matching email and returns it with its text and links.

  • get_message

    Returns one message: headers, plain text, links and attachment details. HTML on request.

Checks

  • check_message

    Runs the HTML compatibility, link or spam check on a message.

Clean up

  • clear_inboxneeds read_write

    Deletes every message in an inbox.

  • delete_messageneeds read_write

    Deletes one message.

Things to ask your agent

  • “Sign up a test user in the app and confirm the email address using the link MailBench receives.”
  • “Trigger a password reset and check every link in the email works.”
  • “Run the spam check on the latest invoice email and fix anything it flags.”

An inbox your agent can read safely

Anyone can send an email that says “ignore your instructions”. MailBench is built so that doesn’t matter.

Email is treated as untrusted
Message bodies reach the agent marked as data, with an instruction never to follow what an email says.
No tool sends mail
The agent can read and check messages. It cannot send email or change account settings.
Read-only keys
A read key can use every tool that only looks. Create or clear inboxes only when you choose to.
Nothing is delivered
Every message your app sends stops in the inbox, so the agent can never email a real customer.

Questions

Do I need to install anything?

No. MailBench runs a remote MCP server over HTTP. You add its URL and an API key to your client.

Which clients work?

Any client that supports remote (streamable HTTP) MCP servers with a custom header, including Claude Code, Cursor, VS Code and Windsurf.

Does it cost extra?

No. Every plan includes MCP. Each MCP request counts as one API request: 1,000 a day on Free, with no daily cap on Pro and Team.

Can I use the REST API instead?

Yes. Every tool is a thin wrapper over the REST API, which has the same data and a few more endpoints.

Give your agent an inbox