Skip to main content
Glama

Read files in a GitHub repository

gh_read
Read-onlyIdempotent

Read a file, list a folder, or with recursive true list every file below a path, at a branch, tag or commit (default branch when ref is left out).

Input Schema

NameRequiredDescriptionDefault
refNo
pathNoFile or folder; empty for the top.
repoYesowner/name, like shopwhizzy/client-shop (or a GitHub address).
recursiveNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already carry readOnly, idempotent, openWorld and non-destructive. The description adds behavior beyond them: ref may be a branch, tag or commit, and omitting ref resolves to the default branch, which is genuine context an agent needs to predict results.

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 dense sentence, front-loaded with the primary action and then the modifiers. It reads slightly packed but no clause is redundant.

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?

No output schema exists, so the description should hint at what comes back (raw file content vs a listing shape, treatment of binary files, truncation on large files). It is adequate for calling the tool correctly but leaves the return shape entirely unspecified.

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

Parameters4/5

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

Schema coverage is only 50% — ref and recursive have no schema descriptions — and the description compensates by defining ref's accepted forms and what recursive=true enumerates. repo/path semantics are already in the schema, so this is solid-but-not-complete supplementation.

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 concrete verbs and resources: 'read a file, list a folder', plus the recursive variant and the ref scope. That distinguishes it from nearby write-side siblings (write_file, git_push), though it never contrasts with same-named alternatives such as read_file or gh_repo.

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 three modes (file read / folder list / recursive listing) imply when to use the tool and when to pass recursive, and the default-branch fallback is stated. There is no explicit guidance on alternatives or preconditions such as auth or repo access.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources