Skip to main content
Glama

Purge Old Messages

purge_old_messages

Delete messages older than a configured retention period (default 180 days) to manage mailbox history; supports dry-run and returns the number purged.

Instructions

Delete messages older than the configured retention period. Defaults to retention_max_age_days from config (180 days). Returns count of messages purged.

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": {
      "project_key": "<project_key>"
    },
    "name": "purge_old_messages"
  }
}

Input Schema

NameRequiredDescriptionDefault
dry_runNo
project_keyYes
max_age_daysNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.5
    • addedInput schema / additionalProperties
      Added value: +false
  2. First observedv0.3.4

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden for a destructive tool. It discloses the retention source and the return shape, but omits whether deletion is irreversible, whether the default dry_run=true makes the call non-destructive unless overridden, and what happens to messages in edge cases (exactly at the age boundary).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short, front-loaded sentences with no filler; the deletion scope leads. The final sentence about the return count is somewhat wasted given a dedicated output schema exists, but the overall shape is efficient.

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

Completeness2/5

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

For a destructive, zero-annotation tool with an entirely undocumented parameter schema, the definition is thin. An output schema covers the return value, but the description should still establish the safety model (dry_run default), the blast radius, and what each parameter controls before an agent invokes a purge.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across 3 parameters, so the description must compensate. It only clarifies max_age_days indirectly ('defaults to retention_max_age_days from config (180 days)') and says nothing about project_key's scope or dry_run's meaning, leaving two of three parameters undocumented anywhere.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource+predicate: 'Delete messages older than the configured retention period.' An agent can distinguish this from search_messages or acknowledge_message by the deletion scope, but the description never names a sibling or clarifies boundary with archive/hard_delete_project style operations.

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

Usage Guidelines3/5

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

Usage is only implied by the retention framing — an agent infers this is a periodic cleanup operation. There is no explicit when-to-use guidance, no note about prerequisites or permissions, and no mention that dry_run defaults to true (a critical pre-condition for a destructive call).

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