Skip to main content
Glama

compose_down

Destructive

Stops and removes Docker Compose containers, networks, and optional volumes to clean up a compose project.

Instructions

Stop and remove containers, networks (and optionally volumes) for a compose project.

Inverse of compose_up. Images are kept; named volumes go only with volumes=True (destructive). Use compose_stop to stop without removing anything. Does not raise on a non-zero CLI exit — inspect returncode/stderr in the result.

args: project_dir - Dir with the compose file (default: server cwd; copied to the target host if no local plugin) files - Explicit compose file paths (repeatable, -f) project_name - Compose project name override profiles - Profiles to consider volumes - Also remove named volumes declared by the project (destructive) remove_orphans - Remove containers not declared in the compose file timeout_seconds - Subprocess timeout (default 300s) returns: dict - {"returncode": int, "stdout": str, "stderr": str, "truncated": bool}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filesNo
volumesNo
profilesNo
project_dirNo
project_nameNo
remove_orphansNo
timeout_secondsNo
Behavior5/5

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

Goes well beyond the destructiveHint annotation by specifying that images are kept, named volumes are only removed with the volumes flag, and that the tool does not raise on non-zero CLI exit (requiring inspection of returncode/stderr). These are non-obvious behavioral traits that an agent needs to know.

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 well-structured: a clear opening line, a usage comparison, a key behavioral note, and a compact bulleted parameter list. Every sentence adds value and there is no redundancy; the length is justified by the number of parameters and the need to clarify destructive behavior.

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?

Despite having no output schema, the description explicitly documents the return format as a dict with returncode, stdout, stderr, and truncated. It covers all 7 parameters, the destructive semantics, and the error behavior, making the tool fully self-contained for an agent to use safely.

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?

The input schema has 0% description coverage, but the description compensates fully by explaining every parameter: project_dir, files, project_name, profiles, volumes, remove_orphans, and timeout_seconds. Each parameter gets a concise one-line semantic explanation, which is critical for correct invocation.

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 clearly states 'Stop and remove containers, networks (and optionally volumes) for a compose project' and identifies it as the inverse of compose_up. It names the exact resource (compose project) and actions, making it easy to distinguish from sibling tools like compose_stop and compose_restart.

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?

Provides explicit guidance: 'Use compose_stop to stop without removing anything' and notes that volumes are only removed with volumes=True. This clearly tells the agent when to choose this tool versus alternatives, which is exactly what usage guidelines should do.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/L337-org/docker-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server