Skip to main content
Glama

delete_media

Permanently delete a WordPress media attachment by ID to remove unwanted files and free storage. Use when an attachment must be erased rather than trashed.

Instructions

Permanently delete a media attachment from WordPress

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": {
      "id": "<id>"
    },
    "name": "delete_media"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesMedia attachment ID to delete
forceNoMust be true for media (media doesn't support trash). Defaults to true.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and the word 'permanently' is a genuine disclosure that the operation is irreversible and bypasses any trash. However, it says nothing about required permissions, what happens to posts that reference the attachment, or failure modes when the ID does not exist.

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?

A single short sentence with the destructive qualifier front-loaded and no wasted words. It is efficient but bare, offering no structure beyond the one clause.

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

Completeness3/5

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

For a destructive two-parameter tool with no annotations and no output schema, the description covers the essential irreversibility but omits permissions, side effects on referencing content, and what a successful call returns. It is minimally adequate rather than complete.

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

Parameters3/5

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

Schema description coverage is 100%, so both 'id' and the non-obvious 'force' flag (which must be true because media has no trash) are already documented in the schema. The description adds no parameter detail beyond that, so the baseline of 3 applies.

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?

The description names a specific verb ('delete') and resource ('media attachment') with a scope qualifier ('from WordPress'), so an agent can tell it apart from delete_post, delete_page, and delete_comment by resource. It does not explicitly compare itself to those siblings, which keeps it short of a 5.

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

Usage Guidelines2/5

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

There is no guidance on when to choose this versus update_media, get_media, or the other delete_* tools, and no stated preconditions such as required capabilities or confirmation steps. The agent must infer usage entirely from the tool name and resource.

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