Skip to main content
Glama

WordPress: Wp classic html replace

wordpress_specialist_wp_classic_html_replace
Destructive

Replaces a WordPress post's content HTML on Classic editor sites, sanitizing markup with wp_kses_post unless raw HTML is explicitly enabled.

Instructions

[UNIFIED] Pure post_content swap for sites still on the Classic editor. Companion sanitises with wp_kses_post unless raw_html=true (S-13). Requires Airano MCP Bridge v2.13.0+ and edit_post on the target.

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>",
      "post_id": "<post_id>",
      "html": "<html>"
    },
    "name": "wordpress_specialist_wp_classic_html_replace"
  }
}

Input Schema

NameRequiredDescriptionDefault
htmlYes
siteYes
post_idYes
raw_htmlNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv3.14.0

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already flag destructive=true and idempotent=false, so the safety profile is covered; the description adds genuinely new context: sanitisation via wp_kses_post unless raw_html=true, plus the Airano MCP Bridge v2.13.0+ requirement and the edit_post capability check. The gripes are minor: "Companion sanitises" is ambiguous about whether this tool or another performs the sanitisation, and revision/rollback consequences of a destructive overwrite are not mentioned.

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 tight sentences with the editor constraint front-loaded. Internal jargon like "[UNIFIED]" and "(S-13)" adds noise without meaning for an agent, and "Companion" is an unclear referent, but overall the wording is efficient.

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 mutation with no output schema, the description covers the prerequisites and sanitisation behaviour well, but omits what the call returns, what happens to existing revisions, and any confirmation/overwrite semantics. Adequate but with real gaps for a write tool.

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 0%, so the description must carry the parameter burden. It explains raw_html semantically (bypasses wp_kses_post sanitisation), which is the one non-obvious flag, but says nothing about site, post_id (post vs revision vs page), or html beyond the phrase "post_content swap".

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 action and resource: a "pure post_content swap" restricted to "sites still on the Classic editor." That editor qualifier is what distinguishes it from the wp_blocks_* siblings, though no sibling is named outright.

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?

"For sites still on the Classic editor" implies the condition for choosing this tool, and the required capability/version gate is stated. However, it never names the alternative (e.g. wp_blocks_replace) or says when NOT to use this, leaving the routing inference to the agent.

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