diagnostics
Get language server errors and warnings for a single file, plus cross-file index checks for undefined or unused CSS variables and unreferenced #id/.class selectors.
Instructions
Get the relevant language server's diagnostics (errors/warnings) for a single file.
For .css/.html files, this also includes index-derived warnings the
single-file language server can't see: var(--x) used with no matching
declaration anywhere in the same indexed root, custom properties declared
but never used, and CSS selectors (#id/.class) with no HTML/JS
reference in that root (files under WEBNAV_MCP_PUBLIC are exempt from
the last two).
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_path": "<file_path>"
},
"name": "diagnostics"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |