MailAtlas

Email tools for AI agents

MailAtlas makes email accessible to AI agents.

It turns complex email into clean, agent-readable data. Connect your mailbox, import archives, export HTML, PDF, or Markdown, and let MailAtlas keep track of embedded images, attachments, metadata, and provenance.

python -m pip install mailatlas

Why MailAtlas

Current email interfaces serve humans, not agents.

Email looks great in an inbox because it was designed for people. Give the same message to an agent as raw source or provider API output and it has to deal with MIME structure, rendered HTML, attachments, thread context, and provider-specific metadata.

Agents need structured, clean email access that does not pollute their context window. MailAtlas gives them an interface for reading email in the cleanest possible way, while preserving body content, HTML, attachments, embedded images, metadata, provenance, and the overall structure of each message.

Use MailAtlas when you need to

  • Turn complex email into clean text, HTML, Markdown, PDF, and structured metadata.
  • Track embedded images, attachments, source messages, and provenance together.
  • Import email from mailboxes, .eml files, or mbox archives.
  • Create a copy of the inbox and outbox your agent can query and send from.

How it works

Clean email data in a workspace your agent can query.

  1. 01

    An email workspace for every agent

    Use the same workspace from the CLI, Python code, or MCP tools, depending on how your agent works.

  2. 02

    Bring email in

    Import from .eml files, mbox archives, Gmail, or selected IMAP folders. Use whichever source matches where your email already lives.

  3. 03

    Clean and export the email

    MailAtlas gives agents clean body text, HTML, Markdown, PDF, JSON, attachments, embedded images, metadata, and links back to the original message.

  4. 04

    Send through your provider

    When your agent needs to reply or follow up, MailAtlas sends through SMTP, Cloudflare Email Service, or Gmail API OAuth.

Sources and outputs

Bring email in. Give agents clean data back.

Connect a live mailbox and keep the agent's email workspace current with watch mode. You can also import archived email, export clean documents, and send through your existing provider from the same workspace.

Email workspace

Everything your agent needs to read and work with email.

MailAtlas stores clean email outputs as ordinary files and uses SQLite for lookup, dedupe, exports, provenance, mailbox sync state, and message records.

Inbound Original raw email bytes, cleaned body text, normalized HTML snapshots, and metadata. raw/ html/ store.db
Assets Extracted inline images and regular file attachments associated with a document. assets
Exports JSON, Markdown, HTML, and PDF artifacts written from stored documents. exports/
Mailbox sync IMAP sync cursors for manual selected-folder sync. store.db
Outbound Outbound .eml snapshots, body files, copied attachments, recipient metadata, provider status, error details, and retry metadata. outbound/ store.db

MailAtlas receives from Gmail API or IMAP, including IMAP password or OAuth-token auth. For outbound email, it sends through SMTP, Cloudflare Email Service, or Gmail API OAuth.

Next steps

Pick the first email workflow your agent needs.