Read module file
read_fileRead a specified file from an npm module or workspace, optionally limited to a line range, to inspect package source code and implementation details.
Instructions
Read a file from a module with optional line range
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": {
"module": "<module>",
"file": "<file>"
},
"name": "read_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | Yes | File path relative to module root | |
| root | No | Project root directory (defaults to cwd) | |
| count | No | Number of lines to read | |
| module | Yes | Module name | |
| startLine | No | Start line (1-based) |