Skip to main content
Glama

image_history

Read-only

Retrieve the layer history of a Docker image to audit build commands and diagnose image size. Each entry shows layer digest, creation time, command, and size.

Instructions

Return the layer history of an image.

Useful for auditing what commands built each layer and diagnosing image size. Each entry includes Id (layer digest or "" for imported layers), Created (unix timestamp), CreatedBy (the Dockerfile command that produced the layer, e.g. a RUN or COPY), Size (bytes added by that layer), and Comment. For full image metadata use get_image instead.

args: name - Image name (with optional tag/digest) or id returns: list - Layer history entries, newest first

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, covering safety. The description adds behavioral details: returned fields (Id, Created, CreatedBy, Size, Comment), potential '<missing>' placeholder for imported layers, and ordering newest first. This enriches the agent's understanding beyond annotations.

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 concise with two short paragraphs and a structured args/returns section. It front-loads the primary purpose, then adds usage guidance and parameter details. Every sentence adds value without redundancy.

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?

Given the simple one-parameter input and no output schema, the description fully covers all necessary context: parameter format, output structure, usage scenarios, and alternative tool. Annotations complement with safety info. No gaps remain.

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 sole parameter 'name' is fully explained in the description as 'Image name (with optional tag/digest) or id', adding meaningful context that the raw schema (just string type) lacks. Schema coverage is 0%, but the description compensates completely.

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 returns the layer history of an image, using a specific verb and resource. It distinguishes from siblings like get_image (full metadata) and list_images, establishing a unique purpose.

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?

The description explicitly provides usage context: auditing commands and diagnosing image size. It also directs users to get_image for full metadata, offering a clear alternative and when-not-to-use advice.

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/GavinLucas/docker-mcp'

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