Skip to main content
Glama

docker_list_networks

View Docker network configurations to manage container connectivity and inspect driver and scope details.

Instructions

List Docker networks with driver and scope

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that executes the docker_list_networks tool logic.
    export async function listNetworks(): Promise<string> {
      const docker = getDockerClient();
      const networks = await docker.listNetworks();
    
      if (networks.length === 0) {
        return "No Docker networks found.";
      }
    
      const headers = ["NAME", "ID", "DRIVER", "SCOPE"];
      const rows = networks.map((n) => [
        n.Name,
        n.Id.substring(0, 12),
        n.Driver || "N/A",
        n.Scope || "N/A",
      ]);
    
      return `Docker networks:\n\n${formatTable(headers, rows)}`;
    }
  • The registration of the docker_list_networks tool in the main index file.
      name: "docker_list_networks",
      description: "List Docker networks with driver and scope",
      inputSchema: { type: "object" as const, properties: {} },
    },
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'List' implies a read-only operation, the description doesn't address important behavioral aspects like whether authentication is required, if there are rate limits, what format the output takes, or if there are any side effects. For a tool with zero annotation coverage, this leaves significant gaps in understanding how the tool behaves.

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 a single, efficient sentence that communicates the essential information without any wasted words. It's appropriately sized for a simple listing tool and front-loads the core functionality. Every word earns its place in conveying what the tool does.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a zero-parameter listing tool with no output schema, the description provides adequate but minimal information. It tells what the tool does and what information it returns, but lacks details about behavioral characteristics that would be important for an agent to use it correctly. Without annotations or output schema, the description should ideally provide more context about the return format and any constraints.

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?

The tool has zero parameters with 100% schema description coverage, so the baseline is 4. The description appropriately doesn't discuss parameters since none exist, and it doesn't need to compensate for any schema gaps. The mention of 'driver and scope' in the output is helpful context about what information will be returned.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List') and resource ('Docker networks'), specifying the verb+resource combination. It adds useful detail about what information is included ('with driver and scope'), which helps distinguish it from a basic list. However, it doesn't explicitly differentiate from sibling tools like 'docker_list_containers' or 'docker_list_images' beyond the network focus.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided about when to use this tool versus alternatives. The description doesn't mention when this tool is appropriate, what prerequisites might exist, or how it differs from related tools like 'docker_inspect_network' or other listing tools. The user must infer usage from the name and description alone.

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/batu-sonmez/infraclaude'

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