Skip to main content
Glama

list_directory

Lists the immediate files and subfolders inside a specified directory, helping AI agents inspect folder contents before taking further action.

Instructions

List the immediate files and subfolders inside a directory.

Input Schema

NameRequiredDescriptionDefault
pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.5.3

TDQS

C2.8/5.0
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 disclosure burden. "Immediate" usefully pins down non-recursion, but nothing is said about hidden files, symlink handling, permission errors on unreadable directories, ordering, or whether results are paginated — all real concerns for a filesystem listing tool.

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 with no filler, and the key scoping constraint ("immediate") appears before the resource is named.

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

Completeness2/5

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

With no annotations and no output schema, the description is the only disclosure channel, yet it never says what the result looks like — plain names, full paths, typed entries, sizes? For a listing tool, the return shape is exactly what an agent needs to plan a follow-up call.

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 coverage is 0% and the sole parameter 'path' is entirely undocumented in the schema. The description only implies it is a directory path; it says nothing about absolute vs relative paths, home expansion, or what happens on an invalid path, so it fails to compensate for the coverage gap.

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 (list) and resource (files and subfolders), with the qualifier "immediate" that signals non-recursive behavior. It does not name the sibling directory_tree, which is the tool an agent would need to contrast with for recursive traversal.

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 explicit when-to-use or when-not-to-use guidance, and no prerequisites (does the path need to exist? absolute or relative?). The word "immediate" hints at the boundary versus directory_tree, but the agent must infer that rather than being told.

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