gmail_search_threads
Search Gmail threads in a connected account using query syntax to find messages by sender, subject, attachment, label, or date.
Instructions
Search email threads using Gmail query syntax (e.g. "from:amy has:attachment newer_than:7d").
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account": "<account>"
},
"name": "gmail_search_threads"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| view | No | THREAD_VIEW_MINIMAL (default) includes subject and snippet; THREAD_VIEW_METADATA_ONLY omits them. | |
| query | No | Gmail search query. Supports from:, to:, subject:, has:, label:, is:, before:/after:YYYY/MM/DD, newer_than:/older_than:, OR, and - to exclude. Omit to list everything except spam and trash. | |
| account | Yes | Which connected account (alias) to act as, e.g. "business". | |
| pageSize | No | Maximum results to return. Defaults to 20, maximum 50. | |
| pageToken | No | Token from a previous call, to fetch the next page. | |
| includeTrash | No | Include threads from Spam and Trash. Defaults to false. |