Mailcap

Every environment’s email, caught before it reaches anyone real.

Mailcap captures outbound mail from dev, staging, and beta into one searchable inbox — so your team stops guessing whether an email sent, and production never gets bothered by a test.

No credit card. Create a project and generate a key in under a minute. Using an AI coding agent? One-paste setup →

# the only line your app ever writes

import { sendEmail } from "@elevora-tech/mailcap";

await sendEmail({ from, to, subject, html });

Zero-branching SDK

One sendEmail() call, identical in dev, staging, and production. Env vars alone decide whether it's captured or delivered for real — no mode flag your code could ship the wrong way.

Real providers built in

Resend, SendGrid, and Mailgun adapters ship with the SDK. Switching providers — or switching from capture to real delivery — is a config change, not a code change.

Drop into existing code

Already calling a provider client directly at a dozen call sites? Wrap the client instead of rewriting them — wrapMailgunClient and friends keep the exact same call shape.

Search like Yopmail

Any recipient, any domain, one inbox. Find the email a tester says never arrived in seconds, not by grepping logs.

OTP & link extraction

Verification codes and links are pulled out and pinned to the top of every email — copy the code without reading the HTML.

Preview templates you can't see

Mailgun and SendGrid templates render server-side, so a capture tool has nothing to show. Register a local {{variable}} preview once and every future capture renders it — never a blank email.

Built for AI coding agents

An llms.txt integration reference, a copy-paste install prompt, and a native MCP server — your agent can wire up capture and check whether the OTP email arrived, without you writing a curl command.

How it works

  1. Step 1

    Create an environment

    One per developer, one per stage — local-dave, staging, production. Each gets its own key.

  2. Step 2

    Set two env vars

    MAILCAP_API_KEY and MAILCAP_URL. That's the entire integration.

  3. Step 3

    Search your inbox

    Every send lands here instead of a real recipient. Find it, read it, copy the code.