code_get_files
Get contents of multiple files from a remote public git repository in a single call. Reduces round-trips when you need to read several related files. Max 10 files per batch, 5000 total lines budget across all files. Each file supports optional line ranges. Failed files return per-file errors without blocking other 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": {
"repository": "<repository>",
"paths": "<paths>"
},
"name": "code_get_files"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| paths | Yes | List of files to read. Each entry has a path and optional line range. | |
| max_lines | No | Per-file safety cap on lines returned (cap: 2000). | |
| repository | Yes | Full git URL of ONE public remote repository, e.g. "https://github.com/redis/redis". Required. There is no cross-repository or global search: this API analyses one repository per call, cloning it on demand. Wildcards and placeholders ("*", "all", "global", a bare host like "github.com") are rejected — if you do not have a specific repository URL, ask for one rather than guessing. |