Skip to main content
Glama
ni-c

imap-mcp

by ni-c

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
IMAP_TLSNoTLS mode: implicit, starttls, or noneimplicit
IMAP_HOSTYesHostname of the IMAP server, e.g. imap.example.net
IMAP_PORTNoPort of the IMAP server; defaults by TLS mode (993 for implicit TLS, 143 for STARTTLS/none)
IMAP_USERYesAccount username, usually the address
IMAP_MAILBOXNoMailbox the message tools default toINBOX
IMAP_PASSWORDYesPassword or app-specific password
IMAP_READ_ONLYNoExactly 'false' registers the five mailbox tools; default is truetrue
IMAP_DENY_TOOLSNoComma-separated tool names or prefixes to subtract from the allow list
IMAP_ALLOW_TOOLSNoComma-separated tool names, list_* prefixes, or 'essential'
IMAP_DOWNLOAD_DIRNoSetting it allows saving attachments to this directory
IMAP_INSECURE_TLSNoExactly 'true' accepts a self-signed certificatefalse
IMAP_MAX_MESSAGESNoDefault page size for listing messages100
IMAP_SEEN_KEYWORDNoKeyword for new-mail tracking; empty turns it offAiSeen
IMAP_DRAFTS_MAILBOXNoOverrides the folder found via the \Drafts flag
IMAP_ATTACHMENT_TYPESNoComma-separated content-type allowlist for attachments
IMAP_MAX_DOWNLOAD_BYTESNoCeiling for writing one attachment to disk26214400
IMAP_TRUSTED_AUTHSERV_IDNoThe authserv-id your provider stamps on Authentication-Results headers
IMAP_MAX_ATTACHMENT_BYTESNoCeiling for returning an attachment inline1048576

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}
resources
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
get_server_infoA

Reports what this account and server can do: the configured mailbox, IMAP capabilities, which flags the mailbox stores permanently, whether the new-mail keyword can be used, and which tool groups are enabled. Start here when a call fails for reasons that sound like configuration.

list_mailboxesA

Lists every folder in the account with its message and unseen counts, its special-use role (drafts, sent, trash, junk) and whether it can hold messages. Use the returned "path" verbatim wherever a tool takes a mailbox.

list_messagesA

Lists messages newest first, optionally narrowed by sender, recipient, subject, body text, date range or flags. With no criteria it simply pages through the mailbox. Every filter is applied by the mail server, so searching a large folder is cheap. Returns summaries only — use get_message for the body.

list_new_messagesA

Returns messages this server has not handed over yet, newest first, and then marks them with the "AiSeen" keyword so the next call returns only what arrived since. This is separate from the human read/unread state, which is never touched. Use dry_run to preview without marking.

get_messageA

Fetches one message by UID and returns its headers and text body, fenced as untrusted content, together with a server-side security assessment (SPF/DKIM/DMARC verdicts, prompt-injection and homoglyph signals) and the list of its attachments. Does not change the read state. Set include_thread to also list the surrounding conversation.

get_attachmentsA

Without part_id: lists the attachments of a message with their type, size and whether the policy allows fetching them. With part_id: returns that one attachment. Small text and images come back inline so you can read them; anything larger is written to the download directory and you get the path. part_id must come from a listing call of this same tool. Executables are refused even when they claim to be something else — including when writing to disk.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ni-c/imap-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server