Skip to main content
Glama

End an agent run

gate_revoke_run
DestructiveIdempotent

End one run granted with gate_create_run: its token stops working at once (403 run_revoked) while the app itself keeps working. Use it to stop an agent mid-job; grant a new run with gate_create_run if the work should continue.

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": {
      "project_id": "<project_id>",
      "admin_key": "<admin_key>",
      "run_id": "<run_id>"
    },
    "name": "gate_revoke_run"
  }
}

Input Schema

NameRequiredDescriptionDefault
run_idYesThe run id: run.run_id in gate_create_run's result
admin_keyYesThe project admin key (ga_...). Read it from the .env; never print it.
project_idYesThe project id from gate_create_project, e.g. p1a2b3...

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the destructive/idempotent hints by describing the observable effect (token invalidated immediately, subsequent use yields 403 run_revoked) and the containment boundary (the app keeps working). That is exactly the blast-radius information an agent needs before calling a destructive tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, front-loaded with the action and its effect, with the alternative last. Nothing is wasted, but the description is terse for a destructive, credential-invalidating operation.

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?

With three required params, no output schema, and full schema coverage, the description covers the important unknowns (effect, scope, follow-up). It stops short of saying what a successful call returns or whether the revocation is reversible, which are the remaining gaps.

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% and each parameter already carries its own description, including how to obtain run_id from gate_create_run's result. The description adds no syntax, format, or validation detail beyond what the schema provides, so the baseline 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?

States a specific verb and resource ('End one run'), names the creating sibling gate_create_run, and clarifies the blast radius ('its token stops working at once ... while the app itself keeps working'). This distinguishes it cleanly from gate_revoke_app and gate_revoke_member.

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?

Explicitly gives the use case ('stop an agent mid-job') and the alternative path ('grant a new run with gate_create_run if the work should continue'), so the agent knows both when to call it and what to do instead of calling it.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources