Remote / API

foldkit-remote-server

foldkit-remote-server — server-side Sources and handler compilation.

Owns entity/query Sources, selection authorization, normalization, and turning them into Effect RPC handlers. It does not own HTTP, serialization, or auth protocol; principal is resolved outside, and passed in or provided.

Namespaces

Functions

assertSupportedRefuses a body needing an operation this interpreter does not run, rather than skipping it and answering a different question. Called by evaluate; call it…
evaluateThe rows the body matches, in the order it asks for. Pure: it reads the rows it is given and nothing else.

Values

supportedThe operations this interpreter runs. It is the reference, so this is the whole kernel — but it is declared rather than assumed, because an interpreter that…

Classes

MutationRefusedA mutation Source's refusal, as the value its descriptor's Refusal declares: made with RemoteServer.refuse, which checks the value's type against the…
QueryEvaluateError
RemoteServerError

Interfaces

EntityRecord
EntitySource
EntitySourceContext
EntityWriterWhere a declared write lands: one row's new values, encoded as the store holds them. With expect, the row is written only while its revision is still that…
HandlerOptions
LiveHubThe server-side "these fields changed" signal. A hub tracks each live subscriber's requirements (entity, id, fields) and principal; changed re-reads the…
LiveSource
MemoryBackend
MemoryServedA memory backend made without a principal: its rows and the server over them, answered as whoever its caller names per request (serveFetch,…
MemoryStoreThe rows a memory backend holds, which its mutations write through. A change is what the next read sees; nothing is pushed to a client.
MutationOutcome
MutationSource
QueryPage
QuerySource
ReadPlanWhat EntitySource.filter decides for one read.
ServerDefinition

Types

ConnectionChangeA connection change a mutation made, as the wire carries it.
MemoryAnsweringWhat a backend needs to give a layer: a principal to answer as, or one undefined can be.
MemoryConfigWhat RemoteServer.memory is made from. See memory.
MemoryReadableWhether a stored row of entity may be read, given its whole stored values.
MemoryRowsOne entity's rows in their wire shape: a relation is its ref key, 'User:u1'.
RowA row as this interpreter reads one: values by field key.