myagent.mxBLOG

apis & sending · best email api for rust

Best Email API for Rust: Six Options Compared (2026)

Comparing the best email API for Rust in 2026: Resend, Postmark, Mailgun, SES, SendGrid and Sendmux, with free tiers, logs, inbound and agent mailboxes.

16 min read~5,204 tokensMarkdown

Developer comparing email API options

The best email API for Rust is the one you can call over plain HTTP or SMTP from an async client, because every serious provider exposes both. For a conventional product that only sends transactional mail, Resend, Postmark and Amazon SES are the usual shortlist. If your Rust service is an agent that also needs to receive, read and thread replies, or you need one mailbox per tenant, Sendmux is the option built for that job. This guide compares six providers on the things a Rust developer actually hits: free tiers, logs, inbound, isolation and setup.

TL;DR

  • Rust does not need a dedicated SDK. Any provider with a REST API works through an HTTP client, and any provider with SMTP works through an SMTP crate such as lettre.
  • For pure transactional sending, Postmark, Resend and SES each win on a different axis: deliverability focus, developer experience and per-email cost.
  • Amazon SES has no built-in message logs, so you build event handling yourself. Mailgun and Resend keep logs for up to 30 days.
  • For agents that need real inboxes, scoped API keys, webhooks or SSE and per-tenant isolation, we built Sendmux. Free includes two mailboxes with fixed limits, and agent registration creates an @myagent.mx inbox with a durable read credential.
  • Whichever you pick, publish SPF, DKIM and DMARC records before the first send and keep keys out of source code.

Table of Contents

What “best for Rust” really means

Rust has no special email problem. What it has is a particular shape of project: a small, fast service (often Axum, Actix or a worker on Tokio) that you want to keep dependency-light, with typed errors and predictable retries. That shapes what matters in an email API.

  1. A clean HTTP or SMTP surface. If the provider offers a JSON REST API, you can call it with reqwest and serde, and model requests as plain structs. If it offers SMTP, lettre covers it. Community crates exist for some providers, but a thin wrapper over the REST API is often easier to audit and keep current.
  2. Observable failures. Rust encourages you to handle every error case. That is easier when the provider returns clear status codes, logs you can query and webhooks for bounces.
  3. Inbound handling. Many Rust services stop at sending. Agents, support tools and scheduling bots also need to receive, parse and thread replies.
  4. Isolation. If one service sends on behalf of many customers, you want scoped keys and per-tenant identities, not a single shared credential.

We cover the sending-side detail for another compiled language in our best email API for Go comparison, and the Rust-specific crates in our Rust email API guide. This article is the decision layer on top of both.

The six options at a glance

Prices below are US dollar list prices from the cited sources. Check each provider’s own pricing page before you commit, since plans change.

Provider Free tier Entry paid plan Logs Inbound Best fit
Resend 3,000/month, 100/day cap $20/month 30 days Not the focus Product teams who want clean DX
Postmark 100/month $15 Plan dependent Not the focus Transactional delivery and stream separation
Mailgun 100/day $15 Up to 30 days Yes, with parsing Teams needing inbound routing
Amazon SES Pay as you go Pay as you go None built in Possible, you build it High volume on AWS
SendGrid 60-day trial $19.95 30 days on paid plans Possible Dedicated IPs, subusers, marketing in one account
Sendmux Free: two mailboxes, fixed limits Pro: $7 per team each month plus usage Delivery logs Mailbox APIs and event notifications Agents, multi-tenant inboxes, BYO providers

The free tier and entry-price figures for Resend, Postmark, Mailgun, SendGrid and SES come from Email for Developers’ pricing breakdown. The Resend and Postmark free-tier numbers are repeated in a November 2026 pricing comparison. Note that SendGrid retired its permanent free tier in May 2025, so new accounts get a 60-day trial instead.

Resend: the developer-experience pick

Resend is positioned as an API-first option for product teams, with React Email support and a polished dashboard, according to Albato’s roundup. Its free tier allows 3,000 emails a month with a 100-a-day cap. Paid, it runs $20 a month for 50,000 emails and $35 for 100,000, with overage at $0.90 per 1,000, and logs last 30 days, per Dreamlit’s comparison.

Rust angle: a simple JSON API means a reqwest call with a bearer token is enough. The daily cap matters on the free plan: a burst of test sends can hit 100 quickly, so do not point a load test at it.

Pick it if you send product email such as sign-in links and receipts and want the least friction. Look elsewhere if your service must receive and thread replies.

Resend: the developer-experience pick

Postmark: the transactional specialist

Postmark focuses on transactional email and has no marketing-broadcast tooling, as GetFluxly’s comparison notes. The same source describes it as having the strongest deliverability reputation in its comparison group. It keeps transactional and marketing email on separate infrastructure, so a marketing batch does not slow down a password reset, according to Albato.

The developer plan includes 100 emails a month, and paid plans start at $15, per Email for Developers.

Rust angle: the same HTTP pattern applies. The tiny free tier is enough to prove your integration, not to run anything.

Pick it if password resets and receipts must arrive fast and you value stream separation.

Mailgun: inbound and logs

Mailgun provides searchable logs (up to 30 days), analytics, inbound parsing and validation. It also offers verification guidance and paid deliverability services, per SendOps. Log retention depends on the plan and caps at 30 days on the highest standard tiers. The permanent free plan allows 100 emails a day, with paid plans from $15 (Email for Developers).

Rust angle: inbound routes post parsed messages to your endpoint, so an Axum handler can accept them directly.

Pick it if you need conventional inbound routing alongside sending.

Amazon SES: lowest cost, most work

SES is pay as you go and is presented as the default pick for stacks already on AWS because of its low per-email cost at high volume (Albato). The trade-off is that it has no built-in message logs. You store events yourself and wire up event handling, and monitoring, warm-up and list hygiene are also left to you (SendOps).

Rust angle: if you already run on AWS, the official SDK route is natural, and you control everything. That control is also the cost: you own the bounce pipeline.

Pick it if you send at high volume and have engineering time to build the surrounding tooling. This is also where a routing layer helps: Sendmux includes managed Amazon SES and supports custom SMTP, Gmail and Outlook sending accounts.

SendGrid: broad, with caveats for new accounts

SendGrid suits teams that want dedicated IPs, subusers and marketing in one account (Dreamlit). Activity logs are retained for 30 days on paid plans, event webhooks retry for 24 hours after a failure, and stream separation needs manual configuration through IP pools or subusers (Grace Themes). New accounts get a 60-day trial, then paid plans start at $19.95 (Email for Developers).

Pick it if you need transactional and marketing mail under one roof and are comfortable configuring pools.

Sendmux: when the Rust service is an agent

The five providers above are, at heart, sending pipes. Sendmux is built around the mailbox. It is email API infrastructure for AI agents and platforms: mailboxes on @myagent.mx or a verified custom domain, HTTP mailbox APIs, SMTP submission, IMAP retrieval, JSON message responses and clean content endpoints, mailbox-scoped credentials, delivery logs with routing-group details, and live mailbox events by SSE or webhooks.

A few things set it apart for a Rust service:

  • HTTP-first, so Rust-friendly. Nothing requires a vendor crate. The same reqwest and serde approach works, and inbound mail arrives as structured JSON you can deserialise into a struct.
  • Bring your own providers. Outbound can use managed Amazon SES or your own Gmail, Outlook and custom SMTP accounts, with configurable weights, quotas and delivery groups. Details are on the sending product page.
  • Scoped keys. Each mailbox can have its own API key and permissions, which fits the minimal-scope advice below.
  • Plan and usage billing. Pro costs $7 per team each month plus usage. Outbound usage is billed per provider-accepted recipient occurrence, inbound usage per distinct mailbox delivery, and storage per decimal GB-month. Free includes two mailboxes and fixed limits. Rates are on the pricing page.

An agent that registers itself

The @myagent.mx domain exists so an agent can get an address without a human signing up. The sequence is:

  1. Read the discovery document at https://sendmux.ai/auth.md.
  2. Generate and save an idempotency key for the registration request.
  3. Register an anonymous agent identity to create a constrained @myagent.mx inbox with a durable read credential.
  4. Use the durable credential at /api/v1/mailbox/me to check the mailbox.
  5. Invite a named human owner.

Pre-claim tokens can receive, read, search and thread mail straight away, but not send. Sending requires the human owner to accept the invitation and explicitly approve sending. The durable read credential can then be exchanged for a one-hour Sending-resource token. For a Rust agent, that is a useful guardrail: the person whose name the mail goes out under stays in control of what leaves. Mailboxes can use the shared @myagent.mx domain or a verified custom domain.

Inbound, threading and webhooks

Most comparison pages skip this, yet it is where the options split most sharply. Postmark and Resend centre on outbound. Mailgun adds inbound parsing. SES leaves it to you. In Sendmux inbound is a first-class feature: mailbox HTTP APIs expose messages and threads, the unified team Inbox supports search across team mailboxes, and SSE or webhooks notify your Rust service about mailbox events.

Inbound email capabilities across five providers

Whichever provider delivers events, treat webhook handling as a reliability problem. Verify signatures, respond quickly and make handlers idempotent so a retry never double-processes a bounce. This write-up on webhooks and idempotency covers the pattern well, and it translates directly to an Axum handler that records event IDs before acting.

Logs and bounces: what you can see

When something goes missing, logs decide how long you spend debugging. Resend and Mailgun keep logs for up to 30 days, SendGrid for 30 days on paid plans, and SES keeps none for you. Hard bounces and complaints also need handling: one transactional relay documents that a hard bounce or spam complaint suppresses an address globally and immediately, and that a later send returns a success status with a suppressed reason rather than an error (PushWard docs). Whatever you choose, read how it reports suppression, because your Rust error handling must distinguish “accepted” from “delivered”.

Sendmux delivery logs expose applied routing-group details, and webhooks report delivery, rejection, bounce, complaint and received-mail events. Our delivery logs guide explains what to record.

List quality matters as much as the provider. Bounces count against your domain before content is evaluated, so validating addresses at signup keeps invalid, disposable and catch-all addresses out in the first place (Abstract API).

Setup checklist before you send from Rust

The setup is the same whichever API you choose.

  1. Publish SPF, DKIM and DMARC before the first send (Instantly’s integration guide). Our SPF, DKIM and DMARC setup guide walks through the records.
  2. Verify DNS propagation before production traffic, and use dedicated API keys with minimal scopes (Instantly).
  3. Keep keys out of source code. Load them from the environment or a secrets manager, use send-only permissions where possible, follow a rotation cadence and rotate straight away after suspected exposure (Volanea).
  4. Separate transactional from promotional mail. Our guide on transactional vs marketing email explains why, and the transactional email API integration guide covers the code side.

In Rust, a few habits pay off: wrap the provider in a trait so you can swap it, give your HTTP client sane timeouts, retry only idempotent calls and log the provider’s message ID with every send.

Which one should you choose?

Your situation Start with
Sign-in links and receipts, minimal fuss Resend
Password resets where speed and reputation come first Postmark
Sending plus inbound routing, conventional setup Mailgun
Very high volume on AWS, with engineers to spare Amazon SES
Transactional and marketing in one account SendGrid
An agent that sends, receives and threads mail Sendmux
Many tenants, each needing its own isolated mailbox and key Sendmux
Outbound spread across providers with weights, quotas and delivery groups Sendmux

Our perspective

Most email APIs were designed for one job: push a message out and report what happened. That is the right design for a receipt. It is the wrong one for an agent, because an agent has to receive the answer, remember the thread and act for someone.

That is why we built Sendmux around the mailbox rather than the send call. Each agent can have an inbox and scoped credential. Outbound supports managed Amazon SES or your own Gmail, Outlook and custom SMTP accounts, with configurable weights, quotas and delivery groups.

We also think sending should stay in human hands until a person says otherwise. That is the reason a self-registered agent gets a durable read credential, while delegated sending requires owner acceptance and explicit approval. For a Rust developer who values explicit permissions, we think that is the honest default.

Give your Rust agent an address

If your service needs to receive mail as well as send it, an agent can register an @myagent.mx inbox without a human signup form or an existing API key. Start at myagent.mx, or read about agent inboxes and the full product if you plan to provision mailboxes per customer.

FAQ

Is there an official email SDK for Rust?

Most providers do not ship an official Rust SDK, and you do not need one. Their REST APIs work with reqwest and serde, and SMTP works through an SMTP crate such as lettre. Community crates exist for some providers, so check how recently one was updated before depending on it.

Which email API has the best free tier for a Rust side project?

Resend gives 3,000 emails a month with a 100-a-day cap, and Mailgun’s free plan allows 100 a day (Email for Developers). Postmark’s developer plan is 100 a month, which suits integration testing. If your project is an agent that needs an inbox, Sendmux Free includes two mailboxes with fixed limits, and an agent can register an @myagent.mx inbox with a durable read credential.

Can I receive email in a Rust service, not just send it?

Yes. Mailgun offers inbound parsing. Sendmux provides JSON mailbox HTTP APIs for messages and threads, search across the unified team Inbox, and live mailbox event notifications through SSE or webhooks. SES can receive too, but you build the handling yourself. Your Rust service needs an HTTP client for mailbox requests and an endpoint or streaming client for event notifications.

How do I keep API keys safe in a Rust project?

Load keys from environment variables or a secrets manager, never from source. Use send-only or mailbox-scoped keys where the provider allows it, rotate on a schedule, and rotate immediately if you suspect exposure (Volanea).

Sources

Give an agent its own address

Sendmux is the Email Inbox API for AI Agents.

Explore Sendmux