Skip to main content
Glama

get_container_logs

Read-only

Retrieve recent stdout/stderr log lines from a container by ID to diagnose issues quickly. Specify line count and timestamps as needed.

Instructions

Get recent log lines from a container's stdout/stderr output.

Input Schema

NameRequiredDescriptionDefault
linesNoNumber of log lines to retrieve, max 1000, default 100
timestampsNoInclude timestamps in log output
container_idYesInternal container ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.10.1

TDQS

B3.3/5.0
Behavior3/5

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

readOnlyHint=true already tells the agent this is a safe non-mutating read, and the description is consistent with that. It adds the useful scope detail that output comes from stdout/stderr and is 'recent' only, but says nothing about behavior on stopped containers, truncation at the 1000-line cap, or error cases.

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?

A single front-loaded sentence naming verb, resource, and source stream, with zero filler. Nothing could be cut without losing information.

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 simple 3-parameter read tool with full schema coverage and a readOnly annotation, the description covers the essentials. It is thin on operational context (container state requirements, output format tied to timestamps) that would let an agent call it confidently the first time.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so lines, timestamps, and container_id are already fully documented with defaults and bounds. The description's only added signal is 'recent', which loosely reinforces the lines default rather than extending parameter meaning.

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?

States a specific verb ('Get') and resource ('log lines from a container's stdout/stderr'), which clearly separates it from get_container (metadata) and list_containers. It stops short of explicitly naming a sibling to contrast with, so it lands at 4 rather than 5.

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?

There is no statement of when to use this versus get_container or list_containers, nor any prerequisites (e.g. container must exist/running). The word 'recent' weakly implies a tail-style read, but the agent must infer the use case entirely.

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