Docs · Editor
Language-server diagnostics
Zero proxies language servers over a WebSocket bridge. The operator gets hover info, go-to-definition, and diagnostics inline — without running a separate editor.
Overview
The LSP bridge starts a language server process on demand and proxies JSON-RPC messages between the console and the running server. One bridge process per language, per workspace.
Supported languages
| Language token | Server |
|---|---|
rust | rust-analyzer |
typescript | typescript-language-server |
javascript | typescript-language-server |
The server binary must be installed on the operator machine and available on PATH. Zero starts the process on first request for a given language.
WebSocket bridge
The primary interface is a WebSocket upgrade. Connect once; send and receive LSP JSON-RPC messages over the socket.
GET /lsp/:language/ws
Upgrade: websocket
# Example: connect for Rust diagnostics
ws://localhost:7878/lsp/rust/wsMessages are standard LSP JSON-RPC frames (no additional framing beyond the WebSocket protocol).
HTTP message endpoint
For one-shot requests, an HTTP endpoint accepts a single LSP message and returns the server response:
POST /lsp/:language/message
Body: { /* LSP JSON-RPC request */ }
→ { /* LSP JSON-RPC response */ }What flows over the socket
- Hover — type info and documentation at a position.
- Go to definition — jump to the definition of a symbol.
- Diagnostics — compiler errors and warnings, streamed as the file changes.
- Completions — see also In-app editor autocomplete, which wraps this bridge.
API reference
| Method | Path | Description |
|---|---|---|
WS | /lsp/:language/ws | WebSocket bridge to the language server for the given language. Upgrades from HTTP GET. |
POST | /lsp/:language/message | Send a single LSP JSON-RPC message; returns the server response over HTTP. |