AlmondTill/G3N API

Saga

object type

A Saga — the cross-boundary / multi-step mutation record-of-truth: each step advances status AND commits its effect in ONE transaction; the record IS the durable state machine. Isolation = the semantic lock. SYSTEM-MINTED end to end: the wire is READ-ONLY (no create/edit/transition mutations exist — lifecycle is kit-channel; the first live records mint with the first genuinely multi-step process, checkout). failed is the terminal — compensation itself could not complete; recovery is a NEW linked saga, never a resurrection.

Fields

FieldTypeNotes
idID ID!The record’s id — a UUID the platform assigned when the record was created; every reference to this record uses it.
sysIdString String!The group-scoped human-facing system id (SG-…).
typeString String!The kind of record — always Saga here.
captionString String!The record’s display name — what people see it called.
statusString String!The FSM state: pending | running | compensating | completed | compensated | failed.
parentIdID ID!The parent org group; for a Saga parentId === rootId.
rootIdID ID!The org-group family root.
createdAtString String!When the record was created, as a UTC timestamp.
updatedAtString String!When the record last changed, as a UTC timestamp.
revisionNumInt Int!How many times this record has been edited; the first save is 0.
revisionID ID!The OCC revision token — supply it on every mutation of this record; rotates on every write.
refCaptionsRefCaption [RefCaption!]!The server-composed captions of this record's declared references (the referenced-caption rule) — one row per referenced id; see RefCaption.
sagaTypeSagaType SagaType!The canned process kind. IMMUTABLE at birth.
lockAggregateIdID ID!The aggregate the semantic lock isolates — e.g. the Order under checkout. IMMUTABLE at birth.
participantsSagaParticipant [SagaParticipant!]!The construct refs this saga's steps touch (1..32, distinct). IMMUTABLE at birth.
compensationLogSagaCompensationEntry [SagaCompensationEntry!]!The compensation audit log (born empty; appends while compensating, ≤ 64 — the failed terminal's last line records why). Server data, never caller-writable.
sfExecutionArnStringNull on SF-less sagas (document-FSM instances) and the degraded lane. The ops/reconcile handle.
taskTokenStringThe LIVE WaitForTaskToken callback token. Present ⟺ the execution is paused at the external wait; kit-stamped.

Used by