github_get_file
Retrieve file contents from a GitHub repository by specifying owner, repo, path, and an optional branch, tag, or commit ref.
Instructions
读取仓库中的文件内容。
Args: owner: 仓库拥有者。 repo: 仓库名称。 path: 文件路径,例如 src/main.py。 ref: 分支、标签或 commit SHA;留空使用默认分支。
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": {
"owner": "<owner>",
"repo": "<repo>",
"path": "<path>"
},
"name": "github_get_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | ||
| path | Yes | ||
| repo | Yes | ||
| owner | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |