Skip to main content
Glama

Change the status of many posts

wp_bulk_update_status
Destructive

Change the status of many posts at once by id list (posts, pages, other post types and media files alike) to publish, draft, pending, private or trash; at most 500 ids per call (over_limit counts the rest, which are not touched). Suited to batches; one post's status and other fields change with wp_update_post. Unknown ids are skipped, posts already in the status are left as they are and an id given twice counts once, so a repeated call changes nothing more, except where WordPress stores another form than asked (stored_as below): those posts are written again. Publishing makes posts public at once. On a site without a trash, "trash" is refused, since WordPress would delete for good. A media file set to draft, pending or publish becomes "inherit" (shown wherever its parent is published, everywhere without one), which needs the right to publish. Returns updated (the count); ids, the posts that have the status now, with stored_as where WordPress stores a form of its own ("future" for a post dated ahead, "inherit" for a file); failed, each with the status it has (null if unreadable) and, where telling, an error: update_failed, trash_refused or untrash_refused (refused by WordPress or a plugin), unreadable (nothing written) or unverified (written, not readable back); forbidden, the posts the account may not change (edit right per post, delete right for trash). failed and forbidden list 100 each; failed_omitted and forbidden_omitted count the rest. undo is the token of an undo point with the previous statuses, for wp_undo (null when none was recorded). Needs edit_others_posts. Forwarded by AlphaBridge Connect to the one site this connection reaches.

Input Schema

NameRequiredDescriptionDefault
idsYesPost ids (integers) of any post type. An id given twice counts once; ids beyond the first 500 are not touched.
statusYesTarget status: publish, draft, pending, private or trash; any other value is refused and nothing changes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / ids / description
      Previous value: -"Array of post ids."New value: +"Post ids (integers) of any post type. An id given twice counts once; ids beyond the first 500 are not touched."
    • changedInput schema / properties / status / description
      Previous value: -"publish, draft, pending, private, trash."New value: +"Target status: publish, draft, pending, private or trash; any other value is refused and nothing changes."
  2. Added

TDQS

A4.5/5.0
Behavior5/5

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

Annotations cover safety (destructiveHint=true, readOnlyHint=false), and the description goes well beyond them: 500-id cap with over_limit accounting, duplicate ids collapsing to one, already-correct posts skipped, trash refused on sites without trash (where WordPress would hard-delete), media files becoming 'inherit', and the edit_others_posts requirement. It also documents the full result shape (updated/ids/stored_as/failed/forbidden/undo) including per-item error codes such as trash_refused and unverified.

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

Conciseness3/5

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

The purpose is front-loaded, but the body is a single dense semicolon-chained block that mixes inputs, edge cases, permissions and return values in one wall of text. The content largely earns its place given the tool's complexity, yet it would be far more scannable split into usage, edge cases, and returns.

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?

No output schema exists, yet the description documents the return payload in detail, including per-item error variants and the 100-item listing caps with omitted counters. For a destructive bulk mutation, permissions, idempotency-edge behavior, and undo token handling are all accounted for.

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 meaning: the 500-id truncation behavior, duplicate collapsing, skipping of unknown ids, and the fact that a media file targeted at draft/pending/publish is stored as 'inherit'. It does not add format or type detail beyond that, so it lands just above baseline.

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 (change status) and an explicit scope (many posts at once by id list, covering posts, pages, other post types and media), and lists the valid target statuses. It also distinguishes itself from the sibling that handles the single-post case: 'one post's status and other fields change with wp_update_post.'

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?

Signals the batch use case ('Suited to batches') and names the alternative for single posts (wp_update_post), plus it points to wp_undo for the returned undo token. The exclusion is embedded in a semicolon-separated clause rather than stated as an explicit when-not-to rule, but the routing information is present and usable.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources