Skip to main content
Glama

Remove a widget

wp_delete_widget
Destructive

Remove a widget instance from its sidebar and delete its settings. The widget option is rewritten directly, without the widget's own cleanup routines. Returns deleted and id; an id found neither in a sidebar nor in the stored settings is reported as not found. Permanent: no undo point is recorded. The settings of an existing widget change with wp_update_widget. Forwarded by AlphaBridge Connect to the one site this connection reaches.

Input Schema

NameRequiredDescriptionDefault
idYesWidget id "<id_base>-<number>" as wp_get_widgets lists it, e.g. "text-2".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / id / description
      Previous value: -"Widget id, e.g. \"text-2\"."New value: +"Widget id \"<id_base>-<number>\" as wp_get_widgets lists it, e.g. \"text-2\"."
  2. Added

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the destructiveHint/idempotentHint annotations, the description discloses that the option row is rewritten directly without the widget's own cleanup routines, that no undo point is recorded, and that the write is forwarded by AlphaBridge Connect to one site. These are non-obvious traits an agent cannot infer from structured fields.

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 permanent/destructive consequence, then the alternative, then connection scope. Dense but every sentence carries information; the 'returns deleted and id' clause is slightly redundant with the id parameter narrative.

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, and the description covers return fields, error case, permanence, cleanup bypass, the alternative tool, and the connection scoping. An agent has everything needed to call it correctly and predict the outcome.

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 100% and the single id parameter is fully described there, so the description adds no format or syntax detail. It does add error semantics (id absent from sidebar and stored settings is reported not found), which is useful but doesn't extend parameter meaning itself. Baseline 3.

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 specific verb and resource (remove a widget instance from its sidebar, delete its settings) and distinguishes it from wp_update_widget and implicitly from wp_add_widget. An agent can select it from the sibling list without opening the schema.

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?

It explicitly routes modification of existing widget settings to wp_update_widget, and the 'not found' clause tells the agent when the call will no-op. It doesn't state a concrete when-not-to-use case like 'use wp_add_widget to create', but the context is clear.

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