Skip to main content
Glama

analyze_plugin

Analyze a WordPress plugin directory to detect security gaps, header issues, cleanup omissions, hook problems, translation-readiness gaps, REST permission flaws, and dangerous function usage.

Instructions

Analyze a WordPress plugin directory for best practices and issues. Checks: plugin header, security (escaping, sanitization, nonces, capabilities), uninstall cleanup, activation/deactivation hooks, translation-readiness, REST API permission callbacks, dangerous function usage.

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": {
      "pluginPath": "<pluginPath>",
      "conversationId": "<conversationId>"
    },
    "name": "analyze_plugin"
  }
}

Input Schema

NameRequiredDescriptionDefault
pluginPathYesAbsolute path to the WordPress plugin directory.
conversationIdYesThe conversation ID obtained from learn_wordpress_api.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.2/5.0
Behavior2/5

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

With no annotations, the description carries the full disclosure burden. It usefully enumerates what is inspected, but never says whether the scan is read-only, whether anything on disk is modified, how findings are reported (severity, pass/fail, line numbers), or what happens when pluginPath is invalid — all material for an agent deciding to call a filesystem-scanning tool.

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 core action in the first clause, then a compact enumeration of check categories. No filler sentences, though the check list is dense and could be slightly tightened.

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?

There is no output schema and no annotations, so the description should say more about the shape of results and side effects than it does. It is adequate for understanding the scope of the audit but leaves an agent guessing about result format and whether the scan is purely read-only.

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 both parameters (pluginPath, conversationId) are already documented, including the note that conversationId comes from learn_wordpress_api. The description adds no parameter-level meaning such as whether nested plugin paths, symlinks, or non-plugin directories are accepted. Baseline 3 applies.

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 verb ('Analyze') and resource ('a WordPress plugin directory') and enumerates the exact check categories (headers, escaping/sanitization/nonces/capabilities, uninstall cleanup, hooks, i18n, REST permission callbacks, dangerous functions). This clearly separates it from analyze_theme and validate_php, but it never explicitly contrasts itself with those siblings.

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?

Usage is only implied: an agent infers it should call this when it has a plugin directory to review. There is no statement of when NOT to use it versus validate_php or analyze_theme, and no mention of the prerequisite chain (conversationId from learn_wordpress_api) that appears only in the schema.

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