Skip to main content
Glama
Fastmail MCP Server

Fastmail MCP Server

by mattmaas

Fastmail MCP Server

An MCP server that exposes Fastmail email via JMAP: email actions (list, get, send, draft) and masked-email alias management (create, update, delete). Drafts are written first by default unless you set FASTMAIL_DRAFT_BY_DEFAULT=false.

Requirements

  • Node.js 20+

  • A Fastmail account with an API token

Related MCP server: multi-mail-mcp

Install

git clone https://github.com/mattmaas/fastmail-mcp.git
cd fastmail-mcp
npm install
npm run build     # compiles TypeScript to dist/
npm start         # node dist/server.js

Environment Variables

Variable

Required

Description

FASTMAIL_API_TOKEN

yes

Fastmail API token

FASTMAIL_ACCOUNT_ID

no

Account ID; auto-detected when omitted

FASTMAIL_DRAFT_BY_DEFAULT

no

Set to false to send right away instead of saving drafts

FASTMAIL_SIGNATURE_NAME

no

Name shown in the optional signature

FASTMAIL_FOOTER_HTML

no

Optional HTML footer added to sent mail

MCP Client Configuration

Add this server to your MCP client's config:

{
  "mcpServers": {
    "fastmail": {
      "command": "node",
      "args": ["<path>/fastmail-mcp/dist/server.js"],
      "env": {
        "FASTMAIL_API_TOKEN": "your-api-token"
      }
    }
  }
}

Tools

Tool

Description

fastmail_get_account

Account information and session details

fastmail_list_emails

List inbox or folder messages (filter by folder, unread, search)

fastmail_get_email

Get one message with a bounded plain-text body

fastmail_send_email

Send or save-as-draft a message

fastmail_list_masked_emails

List masked email aliases

fastmail_create_masked_email

Create a masked email alias

fastmail_update_masked_email

Enable, disable, or rename an alias

fastmail_delete_masked_email

Delete an alias

fastmail_mark_email_read

Mark a message read/unread

fastmail_mark_email_flagged

Flag/unflag a message

fastmail_list_folders

List mail folders

fastmail_get_unread_count

Unread count for a folder

Usage

Ask your agent, for example:

  • "Show my unread inbox" → fastmail_list_emails(unreadOnly=true)

  • "Draft a reply to the latest message from Alice" → fastmail_list_emails(search="Alice") then fastmail_send_email(saveDraft=true, ...)

  • "Make a masked alias for this newsletter" → fastmail_create_masked_email(...)

License

MIT

Available Tools

12 tools
fastmail_create_masked_emailB

Create a new masked email address for privacy protection.

Inputs: email (required), description (required), forDomain.

fastmail_delete_masked_emailB

Delete a masked email address.

Inputs: emailId (required).

fastmail_get_accountB

Get Fastmail account information and session details.

Inputs: no named parameters.

fastmail_get_emailA

Get detailed information about a specific email by its ID.

Inputs: emailId (required).

fastmail_get_unread_countA

Get unread email count for inbox or a specific folder.

Inputs: folder.

fastmail_list_emailsA

List emails from your inbox or other folders. Supports filtering by folder, read status, and search.

Inputs: limit, folder, search, unreadOnly.

fastmail_list_foldersA

List all email folders.

Inputs: no named parameters.

fastmail_list_masked_emailsB

List all masked email addresses (privacy-focused aliases).

Inputs: no named parameters.

fastmail_mark_email_flaggedA

Flag or unflag an email (star).

Inputs: emailId (required), flagged.

fastmail_mark_email_readA

Mark an email as read or unread.

Inputs: emailId (required), read.

fastmail_send_emailA

Compose and send (or save as draft) an email from the account's own Fastmail identity.

IMPORTANT — DEFAULT TO DRAFT: unless the context clearly implies the email should go out immediately (explicit instruction, routine automated alert, or an established-contact follow-up), save it as a draft so a human can review before it sends. Omit saveDraft to use the configured default (draft-first unless FASTMAIL_DRAFT_BY_DEFAULT=false).

Send as the account owner. Never add AI/agent signatures or self-identification; any machine-authorship marker is configured server-side via FASTMAIL_FOOTER_HTML.

Inputs: to (required), subject (required), cc, bcc, +4 more.

fastmail_update_masked_emailA

Update a masked email (enable, disable, or change description).

Inputs: state (required), emailId (required), description.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 12 tools

    Disambiguation5/5

    Each tool targets a distinct resource and action: account info, email listing/detail/sending, masked email CRUD, read/flag state, folders, and unread count. There is no meaningful overlap that would cause an agent to select the wrong tool.

    Naming Consistency5/5

    All tool names follow a consistent snake_case pattern with the fastmail_ prefix and verb_noun structure (get, list, send, create, update, delete, mark). The naming is predictable and makes the toolset easy to navigate.

    Tool Count5/5

    With 12 tools, the server is well-scoped for its domain: email operations, masked email management, folders, and account info. Each tool has a clear purpose, and the count is neither bloated nor too thin.

    Completeness3/5

    Masked emails have full CRUD coverage and core email reading/sending/flagging is supported. However, notable gaps exist in the email lifecycle: there is no delete, move/archive, or folder mutation capability, so agents cannot perform common cleanup or organization workflows.

    Maintenance

    ActivityStale
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables email management via IMAP and SMTP with multi-account support, safe sending with confirmation, and read-only modes.
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables an MCP client to read, draft, organize, send, and delete email across multiple Gmail and Exchange Online/Outlook.com accounts, with per-account capability policies, recipient allowlists, confirmations, minimum OAuth scopes, and local audit logging.
      MIT