Skip to main content
Glama

execute_openocd_command

Runs an allowlisted OpenOCD Tcl command to inspect or control a debug target, requiring explicit user approval before destructive actions like flash erase or programming.

Instructions

Execute one allowlisted OpenOCD Tcl command.

Set user_approved=true only after the user has explicitly approved a potentially destructive operation such as flash erase/programming.

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": {
      "command": "<command>"
    },
    "name": "execute_openocd_command"
  }
}

Input Schema

NameRequiredDescriptionDefault
commandYes
user_approvedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

B3.1/5.0
Behavior3/5

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

With no annotations at all, the description carries the full burden and does disclose two important traits: commands are restricted to an allowlist, and some operations are destructive. It does not say what happens if user_approved is false for a destructive command, whether approval is enforced server-side, or anything about timeouts or failure modes.

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?

Two short sentences with the core capability front-loaded and the approval caveat immediately after. No filler, though the line break mid-sentence is slightly awkward rather than harmful.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no annotations, no output schema, and zero schema descriptions, the definition is thin: it does not describe the return value, error behavior, or how an agent should discover valid command strings. The approval gate is covered, but the surrounding context an agent needs to call this correctly is not.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must supply parameter meaning. It does well for user_approved, tying it to explicit user consent for erase/programming, but says almost nothing about the required `command` parameter: no format example, no escaping or namespacing hint, and no pointer on where the allowlist can be inspected.

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?

"Execute one allowlisted OpenOCD Tcl command" gives a concrete verb (execute), resource (OpenOCD Tcl command), and two scoping constraints: a single command per call, and only commands on an allowlist. This separates it from discovery-oriented siblings like search_openocd_commands and from the higher-level flash helpers, though it never names an alternative explicitly.

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?

The second sentence gives real when-to-use guidance, but only for the user_approved flag: set it after explicit approval for destructive operations such as erase or programming. There is no guidance on when to reach for this raw-command tool versus dedicated siblings like flash_elf or start_openocd, and nothing on how to find which commands are allowed.

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