Skip to main content
Glama

mcp_flush_cache

Flush the WordPress object cache and remove all transients and site transients to clear stale database-cached data without purging the page cache.

Instructions

Flush the WordPress object cache and delete all transients and site transients. Does NOT purge a page cache in front of WordPress (Bearfort forts: the nginx page cache is purged by bearfort-cache.php on content changes; a manual purge goes through the Bearfort API, not this tool).

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>"
    },
    "name": "mcp_flush_cache"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteYesSite id (see list_sites)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv3.4.0
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / site
      Added value: +{
      +  "description": "Site id (see list_sites)",
      +  "type": "string"
      +}
    • addedInput schema / required
      Added value: +[
      +  "site"
      +]
  2. First observedv2.0.0

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries full behavioral weight. It does disclose destructive scope well — all transients and site transients are deleted, and the fronting page cache is not — but it says nothing about permissions required, whether the cache rebuilds automatically, or performance impact during the flush.

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 primary behavior is front-loaded in the first sentence and the exclusion follows. The trailing parenthetical is informative but the 'Bearfort forts:' wording is garbled and the nginx implementation detail could be trimmed without losing agent-relevant meaning.

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 one-parameter, no-output-schema maintenance tool, the essentials are present: what is flushed, what is deleted, and what is deliberately out of scope. Missing are the practical consequences an agent should know before firing a destructive cache operation, such as auth requirements and whether the site is briefly degraded.

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?

Only one parameter, 'site', and the schema describes it at 100% coverage ('Site id (see list_sites)'). The description adds no meaning beyond that, which is the expected baseline when the schema already documents every field.

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 and resource — flush the object cache, delete all transients and site transients — and immediately delimits scope by declaring it does not touch the fronting page cache. Since fort_cache_purge is a sibling, that exclusion is exactly what an agent needs to tell the two apart.

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 when-not is explicit and names the alternative route for the excluded action (manual page-cache purge via the Bearfort API, or automatic purge by bearfort-cache.php). When-to-use is only implied by the verb, and nothing is said about prerequisites or ordering relative to other tools.

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