find_references
Locate every file and line where a function, class, or variable is used across your codebase, with optional file filtering and context lines.
Instructions
Find all references to a symbol (function, class, variable) across the codebase. Shows every file and line where the symbol is used.
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": {
"symbol": "<symbol>"
},
"name": "find_references"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| symbol | Yes | Symbol name to find references for | |
| file_glob | No | Filter by file pattern, e.g. "*.py" | |
| whole_word | No | Match whole word only (default: true) | |
| context_lines | No | Lines of context around each reference (default: 1) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| total | Yes | ||
| symbol | Yes | ||
| references | Yes |