Skip to main content
Glama

gmail_list_emails

Read-onlyIdempotent

Search and list Gmail messages in your connected mailbox using query filters and labels to find the emails you need.

Instructions

List / search Gmail messages in the connected mailbox.

Args: query: Gmail search query (e.g. 'from:alice has:attachment newer_than:7d'). max_results: label_ids: Filter to messages with these labels (e.g. ['INBOX']). project_id: Authenticated Project UUID. project_ref: Exact project correlation reference. connector_account_ref: Project-bound connector account alias. idempotency_key: Stable business-action identity. effect: Required and must be read; Spring verifies it. approval_ref: Approved platform task UUID when resuming a write.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryNo
effectYes
label_idsNo
project_idNo
max_resultsNo
project_refNo
approval_refNo
idempotency_keyNo
connector_account_refNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.1.1
    • addedInput schema / properties / approval_ref
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Approval Ref"
      +}
    • addedInput schema / properties / connector_account_ref
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Connector Account Ref"
      +}
    • addedInput schema / properties / effect
      Added value: +{
      +  "const": "read",
      +  "title": "Effect",
      +  "type": "string"
      +}
    • addedInput schema / properties / idempotency_key
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Idempotency Key"
      +}
    • addedInput schema / properties / project_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Project Id"
      +}
    • addedInput schema / properties / project_ref
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Project Ref"
      +}
    • addedInput schema / required
      Added value: +[
      +  "effect"
      +]
  2. First observedv0.1.0

TDQS

C2.9/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the read-only behavior is covered. The description adds minimal behavioral context: it notes that 'effect: Required and must be read; Spring verifies it,' which is a platform detail but not a behavioral trait of the tool itself. It does not describe return format, pagination, or any side effects. Since annotations cover the safety profile, this is adequate but not enriched.

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

Conciseness2/5

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

The description is not well-structured: it opens with a clear one-liner, but then has a messy list of arguments with inconsistent formatting. The entry for max_results has no explanation (just 'max_results:'), and several parameters are listed without clear delimiters. It is not front-loaded with the most critical information, and the long list of platform-specific params may confuse an agent. The description could be significantly tightened.

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

Completeness2/5

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

With 9 parameters and no schema descriptions, the description should explain the purpose of each parameter and any constraints. It does not mention pagination, sorting, or what the response contains (though an output schema exists, so return value details may be omitted). The presence of internal parameters like effect, approval_ref, and idempotency_key without clear usage guidance leaves an agent uncertain about required values. The tool is more complex than the description addresses, making it incomplete for safe and correct invocation.

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 0%, so the description carries the full burden. It explains query and label_ids with examples, and gives one-line definitions for project_id, project_ref, connector_account_ref, idempotency_key, effect, and approval_ref. However, max_results is left without any explanation, and the definitions for platform parameters are vague (e.g., 'Authenticated Project UUID' without explaining why or when to supply it). Partial compensation, but gaps remain.

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 states a specific verb and resource: 'List / search Gmail messages in the connected mailbox.' It clearly indicates the tool operates on Gmail messages and performs listing/searching, which distinguishes it from siblings like gmail_get_email or gmail_send_email. The phrasing 'List / search' is slightly ambiguous but the resource is clear.

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

Usage Guidelines2/5

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

The description gives no explicit guidance on when to use this tool versus alternatives such as gmail_get_email or gmail_get_thread. It implies listing/searching but does not state conditions like 'when you need multiple messages' or 'when you need to filter by query.' There is no when-not-to-use guidance, and platform-specific parameters like effect and approval_ref are unexplained in terms of when they are required.

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

Deploy Server

Other Tools