Read a file from a cloned repository
repo_read_fileRead file contents from a previously cloned repository by supplying the clone handle and relative path. Refuses binary files and truncates oversized files.
Instructions
Read a text file from a previously cloned repository (by handle and relative path). Binary files are refused and large files are truncated. Use the handle returned by repo_clone.
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": {
"handle": "<handle>",
"path": "<path>"
},
"name": "repo_read_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Relative path to the file within the repo, e.g. 'kubernetes/apps/cert-manager/helmrelease.yaml'. | |
| handle | Yes | The clone handle from repo_clone. | |
| max_bytes | No | Max bytes to return. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| bytes | Yes | ||
| handle | Yes | ||
| content | Yes | ||
| truncated | Yes |