Skip to main content
Glama

gmail_search

Read-only

Search Gmail messages with full Gmail query syntax, such as from:, subject:, is:unread, or has:attachment. Returns newest matches first across All Mail, supporting limits and pagination.

Instructions

Search email with Gmail search syntax (from:, to:, subject:, is:unread, has:attachment, label:, newer_than:2d, after:2026/01/01...). Covers All Mail (not Trash/Spam). Newest first.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo1-100 (default 20)
queryNoGmail search query. Default 'in:inbox'. Use '' for everything.
before_idNoOnly messages with id lower than this (pagination)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so safety is covered. The description adds valuable behavioral context beyond them: the All Mail scope (excluding Trash/Spam) and the newest-first result ordering, which the agent could not learn from the schema.

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?

Three tight sentences, front-loaded with the core action and scope, followed by two short supporting facts. Every clause carries information with no filler.

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 simple read-only search tool with no output schema, the description supplies the scope, ordering, and query syntax needed to call it correctly. Nothing an agent requires is missing.

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 description coverage is already 100%, so the baseline is 3, but the description adds a compact syntax cheatsheet (from:, to:, is:unread, has:attachment, newer_than:2d, after:...) that meaningfully enriches how the query parameter should be constructed beyond the schema's generic 'Gmail search query' text.

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 (Search) and resource (email) and immediately pins down scope: covers All Mail but not Trash/Spam, with newest-first ordering. An agent can distinguish this from siblings like gmail_get_message or gmail_list_drafts without opening the schema.

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?

Usage is implied by the name and syntax examples, but there is no explicit when-to-use guidance, no statement of when to prefer this over gmail_get_thread or a label-filtered list, and no exclusions. Adequate but leaves routing to inference.

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