Skip to main content
Glama

wp_delete_option

Delete a WordPress option row entirely, causing reads to fall back to defaults. Use dry_run to preview before permanent deletion; requires admin and allow_prod for production.

Instructions

Delete a wp_options row entirely (not "set it to empty").

Whatever reads that option falls back to its default - which for a plugin's settings row means every setting it holds is gone at once, and for a core option can change how the site behaves. Read it with wp_get_option and keep the value first: nothing here can restore it. Deleting an option that was never set is reported as action: "noop" (nothing to delete), not an error. DEFAULTS TO dry_run=true (returns a preview with the current value; deletes nothing). Pass dry_run=false to delete. Requires the REST transport, wp-ops-connect 1.3.0+ and an administrator app password. Prod writes require allow_prod=true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
dry_runNo
installYes
allow_prodNo

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.4.0

TDQS

A4.3/5.0
Behavior5/5

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

With no annotations present, the description carries the full burden of disclosing side effects, and it does so thoroughly. It explains irreversibility, impact on plugin settings and site behavior, the no-op result for nonexistent options, dry-run behavior, and production safeguards.

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?

The description is dense but mostly well-structured, leading with the core action and then covering important caveats and usage details. Some phrasing, such as 'Read it with wp_get_option and keep the value first,' is slightly awkward but not confusing enough to hurt clarity significantly.

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?

Given the lack of annotations and output schema, the description provides substantial context: destructive consequences, dry-run behavior, no-op reporting, required permissions, and production guard. It does not describe the output format in detail, but it covers the information most needed to use the tool safely and correctly.

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?

The description explains dry_run and allow_prod clearly, but the required parameters name and install are not explicitly described. While name is fairly inferable as the option name and install may be contextually understood, the description does not fully compensate for the 0% schema coverage.

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 clearly states the tool deletes a wp_options row entirely and explicitly contrasts it with setting the option to empty, which distinguishes it from wp_set_option and other option-related tools. The verb and resource are specific and unambiguous.

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?

The description provides practical usage guidance by warning against using this for setting an empty value, pointing to wp_get_option for reading values first, and explaining the dry_run default and the need to pass dry_run=false to actually delete. It also mentions required environment and permission conditions, though it does not explicitly say 'use this when permanent deletion is intended'.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ad02/wp-ops-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server