Skip to main content
Glama

read-file

Read-only

Reads one small file from a specified host and verifies its bytes using size and SHA-256, helping confirm exact file contents for diagnostics or validation.

Instructions

dbabrain common.cli read-file: ONE small file read on its host, its bytes proven by size and sha256 (0.37.0). Request fields (pass them as request):

  • host: Where the file is: {runtime (windows | linux | docker | k8s), access, host, port, username, password | key_file, container, sudo}; left out, this machine.

  • path (required): The one file, in full - never a pattern, a link or a '..' segment.

  • max_bytes: The largest file read; default 1048576, at most 16777216.

  • timeout_seconds: Seconds the host may take; default 120.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "read-file"
  }
}

Input Schema

NameRequiredDescriptionDefault
requestNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, destructiveHint=false and openWorldHint, so safety is covered; the description adds real value beyond them by promising integrity proof (size and sha256), a hard 16 MiB read ceiling and a host-side timeout budget. It does not say what happens on path rejection, checksum mismatch, or missing host permissions, which is the remaining gap for an openWorld tool.

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?

Front-loaded with the core action and integrity guarantee, then a tight bulleted field list that is easy to scan. The trailing version marker '(0.37.0)' is incidental noise that earns no place in a tool description.

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

Completeness4/5

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

With an output schema present, return-value detail is unnecessary, and annotations cover the safety profile; the description fills in the request contract that the schema omits. It is only marginally incomplete on failure modes and credential/permission requirements for the target host.

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

Parameters5/5

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

Schema description coverage is 0% and the schema is only a generic 'request' object, so the description must do all the work, and it does: it enumerates the host object's sub-fields (runtime/access/host/port/username/password|key_file/container/sudo), marks path required with format constraints, and gives defaults and upper bounds for max_bytes and timeout_seconds.

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 and resource ('read-file: ONE small file read') plus the distinctive guarantee that the result is verified by size and sha256, and bounds the scope (one file, no patterns, links or '..'). It does not name or contrast any sibling such as fetch-file or pull-file, so sibling differentiation is left to inference.

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?

Implied usage is clear from 'ONE small file' and the max_bytes ceiling, which signals this is not for bulk transfers or large artifacts. However, there is no explicit when-to-use/when-not statement and no routing to alternatives like fetch-file or pull-file for remote or bulk cases.

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

Deploy Server

Other Tools