Skip to main content
Glama
Akxan
by Akxan

List a directory in GitHub

github_list_dir
Read-onlyIdempotent

List files and folders in a GitHub repository directory, including name, type, size, and SHA. Use it to audit repository structure and locate files for technical SEO tasks.

Instructions

List files and folders at a path in a repository (name, type, size, sha).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
refNo
pathNo
repoYesRepository as 'owner/name', e.g. 'octocat/my-site'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.1
    • removedInput schema / additionalProperties
      Removed value: -false
  2. First observedv0.3.0

TDQS

A3.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and non-destructive behavior. The description adds useful context beyond those annotations by naming the exact output fields (name, type, size, sha) and clarifying that it lists both files and folders at a given path. This is meaningful but not extensive.

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 a single, front-loaded sentence with no filler. Every part contributes meaning: the action, the resource, and the response fields. It is appropriately sized for a simple listing tool.

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?

The description is adequate for a basic call with just 'repo', and the output fields are mentioned. However, it omits key context such as what 'ref' means, how 'path' behaves when omitted, and any pagination or default-branch behavior. Since there is no output schema, those details would materially improve completeness.

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 33%, and the description does not compensate for the undocumented optional parameters. In particular, 'ref' is not explained as a branch/tag/commit SHA, and 'path' semantics are only vaguely implied by 'at a path'. The description adds little value beyond the parameter names themselves.

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 clearly states the verb ('List') and resource ('files and folders at a path in a repository'), and includes the returned metadata fields. It does not explicitly differentiate from siblings like github_get_file, though the listing-vs-content distinction is reasonably implicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies when to use it — when you need a directory listing — but gives no explicit guidance about when not to use it or which sibling tool might be a better fit. An agent can infer usage, but the description leaves that inference unstated.

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