get_diagnostics
Check TypeScript files for errors and warnings by analyzing code in a specified directory or using virtual content for diagnostics.
Instructions
Get TypeScript diagnostics (errors, warnings) for a single file
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": {
"root": "<root>",
"filePath": "<filePath>"
},
"name": "get_diagnostics"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| root | Yes | Root directory for resolving relative paths | |
| filePath | Yes | File path to check for diagnostics (relative to root) | |
| virtualContent | No | Virtual content to use for diagnostics instead of file content |