Skip to main content
Glama

wp_upgrade_accordions

Fix legacy FAQ/accordion widgets on a page: convert Elementor's CLASSIC accordion (which always force-opens the first item, with no setting to stop it) to the NESTED Accordion — all items COLLAPSED by default, plus native FAQ schema. Preserves every question/answer. Use this on existing pages where the first FAQ opens automatically (new pages already build correctly). dry_run=true previews how many would convert. Write-gated.

Input Schema

NameRequiredDescriptionDefault
dry_runNoPreview the count without writing. Default false.
post_idYesThe page/post ID
site_idYesThe WordPress site ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, openWorldHint=true and idempotentHint=false. The description adds genuine value on top: it promises content preservation ('Preserves every question/answer') and notes the call is write-gated, consistent with the non-destructive hint. It does not clarify re-run behavior on an already-converted page, which matters given idempotentHint=false.

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?

Front-loaded with the action and the defect, and heavy use of caps highlights the key contrasts (CLASSIC vs NESTED, COLLAPSED). It is slightly dense and the parenthetical about the classic accordion's behavior could be trimmed, but no sentence is wasted.

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 only three parameters, no nested objects, and no output schema, the definition covers what an agent needs: the transformation, the precondition, the preview mode, and content preservation. The only gaps are what a non-dry-run response reports and how repeat invocation behaves.

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 all three parameters are already documented and the baseline is 3. The description's note that dry_run 'previews how many would convert' adds only marginal color over the schema's 'Preview the count without writing', and site_id/post_id are not elaborated at all.

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?

The description states a precise verb+resource transformation: convert Elementor's CLASSIC accordion to the NESTED Accordion with FAQ schema, on a specific page. It names the exact defect being fixed (first item force-opens) and the resulting state (all items collapsed), so an agent can distinguish it from generic page-update siblings like wp_update_page or wp_patch_page.

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

Usage Guidelines5/5

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

It explicitly scopes usage to existing pages where the first FAQ opens automatically and excludes new pages ('new pages already build correctly'), which is a real when-not statement. It also flags the dry_run preview path and that the operation is write-gated, giving the agent the conditions needed to decide between previewing and committing.

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