Prepare Call Hierarchy
prepareCallHierarchyRetrieve call hierarchy items (function/method name, kind, file location, and spans) at a specific position in a TypeScript or JavaScript file to analyze function calls.
Instructions
Returns the call hierarchy item(s) at a position — the entry point for call hierarchy queries. Returns the function/method name, kind, file location, and spans.
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": {
"file": "<file>",
"line": "<line>",
"offset": "<offset>"
},
"name": "prepareCallHierarchy"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | Yes | File path (absolute or relative to cwd) | |
| line | Yes | 1-based line number | |
| offset | Yes | 1-based character offset on the line |