Back to Blog
📥
/6 min read/By SMTPfast Team

Inbound Email Parsing APIs Compared: How to Receive Email in Your App (2026)

An inbound email API takes mail sent to an address on your domain, parses it into JSON (sender, subject, text, HTML, attachments) and calls your webhook. Postmark, SendGrid Inbound Parse, Mailgun Routes, CloudMailin, Resend and SMTPfast all do this; they differ in payload format, size limits, which plans include it, and whether they keep a copy. Checked on 21 November 2026.

inboundreceivingwebhookscomparisonemail-api
Share:𝕏in

The short answer: an inbound email API receives mail for an address on your domain, parses it into JSON (sender, recipients, subject, text and HTML bodies, attachments) and calls your webhook. The main options are Postmark Inbound, SendGrid Inbound Parse, Mailgun Routes, CloudMailin, Resend and SMTPfast. Amazon SES can receive too, but you parse the raw MIME yourself.

They differ in four ways that matter: the payload format, the size limit, which plans include receiving, and whether the provider keeps a copy you can fetch later. We build SMTPfast; details for the others come from their own docs and pricing pages, checked on 21 November 2026.

How do the inbound email APIs compare?

Service How mail arrives What your webhook gets Size limit Plans
SMTPfast MX on your domain or a subdomain email.received event with metadata; full JSON (text, HTML, headers, attachment links, auth verdicts) from the API 25 MB message, 25 attachments Paid plans, from $9 a month
Postmark Forward to your server's inbound address, or MX with inbound domain forwarding JSON with bodies, base64 attachments and StrippedTextReply 35 MB of attachments Not on Basic; in Pro and Platform
SendGrid Inbound Parse MX to mx.sendgrid.net multipart/form-data, or the raw MIME message 30 MB Listed as a feature; the pricing page does not show which plans
Mailgun Routes MX to Mailgun, then rules that match recipients Forward to your URL or store the message Not on the pages we checked 1 route on Free, 5 on Basic, full routing from Foundation
CloudMailin A CloudMailin address, or MX on your domain HTTP POST to your URL 512 KB (free), 2 MB (Starter) Free 10,000 a month; Starter $25 for 10,000
Resend MX on your domain Webhook, then read the email and attachments through the API Not on the pages we checked Every plan; received email counts toward the sending quota
Amazon SES MX to SES, receipt rules Raw message to S3 or SNS (a Lambda action gets the headers, not the body); you parse it Set by SES $0.10 per 1,000 emails, plus charges per 256 KB chunk

What to look for

Payload or fetch. Postmark and SendGrid put the whole message in the webhook request. That is simple, but a 20 MB attachment is now a 20 MB POST to your app. If your endpoint is down, SendGrid's copy lives only in its retry queue; Postmark keeps inbound message details for its data retention period (45 days by default) and has a Messages API to read them. SMTPfast and Resend send a small event and keep the message, so you fetch the body and attachments when you are ready, and you can fetch them again later. SMTPfast keeps received mail for 30 days.

Authentication results. A parsed email from [email protected] is not proof it came from your CEO. SMTPfast includes SPF, DKIM, DMARC, spam and virus verdicts on every received email, and quarantines a message whose virus scan fails (no body, raw file or attachments are returned). Check these before you let an inbound email trigger anything.

Replies and threads. For support tools you want the reply without the quoted history. Postmark's StrippedTextReply does this for replies. SMTPfast gives you in_reply_to and references for threading and can reply in the same thread (POST /v1/emails/receiving/:id/reply), or keep a whole mailbox with threads and drafts in Inboxes.

Your MX records. Use a subdomain such as inbound.yourdomain.com, so your root domain keeps its normal mailbox provider. SMTPfast reports a competing MX at the same or lower priority, because it would take a share of the mail.

Receive email with SMTPfast: the whole flow

  1. Verify the domain for sending (or use a subdomain of a verified domain), then turn on receiving:
curl -X PATCH https://smtpfa.st/api/v1/domains/dom_xyz789 \
  -H "Authorization: Bearer $SMTPFAST_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"receiving_enabled": true}'
  1. Publish the MX record from the response (priority 10). The status becomes active within a minute of the record resolving, and every address at the domain receives.

  2. Subscribe a webhook to email.received, and handle it:

// Next.js Route Handler: app/api/inbound/route.ts
import { parseWebhook } from "@smtpfast/sdk";

export async function POST(request: Request) {
  const event = await parseWebhook({
    payload: await request.text(), // the raw body, for the signature check
    headers: request.headers,
    secret: process.env.SMTPFAST_WEBHOOK_SECRET!,
  });
  if (event.type !== "email.received") return new Response(null, { status: 204 });

  // The event has metadata only; fetch the parsed email for the body.
  const res = await fetch(`https://smtpfa.st/api/v1/emails/receiving/${event.data.id}`, {
    headers: { Authorization: `Bearer ${process.env.SMTPFAST_API_KEY}` },
  });
  // A non-2xx answer makes SMTPfast retry the webhook later.
  if (!res.ok) return new Response("fetch failed", { status: 502 });
  const email = await res.json();

  if (email.verdicts?.dkim === "PASS" && email.verdicts?.spam === "PASS") {
    // create a ticket from email.from, email.subject, email.text
    // (store it before you answer 2xx, so a crash here is retried)
  }
  return new Response(null, { status: 204 });
}

The parsed email looks like this (shortened):

{
  "object": "email",
  "id": "rcv_01j9x2m8k4",
  "from": "Ada Lovelace <[email protected]>",
  "to": ["[email protected]"],
  "subject": "Order #4821",
  "text": "Hi, the invoice is attached.",
  "html": "<p>Hi, the invoice is attached.</p>",
  "attachments": [
    { "id": "att_7f3a9c1b2d", "filename": "invoice.pdf", "content_type": "application/pdf", "size": 48213 }
  ],
  "verdicts": { "spf": "PASS", "dkim": "PASS", "dmarc": "PASS", "spam": "PASS", "virus": "PASS" },
  "in_reply_to": null,
  "raw": { "download_url": "https://...", "expires_at": "2026-09-02T10:15:00.000Z" }
}

Attachment and raw-file links are minted per request and live for 15 minutes. AI agents can do the same through the MCP server (list_received_emails, get_received_email, reply_to_received_email). The receiving API follows Resend's endpoints and object shapes, so code written for Resend receiving needs the base URL, a key with the inbound scopes and SMTPfast's signature check. Every endpoint is in the inbound docs.

Which one should I pick?

  • Support inbox or reply-by-email, and you want the reply text without quotes: Postmark.
  • You want the raw MIME and full control, and you run AWS: Amazon SES receipt rules.
  • Small messages, many of them, free: CloudMailin's free plan, if 512 KB per message is enough.
  • Receiving and sending on one domain, JSON you can fetch again, and auth verdicts on every message: SMTPfast.

Sources

Checked on 21 November 2026:

Frequently asked questions

What is a good inbound email parsing API for receiving email in my app?

Postmark Inbound (JSON with the body, attachments and a stripped reply), SendGrid Inbound Parse (multipart form data, 30 MB limit), Mailgun Routes, CloudMailin (10,000 free emails a month at 512 KB each), Resend (receiving on every plan) and SMTPfast (JSON API with SPF, DKIM, DMARC, spam and virus verdicts, stored 30 days, on paid plans from $9). Amazon SES receiving is the cheapest but leaves MIME parsing to you.

How does inbound email parsing work?

You point an MX record for a domain or subdomain (for example inbound.yourdomain.com) at the provider. When mail arrives, the provider accepts it, parses the MIME message into fields and attachments, and sends an HTTP POST to your webhook URL. Your app then reads the sender, subject, body and files from that request or from the provider's API.

Should I receive inbound email on my root domain?

Usually not. Use a subdomain such as inbound.yourdomain.com or reply.yourdomain.com, so the MX records of your root domain keep pointing at your normal mailbox provider (Google Workspace, Microsoft 365). Only one set of MX records can win for a name.

How do I make sure an inbound webhook really came from the provider?

Check the signature. SMTPfast signs each webhook with an HMAC-SHA256 of the raw body in the X-SMTPfast-Signature header, and its SDKs verify it for you. Some providers use basic auth in the webhook URL or IP allowlists instead. Always verify before you act on the content, because anyone can POST to a public URL.

Ready to get started?

Start sending transactional email today. Free to start, no credit card required.

Get Started for Free