Skip to main content
Glama

compose_images

Read-only

List images used by each service in a Docker Compose project, showing repository, tag, and container ID for every running service. Use after compose up to verify which image versions are active.

Instructions

List the images used by a compose project's services, parsed from --format json.

Answers "what image and tag does each service container actually run?" - the containers must exist (compose_up first). Use compose_ps for container state and image_list for daemon-wide images. Raises RemoteFailureError if the CLI call fails.

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 services: Restrict to these services (default: all)

Returns: list: One dict per container image (service, container, repository, tag, id, size)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filesNo
servicesNo
project_dirNo
project_nameNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.9.0

TDQS

A5/5.0
Behavior5/5

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

Annotations already mark it read-only and non-destructive, and the description adds meaningful behavior beyond that: it parses --format json, requires containers to exist, raises RemoteFailureError on CLI failure, and explains project_dir copying behavior on remote hosts. This gives the agent a clear behavioral contract.

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 and front-loaded with the core purpose, then uses a compact Args/Returns layout. Every sentence contributes: purpose, usage context, error behavior, parameter semantics, and return shape. There is no filler.

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 covers all essentials: what the tool does, when to use it, prerequisites, failure mode, parameter meanings, and the exact return structure. An agent has everything needed to invoke it correctly.

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 0%, so the description must carry parameter meaning. It does so for all four parameters: project_dir default and remote-copy behavior, files as repeatable -f paths, project_name as override, and services as a restriction with default all. This fully compensates for the empty schema 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?

The description opens with a specific verb and resource: 'List the images used by a compose project's services.' It also clarifies the exact question the tool answers and explicitly distinguishes itself from compose_ps and image_list, making sibling differentiation immediate.

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?

It states when the tool is appropriate, requires containers to exist and compose_up to have been run first, and names alternatives for adjacent concerns: compose_ps for container state and image_list for daemon-wide images. This is explicit when/when-not guidance.

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

Deploy Server

Other Tools