Skip to main content
Glama

List mail messages

mail_list_messages
Read-onlyIdempotent

Lists Outlook messages newest-first, supporting filters for unread, folder, or properties, and paging via skip. Returns a compact preview with subject, sender, and metadata; retrieve full content with mail_get_message.

Instructions

Lists Outlook messages newest-first, 10 per call by default (50 max), as a compact projection: id, subject, from, toRecipients, receivedDateTime, isRead, hasAttachments, bodyPreview and webLink. Bodies are never included — bodyPreview is Graph's first 255 characters, and mail_get_message returns the rest. Page with skip. Note that Exchange rejects some filter/orderby combinations with "The restriction or sort order is too complex"; when that happens, drop orderby or sort on the same property you filtered.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topNoHow many messages to return. Defaults to 10; 50 is the ceiling.
skipNoMessages to skip before returning results. Use it to page: 0, then 10, then 20.
filterNoRaw OData $filter, e.g. "importance eq 'high'" or "receivedDateTime ge 2026-01-01T00:00:00Z". Combined with unreadOnly using and.
selectNoGraph message property names to return instead of the default projection, e.g. ["subject","importance","conversationId"]. id is always included. Do not ask for "body" here — use mail_get_message.
orderbyNoSort order. Defaults to "receivedDateTime desc" (newest first).receivedDateTime desc
folderIdNoRestrict to one mail folder. Accepts a folder id from mail_list_folders or a well-known name: inbox, drafts, sentitems, deleteditems, archive, junkemail, outbox, clutter, conversationhistory, scheduled. Omit to list the whole mailbox.
unreadOnlyNoReturn only unread messages (adds "isRead eq false" to the filter).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true, so the description doesn't need to repeat safety. It adds valuable behavioral context: bodies are never included, bodyPreview is only the first 255 characters, pagination uses skip, and it warns about Exchange filter/orderby restrictions with a concrete workaround. This goes beyond the annotations without contradicting them.

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

Conciseness5/5

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

The description is concise, front-loaded with the core behavior, then covers body handling, pagination, and a caveat in a logical order. Every sentence adds value; there is no filler or repetition of schema details.

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?

For a read-only listing tool with seven optional parameters and no output schema, the description is remarkably complete. It covers the default projection, how to retrieve full bodies (delegating to mail_get_message), pagination mechanics, folder scoping (including well-known names), and a known error scenario with a workaround. An agent has everything needed to call it correctly.

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 the baseline is 3. The description adds meaning beyond the schema by explaining the compact projection, that bodyPreview is a preview, and that bodies are intentionally excluded. It also contextualizes the 'skip' parameter for paging and hints at the filter/orderby interplay, which enriches parameter understanding.

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?

The description clearly states the verb (Lists), the resource (Outlook messages), and specific behavioral details (newest-first, 10 per call, compact projection). It explicitly distinguishes itself from mail_get_message by noting bodies are never included and that mail_get_message returns the rest, effectively differentiating from a key sibling.

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

Usage Guidelines4/5

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

The description provides clear context: it lists messages in a folder or mailbox with optional filtering and paging. It explicitly points to mail_get_message for full body content, which serves as an alternative. However, it does not explicitly contrast with mail_search_messages or other listing tools, so the when-not-to-use guidance is implicit rather than explicit.

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