add_labels
Add one or more mailbox labels to an email without removing its existing mailbox assignments.
Read, search, send and file Fastmail mail from an assistant, with the calendar and address book on the same connection.
LABSCO SUMMARY
The design detail worth noticing is the anti-search tooling: unread mail, latest mail, mailbox statistics and an account summary each have their own tool, so "what needs attention" does not become a search query returning a wall of messages. Bulk operations and label add/remove that preserve other mailbox assignments make inbox cleanup safe to hand over, and one-click unsubscribe is deliberately narrow — HTTPS only, and only where the message advertises support for it.
A Fastmail server over JMAP. It covers mail, mailboxes, calendars and contacts in one account, with separate tools for the common questions so you are not writing search filters for everything.
A Fastmail account on the Standard or Professional plan and an API token with JMAP access. Create it under Settings → Privacy & Security → Manage API tokens and grant Mail, Calendars and Contacts read and write, then pass it as FASTMAIL_API_TOKEN. Node.js 18 or later; run it with npx @jordonh19/fastmail-mcp-server over stdio, from the npm package @jordonh19/fastmail-mcp-server, currently 1.3.0. Adding --transport http --port 3000 serves a single /mcp endpoint over Streamable HTTP plus a browser dashboard, whose one-time access token is printed to the console at startup. The summarize and reply-drafting tools need an MCP client that supports sampling.
One command plus a key — npx @jordonh19/fastmail-mcp-server, then supply credentials
USE CASES
Pull the account summary and the unread mail rather than searching, then open the threads that matter.
Search the sender, check the headers advertise it, and send the one-click unsubscribe before archiving the rest in bulk.
Read the thread, then reply — In-Reply-To and References are set for you and the recipients worked out.
List the attachments first for names, types and blob IDs, then download the one you want.
List the mailboxes for their IDs, then move or relabel many messages in one call.
Read the message, list the calendars, and create the event on the right one.
Run the capability check — it reports which Fastmail feature groups and client capabilities are available.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
add_labelsAdd one or more mailbox labels to an email without removing its existing mailbox assignments.
archive_emailMove one or more emails to the Archive mailbox. A convenient one-step operation for archiving emails you've dealt with.
bulk_add_labelsAdd one or more mailbox labels to multiple emails at once while preserving their other mailbox assignments.
bulk_email_actionPerform an action on multiple emails at once. Supports marking as read/unread, flagging/unflagging, moving, and deleting.
bulk_remove_labelsRemove one or more mailbox labels from multiple emails at once while preserving any other mailbox assignments.
check_function_availabilityCheck which major Fastmail feature groups are available for this account and MCP client, including setup guidance for missing mail, submission, contacts, calendars, or sampling support.
create_calendar_eventCreate a new calendar event. Use list_calendars first to get calendar IDs.
create_contactCreate a new contact in the Fastmail address book
create_draftSave an email as a draft without sending. The draft can be edited or sent later using send_draft.
create_mailboxCreate a new mailbox (folder) in the Fastmail account
delete_calendar_eventDelete a calendar event by its ID
delete_contactDelete a contact by their ID
delete_emailDelete an email. By default moves to Trash. Set permanent=true to permanently destroy the email.
delete_mailboxDelete a mailbox (folder). The mailbox must be empty or you must set force=true to delete with all contents. System mailboxes (Inbox, Trash, etc.) cannot be deleted.
download_attachmentDownload an email attachment by its blob ID. Use get_email first to find attachment blob IDs. Returns text content directly for text files, or base64-encoded data for binary files. Maximum attachment size is 10 MB.
forward_emailForward an existing email to new recipients with an optional message
get_account_summaryGet a compact account-level summary with unique email totals, unread counts, mailbox counts, and top mailboxes. Prefer this over large list calls when you only need an overview.
get_calendar_eventGet the full details of a specific calendar event by its ID
get_calendar_eventsGet calendar events within a date range. Optionally filter by calendar ID or search text.
get_contactGet full details of a specific contact by their ID
get_emailGet the full content of a specific email by its ID, including headers, body text, and attachment info
get_email_attachmentsList the attachments on a specific email without returning the full email body. Use this when you only need filenames, types, sizes, and blob IDs before calling download_attachment.
get_email_headersGet selected raw email headers for a message without returning the full body. Defaults to unsubscribe, reply routing, return path, and authentication headers.
get_identitiesList all sender identities (email addresses) available for sending emails
get_latest_emailsGet the most recent emails sorted by date. Best for quickly checking recent activity without specific search criteria. Do not use search_emails for this purpose.
get_mailbox_emailsList emails in a specific mailbox with pagination support. Use this when browsing a folder's contents page by page. Use list_mailboxes first to find available mailbox IDs.
get_mailbox_statsGet compact mailbox statistics such as email counts, unread counts, and thread counts. Use this when you need an overview instead of listing mailbox contents.
get_threadGet all emails in a conversation thread, showing the full discussion chronologically
get_unread_emailsRetrieve unread emails, optionally filtered by mailbox. Best for checking what needs attention. Do not use search_emails for this purpose.
list_address_booksList all address books (contact groups) in the Fastmail account
list_calendarsList all calendars in the Fastmail account with their names, colors, and visibility status
list_mailboxesList all mailboxes (folders) in the Fastmail account with their roles, email counts, and IDs
mark_mailbox_readMark all emails in a specific mailbox as read. Useful for clearing unread counts on a mailbox. Processes up to 500 unread emails at a time.
move_emailMove an email to a different mailbox (folder). Use list_mailboxes to find mailbox IDs.
one_click_unsubscribeUnsubscribe from a message using one-click unsubscribe headers. Only posts to safe HTTPS List-Unsubscribe URLs when List-Unsubscribe-Post advertises one-click unsubscribe.
remove_labelsRemove one or more mailbox labels from an email while preserving any other mailbox assignments.
rename_mailboxRename an existing mailbox (folder). Use list_mailboxes to find the mailbox ID.
reply_emailReply to an existing email. Automatically sets threading headers (In-Reply-To, References) and determines recipients.
search_contactsSearch contacts by name, email, or other criteria. Returns a summary list of matching contacts.
search_emailsSearch for emails using filters like sender, recipient, subject, date range, or full-text query. Use this tool when you need to find specific emails matching particular criteria. For simply checking recent emails, use get_latest_emails instead. For unread emails only, use get_unread_emails instead.
send_draftSend a previously saved draft email. The draft must already exist in the Drafts mailbox.
send_emailCompose and send a new email. Use get_identities first to find available sender identities.
suggest_replyUse the connected LLM to draft a reply to an email based on the provided intent or instructions. Requires the MCP client to support sampling.
summarize_emailUse the connected LLM to produce a concise summary of an email's subject, sender, and body. Requires the MCP client to support sampling.
update_calendar_eventUpdate an existing calendar event. Only specified fields will be changed.
update_contactUpdate an existing contact's information. Only the fields you provide will be updated; other fields remain unchanged.
update_email_flagsUpdate email flags (read/unread status, flagged/unflagged status)
BEFORE YOU INSTALL
47 tools when we connected. suggest_reply and summarize_email are available but undocumented. Grant the token Mail, Calendars and Contacts read-write; a Mail-only token leaves calendar and contact tools failing.
CONTEXT COST
Rated by the size of the 47 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
npx @jordonh19/fastmail-mcp-server{
"mcpServers": {
"fastmail": {
"command": "npx",
"args": [
"@jordonh19/fastmail-mcp-server"
],
"env": {
"FASTMAIL_API_TOKEN": "<YOUR_FASTMAIL_API_TOKEN>"
}
}
}
}export FASTMAIL_API_TOKEN="<YOUR_FASTMAIL_API_TOKEN>"
claude mcp add fastmail -- npx @jordonh19/fastmail-mcp-serverThe server reads FASTMAIL_API_TOKEN from the environment Claude Code runs in, so start claude from a shell where it is set.
{
"servers": {
"fastmail": {
"command": "npx",
"args": [
"@jordonh19/fastmail-mcp-server"
],
"env": {
"FASTMAIL_API_TOKEN": "<YOUR_FASTMAIL_API_TOKEN>"
}
}
}
}FASTMAIL_API_TOKEN="<YOUR_FASTMAIL_API_TOKEN>" npx @jordonh19/fastmail-mcp-server