Skip to main content
Glama
kojott

mailmcp

Search (ChatGPT-compatible)

search
Read-onlyIdempotent

Query all linked mailboxes at once to locate email messages and receive their IDs for full retrieval.

Instructions

Searches all readable mailboxes with one query string and returns documents with ids for fetch. Use Gmail search syntax for Gmail accounts (from:, newer_than:7d, has:attachment); plain words elsewhere. Prefix the query with "account: " to limit it to one mailbox. Outlook / Microsoft 365 mailboxes are searched in the Inbox only (Graph has no "all mail" scope), while Gmail is searched across All Mail; use search_messages with a folder to look elsewhere.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesSearch query

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

The annotations already cover read-only, idempotent, and non-destructive traits, and the description adds significant behavioral context: it returns ids for `fetch`, explains scope differences between Gmail (All Mail) and Outlook (Inbox only), and clarifies query syntax. This goes beyond what annotations provide and helps the agent predict behavior.

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 dense but every sentence earns its place: core functionality, syntax rules, account restriction, and platform-specific scope. It is front-loaded with the essential outcome and then layers necessary details. No redundant or filler content.

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?

There is no output schema, so the description correctly states that results are 'documents with ids for `fetch`,' telling the agent how to use the results. It also covers platform-specific behavior and the alternative tool for folder-scoped searches. This is complete for the tool's complexity and one-parameter schema.

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% (the `query` property is documented), so the baseline is 3. The description enriches this by explaining the query format (Gmail syntax vs plain words) and the `account:<id> ` prefix, which is valuable additional semantics for the single parameter. This moves it above the baseline.

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 tool's function: 'Searches all readable mailboxes with one query string and returns documents with ids for `fetch`.' It specifies the verb, resource, and output, and differentiates from the sibling `search_messages` by noting its folder-specific use case. The distinction is explicit and actionable.

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?

The description provides detailed usage guidance: Gmail syntax vs plain words, account prefix to limit scope, and the Outlook/Gmail folder behavior with an explicit pointer to `search_messages` when a specific folder is needed. It tells the agent when to use this tool and when to use an alternative, leaving no ambiguity.

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