Skip to main content
Glama
MarcinWalendowski

AnyMail MCP

Bulk trash

bulk_trash
Destructive

Move email messages matching a search query to the Trash folder. Use dryRun to preview before confirming bulk actions.

Instructions

Move every message matching a query to Trash (reversible ~30 days). Requires a query or mailbox. dryRun:true previews; confirm:true runs batches over 100.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
maxNoCap on messages acted on this call for trash/move/delete/empty (default 2000, keeps calls under the timeout). If the result is done:false, re-run the same call (with confirm:true) to continue until done:true.
queryNoWhat to match. On Gmail this is native search syntax (e.g. 'older_than:1y is:unread'); on other providers a text match. Omit to match the whole mailbox.
dryRunNoPreview only: return the matched count + a small sample, changing nothing.
accountNoGmail address to act on. Omit to use the default account.
confirmNoRequired to actually run a destructive or large (>100) batch.
mailboxNoMailbox/label to run in (e.g. '[Gmail]/Spam'). Omit for the account's whole-mail scope (Gmail: All Mail).
Behavior5/5

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

Disclosed reversible (30 days), batch behavior, need for re-run if done:false, and timeout via max parameter. Adds value beyond destructiveHint annotation.

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?

Two sentences, front-loaded with key info, no wasted words.

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

Completeness4/5

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

Covers operation, reversibility, and batch mechanics. No output schema, but description implies results. Could mention per-message processing time, but adequate.

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?

Adds meaning for dryRun and confirm beyond schema descriptions. Schema already covers all parameters well.

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?

Clearly states the tool moves messages to Trash based on a query. Distinct from siblings like bulk_delete and trash_message.

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

Usage Guidelines4/5

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

Explicitly mentions requirements: query/mailbox, dryRun for preview, confirm for large batches. Does not directly compare to siblings but provides sufficient context.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MarcinWalendowski/anymail-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server