Inspect the data shapes
As an SDK implementer, I want exact named fields and type alternatives alongside the examples. These are the authoritative CDDL files, included verbatim. Maps preserve field names; ordered sequences remain arrays.
flowchart LR
Schema[CDDL shapes] -->|Structural validation| Value[Typed model value]
Value -->|Source predicates| Result[Model result]
Bytes[Original signed evidence bytes] -->|Separate cryptographic profile| Evidence[Verified evidence]
Checkpoint
; Draft abstract Checkpoint profile, not signed KERI or Cardano wire data.
; Field names are named maps; source: CardanoKeri.Checkpoint.Action/State/Flow.
; unsigned includes positive CBOR bignums; see encoding.md for canonical forms.
checkpoint-document = checkpoint-action / checkpoint-state / step-result / parameters / checkpoint-corpus
checkpoint-action = register / rotate / poison / freeze / top-up / convict / close / reopen
register = { action: "register", refund: model-nat, pool0: model-nat }
rotate = { action: "rotate", sn: model-nat, bond: "keep" / "deposit", payee: model-nat, refund: model-nat / null }
poison = { action: "poison" }
freeze = { action: "freeze", sn: model-nat, payee: model-nat }
top-up = { action: "topUp", amount: model-nat }
convict = { action: "convict", payee: model-nat }
close = { action: "close", sn: model-nat, payee: model-nat, refund: model-nat / null }
reopen = { action: "reopen", sn: model-nat, refund: model-nat, pool0: model-nat }
checkpoint-state = absent / present / parked / pending / convicted
absent = { state: "absent" }
present = { state: "present", sn: model-nat, epoch: model-nat, poisoned: bool, frozen: bool, bornAt: model-nat, refundTo: model-nat, pool: model-nat }
parked = { state: "parked", epoch: model-nat, sn: model-nat }
pending = { state: "terminationPending", epoch: model-nat, sn: model-nat }
convicted = { state: "convicted" }
payment = { addr: model-nat, dreg: model-nat, b: model-nat, pool: model-nat }
flow = { dregIn: model-nat, bIn: model-nat, poolIn: model-nat, refund: payment / null, hunter: payment / null, convictor: payment / null }
; Refused results name every failed applicable guard; see spec.md.
step-result = accepted-result / refused-result
accepted-result = { status: "accepted", flow: flow, state: checkpoint-state }
refused-result = { status: "refused", refusals: [+ refusal-name] }
refusal-name = "checkpoint-state-mismatch" / "rotation-evidence-invalid" / "sequence-not-later" / "intent-unauthorized" / "quorum-missing" / "already-poisoned" / "freeze-pool-covers-premium" / "already-frozen" / "freeze-poisoned" / "duplicity-evidence-invalid"
parameters = { D: positive-nat, B: positive-nat, P: model-nat, W: model-nat }
; Finite oracle tables are conformance inputs only, never production evidence.
model-env = {
rotations: [* { epoch: model-nat, from: model-nat, to: model-nat }],
intents: [* { epoch: model-nat, intent: model-intent, refund: model-nat / null }],
quorums: [* { epoch: model-nat }],
duplicities: [* { epoch: model-nat, sn: model-nat }]
}
model-intent = { kind: "keep" / "deposit" } / { kind: "close", payee: model-nat }
checkpoint-corpus = {
profile: "checkpoint-model-v2", params: parameters, now: model-nat,
states: [+ checkpoint-state], actions: [+ checkpoint-action], envs: [+ model-env],
cells: [+ { s: model-nat, a: model-nat, e: model-nat, result: step-result }]
}
model-nat = unsigned
positive-nat = unsigned .gt 0
History, mirrors, credentials and delegation
; Abstract projection of docs/lean-acdc-tel-delegation-statements at 4906cfa.
; Executable statements, not proved guarantees or concrete KERI/Cardano codecs.
statements-document = statements-corpus / statement-call / statement-result / evidence-assessment
nat = unsigned
history-verdict = "final" / "provisional"
history-params = { toadFloor: nat }
history-leaf = { prev: nat / null, epoch: nat, toad: nat }
history-checkpoint = {
aid: nat, latest: nat, cur: nat, parent: nat / null,
hist: [* { sn: nat, leaf: history-leaf }]
}
checkpoint-table = [* { aid: nat, checkpoint: history-checkpoint }]
seal = { i: nat, s: nat, d: nat }
kel-event = { sn: nat, establishment: bool, seals: [* seal] }
walk-core = { kel: kel-event, e: nat, succ: nat / null, idx: nat }
tel-event = { kind: "vcp" / "iss" / "rev", i: nat, ri: nat, s: nat }
tel-walk = { tel: tel-event, core: walk-core }
history-action = { action: "history.advance" / "history.supersede", sn: nat, toad: nat }
history-call = { action: history-action, state: history-checkpoint }
mirror-registry = { issuer: nat, rid: nat, revoked: [* nat] }
registry-table = [* { rid: nat, registry: mirror-registry }]
mirror-system = { ckpt: checkpoint-table, reg: registry-table }
mirror-action =
{ action: "mirror.register", aid: nat, epoch: nat, toad: nat, parent: nat / null } /
{ action: "mirror.history", aid: nat, historyAction: history-action } /
{ action: "mirror.open", issuer: nat, w: tel-walk } /
{ action: "mirror.push", w: tel-walk }
mirror-call = { action: mirror-action, state: mirror-system }
acdc-body = { issuer: nat, schema: nat, registry: nat, issuee: nat, edge: nat / null }
acdc = { body: acdc-body, said: nat }
credential-hop = { acdc: acdc, walk: tel-walk }
credential-policy = { root: nat, schemas: [* nat], maxDepth: nat, notAfter: nat }
admission-dependency = { issuer: nat, e: nat, epoch: nat, k: nat, verdict: history-verdict }
admission = {
saids: [* nat], registries: [* nat], verdict: history-verdict,
deps: [* admission-dependency], admittedAt: nat
}
credential-system = {
ckpt: checkpoint-table, reg: registry-table,
cage: [* { key: nat, admission: admission }]
}
credential-action =
{ action: "credential.mirror", mirrorAction: mirror-action } /
{ action: "credential.admit", key: nat, hops: [* credential-hop], now: nat } /
{ action: "credential.evict", key: nat }
credential-call = { action: credential-action, state: credential-system, policy: credential-policy }
child-event = { sn: nat, toad: nat, nonce: nat }
approval-certificate = {
parent: nat, child: nat, childSn: nat, childSaid: nat,
parentSn: nat, sealIdx: nat, verdict: history-verdict
}
; Preserve Option (Option AID): absent entry = never registered; plain differs from parent zero.
known-parent = { kind: "plain" } / { kind: "delegated", parent: nat }
delegation-system = {
ckpt: checkpoint-table, certs: [* approval-certificate],
known: [* { aid: nat, value: known-parent }]
}
delegation-action =
{ action: "delegation.mint", parent: nat, child: nat, ev: child-event, w: walk-core } /
{ action: "delegation.registerPlain", aid: nat, epoch: nat, toad: nat } /
{ action: "delegation.registerDelegated", child: nat, parent: nat, ev: child-event } /
{ action: "delegation.advancePlain", aid: nat, sn: nat, toad: nat } /
{ action: "delegation.advanceDelegated" / "delegation.supersedeDelegated", child: nat, ev: child-event } /
{ action: "delegation.leave", aid: nat }
delegation-call = { action: delegation-action, state: delegation-system }
query-call =
{ action: { action: "history.cover", e: nat, k: nat, succ: nat / null }, state: history-checkpoint } /
{ action: { action: "history.walkOn", seal: seal, w: walk-core }, state: history-checkpoint } /
{ action: { action: "history.sealWalk", rid: nat, w: tel-walk }, state: history-checkpoint } /
{ action: { action: "mirror.miss", rid: nat, said: nat }, state: mirror-system } /
{ action: { action: "credential.admitChain", hops: [* credential-hop] }, state: mirror-system, policy: credential-policy } /
{ action: { action: "credential.gate", key: nat, now: nat }, state: credential-system, policy: credential-policy } /
{ action: { action: "delegation.ancestorWithin", depth: nat, child: nat, root: nat }, state: delegation-system } /
{ action: { action: "delegation.issuerWalk", aid: nat, rid: nat, w: tel-walk }, state: delegation-system }
statement-call = history-call / mirror-call / credential-call / delegation-call / query-call
statement-value = history-checkpoint / mirror-system / credential-system / delegation-system / history-verdict / bool
statement-result =
{ status: "accepted", value: statement-value } /
{ status: "refused", refusal: statement-refusal }
; One compound admission guard per source Option-returning operation. False query values are not errors.
statement-refusal =
"history.advance-refused" / "history.supersede-refused" /
"mirror.register-refused" / "mirror.history-refused" / "mirror.open-refused" / "mirror.push-refused" /
"credential.mirror-refused" / "credential.admit-refused" / "credential.evict-refused" /
"delegation.mint-refused" / "delegation.registerPlain-refused" / "delegation.registerDelegated-refused" /
"delegation.advancePlain-refused" / "delegation.advanceDelegated-refused" /
"delegation.supersedeDelegated-refused" / "delegation.leave-refused" /
"history.cover-refused" / "history.walkOn-refused" / "history.sealWalk-refused" /
"credential.admitChain-refused" / "delegation.issuerWalk-refused"
; API completeness envelope, distinct from the model's final/provisional verdict.
; Supplied evidence bytes and concrete proof codecs are a separate profile.
evidence-assessment =
{ status: "unknown", missing: [+ { object: "kel" / "tel" / "credential" / "checkpoint" / "mirror" / "approval", subject: tstr }] } /
{ status: "assessed", result: statement-result }
; These are fixture oracles and bounded state observations, not production evidence.
fixture-oracle = { signed: bool, receipted: bool, signatureEpoch: nat / null }
statements-corpus = {
profile: "statements-model-v1", source: tstr, params: history-params,
domain: { aids: [* nat], sequences: [* nat], registries: [* nat], saids: [* nat] },
cases: [+ { name: tstr, oracle: fixture-oracle, call: statement-call, result: statement-result }]
}