Skip to main content
Glama

Read file

read_file
Read-only

Read one file from a project and return its full contents.

read_files reads up to 20 files in one call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_pathYesPath relative to project root
project_nameYesName of the project

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, covering the non-mutating nature. The description adds useful context that the full file contents are returned, suggesting no truncation or pagination. However, it does not cover details such as file size limits, encoding, or error behavior, but this is acceptable given the simple read operation and existing annotation coverage.

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?

Two sentences, no wasted words. The primary purpose is front-loaded, and the sibling differentiation appears immediately after. Every sentence earns its place.

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

Completeness5/5

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

For a simple single-file read operation, the description covers the core behavior and differentiates from the batch sibling. Annotations provide the read-only safety profile, the schema fully documents both parameters, and an output schema exists, so nothing essential is missing for an agent to select and invoke this tool correctly.

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

Parameters3/5

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

Schema description coverage is 100%: file_path is defined as 'Path relative to project root' and project_name as 'Name of the project'. The description adds no additional parameter-level meaning beyond the schema, so the baseline score of 3 is appropriate.

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?

States the specific action 'Read one file from a project' and the result 'return its full contents'. It clearly distinguishes itself from the sibling read_files by explicitly noting that a single file is read, and the second sentence highlights the sibling's batch capability.

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

Usage Guidelines4/5

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

The second sentence, 'read_files reads up to 20 files in one call', provides clear context about the alternative tool and implies when read_file is appropriate (single file) versus read_files (multiple files). It stops short of an explicit 'use read_files when you need more than one file', but the guidance is easy to infer.

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