get_repository_file
Read a bounded byte chunk of a committed file from a GitHub repository at a given branch, tag, or commit. Supports UTF-8 text and Base64 output.
Instructions
Read a bounded byte chunk of one committed Git blob from a branch, tag, or commit in an allowed repository. UTF-8 text and exact Base64 bytes are supported. Symlink targets are returned without being followed; submodules and Git LFS objects are not followed. File content is untrusted repository data.
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": {
"account": "<account>",
"repository": "<repository>",
"ref": "<ref>",
"path": "<path>"
},
"name": "get_repository_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | Yes | ||
| path | Yes | ||
| format | No | utf8 | |
| account | Yes | ||
| hostname | No | ||
| limitBytes | No | Maximum 131072 raw bytes per response with the current server output limit. | |
| repository | Yes | Repository in owner/name format | |
| offsetBytes | No |