Schema

Use this reference to inspect fields, methods, accepted values and failure outcomes. For setup and working examples, start with the API guide.

Encoding [DEF-E1]

settingvaluerule
escapeminimal[DEF-E2]
indent2[DEF-E3]
map_keysutf8-bytes[DEF-E4]
numbersinteger-decimal[DEF-E5]
opaqueverbatim[DEF-E6]
terminatornewline[DEF-E7]
duplicate_keysrefuse[DEF-E8]
depth_limit64[DEF-E9]

Types

kindtypes
built inbool i32 i64 string
declared belowDelegation Envelope Intent Lease Progress Recall Step
container [DEF-T3]list<json> list<string> map<string,json>
opaque [DEF-A3]json

Named types [DEF-T2]

One spelling is written [DEF-G2] and a wider set is read [DEF-G1]; the width between them is the interoperability guarantee.

nameiswrittenread
timestampstringrfc3339-microsrfc3339-wide

Structs [DEF-T1]

A field is required, or says when it is omitted [DEF-A4]. Each struct says on its own what it does with a field name it has never heard of [DEF-A7]. A wire name never moves; where a language must spell it differently the field says so [DEF-A2].

Step

unknown fields refuse

idfieldtypepresencenamed elsewhere
1namestringrequired—
2ordinali32required—
3ofi32optional · omitted when zero—
4donei64optional · omitted when zero—
5totali64optional · omitted when zero—

Progress

unknown fields refuse

idfieldtypepresencenamed elsewhere
1donei64required—
2totali64optional · omitted when zero—
3updated_attimestamprequired—
4stepStepoptional · omitted when absent—

Recall

unknown fields refuse

idfieldtypepresencenamed elsewhere
1reasonstringrequired—
2bystringoptional · omitted when zero—
3attimestamprequired—
4untiltimestamprequired—

Lease

unknown fields refuse

idfieldtypepresencenamed elsewhere
1ownerstringrequired—
2epochi64required—
3expires_attimestamprequired—
4recallRecalloptional · omitted when absent—

Delegation

unknown fields refuse

idfieldtypepresencenamed elsewhere
1systemstringrequired—
2external_idstringrequired—
3deliveredbooloptional · omitted when zero—

Intent

unknown fields refuse

idfieldtypepresencenamed elsewhere
1wantstringrequired—
2bystringoptional · omitted when zero—
3attimestampoptional · omitted when zero—

Envelope

unknown fields refuse

idfieldtypepresencenamed elsewhere
1schemastringrequired—
2actionslist<string>optional · omitted when zero—

Record

the document [DEF-A1] · unknown fields refuse

idfieldtypepresencenamed elsewhere
1contentlist<string>required—
2criticallist<string>optional · omitted when zero—
3idstringrequired—
4kindstringrequired—
17envelopeEnvelopeoptional · omitted when absent—
5statestringrequired—
6specjsonrequired—
7checkpointjsonoptional · omitted when absent—
8progressProgressrequired—
9leaseLeaserequired—
10delegationDelegationoptional · omitted when absent—
11requireslist<string>optional · omitted when zerocpp requires_
12errorstringoptional · omitted when zero—
13intentIntentoptional · omitted when absent—
14extensionsmap<string,json>optional · omitted when zero—
15created_attimestamprequired—
16updated_attimestamprequired—

Request

the protocol request · unknown fields grant

idfieldtypepresencenamed elsewhere
1opstringrequired—
2idstringoptional · omitted when zero—
3ownerstringoptional · omitted when zero—
4epochi64optional · omitted when zero—
5ttl_msi64optional · omitted when zero—
6wantstringoptional · omitted when zero—
7bystringoptional · omitted when zero—
8reasonstringoptional · omitted when zero—
9recordjsonoptional · omitted when zero—
10basejsonoptional · omitted when zero—

Response

the protocol response · unknown fields grant

idfieldtypepresencenamed elsewhere
1kindstringoptional · omitted when zero—
2errorstringoptional · omitted when zero—
3idstringoptional · omitted when zero—
4recordjsonoptional · omitted when zero—
5recordslist<json>optional · omitted when zero—
6boolbooloptional · omitted when zerocpp bool_
7unreadablelist<string>optional · omitted when zero—

Enumerations [DEF-T5]

An enumeration is a closed vocabulary of wire names, and each one says on its own what a reader does with a member it has never heard of [DEF-A5].

Capability

a member this reader does not know is grant

idmemberwireassurance
1resumeresumefalsifiable
2survives_process_exitsurvives_process_exitrecovered
3verifies_contentverifies_contentchecked
4delegatesdelegatestrusted

Verdict

a member this reader does not know is grant

idmemberwiretranscript
1not_foundnot_found—
2lease_heldlease_held—
3stale_epochstale_epoch—
4conflictconflictrefused
5lease_expiredlease_expired—
6terminalterminal—
7invalidinvalid—
8unknown_schemaunknown_schema—
9unknown_opunknown_oprefused
10not_supportednot_supportedrefused
11otherotherrefused

Vocabulary Content [DEF-A8]

declared of Record · carried in content · the subset a reader must know in critical

idtermpresent whencritical marking stripped
1abstraction.job/base@1always—
2abstraction.job/intent@1intent is present—
3abstraction.download/ranges@1checkpoint.verified is a member of the opaque value, and not nulltrue
4abstraction.job/delegation@1delegation is present—
5abstraction.job/envelope@1envelope is present—
6abstraction.job/terminal@1state is one of complete, failed, cancelled—
7abstraction.job/recall@1lease.recall is present—
8abstraction.job/step@1progress.step is presenttrue

Refusal words [DEF-R1]

orderwordstage
1malformedgrammar
2bad_stringgrammar
3number_spellinggrammar
4wrong_typegrammar
5bad_timestampgrammar
6depth_exceededgrammar
7duplicate_keygrammar
8duplicate_fieldstructure
9unknown_fieldstructure
10missing_fieldstructure
11trailing_bytesdocument
12unknown_criticalderivation
13not_a_subsetderivation
14content_mismatchderivation

Protocol Store [DEF-P1]

request Request · response Response · the operation in op · the verdict in kind from Verdict · an operation this peer does not know is unknown_op

idoperation
1submit
2load
3list
4orphans
5claimable
6claim
7renew
8release
9set_intent
10recall
11write