Skip to main content
Glama
kharonx
by kharonx

list-mail-messages

list-mail-messages
Read-onlyIdempotent

Find specific messages in a Microsoft 365 mailbox by applying full-text KQL search, OData filters, and time ranges—so you can locate emails by sender, recipient, subject, attachment, or importance.

Instructions

List/search messages in the signed-in user's mailbox. Supports full-text KQL search (sender, recipient, cc, subject, keyword, attachment, read/unread, importance) and time ranges.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toNoEnd of explicit time range (ISO date or datetime)
fromNoStart of explicit time range (ISO date or datetime, overrides timeRange)
cursorNoContinuation token (nextCursor of a previous truncated response). Continues that listing; other query inputs are ignored.
filterNoOData $filter expression, e.g. "importance eq 'high'" or "hasAttachments eq true"
searchNoFull-text search (KQL supported), e.g. 'from:kiss.peter@ceg.hu subject:"AI projekt" hasattachment:true'
selectNoComma separated list of properties to return (OData $select)
orderbyNoOData $orderby, e.g. "receivedDateTime desc"
maxItemsNoMaximum items to return across pages (default 50, max 500). Pagination via @odata.nextLink is handled automatically; when the result is truncated, pass its nextCursor as cursor to continue.
timeRangeNoNamed time range applied on receivedDateTime
Install Server

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, openWorldHint=true, idempotentHint=true, and destructiveHint=false, covering the safety profile. The description adds that full-text KQL search and time ranges are supported, which is useful but not deeply behavioral. No contradiction with annotations exists.

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 a single focused sentence that front-loads the core action and resource, then names the key capabilities. Every word contributes value and there is no redundant filler.

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

Completeness4/5

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

For a moderately complex tool with nine parameters, the description plus a fully covered schema is largely sufficient. It does not describe the output shape, and there is no output schema, but the schema covers pagination via maxItems/cursor and the description clearly conveys the tool's scope. Minor gap: it does not mention that omitting all filters returns all messages.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema documents all nine parameters thoroughly. The description adds high-level context about KQL and time ranges, but it mostly restates what the search and timeRange parameter descriptions already provide. This is the baseline for full schema coverage.

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

Purpose4/5

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

The description clearly states the verb-resource pair: list/search messages in the signed-in user's mailbox, and adds specific capabilities (KQL full-text search and time ranges). It does not explicitly contrast with sibling tools like list-mail-folder-messages or list-shared-mailbox-messages, but the 'signed-in user's mailbox' scope distinguishes it from shared-mailbox variants.

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

Usage Guidelines3/5

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

The description implies when to use the tool: for searching or listing messages in the signed-in user's mailbox with KQL or time-range filters. However, it gives no explicit guidance about alternatives such as list-mail-folder-messages for folder-scoped listing or get-mail-message for retrieving a single message, so the agent must infer the routing decision.

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

Other Tools

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/kharonx/mcp_gateway'

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