Skip to main content
Glama

WordPress: Bulk delete media

wordpress_bulk_delete_media
Destructive

Delete WordPress media attachments in bulk by ID list, up to 100 per call, with optional permanent removal and processed, error, and total results.

Instructions

[UNIFIED] Delete (trash or permanently remove) a list of media attachments in a single call. Max 100 IDs per request. Returns processed / errors / total. Uses stock /wp/v2/media/{id} DELETE so no companion plugin is required, but issues N requests (with a small concurrency cap); for 1000+ attachments, paginate client-side.

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": {
      "site": "<site>",
      "media_ids": "<media_ids>"
    },
    "name": "wordpress_bulk_delete_media"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteYes
forceNo
media_idsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv3.13.1

TDQS

A4.2/5.0
Behavior4/5

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

Beyond the destructiveHint=true annotation, it discloses the request pattern (N requests with a small concurrency cap), the plugin-free requirement, and the return shape (processed / errors / total). It never explicitly ties the force flag to permanent deletion versus trashing, which is the key destructive nuance an agent needs.

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 dense sentences, front-loaded with the action and scope, followed by limits and implementation expectations. No filler or restatement of the name.

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?

With annotations covering the destructive profile and no output schema, the description supplies limits, pagination advice, and result fields, which is close to complete. The remaining gap is the unexplained force and site parameters for a tool whose schema documents neither.

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 coverage is 0%, so the description carries the burden. It documents the media_ids list and its 100-item cap and implies the trash/permanent dichotomy, but the site parameter is never explained and force is never named or mapped to its default, leaving two of three parameters underspecified.

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 plus resource and scope: delete a list of media attachments in a single call, with trash vs permanent spelled out. The word 'list' and 'single call' clearly separate it from the single-item wordpress_delete_media sibling without needing to name it.

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?

Gives concrete operating guidance: max 100 IDs per request, and for 1000+ attachments paginate client-side. It does not explicitly say when to prefer the single-delete sibling or state any 'when not to use' condition, so it stops short of full routing guidance.

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

Deploy Server

Other Tools