Skip to main content
Glama
docker-mcp
by falkenslab

Remove a container

remove_container
DestructiveIdempotent

Deletes a Docker container, optionally stopping it first and removing anonymous volumes, after confirming the destructive action.

Instructions

Remove a container, with force to stop it first if it's running, and with volumes to remove its anonymous volumes. Its data is gone. The server asks the person to confirm it, naming what goes; if they say no, nothing is done.

Input Schema

NameRequiredDescriptionDefault
forceNo
volumesNo
containerYesThe container's name or id, as its list gives it

Output Schema

NameRequiredDescriptionDefault
removedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the destructiveHint annotation, the description discloses that data is permanently gone and that the server asks the person to confirm, naming what will be removed, with no action if they decline. It also clarifies that force stops a running container first and volumes removes anonymous volumes.

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?

The description is front-loaded with the action, then covers the two flags, the destructive consequence, and the confirmation flow in a compact sequence. Every sentence adds useful information.

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?

Annotations already declare the destructive, non-read-only, idempotent behavior, and an output schema exists. The description completes the picture by explaining data loss, flag semantics, and the interactive confirmation safeguard.

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

Parameters5/5

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

Schema description coverage is only 33%, so the description carries important parameter meaning. It explains the two boolean options precisely: force stops a running container before removal, and volumes removes anonymous volumes.

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 states a specific verb and resource: remove a container. It is clearly distinct from sibling removal tools such as remove_network, remove_image, and remove_volume because the resource is named 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?

It explains what force and volumes do, which implies when those flags are useful, but it never states when to use remove_container instead of alternatives like stop_container. Usage is implied by the removal action rather than explicitly guided.

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