Skip to main content
Glama

gmail_search

Search Gmail messages in a specific account using Gmail query syntax, with optional result limits. Returns matching messages without attachment details; use message read to view attachments.

Instructions

Search Gmail messages on one account. Results do not include attachment info (fetched with format: metadata, which never populates the MIME parts tree) — use gmail_read_message on a specific message to see its attachments.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesGmail search query, e.g. from:alice@example.com newer_than:7d.
accountYesConfigured Gmail account alias, e.g. work, personal, support.
maxResultsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden of behavioral disclosure. It does disclose a specific limitation (no attachment info) and explains why, which is useful. However, it does not describe the return format or pagination behavior, leaving the agent to infer what the result list looks like. While it covers a key behavior, it is not fully transparent about the operation's output.

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 two sentences with no fluff. It front-loads the core purpose and scope, then adds the critical limitation and a pointer to the alternative. Every sentence earns its place, and the structure is easy to scan.

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 simple search tool with 3 params and no output schema, the description covers the essential points: what it does, the single-account scope, the attachment limitation, and the alternative. The main gap is the lack of return format details, but this is not critical for deciding to call the tool, and the schema covers parameters. Overall, it is reasonably complete for its complexity.

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 67% (query and account have descriptions; maxResults only has constraints). The description adds no parameter-specific detail beyond what the schema provides. Since coverage is moderate, the baseline is 3, and the description does not compensate for the missing maxResults description, but the schema constraints give some guidance.

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 action (search), the resource (Gmail messages), and the scope (on one account). It also distinguishes from gmail_search_many by explicitly limiting to one account, and from gmail_read_message by noting the attachment limitation. This makes the tool's purpose unambiguous and differentiates it from siblings.

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 gives a clear when-not: results lack attachment info, and directs the agent to use gmail_read_message for attachments. It implicitly distinguishes from gmail_search_many by saying 'one account,' but does not explicitly name that alternative. Overall, it provides actionable guidance for choosing between tools.

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