Skip to main content
Glama

file_read

Read a file's contents from an OpenWrt router over SSH. Use offset and limit to read large files in chunks; returns total lines and size.

Instructions

Read the contents of a file on the OpenWrt router. For large files, use offset and limit to read in chunks. Returns file metadata (total lines and size) alongside content.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute path to the file on the router
limitNoNumber of lines to read from offset. Omit to read to end of file. Recommended: 200 for large files.
linesNo(Legacy) Number of lines to read from the end of file (tail). Use offset/limit instead.
offsetNo1-indexed starting line number. Omit to start from beginning.
Behavior3/5

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

The description discloses a key behavioral trait: it returns file metadata (total lines and size) alongside content, which goes beyond a simple read. It also explains chunked reading. However, with no annotations provided, the description carries the full burden, and it does not mention potential side effects, safety guarantees (like read-only certainty), error cases, or performance implications, leaving some gaps.

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 exceptionally concise: two sentences that front-load the purpose and immediately provide actionable large-file guidance. Every word contributes, with no redundancy or filler.

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?

Given the relatively simple use case and the fully described schema, the description is mostly complete. It covers reading, chunking, and the metadata return. It does not mention the legacy 'lines' parameter or explicitly compare with file_read_batch, but these are covered by the schema and sibling names. It is adequate for selecting and invoking the tool.

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 description coverage is 100%, so the baseline is 3. The description adds value by explicitly framing offset and limit as a chunking mechanism for large files, which is not fully explicit in the schema. It reinforces the intended usage pattern, earning a 4.

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 ('Read') and a specific resource ('file on the OpenWrt router'), clearly distinguishing it from siblings like file_write, file_list, or file_read_batch. It also adds a unique detail about reading large files in chunks, reinforcing its identity.

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?

It provides clear usage context by advising to use offset and limit for large files to read in chunks, which is a practical guideline. However, it does not explicitly mention alternatives (e.g., when to use file_read_batch instead) or exclusionary conditions, keeping it from a 5.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/haode01/openwrt-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server