Skip to main content
Glama

volume_prune

DestructiveIdempotent

Remove unused Docker volumes not referenced by any container. Optionally filter by label or include all volumes to reclaim disk space.

Instructions

Remove volumes not referenced by any container, running or stopped.

A volume used by even one stopped container is not "unused" and survives the prune — remove the container first (or use container_prune, then this) to reclaim its volumes. Valid filter keys: label (key or key=value), all ("true" as a string — without it only anonymous volumes are eligible, matching docker volume prune's default). Use volume_list first to see what currently exists.

args: filters - Narrow which unused volumes to remove; omit to remove all anonymous ones returns: dict - {"VolumesDeleted": [...], "SpaceReclaimed": }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filtersNo
Behavior4/5

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

Annotations indicate destructive and idempotent. Description adds specifics: only unused volumes are removed, anonymous vs named volume behavior with the 'all' filter, and return format.

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?

Well-structured with clear sections, but slightly verbose. Every sentence adds value, but could be slightly more concise.

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?

Covers all aspects: purpose, usage, parameters, return type, and references sibling tools. No output schema needed since description explains return dict.

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?

Despite 0% schema coverage, the description explains the 'filters' parameter in detail: valid keys (label, all), value format, and default behavior. It compensates fully for the sparse schema.

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 the tool removes volumes not referenced by any container, running or stopped, and explains what counts as 'unused'. This distinguishes it from volume_remove and container_prune.

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 advises to remove the container first or use container_prune before this tool to reclaim volumes, and suggests using volume_list first to see existing volumes.

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