Skip to main content
Glama

stop_process

Destructive

Stop a process by PID or the one listening on a port: asks it to exit, then kills it after 5 seconds; use dry_run to preview.

Instructions

Stop the process listening on a port, or a process by PID: asks it to exit, then kills it after 5 s. Refuses system processes and the assistant itself. Ports published by Docker, Podman or WSL report the command to run instead. Use dry_run to see what would be stopped, and check_port first to tell the user what it is.

Input Schema

NameRequiredDescriptionDefault
pidNostop this process
portNostop what listens on this port
forceNokill at once instead of asking it to exit first
dry_runNoonly report what would be stopped

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Adds substantial behavior beyond the destructiveHint annotation: a two-phase termination (graceful request, then kill after 5 s), a self-protection guard, and the notable edge case that Docker/Podman/WSL-published ports return a command to run instead of being killed. That last detail materially changes what the agent should expect on failure.

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

Conciseness5/5

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

Four short sentences, front-loaded with the core action and target options, then escalation, refusals, container caveat, and safety workflow. No filler and no repetition of the annotation fields.

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?

No output schema exists, and the description covers most of what matters for a destructive tool: escalation, refusal conditions, and the notable container case. It does not describe the return payload for a successful stop (e.g., PID/process name reported), which is the only real gap.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3, but the description adds the escalation timing behind `force` (5 s grace period) and frames `dry_run` as a preview workflow, which the schema only states as 'only report what would be stopped'. Small but genuine added meaning.

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 (stop) and resource (a process), plus the two ways to target it (port or PID). This is clearly distinct from the read-only siblings like list_ports and check_port, which the description positions as a prior inspection step.

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?

Gives explicit workflow guidance: use dry_run to preview what would be stopped, and run check_port first to identify the process before stopping it. It also states hard exclusions (system processes and the assistant itself are refused), so the agent knows when this call will decline.

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