Skip to content
Talk to our solutions team

HTTP API

One listener (default :7123) serves both subsystems. Bodies may be JSON or YAML per Content-Type; responses are JSON by default, YAML via Accept or ?format.

MethodPathPurpose
GET/hivesList hives + registry version
GET / HEAD/hives/:hive/*pathResolved snapshot at path. ETag = version
PUT/hives/:hive/*pathReplace value → 200/201; 409 on If-Match mismatch; 422 on CUE failure
PATCH/hives/:hive/*pathDeep-merge a partial document
DELETE/hives/:hive/*pathDelete → 204
GET/hives/:hive/*path/_meta/schemaThe hive’s CUE schema (text)
GET/hives/:hive/*path/_meta/exampleCanonical example document
GET/sourcesDeclared sources per hive
GET/subscribersConnected SSE subscribers (admin)

Read modifiers:

  • ?raw=<source> — the unresolved contribution of one source.
  • ?tree=true[&depth=N] — list the subtree under a path.
  • If-None-Match — conditional read → 304.
  • If-Min-Version — block briefly until the snapshot reaches a version (read-after-write).

Write headers:

  • If-Match — optimistic concurrency (mismatch → 409).
  • X-Reason — audit annotation.
  • X-Schedule-Revert-At — break-glass auto-revert: the write is applied now and an audited revert is enqueued for the given time.
  • ?source=<name> — disambiguate when more than one writable source owns the path.

Writes under /_meta return 405. Paths that violate a predefined level (e.g. an unknown environment) fail structurally with 400 invalid_path before any source I/O.

MethodPathPurpose
GET/stream/configSnapshot push. Query: ?hives=…, &label.<k>=<v>. Resume with Last-Event-Id
POST/stream/config/driftSubscriber drift report → 202 (feeds metrics)

Event types: snapshot (upsert), delete, full_resync (drop your view and re-read), heartbeat. At connect, backfill carries hive roots only — clients REST-read their own node first, then follow the stream. Per-connection buffer is 256 events; overflow disconnects the subscriber, which resumes by cursor.

MethodPathPurpose
POST/webhooks/git/<source-name>Nudge a git source to pull now instead of waiting for the poll interval

Signatures validated: X-Hub-Signature-256 (GitHub), X-Gitlab-Token, X-Gitea-Signature.

MethodPathPurpose
POST/registerUpsert an instance by instance_id; ttl_secs 5–600
PUT/heartbeat/:idRenew the lease
DELETE/deregister/:idRevoke the lease
GET/servicesService names with registrations
GET/services/:name/instancesInstances; filters ?dc=, ?cluster=, ?tag=k:v
GET/stream/discoverySSE membership stream (?services=…); events instance_up, instance_down, instance_expired, heartbeat

An instance that stops heartbeating drops out when its lease expires — crash-safe by construction.

GET /health (liveness, no dependency checks), GET /ready (200 only after the first reconcile pass), GET /version. All unauthenticated.

Any one of, in order: X-Api-Key (file-backed), Authorization: Bearer (JWKS-validated JWT), or an mTLS client certificate. Authorization is per-hive expression policy evaluated over (subject, action, hive, path).