read_file
Reads a bounded UTF-8 text file or specific line range, providing structured line metadata for precise content access.
Instructions
Read a bounded UTF-8 text file or 1-based line range with structured line metadata. Use shell tools for binary or very large files.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>"
},
"name": "read_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Base directory. Defaults to the agent user home directory. | |
| path | Yes | File path. Relative paths are resolved against cwd. | |
| endLine | No | Inclusive last line to return. | |
| startLine | No | First line to return, using 1-based indexing. |