Skip to main content
Glama

List Emails

list_emails
Read-only

Use this when the user wants to see or triage their inbox on this Mac (Apple Mail — any account added to Mail.app: iCloud, Gmail, IMAP, Exchange). Lists email headers (subject, sender, date, unread); call read_email(message_id) for the full body. For a Microsoft 365 mailbox NOT added to Mail.app, use m365_list_emails.

IMPORTANT: on machines with 2+ accounts, call with account= (from list_email_accounts). Without it, and when the fast index can't answer, list_emails returns the account list instead of scanning all of them — scanning every account in one call has no time limit and can block Mail for other requests too (#2268). Exactly 1 account is unaffected.

Supports pagination: use offset to page through results (e.g. offset=20 for page 2 with limit=20). The limit parameter is capped at 50 per call (default 20); to read more, page with offset rather than requesting a larger limit.

Input Schema

NameRequiredDescriptionDefault
limitNoHow many messages to return, 0-50 (0 returns none). Defaults to 20.20
offsetNoHow many messages to skip before returning, for paging through a folder. Defaults to 0.0
accountNoMail.app account name (from list_email_accounts). On a Mac with 2+ accounts, passing it is much faster than letting the walk cover all of them.
mailboxNoFolder to list, by name (see list_email_folders). Defaults to the Inbox.
unread_onlyNoReturn only unread messages. Defaults to false.false

Output Schema

NameRequiredDescriptionDefault
countNo
offsetNo
messagesNo
next_actionsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / next_actions / items
      Added value: +{
      +  "type": "object"
      +}
  2. Changed6 schema fields changed
    • addedInput schema / properties / account / description
      Added value: +"Mail.app account name (from list_email_accounts). On a Mac with 2+ accounts, passing it is much faster than letting the walk cover all of them."
    • addedInput schema / properties / limit / description
      Added value: +"How many messages to return, 0-50 (0 returns none). Defaults to 20."
    • changedInput schema / properties / limit / minimum
      Previous value: -1New value: +0
    • addedInput schema / properties / mailbox / description
      Added value: +"Folder to list, by name (see list_email_folders). Defaults to the Inbox."
    • addedInput schema / properties / offset / description
      Added value: +"How many messages to skip before returning, for paging through a folder. Defaults to 0."
    • addedInput schema / properties / unread_only / description
      Added value: +"Return only unread messages. Defaults to false."
  3. Changed6 schema fields changed
    • removedInput schema / properties / account / description
      Removed value: -"Mail.app account name (from list_email_accounts). On a Mac with 2+ accounts, passing it is much faster than letting the walk cover all of them."
    • removedInput schema / properties / limit / description
      Removed value: -"How many messages to return, 0-50 (0 returns none). Defaults to 20."
    • changedInput schema / properties / limit / minimum
      Previous value: -0New value: +1
    • removedInput schema / properties / mailbox / description
      Removed value: -"Folder to list, by name (see list_email_folders). Defaults to the Inbox."
    • removedInput schema / properties / offset / description
      Removed value: -"How many messages to skip before returning, for paging through a folder. Defaults to 0."
    • removedInput schema / properties / unread_only / description
      Removed value: -"Return only unread messages. Defaults to false."
  4. Changed2 schema fields changed
    • changedInput schema / properties / limit / description
      Previous value: -"How many messages to return, 1-50. Defaults to 20."New value: +"How many messages to return, 0-50 (0 returns none). Defaults to 20."
    • changedInput schema / properties / limit / minimum
      Previous value: -1New value: +0
  5. Changed5 schema fields changed
    • addedInput schema / properties / account / description
      Added value: +"Mail.app account name (from list_email_accounts). On a Mac with 2+ accounts, passing it is much faster than letting the walk cover all of them."
    • addedInput schema / properties / limit / description
      Added value: +"How many messages to return, 1-50. Defaults to 20."
    • addedInput schema / properties / mailbox / description
      Added value: +"Folder to list, by name (see list_email_folders). Defaults to the Inbox."
    • addedInput schema / properties / offset / description
      Added value: +"How many messages to skip before returning, for paging through a folder. Defaults to 0."
    • addedInput schema / properties / unread_only / description
      Added value: +"Return only unread messages. Defaults to false."
  6. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations cover the safety profile (readOnlyHint=true, destructiveHint=false), so the bar is lower, yet the description goes well beyond: without account= on multi-account machines it returns the account list instead of scanning, scanning all accounts has no time limit and can block Mail for other requests (#2268), and exactly 1 account is unaffected. That is substantive behavioral disclosure an agent cannot get from structured fields.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the primary purpose, then an IMPORTANT block for the highest-risk gotcha, then pagination. Every sentence carries weight, though the pagination paragraph partly restates what the limit/offset schema descriptions already say, so it is slightly longer than strictly necessary.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be described. The description covers routing to alternatives, the multi-account failure mode, and paging limits — everything an agent needs to invoke this correctly, with no meaningful gap remaining.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, but the description adds real meaning: the rationale and consequence of the account parameter (fallback to returning the account list, blocking behavior), and concrete pagination usage ('offset=20 for page 2 with limit=20') plus the hard cap rationale. The account-perf note partially duplicates the schema text, which keeps it from a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Lists email headers (subject, sender, date, unread)') scoped to Apple Mail on this Mac, and explicitly names what it is not: it points to read_email for bodies and m365_list_emails for Microsoft 365 mailboxes outside Mail.app. An agent can distinguish it from the many sibling email/search tools without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit trigger ('when the user wants to see or triage their inbox on this Mac'), names the read_email alternative for full bodies, and routes the non-Mail.app M365 case to m365_list_emails. It also states a hard operational condition: on 2+ account machines, call with account=<name> from list_email_accounts.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources