Skip to content

Connections

MethodPathAuthDescription
POST/api/v1/relaysAdminRegister relay
GET/api/v1/relaysAdminList relays
GET/api/v1/relays/{id}AdminRelay details
DELETE/api/v1/relays/{id}AdminDeregister relay

Register: POST /api/v1/relays with {"name": "NYC Office"} returns {"id": "...", "token": "rl_..."}. Save the token — it is shown only once.

MethodPathAuthDescription
GET/api/v1/relay/eventsRelay tokenSSE stream (query jobs)
POST/api/v1/relay/registerRelay tokenRegister connections
POST/api/v1/relay/results/{rid}Relay tokenPost query results

These endpoints are used by the relay binary, not by users.

MethodPathAuthDescription
GET/api/v1/connectionsJWTList available connections
POST/api/v1/connections/{id}/queryJWTExecute SQL
POST/api/v1/connections/{id}/introspectJWTSchema introspection

Query: {"sql": "SELECT * FROM revenue WHERE quarter = 'Q4'"}

Response: {"columns": ["id", "amount", "quarter"], "rows": [["1", 50000, "Q4"], ...]}

Introspect: {"action": "list_tables"} or {"action": "describe_table", "table": "revenue"} or {"action": "table_schema", "table": "revenue"}