Skip to main content
Glama
mailbox-org-mcp
by getrdone

Delete messages permanently

mailbox_delete_messages
Destructive

Permanently deletes matching messages in a mailbox.org folder with no Trash recovery, requiring confirm=true. Use it to empty Trash or Junk, or purge messages selected by a Gmail-style query or UIDs.

Instructions

PERMANENTLY delete messages (no Trash, cannot be undone except from mailbox.org backups). Prefer mailbox_move_messages to='trash'. Typical use: emptying Trash or Junk with query '' in that folder. Requires confirm=true.

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": {
      "confirm": "<confirm>"
    },
    "name": "mailbox_delete_messages"
  }
}

Input Schema

NameRequiredDescriptionDefault
maxNoSafety cap on how many messages a query may touch. The tool refuses when more match; raise it deliberately.
uidsNoExact message UIDs in `folder`. Give either uids or query.
queryNoSelect by query instead of UIDs (searches `folder` unless the query has in:...). Gmail-style query. Examples: from:amazon is:unread | subject:"invoice" newer_than:30d | has:attachment larger:5M | label:$purchases | color:red | is:starred -from:me | has:unsubscribe older_than:6m | (from:a OR from:b) | in:Archive. Bare words search headers and body. Empty = all messages.
folderNoFolder path, e.g. "INBOX", "Archive", "INBOX/newsletters". Names like archive, trash, junk, sent, drafts also work.INBOX
confirmYesMust be true: confirms permanent deletion
dry_runNotrue = only report what would change

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, but the description adds the crucial details those hints cannot express: there is no Trash step, the action cannot be undone except via mailbox.org backups, and confirm=true is mandatory. It does not discuss whether partial failures occur or what the response looks like, which keeps it just short of a 5.

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?

Three tight sentences, with the irreversible nature front-loaded and the safer alternative second. Nothing is padded or repeated from the schema.

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

Completeness5/5

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

For a destructive six-parameter tool with full schema coverage and no output schema, the definition covers the risk profile, the escape hatch, the safer alternative, and the confirm requirement. An agent has everything needed to decide whether to call it and how to call it safely.

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?

Schema coverage is 100%, so the baseline is 3, but the description adds real semantic value by showing how query and folder combine in practice (query '' inside the Trash folder selects everything) and by restating that confirm must be true. The max safety cap and query syntax remain the schema's job, which is an appropriate division.

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?

States a specific verb and resource ('PERMANENTLY delete messages') and immediately distinguishes itself from the non-destructive sibling by contrasting with mailbox_move_messages to='trash'. The capitalization of PERMANENTLY makes the scope of the operation unmistakable.

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

Usage Guidelines5/5

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

Explicitly names the alternative (mailbox_move_messages to='trash') and the condition that should select it, then gives a concrete typical use case: emptying Trash or Junk with query '' in that folder. It also states the confirm=true prerequisite, so an agent knows both the when-to-use and the guardrail before calling.

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