Skip to main content
Glama

docker/networks

Read-onlyIdempotent

List Docker networks with driver, scope, subnet, gateway, and attached containers. Filter by name pattern or driver; output as text, JSON, YAML, or table.

Instructions

Lists Docker networks (not the host's: for host interfaces and routes use the network:// resources and network/* tools) with driver, scope, subnet, gateway and the containers attached with their addresses. Read-only. pattern is a glob on the name; driver an exact driver (bridge, host, none, overlay, macvlan). Text shows Attached: (nothing) for an empty network; output_format: json (also yaml/table/wide) returns an array of objects (name, id, full_id, driver, scope, created, internal, attachable, ingress, ipam_driver, subnets, gateways, containers, options, labels). Removing unused networks is docker/prune (target networks); one network's full detail is the docker-network://<name>/inspect resource. Always runs as root: no privileged argument, refused unless the grant has allowed: true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
driverNoOnly networks using this driver (bridge, host, none, overlay, macvlan, ...)
patternNoOnly networks whose name matches this glob (e.g. 'app-*')
output_formatNoUse json for structured output (yaml, table and wide return the same JSON); default is text

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.4.1

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnly/destructive/idempotent/openWorld, so the safety profile is covered. The description adds context beyond them: the root-execution requirement, refusal unless the grant has `allowed: true`, and the text-mode rendering (`Attached: (nothing)` for empty networks). These are genuine behavioral details, though return-shape nuances could be richer.

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?

Dense but front-loaded: purpose and scoping lead, then outputs, then sibling routing. Nearly every sentence earns its place, though the single long paragraph packs many clauses and could be slightly tighter.

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?

There is no output schema, yet the description enumerates the JSON object fields (name, id, full_id, driver, scope, created, internal, attachable, ingress, ipam_driver, subnets, gateways, containers, options, labels), so the agent knows the return shape. Combined with sibling routing and auth requirements, nothing essential is missing.

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 real meaning: `pattern` is a glob on the name, `driver` is an exact driver match with valid values (bridge, host, none, overlay, macvlan), and it documents what `output_format: json` returns. This goes beyond the schema's own descriptions.

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 ('Lists Docker networks') and enumerates exactly what is returned: driver, scope, subnet, gateway, and attached containers with addresses. It actively distinguishes itself from the host-interface siblings (`network/*`, `network://`) and other docker tools, so an agent can identify it without opening the schema.

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 routes the agent: host interfaces/routes go to `network://` resources and `network/*` tools, unused-network removal is `docker/prune` (target `networks`), and single-network detail is the `docker-network://<name>/inspect` resource. When-to-use and when-not-to-use are both spelled out.

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