Skip to main content
Glama

list_directory

Read-onlyIdempotent

Lists files and folders in a specified absolute local directory with bounded depth and result limits, helping agents inspect project structure safely.

Instructions

List a bounded absolute local directory.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
depthNo
limitNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.2

TDQS

B3/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false, and openWorldHint=false, so the safety profile is fully covered by structured data. The description adds the 'absolute path' requirement and hints that results are bounded, but says nothing about pagination, truncation behavior, or what happens when depth/limit are hit.

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?

A single front-loaded sentence with no filler. It is efficient, though the brevity shades into under-specification rather than tight editing.

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?

An output schema exists, so return-value explanation is not required, and annotations cover the safety posture. Still, for a 3-parameter tool with 0% schema coverage and no usage guidance, an agent lacks enough to call depth/limit intelligently; 'absolute' and 'bounded' partially compensate.

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

Parameters2/5

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

Schema description coverage is 0% and the description does not compensate: depth (default 2) and limit (default 200) are never explained, nor is 'path' defined beyond the implicit absolute-path constraint. 'Bounded' gestures at the two numeric params but gives no semantics for them.

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 gives a specific verb and resource ('List ... directory') and adds meaningful qualifiers: absolute path requirement and 'bounded' enumeration. It does not, however, differentiate itself from sibling navigation tools like read_file or search_code, so it falls short of a 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 tool versus read_file or search_code, and no mention of prerequisites or exclusions. The agent is left to infer that listing a directory is the right choice for inspecting a folder's contents.

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