Something went wrong. Try again.
small gleam coding and persistent agent daemon with a detachable cli and a canvas ui forked from okami.mom/albedo
Something went wrong. Try again.
# HTTP API architecture
[OpenAPI](openapi.yaml) defines wire shapes. [HTTP API design](http-api-design.md)
defines ordering, retry, recovery, and resource behavior. This document explains
the owners and persistence boundaries behind those operations.
## State ownership
Session actors, the store transaction connection, the family owner, the
settings lock, and the bounded bus own the state below. HTTP handlers call
these owners and project their results.
`session/creation` owns new, fork, and child intents, their canonical submitted
JSON, and rejection policy. `http_api` parses requests into that type. The
registry resolves defaults and coordinates creation; `conversation` and
`operations` persist the submitted intent and the resulting decision. Dependency
failures stay retryable; validation refusals retain their original fingerprint
and rejection.
The runtime owns a generic `store.Store` handle named `ledger`. Extensions such
as work initialise and consume their own tables through that handle. Kernel APIs
accept the same generic store and receive their plugin wiring from callers.
| State | Owner and commit boundary | Recovery and removal |
| --- | --- | --- |
| Creation intent and decision | `conversation` and `operations`, on the shared store transaction connection. Persist the submitted descriptor separately from resolved defaults and editable configuration. | Keep provenance while the session exists. Keep rejected decisions and deletion tombstones for the contract's seven-day window. A lost response is recovered by the same session URI and original ID. |
| Child creation and initial task | Family owner serializes membership validation. One store transaction commits session, relationship, creation decision, and identified task. | A failed commit leaves none of them. Deletion admission prevents a racing child from escaping captured membership. |
| Input admission | `operations` commits the immutable decision and pending input together. Check a known ID before mutable validation. | Accepted pending input sur…