Reference
For the complete documentation index optimized for AI agents, see llms.txt.The HelixDB HTTP API accepts operation-tree queries at
POST /v2/query. The
same contract is available from a local server and a Helix Cloud gateway.
Machine-readable specification
The canonical OpenAPI 3.1 document is published at both predictable URLs: Use the specification to discover request headers, response codes, health endpoints, query-envelope variants, and example read and write requests. Use the typed SDKs orhelix query to build the nested operation tree.
Endpoint
http://localhost:6969/v2/query by default. For Helix
Cloud, use the gateway URL and database ID shown in the dashboard or written to
helix.toml by helix sync. The
cluster.helix-db.com hostname in the OpenAPI document is a placeholder, not a
shared query endpoint.
The root OpenAPI server and the /healthz and /readyz operations describe a
local HelixDB server. The Helix Cloud gateway is advertised only for
POST /v2/query; its separate /health and /readyz contracts are not part of
this specification.
Local HelixDB accepts encoded request bodies up to 16 MiB. The Helix Cloud
gateway accepts up to 2 MiB. Keep requests at or below 2 MiB when the same
client must work against both environments.
Authentication
Local servers do not require authentication by default. A Helix Cloud GA shared gateway requires a cluster API key and database ID:X-Helix-Tenant-Id remains a legacy alias in GA mode. Database-specific
cluster-mode gateway URLs require the API key but reject both database and
tenant selection headers. Use the endpoint mode shown in the dashboard or
written by helix sync; do not copy headers between the two modes.
The current public SDK request builders set bearer authentication and execution
headers but do not expose the GA database-selection header. Use them with a
database-specific cluster gateway URL, or use direct HTTP for a GA shared
gateway.
Create or rotate the cluster key in the Helix Cloud dashboard. Do not put keys
in source control, agent instructions, llms.txt, or catalog manifests.
The hosted HelixDB MCP server has a separate browser OAuth flow. See the
HelixDB MCP guide and the public
HelixDB authentication guide.
Request envelope
request_type and the single query variant must agree: read with read, or
write with write. query_name is optional diagnostic metadata. Parameters
can be untyped, or every parameter can have a matching entry in
parameter_types.
For raw HTTP JSON, send floating-point values without parameter_types.
The HTTP schema does not advertise typed f32 or f64 declarations because
JSON Schema cannot distinguish an integral number token such as 5 from the
integer representation that exact typed decoding rejects.
Execution headers
Boolean execution headers accept
true, false, 1, or 0. Warm writes and
durability waits on reads are rejected with 400 Bad Request.
Responses
200returns a JSON object keyed by the requested return variables.204means Helix Cloud completed a cache-warming read without a body.400reports invalid input or request options. On Helix Cloud, it also reports a missing or malformed authentication header.401reports an invalid Helix Cloud API key.402reports that Helix Cloud query processing is disabled because credit is exhausted.403reports that the Helix Cloud API key lacks permission for the query.408reports that a Helix Cloud query exceeded its wall-clock limit.409reports a transaction conflict. Retry the whole transaction only when it is idempotent or protected by an application idempotency key.413reports that a Helix Cloud request body exceeded 2 MiB. The gateway rejects it before query parsing.429reports a Helix Cloud rate limit and can includeRetry-After.500reports an internal query or storage failure.503reports that a required writer or ready database is unavailable.
{ "error": "<code>", "msg": "<message>" }. Clients should branch on
error and treat msg as diagnostic text. An oversized Cloud request uses
payload_too_large as its stable error code. See
Error handling for local error
codes and retry guidance.
Related resources
helix querybuilds and sends requests from JSON or the TypeScript DSL.- Build and run a query explains the operation tree.
- Parameters defines typed and untyped runtime values.