> ## Documentation Index
> Fetch the complete documentation index at: https://developers.myhero.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Gmail search

> Search the user's Gmail using Gmail's native query syntax. Returns message headers + snippets (NOT full bodies). Gmail query examples: …

`gmail_search`

Search the user's Gmail using Gmail's native query syntax. Returns message headers + snippets (NOT full bodies). Gmail query examples:   - `from:sarah@example.com` — messages from Sarah   - `subject:invoice newer_than:7d` — invoices from the last week   - `has:attachment filename:pdf` — PDFs   - `label:inbox is:unread` — unread inbox items   - `in:sent to:bob@example.com` — mail I sent to Bob   - Leave `query` empty to list the most recent messages. Follow up with `gmail_get_message` or `gmail_get_thread` to fetch full bodies.

## Parameters

<ParamField path="query" type="string">
  Gmail search query. Use the operators listed in the tool description. Empty string = most recent messages.
</ParamField>

<ParamField path="limit" type="integer" default={10}>
  Max number of messages to return (1-25). Minimum: 1. Maximum: 25.
</ParamField>
