Skip to main content
Glama

guard_verify

Destructive

Runs a shell command and records its outcome as verifiable evidence, so agents can cite an evidence ID before claiming a check passed.

Instructions

Run a shell command and record the outcome as evidence.

Use it before claiming a check passed, and cite the returned evidence id. Do not use it to retry a command that guard_loop_check already says will be blocked. command is a required string and runs verbatim (shell=True) with the caller's privileges; stdin is closed. timeout_s is an int, default 180, clamped to 1–900. It returns a text report: on a real run, PC verify ev-NNNN · exit N · ok|FAIL|UNTRUSTED · <ms>ms, plus cwd, the command, a digest or failure tail, and a Nudge. Exit 0 from a pipeline (no pipefail) or a failure mask such as || true is labelled UNTRUSTED and is not proof. A blocked loop returns PC verify blocked and does not add a ledger row. Nonzero exits are recorded, not raised. Side effects: the command itself can change files, the network, or anything else the shell can do. A run that is not blocked appends one row to .agent-guard/verify_runs.jsonl and creates the store if needed. The loop-brake check can also seed config.json.

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": "guard_verify"
  }
}

Input Schema

NameRequiredDescriptionDefault
commandYesShell command to run and record, as one string (pipes and quotes included). Required. Executed with the caller's privileges via the shell; this is not a sandbox. A blank string returns an error line and records nothing.
timeout_sNoSeconds before the child is killed. Integer. Default 180. Clamped to 1–900; a timeout is recorded as exit 124, not raised.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv3.3.1
    • addedInput schema / properties / command / description
      Added value: +"Shell command to run and record, as one string (pipes and quotes included). Required. Executed with the caller's privileges via the shell; this is not a sandbox. A blank string returns an error line and records nothing."
    • addedInput schema / properties / timeout_s / description
      Added value: +"Seconds before the child is killed. Integer. Default 180. Clamped to 1–900; a timeout is recorded as exit 124, not raised."
  2. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare destructive/openWorld/not-idempotent, and the description goes well beyond them: the command runs verbatim via `shell=True` with caller privileges, stdin is closed, timeouts are clamped and recorded as exit 124 rather than raised, exit 0 from a pipeline or `|| true` is labelled UNTRUSTED, and blocked loops add no ledger row. It also discloses persistent side effects — an appended row in `.agent-guard/verify_runs.jsonl` and possible seeding of `config.json`.

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 opening sentence is front-loaded and every clause about UNTRUSTED status and blocked loops carries operational weight. It is dense and slightly long, and it repeats schema-level parameter facts and return-format detail that arguably belong to the output schema, but there is little pure filler.

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?

For a high-risk, side-effecting tool, the description covers execution semantics, failure labelling, ledger persistence, and non-raising nonzero exits, which is what an agent needs to call it safely. Although an output schema exists, the inline report format and the UNTRUSTED distinction add interpretation the schema alone would not convey.

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%, so `command` and `timeout_s` are already documented in structured fields, and the description largely restates them (required string, default 180, clamped 1–900). It adds a small amount of genuinely new meaning — stdin closed, blank string returns an error and records nothing — but that is marginal over the schema, so the baseline of 3 applies.

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 opens with a specific verb+resource: run a shell command and record the outcome as evidence. It also distinguishes itself from the named sibling by warning against retrying what `guard_loop_check` already blocks, so an agent can tell the two apart without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives both a positive trigger (use before claiming a check passed, then cite the returned evidence id) and an explicit exclusion (do not use it to retry a command `guard_loop_check` says will be blocked), naming the alternative. That is a full when/when-not/alternative rule set.

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