code
Inspect source files structurally: outline functions, classes, and types with line numbers, list imports, find TODO/FIXME markers, and count lines by language.
Instructions
Structural views of source code: outline (functions, classes, types in a file, with line numbers — read this before reading the file), imports (what a file depends on), todos (TODO/FIXME/HACK/XXX across the tree), stats (lines of code by language).
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": {
"action": "<action>"
},
"name": "code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| glob | No | todos/stats: restrict to these globs. | |
| path | No | outline/imports: the file. todos/stats: directory to scan. Default: server cwd. | |
| tags | No | todos: which markers to look for. Default TODO, FIXME, HACK, XXX, BUG. | |
| limit | No | todos: max results. Default 100. | |
| action | Yes | Which view. | |
| max_bytes | No | Byte cap on returned output. | |
| max_depth | No | todos/stats: recursion depth. Default 24. |