Skip to main content
Glama

list_files

List the contents of a directory within a workspace to inspect project files and subdirectories, with options for recursive traversal and entry limits.

Instructions

List a directory's contents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoDefault/max 500 entries
dirPathYes
recursiveNo
workspaceNoWorkspace name (not id) - created automatically if it doesn't exist yet. Defaults to "default".

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.3.0

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It only says 'List,' which implies a read operation, but it does not disclose that the workspace is created automatically if it does not exist, nor does it mention recursive behavior, sorting, hidden files, or the return format.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single front-loaded sentence with no wasted words, but it is under-specified for a tool with four parameters. Brevity is good, but here it crosses into sparse rather than appropriately concise.

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?

There is no output schema and no annotations, so the description needs to be more complete. It omits return value expectations, recursive semantics, and the workspace auto-creation side effect. The schema partially documents limit and workspace, but overall the description is not sufficient for reliable invocation.

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 only 50%, so the description should compensate for undocumented parameters. It does not explain dirPath beyond implying it is a directory, and it gives no meaning for the recursive boolean. The only parameter-related value is the phrase 'directory's contents,' which weakly maps to dirPath.

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 uses a specific verb and resource: 'List a directory's contents.' This clearly distinguishes the tool from siblings like list_workspaces, list_knowledge, and read_file, which operate on different resource types. The core purpose is immediately understandable.

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?

The description gives no guidance on when to use this tool versus alternatives such as read_file or list_workspaces. There is no mention of when recursion should be enabled, how this relates to workspaces, or any exclusions.

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