serve
tonic serve --stdio exposes the same target resolution, execution, artifact planning, inspect, and session behavior as the CLI through newline-delimited JSON-RPC 2.0.
tonic serve --stdio--stdio is currently required.
Transport
Section titled “Transport”- One JSON-RPC message per UTF-8 line.
- Request-response only; server-initiated notifications are not implemented.
- Sessions are process-local and close when the server process exits.
- Open transactions are rolled back best-effort when their session closes.
Capabilities
Section titled “Capabilities”{"jsonrpc":"2.0","id":1,"method":"server.capabilities","params":{}}The result includes the service name, binary version, transport, supported backends, and method list.
Current backends reported by the service are postgres, snowflake, sqlite, and mysql.
Common Methods
Section titled “Common Methods”targets.listtargets.pingquery.executeInlinequery.planArtifactquery.executeArtifactsessions.opensessions.executesessions.closeinspect.catalogsinspect.namespacesinspect.tablesinspect.viewsinspect.columnsinspect.viewDefinitioninspect.ddl
See Serve JSON-RPC for request and response shapes.