Searches Gmail using queries, then extracts specific strings using regex patterns with context lines and output size controls.
Single tool 'gmail_grep' has a well-structured schema with all parameters typed and described. The tool description is comprehensive (450+ chars) and explains when to use it vs alternatives, addressing the pattern:tool-description requirement. However, the output schema is only partially documented in the docstring (mentions 'results', 'errors', 'warnings' but lacks field-level type details). Parameter descriptions are detailed and include constraints (e.g., 'max recommended: 50'). No security issues detected, credentials are loaded server-side, not exposed as parameters. The tool follows verb_noun naming (gmail_grep) and is read-only. Main gaps: output schema lacks formal JSON Schema documentation, and error handling could be more granular (currently returns generic error strings rather than structured error objects with recovery guidance).
Searches Gmail using a query, then extracts specific strings using a regex pattern. Prefer this tool over reading full email messages/threads whenever the task is to find or tally a piece of data (an amount, code, ID, etc.) across MORE THAN ONE email -- e.g. "how much did I spend on X last quarter" or "find all the tracking numbers in these shipping emails." Reading full message bodies for that kind of task costs vastly more tokens (HTML, tracking pixels, boilerplate) for the same answer. Only reach for a full message/thread read when you need to see an entire email's content, or need context (attachments, formatting) this tool doesn't return.
Output schema not formally documented. Docstring mentions 'results', 'errors', 'warnings' but lacks JSON Schema definition with field types, nested object structures, and per-item field descriptions.
Error responses are unstructured strings rather than categorized error objects. LLM cannot distinguish retryable errors from user-fixable ones. E.g., 'Authentication Error: ...' lacks guidance on next steps.
No per-item error reporting for partial failures. If 5 of 30 emails fail to fetch, the tool returns a single error string rather than per-email success/failure status, forcing the LLM to retry all emails.
Tool description includes example Gmail query syntax ('subject:invoice newer_than:30d') which LLMs may reuse literally. Replace with formal parameter constraints or a separate 'query_syntax_guide' resource.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | C | 68 | 2026-07-28+ | v2 |