@real-life/trust-protocol 0.3.2 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (277) hide show
  1. package/CHANGELOG.md +97 -0
  2. package/README.md +209 -78
  3. package/dist/ack.d.ts +84 -0
  4. package/dist/ack.d.ts.map +1 -0
  5. package/dist/ack.js +114 -0
  6. package/dist/ack.js.map +1 -0
  7. package/dist/adapters/vti-mediator.d.ts +169 -0
  8. package/dist/adapters/vti-mediator.d.ts.map +1 -0
  9. package/dist/adapters/vti-mediator.js +659 -0
  10. package/dist/adapters/vti-mediator.js.map +1 -0
  11. package/dist/anchor.d.ts +226 -0
  12. package/dist/anchor.d.ts.map +1 -0
  13. package/dist/anchor.js +347 -0
  14. package/dist/anchor.js.map +1 -0
  15. package/dist/{holder.d.ts → carrier-holder.d.ts} +1 -1
  16. package/dist/carrier-holder.d.ts.map +1 -0
  17. package/dist/{holder.js → carrier-holder.js} +5 -4
  18. package/dist/carrier-holder.js.map +1 -0
  19. package/dist/carrier-identity.js +4 -4
  20. package/dist/carrier-identity.js.map +1 -1
  21. package/dist/carrier.d.ts.map +1 -1
  22. package/dist/carrier.js +4 -3
  23. package/dist/carrier.js.map +1 -1
  24. package/dist/ceremony.d.ts +3 -2
  25. package/dist/ceremony.d.ts.map +1 -1
  26. package/dist/ceremony.js +16 -26
  27. package/dist/ceremony.js.map +1 -1
  28. package/dist/codec.d.ts +54 -0
  29. package/dist/codec.d.ts.map +1 -0
  30. package/dist/codec.js +494 -0
  31. package/dist/codec.js.map +1 -0
  32. package/dist/continuity.d.ts +67 -0
  33. package/dist/continuity.d.ts.map +1 -0
  34. package/dist/continuity.js +110 -0
  35. package/dist/continuity.js.map +1 -0
  36. package/dist/core.d.ts +4 -0
  37. package/dist/core.d.ts.map +1 -1
  38. package/dist/core.js.map +1 -1
  39. package/dist/crypto.d.ts +23 -7
  40. package/dist/crypto.d.ts.map +1 -1
  41. package/dist/crypto.js +54 -20
  42. package/dist/crypto.js.map +1 -1
  43. package/dist/delivery.d.ts +31 -3
  44. package/dist/delivery.d.ts.map +1 -1
  45. package/dist/delivery.js +75 -28
  46. package/dist/delivery.js.map +1 -1
  47. package/dist/encounter/ceremony.d.ts +37 -0
  48. package/dist/encounter/ceremony.d.ts.map +1 -0
  49. package/dist/encounter/ceremony.js +662 -0
  50. package/dist/encounter/ceremony.js.map +1 -0
  51. package/dist/encounter.d.ts +91 -1
  52. package/dist/encounter.d.ts.map +1 -1
  53. package/dist/encounter.js +191 -12
  54. package/dist/encounter.js.map +1 -1
  55. package/dist/engine.d.ts +303 -0
  56. package/dist/engine.d.ts.map +1 -0
  57. package/dist/engine.js +1509 -0
  58. package/dist/engine.js.map +1 -0
  59. package/dist/entropy.d.ts +28 -0
  60. package/dist/entropy.d.ts.map +1 -0
  61. package/dist/entropy.js +96 -0
  62. package/dist/entropy.js.map +1 -0
  63. package/dist/events.d.ts +198 -0
  64. package/dist/events.d.ts.map +1 -0
  65. package/dist/events.js +2 -0
  66. package/dist/events.js.map +1 -0
  67. package/dist/fixtures.d.ts +30 -0
  68. package/dist/fixtures.d.ts.map +1 -0
  69. package/dist/fixtures.js +155 -0
  70. package/dist/fixtures.js.map +1 -0
  71. package/dist/forge.d.ts +47 -0
  72. package/dist/forge.d.ts.map +1 -0
  73. package/dist/forge.js +20 -0
  74. package/dist/forge.js.map +1 -0
  75. package/dist/group-star.d.ts +251 -0
  76. package/dist/group-star.d.ts.map +1 -0
  77. package/dist/group-star.js +348 -0
  78. package/dist/group-star.js.map +1 -0
  79. package/dist/holder-api.d.ts +165 -0
  80. package/dist/holder-api.d.ts.map +1 -0
  81. package/dist/holder-api.js +142 -0
  82. package/dist/holder-api.js.map +1 -0
  83. package/dist/holder-state-v1.d.ts +801 -0
  84. package/dist/holder-state-v1.d.ts.map +1 -0
  85. package/dist/holder-state-v1.js +2 -0
  86. package/dist/holder-state-v1.js.map +1 -0
  87. package/dist/holder-state-v2.d.ts +858 -0
  88. package/dist/holder-state-v2.d.ts.map +1 -0
  89. package/dist/holder-state-v2.js +2 -0
  90. package/dist/holder-state-v2.js.map +1 -0
  91. package/dist/identity-state.d.ts +43 -0
  92. package/dist/identity-state.d.ts.map +1 -0
  93. package/dist/identity-state.js +345 -0
  94. package/dist/identity-state.js.map +1 -0
  95. package/dist/identity.d.ts +24 -2
  96. package/dist/identity.d.ts.map +1 -1
  97. package/dist/identity.js +70 -11
  98. package/dist/identity.js.map +1 -1
  99. package/dist/index.d.ts +27 -1
  100. package/dist/index.d.ts.map +1 -1
  101. package/dist/index.js +81 -29
  102. package/dist/index.js.map +1 -1
  103. package/dist/internal.d.ts +37 -0
  104. package/dist/internal.d.ts.map +1 -0
  105. package/dist/internal.js +22 -0
  106. package/dist/internal.js.map +1 -0
  107. package/dist/introduction/holder.d.ts +18 -0
  108. package/dist/introduction/holder.d.ts.map +1 -0
  109. package/dist/introduction/holder.js +764 -0
  110. package/dist/introduction/holder.js.map +1 -0
  111. package/dist/introduction.d.ts +101 -0
  112. package/dist/introduction.d.ts.map +1 -0
  113. package/dist/introduction.js +132 -0
  114. package/dist/introduction.js.map +1 -0
  115. package/dist/invariants.d.ts +43 -0
  116. package/dist/invariants.d.ts.map +1 -0
  117. package/dist/invariants.js +953 -0
  118. package/dist/invariants.js.map +1 -0
  119. package/dist/keys-seed.d.ts +7 -0
  120. package/dist/keys-seed.d.ts.map +1 -0
  121. package/dist/keys-seed.js +133 -0
  122. package/dist/keys-seed.js.map +1 -0
  123. package/dist/log-memory.d.ts +12 -0
  124. package/dist/log-memory.d.ts.map +1 -0
  125. package/dist/log-memory.js +101 -0
  126. package/dist/log-memory.js.map +1 -0
  127. package/dist/membership/holder.d.ts +33 -0
  128. package/dist/membership/holder.d.ts.map +1 -0
  129. package/dist/membership/holder.js +929 -0
  130. package/dist/membership/holder.js.map +1 -0
  131. package/dist/membership.d.ts +123 -0
  132. package/dist/membership.d.ts.map +1 -0
  133. package/dist/membership.js +180 -0
  134. package/dist/membership.js.map +1 -0
  135. package/dist/message/holder.d.ts +49 -0
  136. package/dist/message/holder.d.ts.map +1 -0
  137. package/dist/message/holder.js +290 -0
  138. package/dist/message/holder.js.map +1 -0
  139. package/dist/message.d.ts +43 -0
  140. package/dist/message.d.ts.map +1 -0
  141. package/dist/message.js +51 -0
  142. package/dist/message.js.map +1 -0
  143. package/dist/ports.d.ts +237 -0
  144. package/dist/ports.d.ts.map +1 -0
  145. package/dist/ports.js +2 -0
  146. package/dist/ports.js.map +1 -0
  147. package/dist/profile.d.ts +56 -0
  148. package/dist/profile.d.ts.map +1 -0
  149. package/dist/profile.js +193 -0
  150. package/dist/profile.js.map +1 -0
  151. package/dist/prompts.d.ts +14 -0
  152. package/dist/prompts.d.ts.map +1 -0
  153. package/dist/prompts.js +69 -0
  154. package/dist/prompts.js.map +1 -0
  155. package/dist/receive.d.ts +134 -0
  156. package/dist/receive.d.ts.map +1 -0
  157. package/dist/receive.js +317 -0
  158. package/dist/receive.js.map +1 -0
  159. package/dist/results.d.ts +173 -0
  160. package/dist/results.d.ts.map +1 -0
  161. package/dist/results.js +21 -0
  162. package/dist/results.js.map +1 -0
  163. package/dist/schemas.d.ts.map +1 -1
  164. package/dist/schemas.js +45 -38
  165. package/dist/schemas.js.map +1 -1
  166. package/dist/sha256.d.ts +3 -0
  167. package/dist/sha256.d.ts.map +1 -0
  168. package/dist/sha256.js +69 -0
  169. package/dist/sha256.js.map +1 -0
  170. package/dist/star.d.ts +31 -0
  171. package/dist/star.d.ts.map +1 -0
  172. package/dist/star.js +56 -0
  173. package/dist/star.js.map +1 -0
  174. package/dist/state-builder.d.ts +42 -0
  175. package/dist/state-builder.d.ts.map +1 -0
  176. package/dist/state-builder.js +100 -0
  177. package/dist/state-builder.js.map +1 -0
  178. package/dist/state.d.ts +914 -0
  179. package/dist/state.d.ts.map +1 -0
  180. package/dist/state.js +37 -0
  181. package/dist/state.js.map +1 -0
  182. package/dist/store-contract.d.ts +11 -0
  183. package/dist/store-contract.d.ts.map +1 -0
  184. package/dist/store-contract.js +189 -0
  185. package/dist/store-contract.js.map +1 -0
  186. package/dist/store-memory.d.ts +8 -0
  187. package/dist/store-memory.d.ts.map +1 -0
  188. package/dist/store-memory.js +17 -0
  189. package/dist/store-memory.js.map +1 -0
  190. package/dist/testing.d.ts +22 -0
  191. package/dist/testing.d.ts.map +1 -0
  192. package/dist/testing.js +21 -0
  193. package/dist/testing.js.map +1 -0
  194. package/dist/trust/continuity.d.ts +71 -0
  195. package/dist/trust/continuity.d.ts.map +1 -0
  196. package/dist/trust/continuity.js +1222 -0
  197. package/dist/trust/continuity.js.map +1 -0
  198. package/dist/trust/duties.d.ts +67 -0
  199. package/dist/trust/duties.d.ts.map +1 -0
  200. package/dist/trust/duties.js +179 -0
  201. package/dist/trust/duties.js.map +1 -0
  202. package/dist/trust/entries.d.ts +139 -0
  203. package/dist/trust/entries.d.ts.map +1 -0
  204. package/dist/trust/entries.js +795 -0
  205. package/dist/trust/entries.js.map +1 -0
  206. package/dist/trust/group-star.d.ts +43 -0
  207. package/dist/trust/group-star.d.ts.map +1 -0
  208. package/dist/trust/group-star.js +188 -0
  209. package/dist/trust/group-star.js.map +1 -0
  210. package/dist/trust/mapping.d.ts +56 -0
  211. package/dist/trust/mapping.d.ts.map +1 -0
  212. package/dist/trust/mapping.js +584 -0
  213. package/dist/trust/mapping.js.map +1 -0
  214. package/dist/trust/profile.d.ts +25 -0
  215. package/dist/trust/profile.d.ts.map +1 -0
  216. package/dist/trust/profile.js +249 -0
  217. package/dist/trust/profile.js.map +1 -0
  218. package/dist/trust/star.d.ts +208 -0
  219. package/dist/trust/star.d.ts.map +1 -0
  220. package/dist/trust/star.js +588 -0
  221. package/dist/trust/star.js.map +1 -0
  222. package/dist/trust/state.d.ts +83 -0
  223. package/dist/trust/state.d.ts.map +1 -0
  224. package/dist/trust/state.js +154 -0
  225. package/dist/trust/state.js.map +1 -0
  226. package/dist/util-freeze.d.ts +3 -0
  227. package/dist/util-freeze.d.ts.map +1 -0
  228. package/dist/util-freeze.js +11 -0
  229. package/dist/util-freeze.js.map +1 -0
  230. package/dist/views.d.ts +179 -0
  231. package/dist/views.d.ts.map +1 -0
  232. package/dist/views.js +286 -0
  233. package/dist/views.js.map +1 -0
  234. package/dist/visibility.d.ts +5 -5
  235. package/dist/visibility.d.ts.map +1 -1
  236. package/dist/visibility.js +22 -28
  237. package/dist/visibility.js.map +1 -1
  238. package/dist/wire.d.ts +218 -83
  239. package/dist/wire.d.ts.map +1 -1
  240. package/dist/wire.js.map +1 -1
  241. package/package.json +60 -10
  242. package/schemas/holder-state-v1.schema.json +3880 -0
  243. package/schemas/holder-state-v2.schema.json +4123 -0
  244. package/dist/holder.d.ts.map +0 -1
  245. package/dist/holder.js.map +0 -1
  246. package/dist/probe/acks.d.ts +0 -27
  247. package/dist/probe/acks.d.ts.map +0 -1
  248. package/dist/probe/acks.js +0 -152
  249. package/dist/probe/acks.js.map +0 -1
  250. package/dist/probe/continuity.d.ts +0 -20
  251. package/dist/probe/continuity.d.ts.map +0 -1
  252. package/dist/probe/continuity.js +0 -805
  253. package/dist/probe/continuity.js.map +0 -1
  254. package/dist/probe/deps.d.ts +0 -61
  255. package/dist/probe/deps.d.ts.map +0 -1
  256. package/dist/probe/deps.js +0 -54
  257. package/dist/probe/deps.js.map +0 -1
  258. package/dist/probe/encounter.d.ts +0 -26
  259. package/dist/probe/encounter.d.ts.map +0 -1
  260. package/dist/probe/encounter.js +0 -938
  261. package/dist/probe/encounter.js.map +0 -1
  262. package/dist/probe/introduce.d.ts +0 -62
  263. package/dist/probe/introduce.d.ts.map +0 -1
  264. package/dist/probe/introduce.js +0 -306
  265. package/dist/probe/introduce.js.map +0 -1
  266. package/dist/probe/membership.d.ts +0 -96
  267. package/dist/probe/membership.d.ts.map +0 -1
  268. package/dist/probe/membership.js +0 -467
  269. package/dist/probe/membership.js.map +0 -1
  270. package/dist/probe/trust.d.ts +0 -156
  271. package/dist/probe/trust.d.ts.map +0 -1
  272. package/dist/probe/trust.js +0 -1233
  273. package/dist/probe/trust.js.map +0 -1
  274. package/dist/probe.d.ts +0 -7
  275. package/dist/probe.d.ts.map +0 -1
  276. package/dist/probe.js +0 -42
  277. package/dist/probe.js.map +0 -1
@@ -0,0 +1,3880 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://real-life.org/trust-protocol/lib/holder-state-v1.schema.json",
4
+ "title": "HolderState, codec 1",
5
+ "description": "NON-NORMATIVE. The stored state of an @real-life/trust-protocol holder at codec 1 (lib/src/codec.ts): the library's storage format, not a protocol artifact. lib/src/holder-state-v1.ts is generated from it (scripts/build-holder-state-types.mjs). Not expressible here and checked by the codec alone: a record's id equals its key (contacts, relationships, groups, duties, rotations, prompts, acts, roster, invitations, records, introductions, offers, challenges), and an envelope's rkid equals its recipient's keyAgreement.",
6
+ "type": "object",
7
+ "properties": {
8
+ "codec": {
9
+ "const": 1
10
+ },
11
+ "commitSeq": {
12
+ "$ref": "#/$defs/Dec"
13
+ },
14
+ "lastWhen": {
15
+ "$ref": "#/$defs/Millis"
16
+ },
17
+ "register": {
18
+ "type": "object",
19
+ "properties": {
20
+ "labels": {
21
+ "type": "array",
22
+ "items": {
23
+ "type": "string"
24
+ },
25
+ "uniqueItems": true
26
+ },
27
+ "pairNonces": {
28
+ "type": "object",
29
+ "additionalProperties": {
30
+ "type": "string"
31
+ }
32
+ },
33
+ "carriers": {
34
+ "type": "object",
35
+ "additionalProperties": {
36
+ "type": "array",
37
+ "items": {
38
+ "type": "object",
39
+ "properties": {
40
+ "nonce": {
41
+ "type": "string"
42
+ },
43
+ "generation": {
44
+ "$ref": "#/$defs/Dec"
45
+ }
46
+ },
47
+ "required": [
48
+ "nonce",
49
+ "generation"
50
+ ],
51
+ "additionalProperties": false
52
+ }
53
+ }
54
+ },
55
+ "devices": {
56
+ "type": "object",
57
+ "properties": {
58
+ "names": {
59
+ "type": "array",
60
+ "items": {
61
+ "type": "string"
62
+ },
63
+ "uniqueItems": true
64
+ },
65
+ "revoked": {
66
+ "type": "array",
67
+ "items": {
68
+ "type": "string"
69
+ },
70
+ "uniqueItems": true
71
+ }
72
+ },
73
+ "required": [
74
+ "names",
75
+ "revoked"
76
+ ],
77
+ "additionalProperties": false
78
+ },
79
+ "community": {
80
+ "anyOf": [
81
+ {
82
+ "type": "object",
83
+ "properties": {
84
+ "genesis": {
85
+ "type": "string"
86
+ },
87
+ "head": {
88
+ "$ref": "#/$defs/Dec"
89
+ }
90
+ },
91
+ "required": [
92
+ "genesis",
93
+ "head"
94
+ ],
95
+ "additionalProperties": false
96
+ },
97
+ {
98
+ "type": "null"
99
+ }
100
+ ]
101
+ },
102
+ "lineage": {
103
+ "type": "array",
104
+ "items": {
105
+ "type": "object"
106
+ }
107
+ }
108
+ },
109
+ "required": [
110
+ "labels",
111
+ "pairNonces",
112
+ "carriers",
113
+ "devices",
114
+ "community",
115
+ "lineage"
116
+ ],
117
+ "additionalProperties": false
118
+ },
119
+ "addresses": {
120
+ "type": "object",
121
+ "properties": {
122
+ "keys": {
123
+ "type": "object",
124
+ "additionalProperties": {
125
+ "type": "object",
126
+ "properties": {
127
+ "label": {
128
+ "type": "string"
129
+ },
130
+ "lastShown": {
131
+ "$ref": "#/$defs/Millis"
132
+ },
133
+ "retiredAt": {
134
+ "$ref": "#/$defs/Millis"
135
+ }
136
+ },
137
+ "required": [
138
+ "label",
139
+ "lastShown"
140
+ ],
141
+ "additionalProperties": false
142
+ }
143
+ },
144
+ "tombstones": {
145
+ "type": "array",
146
+ "items": {
147
+ "type": "string"
148
+ },
149
+ "uniqueItems": true
150
+ }
151
+ },
152
+ "required": [
153
+ "keys",
154
+ "tombstones"
155
+ ],
156
+ "additionalProperties": false
157
+ },
158
+ "contacts": {
159
+ "type": "object",
160
+ "additionalProperties": {
161
+ "$ref": "#/$defs/Contact"
162
+ }
163
+ },
164
+ "relationships": {
165
+ "type": "object",
166
+ "additionalProperties": {
167
+ "$ref": "#/$defs/Relationship"
168
+ }
169
+ },
170
+ "entryOrder": {
171
+ "type": "object",
172
+ "properties": {
173
+ "nextPos": {
174
+ "$ref": "#/$defs/Dec"
175
+ },
176
+ "heads": {
177
+ "type": "array",
178
+ "items": {
179
+ "type": "string"
180
+ },
181
+ "uniqueItems": true
182
+ }
183
+ },
184
+ "required": [
185
+ "nextPos",
186
+ "heads"
187
+ ],
188
+ "additionalProperties": false
189
+ },
190
+ "groups": {
191
+ "type": "object",
192
+ "additionalProperties": {
193
+ "$ref": "#/$defs/Group"
194
+ }
195
+ },
196
+ "profile": {
197
+ "type": "object",
198
+ "properties": {
199
+ "body": true,
200
+ "revision": {
201
+ "$ref": "#/$defs/Dec"
202
+ }
203
+ },
204
+ "required": [
205
+ "body",
206
+ "revision"
207
+ ],
208
+ "additionalProperties": false
209
+ },
210
+ "effects": {
211
+ "type": "object",
212
+ "additionalProperties": {
213
+ "type": "object",
214
+ "properties": {
215
+ "ack": {
216
+ "anyOf": [
217
+ {
218
+ "$ref": "#/$defs/StoredAck"
219
+ },
220
+ {
221
+ "type": "null"
222
+ }
223
+ ]
224
+ },
225
+ "expiresAt": {
226
+ "$ref": "#/$defs/Millis"
227
+ }
228
+ },
229
+ "required": [
230
+ "ack",
231
+ "expiresAt"
232
+ ],
233
+ "additionalProperties": false
234
+ }
235
+ },
236
+ "outbox": {
237
+ "type": "object",
238
+ "additionalProperties": {
239
+ "$ref": "#/$defs/OutboxItem"
240
+ }
241
+ },
242
+ "duties": {
243
+ "type": "object",
244
+ "additionalProperties": {
245
+ "$ref": "#/$defs/Duty"
246
+ }
247
+ },
248
+ "rotations": {
249
+ "type": "object",
250
+ "additionalProperties": {
251
+ "$ref": "#/$defs/Rotation"
252
+ }
253
+ },
254
+ "prompts": {
255
+ "type": "object",
256
+ "additionalProperties": {
257
+ "$ref": "#/$defs/Prompt"
258
+ }
259
+ },
260
+ "acts": {
261
+ "type": "object",
262
+ "additionalProperties": {
263
+ "$ref": "#/$defs/ActRecord"
264
+ }
265
+ },
266
+ "encounter": {
267
+ "type": "object",
268
+ "properties": {
269
+ "challenges": {
270
+ "type": "object",
271
+ "additionalProperties": {
272
+ "type": "object",
273
+ "properties": {
274
+ "value": {
275
+ "type": "string"
276
+ },
277
+ "tCh": {
278
+ "$ref": "#/$defs/Millis"
279
+ },
280
+ "label": {
281
+ "type": "string"
282
+ },
283
+ "card": {
284
+ "type": "object"
285
+ }
286
+ },
287
+ "required": [
288
+ "value",
289
+ "tCh",
290
+ "label",
291
+ "card"
292
+ ],
293
+ "additionalProperties": false
294
+ }
295
+ },
296
+ "records": {
297
+ "type": "object",
298
+ "additionalProperties": {
299
+ "$ref": "#/$defs/EnactmentRecord"
300
+ }
301
+ },
302
+ "introductions": {
303
+ "type": "object",
304
+ "additionalProperties": {
305
+ "$ref": "#/$defs/IntroAct"
306
+ }
307
+ },
308
+ "offers": {
309
+ "type": "object",
310
+ "additionalProperties": {
311
+ "type": "object",
312
+ "properties": {
313
+ "id": {
314
+ "type": "string"
315
+ },
316
+ "mediatorContactId": {
317
+ "type": "string"
318
+ },
319
+ "pin": {
320
+ "type": "string"
321
+ },
322
+ "target": {
323
+ "type": "string"
324
+ },
325
+ "at": {
326
+ "$ref": "#/$defs/Millis"
327
+ },
328
+ "label": {
329
+ "type": "string"
330
+ }
331
+ },
332
+ "required": [
333
+ "id",
334
+ "mediatorContactId",
335
+ "pin",
336
+ "target",
337
+ "at"
338
+ ],
339
+ "additionalProperties": false
340
+ }
341
+ },
342
+ "designators": {
343
+ "type": "object",
344
+ "additionalProperties": {
345
+ "type": "string"
346
+ }
347
+ },
348
+ "declarations": {
349
+ "type": "object",
350
+ "additionalProperties": {
351
+ "type": "object",
352
+ "properties": {
353
+ "issuer": {
354
+ "type": "string"
355
+ },
356
+ "role": {
357
+ "type": "string"
358
+ },
359
+ "revision": {
360
+ "$ref": "#/$defs/Dec"
361
+ },
362
+ "constants": {
363
+ "type": "object",
364
+ "additionalProperties": {
365
+ "type": "string"
366
+ }
367
+ },
368
+ "at": {
369
+ "$ref": "#/$defs/Millis"
370
+ }
371
+ },
372
+ "required": [
373
+ "issuer",
374
+ "role",
375
+ "revision",
376
+ "constants",
377
+ "at"
378
+ ],
379
+ "additionalProperties": false
380
+ }
381
+ }
382
+ },
383
+ "required": [
384
+ "challenges",
385
+ "records",
386
+ "introductions",
387
+ "offers",
388
+ "designators",
389
+ "declarations"
390
+ ],
391
+ "additionalProperties": false
392
+ },
393
+ "joining": {
394
+ "type": "object",
395
+ "properties": {
396
+ "preludes": {
397
+ "type": "object",
398
+ "additionalProperties": {
399
+ "type": "object",
400
+ "properties": {
401
+ "group": {
402
+ "type": "string"
403
+ },
404
+ "inviter": {
405
+ "type": "string"
406
+ },
407
+ "contactId": {
408
+ "type": "string"
409
+ },
410
+ "rkid": {
411
+ "type": "string"
412
+ },
413
+ "memberLabel": {
414
+ "type": "string"
415
+ },
416
+ "at": {
417
+ "$ref": "#/$defs/Millis"
418
+ }
419
+ },
420
+ "required": [
421
+ "group",
422
+ "inviter",
423
+ "contactId",
424
+ "rkid",
425
+ "memberLabel",
426
+ "at"
427
+ ],
428
+ "additionalProperties": false
429
+ }
430
+ },
431
+ "invites": {
432
+ "type": "object",
433
+ "additionalProperties": {
434
+ "type": "object",
435
+ "properties": {
436
+ "credDigest": {
437
+ "type": "string"
438
+ },
439
+ "group": {
440
+ "type": "string"
441
+ },
442
+ "name": {
443
+ "type": "string"
444
+ },
445
+ "contactId": {
446
+ "type": "string"
447
+ },
448
+ "rkid": {
449
+ "type": "string"
450
+ },
451
+ "memberLabel": {
452
+ "type": "string"
453
+ },
454
+ "invite": {
455
+ "type": "object"
456
+ },
457
+ "promptId": {
458
+ "type": "string"
459
+ },
460
+ "validUntil": {
461
+ "$ref": "#/$defs/Millis"
462
+ },
463
+ "status": {
464
+ "enum": [
465
+ "open",
466
+ "accepted",
467
+ "declined",
468
+ "joined"
469
+ ]
470
+ },
471
+ "at": {
472
+ "$ref": "#/$defs/Millis"
473
+ },
474
+ "acceptDigest": {
475
+ "type": "string"
476
+ }
477
+ },
478
+ "required": [
479
+ "credDigest",
480
+ "group",
481
+ "name",
482
+ "contactId",
483
+ "rkid",
484
+ "memberLabel",
485
+ "invite",
486
+ "promptId",
487
+ "validUntil",
488
+ "status",
489
+ "at"
490
+ ],
491
+ "additionalProperties": false
492
+ }
493
+ }
494
+ },
495
+ "required": [
496
+ "preludes",
497
+ "invites"
498
+ ],
499
+ "additionalProperties": false
500
+ }
501
+ },
502
+ "required": [
503
+ "codec",
504
+ "commitSeq",
505
+ "lastWhen",
506
+ "register",
507
+ "addresses",
508
+ "contacts",
509
+ "relationships",
510
+ "entryOrder",
511
+ "groups",
512
+ "profile",
513
+ "effects",
514
+ "outbox",
515
+ "duties",
516
+ "rotations",
517
+ "prompts",
518
+ "acts",
519
+ "encounter",
520
+ "joining"
521
+ ],
522
+ "additionalProperties": false,
523
+ "$defs": {
524
+ "Dec": {
525
+ "description": "a counter as a canonical decimal string",
526
+ "type": "string",
527
+ "pattern": "^(0|[1-9][0-9]{0,17})$"
528
+ },
529
+ "Millis": {
530
+ "description": "milliseconds since the epoch, a safe non-negative integer",
531
+ "type": "integer",
532
+ "minimum": 0,
533
+ "maximum": 9007199254740991
534
+ },
535
+ "Setting": {
536
+ "enum": [
537
+ "default",
538
+ "on",
539
+ "off"
540
+ ]
541
+ },
542
+ "TrustClass": {
543
+ "enum": [
544
+ "star",
545
+ "groupStar",
546
+ "anchorMapping",
547
+ "sealedGroupStar",
548
+ "profile"
549
+ ]
550
+ },
551
+ "Recipient": {
552
+ "type": "object",
553
+ "properties": {
554
+ "contactId": {
555
+ "type": "string"
556
+ },
557
+ "rkid": {
558
+ "type": "string"
559
+ },
560
+ "keyAgreement": {
561
+ "type": "string"
562
+ },
563
+ "anchor": {
564
+ "type": "string"
565
+ },
566
+ "via": {
567
+ "type": "string"
568
+ }
569
+ },
570
+ "required": [
571
+ "contactId",
572
+ "rkid",
573
+ "keyAgreement"
574
+ ],
575
+ "additionalProperties": false
576
+ },
577
+ "Envelope": {
578
+ "type": "object",
579
+ "properties": {
580
+ "rkid": {
581
+ "type": "string"
582
+ },
583
+ "epk": {
584
+ "type": "string"
585
+ },
586
+ "nonce": {
587
+ "type": "string"
588
+ },
589
+ "ciphertext": {
590
+ "type": "string"
591
+ }
592
+ },
593
+ "required": [
594
+ "rkid",
595
+ "epk",
596
+ "nonce",
597
+ "ciphertext"
598
+ ],
599
+ "additionalProperties": false
600
+ },
601
+ "Assembly": {
602
+ "type": "object",
603
+ "properties": {
604
+ "salt": {
605
+ "$ref": "#/$defs/Dec"
606
+ },
607
+ "chunks": {
608
+ "type": "object",
609
+ "additionalProperties": true
610
+ }
611
+ },
612
+ "required": [
613
+ "salt",
614
+ "chunks"
615
+ ],
616
+ "additionalProperties": false
617
+ },
618
+ "StarPair": {
619
+ "type": "object",
620
+ "properties": {
621
+ "member": {
622
+ "type": "string"
623
+ },
624
+ "head": {
625
+ "type": "string"
626
+ }
627
+ },
628
+ "required": [
629
+ "member",
630
+ "head"
631
+ ],
632
+ "additionalProperties": false
633
+ },
634
+ "GroupStarItem": {
635
+ "anyOf": [
636
+ {
637
+ "type": "object",
638
+ "properties": {
639
+ "group": {
640
+ "type": "string"
641
+ },
642
+ "mode": {
643
+ "const": "digest"
644
+ }
645
+ },
646
+ "required": [
647
+ "group",
648
+ "mode"
649
+ ],
650
+ "additionalProperties": false
651
+ },
652
+ {
653
+ "type": "object",
654
+ "properties": {
655
+ "group": {
656
+ "type": "string"
657
+ },
658
+ "mode": {
659
+ "const": "sealed"
660
+ },
661
+ "member": {
662
+ "type": "string"
663
+ },
664
+ "memberOp": {
665
+ "type": "string"
666
+ }
667
+ },
668
+ "required": [
669
+ "group",
670
+ "mode",
671
+ "member",
672
+ "memberOp"
673
+ ],
674
+ "additionalProperties": false
675
+ }
676
+ ]
677
+ },
678
+ "StarOutInflight": {
679
+ "type": "object",
680
+ "properties": {
681
+ "view": {
682
+ "type": "array",
683
+ "items": {
684
+ "$ref": "#/$defs/StarPair"
685
+ }
686
+ },
687
+ "viewDigest": {
688
+ "type": "string"
689
+ },
690
+ "digests": {
691
+ "type": "array",
692
+ "items": {
693
+ "type": "string"
694
+ }
695
+ },
696
+ "acked": {
697
+ "type": "array",
698
+ "items": {
699
+ "type": "string"
700
+ }
701
+ }
702
+ },
703
+ "required": [
704
+ "view",
705
+ "viewDigest",
706
+ "digests",
707
+ "acked"
708
+ ],
709
+ "additionalProperties": false
710
+ },
711
+ "StarOut": {
712
+ "description": "the sender side of one reconciled sequence (5.4); snapshot and snapshotDigest are null together",
713
+ "type": "object",
714
+ "properties": {
715
+ "lastSalt": {
716
+ "$ref": "#/$defs/Dec"
717
+ },
718
+ "exhausted": {
719
+ "type": "boolean"
720
+ },
721
+ "hwm": {
722
+ "$ref": "#/$defs/Dec"
723
+ },
724
+ "snapshot": {
725
+ "anyOf": [
726
+ {
727
+ "type": "array",
728
+ "items": {
729
+ "$ref": "#/$defs/StarPair"
730
+ }
731
+ },
732
+ {
733
+ "type": "null"
734
+ }
735
+ ]
736
+ },
737
+ "snapshotDigest": {
738
+ "anyOf": [
739
+ {
740
+ "type": "string"
741
+ },
742
+ {
743
+ "type": "null"
744
+ }
745
+ ]
746
+ },
747
+ "inflight": {
748
+ "type": "object",
749
+ "additionalProperties": {
750
+ "$ref": "#/$defs/StarOutInflight"
751
+ }
752
+ }
753
+ },
754
+ "required": [
755
+ "lastSalt",
756
+ "exhausted",
757
+ "hwm",
758
+ "snapshot",
759
+ "snapshotDigest",
760
+ "inflight"
761
+ ],
762
+ "additionalProperties": false,
763
+ "if": {
764
+ "properties": {
765
+ "snapshot": {
766
+ "type": "null"
767
+ }
768
+ }
769
+ },
770
+ "then": {
771
+ "properties": {
772
+ "snapshotDigest": {
773
+ "type": "null"
774
+ }
775
+ }
776
+ },
777
+ "else": {
778
+ "properties": {
779
+ "snapshotDigest": {
780
+ "type": "string"
781
+ }
782
+ }
783
+ }
784
+ },
785
+ "StarIn": {
786
+ "type": "object",
787
+ "properties": {
788
+ "hwm": {
789
+ "$ref": "#/$defs/Dec"
790
+ },
791
+ "lowerBound": {
792
+ "$ref": "#/$defs/Dec"
793
+ },
794
+ "assembly": {
795
+ "anyOf": [
796
+ {
797
+ "$ref": "#/$defs/Assembly"
798
+ },
799
+ {
800
+ "type": "null"
801
+ }
802
+ ]
803
+ },
804
+ "accepted": {
805
+ "anyOf": [
806
+ {
807
+ "type": "object",
808
+ "properties": {
809
+ "salt": {
810
+ "$ref": "#/$defs/Dec"
811
+ },
812
+ "blinded": {
813
+ "type": "array",
814
+ "items": {
815
+ "type": "string"
816
+ }
817
+ },
818
+ "matches": {
819
+ "type": "array",
820
+ "items": {
821
+ "type": "string"
822
+ }
823
+ }
824
+ },
825
+ "required": [
826
+ "salt",
827
+ "blinded",
828
+ "matches"
829
+ ],
830
+ "additionalProperties": false
831
+ },
832
+ {
833
+ "type": "null"
834
+ }
835
+ ]
836
+ }
837
+ },
838
+ "required": [
839
+ "hwm",
840
+ "lowerBound",
841
+ "assembly",
842
+ "accepted"
843
+ ],
844
+ "additionalProperties": false
845
+ },
846
+ "GroupStarOutInflight": {
847
+ "type": "object",
848
+ "properties": {
849
+ "view": {
850
+ "type": "array",
851
+ "items": {
852
+ "$ref": "#/$defs/GroupStarItem"
853
+ }
854
+ },
855
+ "viewDigest": {
856
+ "type": "string"
857
+ },
858
+ "digests": {
859
+ "type": "array",
860
+ "items": {
861
+ "type": "string"
862
+ }
863
+ },
864
+ "acked": {
865
+ "type": "array",
866
+ "items": {
867
+ "type": "string"
868
+ }
869
+ }
870
+ },
871
+ "required": [
872
+ "view",
873
+ "viewDigest",
874
+ "digests",
875
+ "acked"
876
+ ],
877
+ "additionalProperties": false
878
+ },
879
+ "GroupStarOut": {
880
+ "description": "the sender side of one reconciled sequence (5.4); snapshot and snapshotDigest are null together",
881
+ "type": "object",
882
+ "properties": {
883
+ "lastSalt": {
884
+ "$ref": "#/$defs/Dec"
885
+ },
886
+ "exhausted": {
887
+ "type": "boolean"
888
+ },
889
+ "hwm": {
890
+ "$ref": "#/$defs/Dec"
891
+ },
892
+ "snapshot": {
893
+ "anyOf": [
894
+ {
895
+ "type": "array",
896
+ "items": {
897
+ "$ref": "#/$defs/GroupStarItem"
898
+ }
899
+ },
900
+ {
901
+ "type": "null"
902
+ }
903
+ ]
904
+ },
905
+ "snapshotDigest": {
906
+ "anyOf": [
907
+ {
908
+ "type": "string"
909
+ },
910
+ {
911
+ "type": "null"
912
+ }
913
+ ]
914
+ },
915
+ "inflight": {
916
+ "type": "object",
917
+ "additionalProperties": {
918
+ "$ref": "#/$defs/GroupStarOutInflight"
919
+ }
920
+ }
921
+ },
922
+ "required": [
923
+ "lastSalt",
924
+ "exhausted",
925
+ "hwm",
926
+ "snapshot",
927
+ "snapshotDigest",
928
+ "inflight"
929
+ ],
930
+ "additionalProperties": false,
931
+ "if": {
932
+ "properties": {
933
+ "snapshot": {
934
+ "type": "null"
935
+ }
936
+ }
937
+ },
938
+ "then": {
939
+ "properties": {
940
+ "snapshotDigest": {
941
+ "type": "null"
942
+ }
943
+ }
944
+ },
945
+ "else": {
946
+ "properties": {
947
+ "snapshotDigest": {
948
+ "type": "string"
949
+ }
950
+ }
951
+ }
952
+ },
953
+ "GroupStarIn": {
954
+ "type": "object",
955
+ "properties": {
956
+ "hwm": {
957
+ "$ref": "#/$defs/Dec"
958
+ },
959
+ "lowerBound": {
960
+ "$ref": "#/$defs/Dec"
961
+ },
962
+ "assembly": {
963
+ "anyOf": [
964
+ {
965
+ "$ref": "#/$defs/Assembly"
966
+ },
967
+ {
968
+ "type": "null"
969
+ }
970
+ ]
971
+ },
972
+ "accepted": {
973
+ "anyOf": [
974
+ {
975
+ "type": "object",
976
+ "properties": {
977
+ "salt": {
978
+ "$ref": "#/$defs/Dec"
979
+ },
980
+ "entries": {
981
+ "type": "array",
982
+ "items": {
983
+ "type": "object",
984
+ "properties": {
985
+ "d": {
986
+ "type": "string"
987
+ },
988
+ "c": {
989
+ "type": "string"
990
+ }
991
+ },
992
+ "required": [
993
+ "d",
994
+ "c"
995
+ ],
996
+ "additionalProperties": false
997
+ }
998
+ },
999
+ "groups": {
1000
+ "type": "array",
1001
+ "items": {
1002
+ "type": "string"
1003
+ }
1004
+ }
1005
+ },
1006
+ "required": [
1007
+ "salt",
1008
+ "entries",
1009
+ "groups"
1010
+ ],
1011
+ "additionalProperties": false
1012
+ },
1013
+ {
1014
+ "type": "null"
1015
+ }
1016
+ ]
1017
+ }
1018
+ },
1019
+ "required": [
1020
+ "hwm",
1021
+ "lowerBound",
1022
+ "assembly",
1023
+ "accepted"
1024
+ ],
1025
+ "additionalProperties": false
1026
+ },
1027
+ "ContinuityDue": {
1028
+ "anyOf": [
1029
+ {
1030
+ "type": "object",
1031
+ "properties": {
1032
+ "kind": {
1033
+ "const": "choice"
1034
+ },
1035
+ "prior": {
1036
+ "type": "string"
1037
+ },
1038
+ "alts": {
1039
+ "type": "array",
1040
+ "items": {
1041
+ "type": "string"
1042
+ }
1043
+ }
1044
+ },
1045
+ "required": [
1046
+ "kind",
1047
+ "prior",
1048
+ "alts"
1049
+ ],
1050
+ "additionalProperties": false
1051
+ },
1052
+ {
1053
+ "type": "object",
1054
+ "properties": {
1055
+ "kind": {
1056
+ "enum": [
1057
+ "report",
1058
+ "align"
1059
+ ]
1060
+ },
1061
+ "prior": {
1062
+ "type": "string"
1063
+ }
1064
+ },
1065
+ "required": [
1066
+ "kind",
1067
+ "prior"
1068
+ ],
1069
+ "additionalProperties": false
1070
+ }
1071
+ ]
1072
+ },
1073
+ "LogHead": {
1074
+ "anyOf": [
1075
+ {
1076
+ "type": "object",
1077
+ "properties": {
1078
+ "genesis": {
1079
+ "type": "string"
1080
+ },
1081
+ "empty": {
1082
+ "const": true
1083
+ }
1084
+ },
1085
+ "required": [
1086
+ "genesis",
1087
+ "empty"
1088
+ ],
1089
+ "additionalProperties": false
1090
+ },
1091
+ {
1092
+ "type": "object",
1093
+ "properties": {
1094
+ "genesis": {
1095
+ "type": "string"
1096
+ },
1097
+ "entryId": {
1098
+ "type": "string"
1099
+ },
1100
+ "gen": {
1101
+ "type": "integer",
1102
+ "minimum": 1,
1103
+ "maximum": 9007199254740991
1104
+ },
1105
+ "next": {
1106
+ "type": "string"
1107
+ },
1108
+ "commit": {
1109
+ "type": "string"
1110
+ }
1111
+ },
1112
+ "required": [
1113
+ "genesis",
1114
+ "entryId",
1115
+ "gen",
1116
+ "next",
1117
+ "commit"
1118
+ ],
1119
+ "additionalProperties": false
1120
+ }
1121
+ ]
1122
+ },
1123
+ "Tuple": {
1124
+ "description": "one enactment's tuple of a relationship (Trust 6.4)",
1125
+ "type": "object",
1126
+ "properties": {
1127
+ "ownPairLabel": {
1128
+ "type": "string"
1129
+ },
1130
+ "counterpartAnchor": {
1131
+ "type": "string"
1132
+ },
1133
+ "counterpartKeyAgreement": {
1134
+ "type": "string"
1135
+ },
1136
+ "rkid": {
1137
+ "type": "string"
1138
+ },
1139
+ "entryId": {
1140
+ "type": "string"
1141
+ },
1142
+ "priorCandidates": {
1143
+ "type": "array",
1144
+ "items": {
1145
+ "type": "object",
1146
+ "properties": {
1147
+ "ownPairLabel": {
1148
+ "type": "string"
1149
+ },
1150
+ "counterpartAnchor": {
1151
+ "type": "string"
1152
+ },
1153
+ "replaces": {
1154
+ "type": "array",
1155
+ "items": {
1156
+ "type": "string"
1157
+ }
1158
+ }
1159
+ },
1160
+ "required": [
1161
+ "ownPairLabel",
1162
+ "counterpartAnchor"
1163
+ ],
1164
+ "additionalProperties": false
1165
+ }
1166
+ },
1167
+ "starOut": {
1168
+ "$ref": "#/$defs/StarOut"
1169
+ },
1170
+ "starIn": {
1171
+ "$ref": "#/$defs/StarIn"
1172
+ },
1173
+ "groupStarOut": {
1174
+ "$ref": "#/$defs/GroupStarOut"
1175
+ },
1176
+ "groupStarIn": {
1177
+ "$ref": "#/$defs/GroupStarIn"
1178
+ },
1179
+ "probeOut": {
1180
+ "type": "object",
1181
+ "properties": {
1182
+ "seq": {
1183
+ "$ref": "#/$defs/Dec"
1184
+ },
1185
+ "inflight": {
1186
+ "type": "object",
1187
+ "additionalProperties": {
1188
+ "type": "object",
1189
+ "properties": {
1190
+ "digests": {
1191
+ "type": "array",
1192
+ "items": {
1193
+ "type": "string"
1194
+ }
1195
+ },
1196
+ "acked": {
1197
+ "type": "array",
1198
+ "items": {
1199
+ "type": "string"
1200
+ }
1201
+ }
1202
+ },
1203
+ "required": [
1204
+ "digests",
1205
+ "acked"
1206
+ ],
1207
+ "additionalProperties": false
1208
+ }
1209
+ },
1210
+ "done": {
1211
+ "type": "boolean"
1212
+ }
1213
+ },
1214
+ "required": [
1215
+ "seq",
1216
+ "inflight",
1217
+ "done"
1218
+ ],
1219
+ "additionalProperties": false
1220
+ },
1221
+ "probeIn": {
1222
+ "type": "object",
1223
+ "properties": {
1224
+ "hwm": {
1225
+ "$ref": "#/$defs/Dec"
1226
+ },
1227
+ "lowerBound": {
1228
+ "$ref": "#/$defs/Dec"
1229
+ },
1230
+ "assembly": {
1231
+ "anyOf": [
1232
+ {
1233
+ "$ref": "#/$defs/Assembly"
1234
+ },
1235
+ {
1236
+ "type": "null"
1237
+ }
1238
+ ]
1239
+ }
1240
+ },
1241
+ "required": [
1242
+ "hwm",
1243
+ "lowerBound",
1244
+ "assembly"
1245
+ ],
1246
+ "additionalProperties": false
1247
+ },
1248
+ "continuityOut": {
1249
+ "type": "object",
1250
+ "properties": {
1251
+ "rev": {
1252
+ "$ref": "#/$defs/Dec"
1253
+ },
1254
+ "body": true,
1255
+ "proof": true,
1256
+ "sent": {
1257
+ "type": "array",
1258
+ "items": {
1259
+ "type": "string"
1260
+ }
1261
+ },
1262
+ "align": {
1263
+ "type": "boolean"
1264
+ },
1265
+ "chosen": {
1266
+ "anyOf": [
1267
+ {
1268
+ "type": "string"
1269
+ },
1270
+ {
1271
+ "type": "null"
1272
+ }
1273
+ ]
1274
+ },
1275
+ "reported": {
1276
+ "anyOf": [
1277
+ {
1278
+ "type": "string"
1279
+ },
1280
+ {
1281
+ "type": "null"
1282
+ }
1283
+ ]
1284
+ },
1285
+ "aligned": {
1286
+ "type": "boolean"
1287
+ },
1288
+ "due": {
1289
+ "anyOf": [
1290
+ {
1291
+ "$ref": "#/$defs/ContinuityDue"
1292
+ },
1293
+ {
1294
+ "type": "null"
1295
+ }
1296
+ ]
1297
+ }
1298
+ },
1299
+ "required": [
1300
+ "rev",
1301
+ "body",
1302
+ "proof",
1303
+ "sent",
1304
+ "align",
1305
+ "chosen",
1306
+ "reported",
1307
+ "aligned",
1308
+ "due"
1309
+ ],
1310
+ "additionalProperties": false
1311
+ },
1312
+ "continuityIn": {
1313
+ "type": "object",
1314
+ "properties": {
1315
+ "rev": {
1316
+ "$ref": "#/$defs/Dec"
1317
+ },
1318
+ "body": true,
1319
+ "recordPrior": {
1320
+ "anyOf": [
1321
+ {
1322
+ "type": "string"
1323
+ },
1324
+ {
1325
+ "type": "null"
1326
+ }
1327
+ ]
1328
+ }
1329
+ },
1330
+ "required": [
1331
+ "rev",
1332
+ "body",
1333
+ "recordPrior"
1334
+ ],
1335
+ "additionalProperties": false
1336
+ },
1337
+ "mappingOut": {
1338
+ "type": "object",
1339
+ "properties": {
1340
+ "rev": {
1341
+ "$ref": "#/$defs/Dec"
1342
+ },
1343
+ "body": true,
1344
+ "underAnchor": {
1345
+ "anyOf": [
1346
+ {
1347
+ "type": "string"
1348
+ },
1349
+ {
1350
+ "type": "null"
1351
+ }
1352
+ ]
1353
+ }
1354
+ },
1355
+ "required": [
1356
+ "rev",
1357
+ "body",
1358
+ "underAnchor"
1359
+ ],
1360
+ "additionalProperties": false
1361
+ },
1362
+ "mappingIn": {
1363
+ "type": "object",
1364
+ "properties": {
1365
+ "rev": {
1366
+ "$ref": "#/$defs/Dec"
1367
+ },
1368
+ "body": true,
1369
+ "self": {
1370
+ "anyOf": [
1371
+ {
1372
+ "type": "string"
1373
+ },
1374
+ {
1375
+ "type": "null"
1376
+ }
1377
+ ]
1378
+ },
1379
+ "card": true
1380
+ },
1381
+ "required": [
1382
+ "rev",
1383
+ "body",
1384
+ "self",
1385
+ "card"
1386
+ ],
1387
+ "additionalProperties": false
1388
+ },
1389
+ "profileOut": {
1390
+ "type": "object",
1391
+ "properties": {
1392
+ "rev": {
1393
+ "$ref": "#/$defs/Dec"
1394
+ }
1395
+ },
1396
+ "required": [
1397
+ "rev"
1398
+ ],
1399
+ "additionalProperties": false
1400
+ },
1401
+ "profileIn": {
1402
+ "type": "object",
1403
+ "properties": {
1404
+ "rev": {
1405
+ "$ref": "#/$defs/Dec"
1406
+ },
1407
+ "body": true,
1408
+ "verifiedSeq": {
1409
+ "$ref": "#/$defs/Dec"
1410
+ }
1411
+ },
1412
+ "required": [
1413
+ "rev",
1414
+ "body",
1415
+ "verifiedSeq"
1416
+ ],
1417
+ "additionalProperties": false
1418
+ },
1419
+ "deactivated": {
1420
+ "type": "boolean"
1421
+ }
1422
+ },
1423
+ "required": [
1424
+ "ownPairLabel",
1425
+ "counterpartAnchor",
1426
+ "counterpartKeyAgreement",
1427
+ "rkid",
1428
+ "entryId",
1429
+ "priorCandidates",
1430
+ "starOut",
1431
+ "starIn",
1432
+ "groupStarOut",
1433
+ "groupStarIn",
1434
+ "probeOut",
1435
+ "probeIn",
1436
+ "continuityOut",
1437
+ "continuityIn",
1438
+ "mappingOut",
1439
+ "mappingIn",
1440
+ "profileOut",
1441
+ "profileIn",
1442
+ "deactivated"
1443
+ ],
1444
+ "additionalProperties": false
1445
+ },
1446
+ "Relationship": {
1447
+ "type": "object",
1448
+ "properties": {
1449
+ "id": {
1450
+ "type": "string"
1451
+ },
1452
+ "contactId": {
1453
+ "type": "string"
1454
+ },
1455
+ "tuples": {
1456
+ "type": "array",
1457
+ "items": {
1458
+ "$ref": "#/$defs/Tuple"
1459
+ }
1460
+ },
1461
+ "activeHead": {
1462
+ "type": "string"
1463
+ },
1464
+ "earliestAnchor": {
1465
+ "anyOf": [
1466
+ {
1467
+ "type": "string"
1468
+ },
1469
+ {
1470
+ "type": "null"
1471
+ }
1472
+ ]
1473
+ },
1474
+ "links": {
1475
+ "type": "array",
1476
+ "items": {
1477
+ "type": "object",
1478
+ "properties": {
1479
+ "prev": {
1480
+ "type": "string"
1481
+ },
1482
+ "next": {
1483
+ "type": "string"
1484
+ }
1485
+ },
1486
+ "required": [
1487
+ "prev",
1488
+ "next"
1489
+ ],
1490
+ "additionalProperties": false
1491
+ }
1492
+ },
1493
+ "bindings": {
1494
+ "type": "object",
1495
+ "additionalProperties": {
1496
+ "type": "array",
1497
+ "items": {
1498
+ "type": "string"
1499
+ },
1500
+ "uniqueItems": true
1501
+ }
1502
+ },
1503
+ "heldCounterpartHead": {
1504
+ "anyOf": [
1505
+ {
1506
+ "type": "string"
1507
+ },
1508
+ {
1509
+ "type": "null"
1510
+ }
1511
+ ]
1512
+ },
1513
+ "memory": {
1514
+ "type": "object",
1515
+ "additionalProperties": true
1516
+ },
1517
+ "provenance": {
1518
+ "type": "object",
1519
+ "properties": {
1520
+ "kind": {
1521
+ "enum": [
1522
+ "ceremony",
1523
+ "introduced"
1524
+ ]
1525
+ },
1526
+ "at": {
1527
+ "$ref": "#/$defs/Millis"
1528
+ },
1529
+ "via": {
1530
+ "type": "string"
1531
+ },
1532
+ "viaPin": {
1533
+ "type": "string"
1534
+ }
1535
+ },
1536
+ "required": [
1537
+ "kind",
1538
+ "at"
1539
+ ],
1540
+ "additionalProperties": false
1541
+ },
1542
+ "chainedInto": {
1543
+ "anyOf": [
1544
+ {
1545
+ "type": "string"
1546
+ },
1547
+ {
1548
+ "type": "null"
1549
+ }
1550
+ ]
1551
+ },
1552
+ "firstVerified": {
1553
+ "anyOf": [
1554
+ {
1555
+ "$ref": "#/$defs/Dec"
1556
+ },
1557
+ {
1558
+ "type": "null"
1559
+ }
1560
+ ]
1561
+ }
1562
+ },
1563
+ "required": [
1564
+ "id",
1565
+ "contactId",
1566
+ "tuples",
1567
+ "activeHead",
1568
+ "earliestAnchor",
1569
+ "links",
1570
+ "bindings",
1571
+ "heldCounterpartHead",
1572
+ "memory",
1573
+ "provenance",
1574
+ "chainedInto",
1575
+ "firstVerified"
1576
+ ],
1577
+ "additionalProperties": false
1578
+ },
1579
+ "Contact": {
1580
+ "description": "one entry of the deliverable set (Trust 2120, 2140); its id equals its key",
1581
+ "type": "object",
1582
+ "properties": {
1583
+ "id": {
1584
+ "type": "string"
1585
+ },
1586
+ "pos": {
1587
+ "anyOf": [
1588
+ {
1589
+ "$ref": "#/$defs/Dec"
1590
+ },
1591
+ {
1592
+ "type": "null"
1593
+ }
1594
+ ]
1595
+ },
1596
+ "status": {
1597
+ "enum": [
1598
+ "none",
1599
+ "admitted",
1600
+ "pending"
1601
+ ]
1602
+ },
1603
+ "aliases": {
1604
+ "type": "array",
1605
+ "items": {
1606
+ "type": "string"
1607
+ },
1608
+ "uniqueItems": true
1609
+ },
1610
+ "relIds": {
1611
+ "type": "array",
1612
+ "items": {
1613
+ "type": "string"
1614
+ },
1615
+ "uniqueItems": true
1616
+ },
1617
+ "anchorHead": {
1618
+ "anyOf": [
1619
+ {
1620
+ "type": "string"
1621
+ },
1622
+ {
1623
+ "type": "null"
1624
+ }
1625
+ ]
1626
+ },
1627
+ "settings": {
1628
+ "type": "object",
1629
+ "properties": {
1630
+ "star": {
1631
+ "$ref": "#/$defs/Setting"
1632
+ },
1633
+ "groupStar": {
1634
+ "$ref": "#/$defs/Setting"
1635
+ },
1636
+ "anchorMapping": {
1637
+ "$ref": "#/$defs/Setting"
1638
+ },
1639
+ "sealedGroupStar": {
1640
+ "$ref": "#/$defs/Setting"
1641
+ },
1642
+ "profile": {
1643
+ "$ref": "#/$defs/Setting"
1644
+ }
1645
+ },
1646
+ "required": [
1647
+ "star",
1648
+ "groupStar",
1649
+ "anchorMapping",
1650
+ "sealedGroupStar",
1651
+ "profile"
1652
+ ],
1653
+ "additionalProperties": false
1654
+ },
1655
+ "groupSettings": {
1656
+ "type": "object",
1657
+ "additionalProperties": {
1658
+ "$ref": "#/$defs/Setting"
1659
+ }
1660
+ }
1661
+ },
1662
+ "required": [
1663
+ "id",
1664
+ "pos",
1665
+ "status",
1666
+ "aliases",
1667
+ "relIds",
1668
+ "anchorHead",
1669
+ "settings",
1670
+ "groupSettings"
1671
+ ],
1672
+ "additionalProperties": false
1673
+ },
1674
+ "OutboxStep": {
1675
+ "anyOf": [
1676
+ {
1677
+ "type": "object",
1678
+ "properties": {
1679
+ "status": {
1680
+ "const": "submitted"
1681
+ },
1682
+ "at": {
1683
+ "$ref": "#/$defs/Millis"
1684
+ },
1685
+ "attempt": {
1686
+ "type": "integer",
1687
+ "minimum": 1,
1688
+ "maximum": 9007199254740991
1689
+ }
1690
+ },
1691
+ "required": [
1692
+ "status",
1693
+ "at",
1694
+ "attempt"
1695
+ ],
1696
+ "additionalProperties": false
1697
+ },
1698
+ {
1699
+ "type": "object",
1700
+ "properties": {
1701
+ "status": {
1702
+ "const": "awaiting-transport"
1703
+ },
1704
+ "at": {
1705
+ "$ref": "#/$defs/Millis"
1706
+ },
1707
+ "reason": {
1708
+ "enum": [
1709
+ "offline",
1710
+ "transport-unreachable",
1711
+ "carrier-refused-retriable"
1712
+ ]
1713
+ }
1714
+ },
1715
+ "required": [
1716
+ "status",
1717
+ "at",
1718
+ "reason"
1719
+ ],
1720
+ "additionalProperties": false
1721
+ },
1722
+ {
1723
+ "type": "object",
1724
+ "properties": {
1725
+ "status": {
1726
+ "const": "accepted"
1727
+ },
1728
+ "at": {
1729
+ "$ref": "#/$defs/Millis"
1730
+ }
1731
+ },
1732
+ "required": [
1733
+ "status",
1734
+ "at"
1735
+ ],
1736
+ "additionalProperties": false
1737
+ },
1738
+ {
1739
+ "type": "object",
1740
+ "properties": {
1741
+ "status": {
1742
+ "const": "delivered"
1743
+ },
1744
+ "at": {
1745
+ "$ref": "#/$defs/Millis"
1746
+ },
1747
+ "late": {
1748
+ "type": "boolean"
1749
+ }
1750
+ },
1751
+ "required": [
1752
+ "status",
1753
+ "at",
1754
+ "late"
1755
+ ],
1756
+ "additionalProperties": false
1757
+ },
1758
+ {
1759
+ "type": "object",
1760
+ "properties": {
1761
+ "status": {
1762
+ "const": "failed"
1763
+ },
1764
+ "at": {
1765
+ "$ref": "#/$defs/Millis"
1766
+ },
1767
+ "reason": {
1768
+ "enum": [
1769
+ "unroutable",
1770
+ "oversize",
1771
+ "expired-by-adapter-policy"
1772
+ ]
1773
+ }
1774
+ },
1775
+ "required": [
1776
+ "status",
1777
+ "at",
1778
+ "reason"
1779
+ ],
1780
+ "additionalProperties": false
1781
+ },
1782
+ {
1783
+ "type": "object",
1784
+ "properties": {
1785
+ "status": {
1786
+ "const": "failed"
1787
+ },
1788
+ "at": {
1789
+ "$ref": "#/$defs/Millis"
1790
+ },
1791
+ "reason": {
1792
+ "const": "rejected-by-receiver"
1793
+ },
1794
+ "code": {
1795
+ "enum": [
1796
+ "malformedRequest",
1797
+ "unsupportedType",
1798
+ "proofRequired",
1799
+ "proofInvalid",
1800
+ "wrongRecipient",
1801
+ "identityMismatch"
1802
+ ]
1803
+ }
1804
+ },
1805
+ "required": [
1806
+ "status",
1807
+ "at",
1808
+ "reason",
1809
+ "code"
1810
+ ],
1811
+ "additionalProperties": false
1812
+ }
1813
+ ]
1814
+ },
1815
+ "OutboxItem": {
1816
+ "description": "an issued document; its envelope's rkid equals recipient.keyAgreement (not expressible here, checked by the codec)",
1817
+ "type": "object",
1818
+ "properties": {
1819
+ "type": {
1820
+ "type": "string"
1821
+ },
1822
+ "threadId": {
1823
+ "type": "string"
1824
+ },
1825
+ "recipient": {
1826
+ "$ref": "#/$defs/Recipient"
1827
+ },
1828
+ "envelope": {
1829
+ "$ref": "#/$defs/Envelope"
1830
+ },
1831
+ "attempt": {
1832
+ "type": "integer",
1833
+ "minimum": 1,
1834
+ "maximum": 9007199254740991
1835
+ },
1836
+ "history": {
1837
+ "type": "array",
1838
+ "items": {
1839
+ "$ref": "#/$defs/OutboxStep"
1840
+ }
1841
+ },
1842
+ "nextAttemptAt": {
1843
+ "$ref": "#/$defs/Millis"
1844
+ }
1845
+ },
1846
+ "required": [
1847
+ "type",
1848
+ "threadId",
1849
+ "recipient",
1850
+ "envelope",
1851
+ "attempt",
1852
+ "history"
1853
+ ],
1854
+ "additionalProperties": false
1855
+ },
1856
+ "StoredAck": {
1857
+ "type": "object",
1858
+ "properties": {
1859
+ "digest": {
1860
+ "type": "string"
1861
+ },
1862
+ "envelope": {
1863
+ "$ref": "#/$defs/Envelope"
1864
+ },
1865
+ "threadId": {
1866
+ "type": "string"
1867
+ },
1868
+ "recipient": {
1869
+ "$ref": "#/$defs/Recipient"
1870
+ },
1871
+ "at": {
1872
+ "$ref": "#/$defs/Millis"
1873
+ },
1874
+ "attempt": {
1875
+ "type": "integer",
1876
+ "minimum": 1,
1877
+ "maximum": 9007199254740991
1878
+ },
1879
+ "sent": {
1880
+ "type": "boolean"
1881
+ },
1882
+ "nextAttemptAt": {
1883
+ "$ref": "#/$defs/Millis"
1884
+ },
1885
+ "sentBy": {
1886
+ "enum": [
1887
+ "report",
1888
+ "horizon"
1889
+ ]
1890
+ }
1891
+ },
1892
+ "required": [
1893
+ "digest",
1894
+ "envelope",
1895
+ "threadId",
1896
+ "recipient",
1897
+ "at",
1898
+ "attempt",
1899
+ "sent"
1900
+ ],
1901
+ "additionalProperties": false
1902
+ },
1903
+ "ReissueMappingDuty": {
1904
+ "type": "object",
1905
+ "properties": {
1906
+ "kind": {
1907
+ "const": "reissue-mapping"
1908
+ },
1909
+ "v": {
1910
+ "const": 1
1911
+ },
1912
+ "id": {
1913
+ "type": "string"
1914
+ },
1915
+ "contactId": {
1916
+ "type": "string"
1917
+ },
1918
+ "relId": {
1919
+ "type": "string"
1920
+ },
1921
+ "awaitHead": {
1922
+ "anyOf": [
1923
+ {
1924
+ "type": "string"
1925
+ },
1926
+ {
1927
+ "type": "null"
1928
+ }
1929
+ ]
1930
+ },
1931
+ "dueAt": {
1932
+ "$ref": "#/$defs/Millis"
1933
+ }
1934
+ },
1935
+ "required": [
1936
+ "kind",
1937
+ "v",
1938
+ "id",
1939
+ "contactId",
1940
+ "relId",
1941
+ "awaitHead"
1942
+ ],
1943
+ "additionalProperties": false
1944
+ },
1945
+ "ClassOnDuty": {
1946
+ "type": "object",
1947
+ "properties": {
1948
+ "kind": {
1949
+ "const": "class-on"
1950
+ },
1951
+ "v": {
1952
+ "const": 1
1953
+ },
1954
+ "id": {
1955
+ "type": "string"
1956
+ },
1957
+ "contactId": {
1958
+ "type": "string"
1959
+ },
1960
+ "relId": {
1961
+ "type": "string"
1962
+ },
1963
+ "cls": {
1964
+ "$ref": "#/$defs/TrustClass"
1965
+ },
1966
+ "dueAt": {
1967
+ "$ref": "#/$defs/Millis"
1968
+ }
1969
+ },
1970
+ "required": [
1971
+ "kind",
1972
+ "v",
1973
+ "id",
1974
+ "contactId",
1975
+ "relId",
1976
+ "cls"
1977
+ ],
1978
+ "additionalProperties": false
1979
+ },
1980
+ "ProfileDuty": {
1981
+ "type": "object",
1982
+ "properties": {
1983
+ "kind": {
1984
+ "const": "profile"
1985
+ },
1986
+ "v": {
1987
+ "const": 1
1988
+ },
1989
+ "id": {
1990
+ "type": "string"
1991
+ },
1992
+ "contactId": {
1993
+ "type": "string"
1994
+ },
1995
+ "relId": {
1996
+ "type": "string"
1997
+ },
1998
+ "rev": {
1999
+ "$ref": "#/$defs/Dec"
2000
+ },
2001
+ "dueAt": {
2002
+ "$ref": "#/$defs/Millis"
2003
+ }
2004
+ },
2005
+ "required": [
2006
+ "kind",
2007
+ "v",
2008
+ "id",
2009
+ "contactId",
2010
+ "relId",
2011
+ "rev"
2012
+ ],
2013
+ "additionalProperties": false
2014
+ },
2015
+ "ContinuityDuty": {
2016
+ "type": "object",
2017
+ "properties": {
2018
+ "kind": {
2019
+ "const": "continuity"
2020
+ },
2021
+ "v": {
2022
+ "const": 1
2023
+ },
2024
+ "id": {
2025
+ "type": "string"
2026
+ },
2027
+ "relId": {
2028
+ "type": "string"
2029
+ },
2030
+ "tuple": {
2031
+ "type": "string"
2032
+ },
2033
+ "step": {
2034
+ "enum": [
2035
+ "probe",
2036
+ "mapping"
2037
+ ]
2038
+ },
2039
+ "dueAt": {
2040
+ "$ref": "#/$defs/Millis"
2041
+ },
2042
+ "attempt": {
2043
+ "type": "integer",
2044
+ "minimum": 0,
2045
+ "maximum": 9007199254740991
2046
+ },
2047
+ "lastAt": {
2048
+ "$ref": "#/$defs/Millis"
2049
+ }
2050
+ },
2051
+ "required": [
2052
+ "kind",
2053
+ "v",
2054
+ "id",
2055
+ "relId",
2056
+ "tuple",
2057
+ "step"
2058
+ ],
2059
+ "additionalProperties": false
2060
+ },
2061
+ "MergeDuty": {
2062
+ "type": "object",
2063
+ "properties": {
2064
+ "kind": {
2065
+ "const": "merge"
2066
+ },
2067
+ "v": {
2068
+ "const": 1
2069
+ },
2070
+ "id": {
2071
+ "type": "string"
2072
+ },
2073
+ "entryIds": {
2074
+ "type": "array",
2075
+ "items": {
2076
+ "type": "string"
2077
+ },
2078
+ "uniqueItems": true
2079
+ },
2080
+ "relId": {
2081
+ "type": "string"
2082
+ },
2083
+ "witness": {
2084
+ "type": "object",
2085
+ "properties": {
2086
+ "heads": {
2087
+ "type": "object",
2088
+ "additionalProperties": {
2089
+ "type": "string"
2090
+ }
2091
+ },
2092
+ "superseded": {
2093
+ "type": "object",
2094
+ "additionalProperties": {
2095
+ "type": "array",
2096
+ "items": {
2097
+ "type": "string"
2098
+ },
2099
+ "uniqueItems": true
2100
+ }
2101
+ }
2102
+ },
2103
+ "required": [
2104
+ "heads",
2105
+ "superseded"
2106
+ ],
2107
+ "additionalProperties": false
2108
+ },
2109
+ "dueAt": {
2110
+ "$ref": "#/$defs/Millis"
2111
+ }
2112
+ },
2113
+ "required": [
2114
+ "kind",
2115
+ "v",
2116
+ "id",
2117
+ "entryIds",
2118
+ "relId",
2119
+ "witness"
2120
+ ],
2121
+ "additionalProperties": false
2122
+ },
2123
+ "RotationDuty": {
2124
+ "type": "object",
2125
+ "properties": {
2126
+ "kind": {
2127
+ "const": "rotation"
2128
+ },
2129
+ "v": {
2130
+ "const": 1
2131
+ },
2132
+ "id": {
2133
+ "type": "string"
2134
+ },
2135
+ "rotationId": {
2136
+ "type": "string"
2137
+ },
2138
+ "dueAt": {
2139
+ "$ref": "#/$defs/Millis"
2140
+ },
2141
+ "attempt": {
2142
+ "type": "integer",
2143
+ "minimum": 0,
2144
+ "maximum": 9007199254740991
2145
+ },
2146
+ "lastAt": {
2147
+ "$ref": "#/$defs/Millis"
2148
+ }
2149
+ },
2150
+ "required": [
2151
+ "kind",
2152
+ "v",
2153
+ "id",
2154
+ "rotationId"
2155
+ ],
2156
+ "additionalProperties": false
2157
+ },
2158
+ "IntroAckDuty": {
2159
+ "type": "object",
2160
+ "properties": {
2161
+ "kind": {
2162
+ "const": "intro-ack"
2163
+ },
2164
+ "v": {
2165
+ "const": 1
2166
+ },
2167
+ "id": {
2168
+ "type": "string"
2169
+ },
2170
+ "act": {
2171
+ "type": "string"
2172
+ },
2173
+ "dueAt": {
2174
+ "$ref": "#/$defs/Millis"
2175
+ }
2176
+ },
2177
+ "required": [
2178
+ "kind",
2179
+ "v",
2180
+ "id",
2181
+ "act"
2182
+ ],
2183
+ "additionalProperties": false
2184
+ },
2185
+ "UnknownDuty": {
2186
+ "description": "a duty of a kind or version this library does not handle: kept as it is",
2187
+ "type": "object",
2188
+ "properties": {
2189
+ "kind": {
2190
+ "type": "string"
2191
+ },
2192
+ "v": {
2193
+ "type": "integer",
2194
+ "minimum": 0,
2195
+ "maximum": 9007199254740991
2196
+ },
2197
+ "id": {
2198
+ "type": "string"
2199
+ }
2200
+ },
2201
+ "required": [
2202
+ "kind",
2203
+ "v",
2204
+ "id"
2205
+ ],
2206
+ "additionalProperties": true,
2207
+ "not": {
2208
+ "anyOf": [
2209
+ {
2210
+ "properties": {
2211
+ "kind": {
2212
+ "const": "reissue-mapping"
2213
+ },
2214
+ "v": {
2215
+ "const": 1
2216
+ }
2217
+ },
2218
+ "required": [
2219
+ "kind",
2220
+ "v"
2221
+ ]
2222
+ },
2223
+ {
2224
+ "properties": {
2225
+ "kind": {
2226
+ "const": "class-on"
2227
+ },
2228
+ "v": {
2229
+ "const": 1
2230
+ }
2231
+ },
2232
+ "required": [
2233
+ "kind",
2234
+ "v"
2235
+ ]
2236
+ },
2237
+ {
2238
+ "properties": {
2239
+ "kind": {
2240
+ "const": "profile"
2241
+ },
2242
+ "v": {
2243
+ "const": 1
2244
+ }
2245
+ },
2246
+ "required": [
2247
+ "kind",
2248
+ "v"
2249
+ ]
2250
+ },
2251
+ {
2252
+ "properties": {
2253
+ "kind": {
2254
+ "const": "continuity"
2255
+ },
2256
+ "v": {
2257
+ "const": 1
2258
+ }
2259
+ },
2260
+ "required": [
2261
+ "kind",
2262
+ "v"
2263
+ ]
2264
+ },
2265
+ {
2266
+ "properties": {
2267
+ "kind": {
2268
+ "const": "merge"
2269
+ },
2270
+ "v": {
2271
+ "const": 1
2272
+ }
2273
+ },
2274
+ "required": [
2275
+ "kind",
2276
+ "v"
2277
+ ]
2278
+ },
2279
+ {
2280
+ "properties": {
2281
+ "kind": {
2282
+ "const": "rotation"
2283
+ },
2284
+ "v": {
2285
+ "const": 1
2286
+ }
2287
+ },
2288
+ "required": [
2289
+ "kind",
2290
+ "v"
2291
+ ]
2292
+ },
2293
+ {
2294
+ "properties": {
2295
+ "kind": {
2296
+ "const": "intro-ack"
2297
+ },
2298
+ "v": {
2299
+ "const": 1
2300
+ }
2301
+ },
2302
+ "required": [
2303
+ "kind",
2304
+ "v"
2305
+ ]
2306
+ }
2307
+ ]
2308
+ }
2309
+ },
2310
+ "Duty": {
2311
+ "anyOf": [
2312
+ {
2313
+ "$ref": "#/$defs/ReissueMappingDuty"
2314
+ },
2315
+ {
2316
+ "$ref": "#/$defs/ClassOnDuty"
2317
+ },
2318
+ {
2319
+ "$ref": "#/$defs/ProfileDuty"
2320
+ },
2321
+ {
2322
+ "$ref": "#/$defs/ContinuityDuty"
2323
+ },
2324
+ {
2325
+ "$ref": "#/$defs/MergeDuty"
2326
+ },
2327
+ {
2328
+ "$ref": "#/$defs/RotationDuty"
2329
+ },
2330
+ {
2331
+ "$ref": "#/$defs/IntroAckDuty"
2332
+ },
2333
+ {
2334
+ "$ref": "#/$defs/UnknownDuty"
2335
+ }
2336
+ ]
2337
+ },
2338
+ "Event": {
2339
+ "description": "a journaled event (events.ts)",
2340
+ "anyOf": [
2341
+ {
2342
+ "type": "object",
2343
+ "properties": {
2344
+ "type": {
2345
+ "const": "contact.added"
2346
+ },
2347
+ "eventId": {
2348
+ "type": "string"
2349
+ },
2350
+ "commitSeq": {
2351
+ "$ref": "#/$defs/Dec"
2352
+ },
2353
+ "contactId": {
2354
+ "type": "string"
2355
+ },
2356
+ "actId": {
2357
+ "type": "string"
2358
+ }
2359
+ },
2360
+ "required": [
2361
+ "type",
2362
+ "eventId",
2363
+ "commitSeq",
2364
+ "contactId"
2365
+ ],
2366
+ "additionalProperties": false
2367
+ },
2368
+ {
2369
+ "type": "object",
2370
+ "properties": {
2371
+ "type": {
2372
+ "const": "contact.verified"
2373
+ },
2374
+ "eventId": {
2375
+ "type": "string"
2376
+ },
2377
+ "commitSeq": {
2378
+ "$ref": "#/$defs/Dec"
2379
+ },
2380
+ "contactId": {
2381
+ "type": "string"
2382
+ },
2383
+ "relationshipId": {
2384
+ "type": "string"
2385
+ },
2386
+ "actId": {
2387
+ "type": "string"
2388
+ }
2389
+ },
2390
+ "required": [
2391
+ "type",
2392
+ "eventId",
2393
+ "commitSeq",
2394
+ "contactId",
2395
+ "relationshipId"
2396
+ ],
2397
+ "additionalProperties": false
2398
+ },
2399
+ {
2400
+ "type": "object",
2401
+ "properties": {
2402
+ "type": {
2403
+ "const": "contact.chained"
2404
+ },
2405
+ "eventId": {
2406
+ "type": "string"
2407
+ },
2408
+ "commitSeq": {
2409
+ "$ref": "#/$defs/Dec"
2410
+ },
2411
+ "contactId": {
2412
+ "type": "string"
2413
+ },
2414
+ "from": {
2415
+ "type": "string"
2416
+ },
2417
+ "into": {
2418
+ "type": "string"
2419
+ },
2420
+ "actId": {
2421
+ "type": "string"
2422
+ }
2423
+ },
2424
+ "required": [
2425
+ "type",
2426
+ "eventId",
2427
+ "commitSeq",
2428
+ "contactId",
2429
+ "from",
2430
+ "into"
2431
+ ],
2432
+ "additionalProperties": false
2433
+ },
2434
+ {
2435
+ "type": "object",
2436
+ "properties": {
2437
+ "type": {
2438
+ "const": "contact.merged"
2439
+ },
2440
+ "eventId": {
2441
+ "type": "string"
2442
+ },
2443
+ "commitSeq": {
2444
+ "$ref": "#/$defs/Dec"
2445
+ },
2446
+ "contactId": {
2447
+ "type": "string"
2448
+ },
2449
+ "merged": {
2450
+ "type": "array",
2451
+ "items": {
2452
+ "type": "string"
2453
+ }
2454
+ },
2455
+ "actId": {
2456
+ "type": "string"
2457
+ }
2458
+ },
2459
+ "required": [
2460
+ "type",
2461
+ "eventId",
2462
+ "commitSeq",
2463
+ "contactId",
2464
+ "merged"
2465
+ ],
2466
+ "additionalProperties": false
2467
+ },
2468
+ {
2469
+ "type": "object",
2470
+ "properties": {
2471
+ "type": {
2472
+ "const": "contact.split"
2473
+ },
2474
+ "eventId": {
2475
+ "type": "string"
2476
+ },
2477
+ "commitSeq": {
2478
+ "$ref": "#/$defs/Dec"
2479
+ },
2480
+ "contactId": {
2481
+ "type": "string"
2482
+ },
2483
+ "leaver": {
2484
+ "type": "string"
2485
+ },
2486
+ "relationshipId": {
2487
+ "type": "string"
2488
+ },
2489
+ "actId": {
2490
+ "type": "string"
2491
+ }
2492
+ },
2493
+ "required": [
2494
+ "type",
2495
+ "eventId",
2496
+ "commitSeq",
2497
+ "contactId",
2498
+ "leaver",
2499
+ "relationshipId"
2500
+ ],
2501
+ "additionalProperties": false
2502
+ },
2503
+ {
2504
+ "type": "object",
2505
+ "properties": {
2506
+ "type": {
2507
+ "const": "contact.departed"
2508
+ },
2509
+ "eventId": {
2510
+ "type": "string"
2511
+ },
2512
+ "commitSeq": {
2513
+ "$ref": "#/$defs/Dec"
2514
+ },
2515
+ "contactId": {
2516
+ "type": "string"
2517
+ },
2518
+ "relationshipIds": {
2519
+ "type": "array",
2520
+ "items": {
2521
+ "type": "string"
2522
+ }
2523
+ },
2524
+ "removed": {
2525
+ "type": "boolean"
2526
+ },
2527
+ "actId": {
2528
+ "type": "string"
2529
+ }
2530
+ },
2531
+ "required": [
2532
+ "type",
2533
+ "eventId",
2534
+ "commitSeq",
2535
+ "contactId",
2536
+ "relationshipIds",
2537
+ "removed"
2538
+ ],
2539
+ "additionalProperties": false
2540
+ },
2541
+ {
2542
+ "type": "object",
2543
+ "properties": {
2544
+ "type": {
2545
+ "const": "trust.given"
2546
+ },
2547
+ "eventId": {
2548
+ "type": "string"
2549
+ },
2550
+ "commitSeq": {
2551
+ "$ref": "#/$defs/Dec"
2552
+ },
2553
+ "contactId": {
2554
+ "type": "string"
2555
+ },
2556
+ "actId": {
2557
+ "type": "string"
2558
+ }
2559
+ },
2560
+ "required": [
2561
+ "type",
2562
+ "eventId",
2563
+ "commitSeq",
2564
+ "contactId"
2565
+ ],
2566
+ "additionalProperties": false
2567
+ },
2568
+ {
2569
+ "type": "object",
2570
+ "properties": {
2571
+ "type": {
2572
+ "const": "trust.received"
2573
+ },
2574
+ "eventId": {
2575
+ "type": "string"
2576
+ },
2577
+ "commitSeq": {
2578
+ "$ref": "#/$defs/Dec"
2579
+ },
2580
+ "contactId": {
2581
+ "type": "string"
2582
+ },
2583
+ "actId": {
2584
+ "type": "string"
2585
+ }
2586
+ },
2587
+ "required": [
2588
+ "type",
2589
+ "eventId",
2590
+ "commitSeq",
2591
+ "contactId"
2592
+ ],
2593
+ "additionalProperties": false
2594
+ },
2595
+ {
2596
+ "type": "object",
2597
+ "properties": {
2598
+ "type": {
2599
+ "const": "trust.paused"
2600
+ },
2601
+ "eventId": {
2602
+ "type": "string"
2603
+ },
2604
+ "commitSeq": {
2605
+ "$ref": "#/$defs/Dec"
2606
+ },
2607
+ "contactId": {
2608
+ "type": "string"
2609
+ },
2610
+ "paused": {
2611
+ "type": "boolean"
2612
+ },
2613
+ "actId": {
2614
+ "type": "string"
2615
+ }
2616
+ },
2617
+ "required": [
2618
+ "type",
2619
+ "eventId",
2620
+ "commitSeq",
2621
+ "contactId",
2622
+ "paused"
2623
+ ],
2624
+ "additionalProperties": false
2625
+ },
2626
+ {
2627
+ "type": "object",
2628
+ "properties": {
2629
+ "type": {
2630
+ "const": "group.joined"
2631
+ },
2632
+ "eventId": {
2633
+ "type": "string"
2634
+ },
2635
+ "commitSeq": {
2636
+ "$ref": "#/$defs/Dec"
2637
+ },
2638
+ "groupId": {
2639
+ "type": "string"
2640
+ },
2641
+ "actId": {
2642
+ "type": "string"
2643
+ }
2644
+ },
2645
+ "required": [
2646
+ "type",
2647
+ "eventId",
2648
+ "commitSeq",
2649
+ "groupId"
2650
+ ],
2651
+ "additionalProperties": false
2652
+ },
2653
+ {
2654
+ "type": "object",
2655
+ "properties": {
2656
+ "type": {
2657
+ "const": "prompt.opened"
2658
+ },
2659
+ "eventId": {
2660
+ "type": "string"
2661
+ },
2662
+ "commitSeq": {
2663
+ "$ref": "#/$defs/Dec"
2664
+ },
2665
+ "promptId": {
2666
+ "type": "string"
2667
+ },
2668
+ "kind": {
2669
+ "enum": [
2670
+ "encounter-confirm",
2671
+ "group-invite",
2672
+ "introduction"
2673
+ ]
2674
+ },
2675
+ "actId": {
2676
+ "type": "string"
2677
+ }
2678
+ },
2679
+ "required": [
2680
+ "type",
2681
+ "eventId",
2682
+ "commitSeq",
2683
+ "promptId",
2684
+ "kind"
2685
+ ],
2686
+ "additionalProperties": false
2687
+ },
2688
+ {
2689
+ "type": "object",
2690
+ "properties": {
2691
+ "type": {
2692
+ "const": "prompt.decided"
2693
+ },
2694
+ "eventId": {
2695
+ "type": "string"
2696
+ },
2697
+ "commitSeq": {
2698
+ "$ref": "#/$defs/Dec"
2699
+ },
2700
+ "promptId": {
2701
+ "type": "string"
2702
+ },
2703
+ "kind": {
2704
+ "enum": [
2705
+ "encounter-confirm",
2706
+ "group-invite",
2707
+ "introduction"
2708
+ ]
2709
+ },
2710
+ "choice": {
2711
+ "enum": [
2712
+ "accept",
2713
+ "decline"
2714
+ ]
2715
+ },
2716
+ "actId": {
2717
+ "type": "string"
2718
+ }
2719
+ },
2720
+ "required": [
2721
+ "type",
2722
+ "eventId",
2723
+ "commitSeq",
2724
+ "promptId",
2725
+ "kind",
2726
+ "choice"
2727
+ ],
2728
+ "additionalProperties": false
2729
+ },
2730
+ {
2731
+ "type": "object",
2732
+ "properties": {
2733
+ "type": {
2734
+ "const": "delivery.status"
2735
+ },
2736
+ "eventId": {
2737
+ "type": "string"
2738
+ },
2739
+ "commitSeq": {
2740
+ "$ref": "#/$defs/Dec"
2741
+ },
2742
+ "digest": {
2743
+ "type": "string"
2744
+ },
2745
+ "threadId": {
2746
+ "type": "string"
2747
+ },
2748
+ "status": {
2749
+ "enum": [
2750
+ "submitted",
2751
+ "accepted",
2752
+ "delivered",
2753
+ "failed"
2754
+ ]
2755
+ },
2756
+ "actId": {
2757
+ "type": "string"
2758
+ },
2759
+ "late": {
2760
+ "type": "boolean"
2761
+ }
2762
+ },
2763
+ "required": [
2764
+ "type",
2765
+ "eventId",
2766
+ "commitSeq",
2767
+ "digest",
2768
+ "threadId",
2769
+ "status"
2770
+ ],
2771
+ "additionalProperties": false
2772
+ },
2773
+ {
2774
+ "type": "object",
2775
+ "properties": {
2776
+ "type": {
2777
+ "const": "profile.updated"
2778
+ },
2779
+ "eventId": {
2780
+ "type": "string"
2781
+ },
2782
+ "commitSeq": {
2783
+ "$ref": "#/$defs/Dec"
2784
+ },
2785
+ "contactId": {
2786
+ "anyOf": [
2787
+ {
2788
+ "type": "string"
2789
+ },
2790
+ {
2791
+ "type": "null"
2792
+ }
2793
+ ]
2794
+ },
2795
+ "actId": {
2796
+ "type": "string"
2797
+ }
2798
+ },
2799
+ "required": [
2800
+ "type",
2801
+ "eventId",
2802
+ "commitSeq",
2803
+ "contactId"
2804
+ ],
2805
+ "additionalProperties": false
2806
+ },
2807
+ {
2808
+ "type": "object",
2809
+ "properties": {
2810
+ "type": {
2811
+ "const": "anchor.rotated"
2812
+ },
2813
+ "eventId": {
2814
+ "type": "string"
2815
+ },
2816
+ "commitSeq": {
2817
+ "$ref": "#/$defs/Dec"
2818
+ },
2819
+ "generation": {
2820
+ "$ref": "#/$defs/Dec"
2821
+ },
2822
+ "actId": {
2823
+ "type": "string"
2824
+ }
2825
+ },
2826
+ "required": [
2827
+ "type",
2828
+ "eventId",
2829
+ "commitSeq",
2830
+ "generation"
2831
+ ],
2832
+ "additionalProperties": false
2833
+ },
2834
+ {
2835
+ "type": "object",
2836
+ "properties": {
2837
+ "type": {
2838
+ "const": "device.added"
2839
+ },
2840
+ "eventId": {
2841
+ "type": "string"
2842
+ },
2843
+ "commitSeq": {
2844
+ "$ref": "#/$defs/Dec"
2845
+ },
2846
+ "name": {
2847
+ "type": "string"
2848
+ },
2849
+ "actId": {
2850
+ "type": "string"
2851
+ }
2852
+ },
2853
+ "required": [
2854
+ "type",
2855
+ "eventId",
2856
+ "commitSeq",
2857
+ "name"
2858
+ ],
2859
+ "additionalProperties": false
2860
+ },
2861
+ {
2862
+ "type": "object",
2863
+ "properties": {
2864
+ "type": {
2865
+ "const": "device.revoked"
2866
+ },
2867
+ "eventId": {
2868
+ "type": "string"
2869
+ },
2870
+ "commitSeq": {
2871
+ "$ref": "#/$defs/Dec"
2872
+ },
2873
+ "name": {
2874
+ "type": "string"
2875
+ },
2876
+ "actId": {
2877
+ "type": "string"
2878
+ }
2879
+ },
2880
+ "required": [
2881
+ "type",
2882
+ "eventId",
2883
+ "commitSeq",
2884
+ "name"
2885
+ ],
2886
+ "additionalProperties": false
2887
+ },
2888
+ {
2889
+ "type": "object",
2890
+ "properties": {
2891
+ "type": {
2892
+ "const": "duty.unsupported"
2893
+ },
2894
+ "eventId": {
2895
+ "type": "string"
2896
+ },
2897
+ "commitSeq": {
2898
+ "$ref": "#/$defs/Dec"
2899
+ },
2900
+ "dutyId": {
2901
+ "type": "string"
2902
+ },
2903
+ "kind": {
2904
+ "type": "string"
2905
+ },
2906
+ "v": {
2907
+ "type": "integer",
2908
+ "minimum": 0,
2909
+ "maximum": 9007199254740991
2910
+ },
2911
+ "actId": {
2912
+ "type": "string"
2913
+ }
2914
+ },
2915
+ "required": [
2916
+ "type",
2917
+ "eventId",
2918
+ "commitSeq",
2919
+ "dutyId",
2920
+ "kind",
2921
+ "v"
2922
+ ],
2923
+ "additionalProperties": false
2924
+ },
2925
+ {
2926
+ "type": "object",
2927
+ "properties": {
2928
+ "type": {
2929
+ "const": "star.accepted"
2930
+ },
2931
+ "eventId": {
2932
+ "type": "string"
2933
+ },
2934
+ "commitSeq": {
2935
+ "$ref": "#/$defs/Dec"
2936
+ },
2937
+ "contactId": {
2938
+ "type": "string"
2939
+ },
2940
+ "relationshipId": {
2941
+ "type": "string"
2942
+ },
2943
+ "salt": {
2944
+ "$ref": "#/$defs/Dec"
2945
+ },
2946
+ "actId": {
2947
+ "type": "string"
2948
+ }
2949
+ },
2950
+ "required": [
2951
+ "type",
2952
+ "eventId",
2953
+ "commitSeq",
2954
+ "contactId",
2955
+ "relationshipId",
2956
+ "salt"
2957
+ ],
2958
+ "additionalProperties": false
2959
+ },
2960
+ {
2961
+ "type": "object",
2962
+ "properties": {
2963
+ "type": {
2964
+ "const": "groupStar.accepted"
2965
+ },
2966
+ "eventId": {
2967
+ "type": "string"
2968
+ },
2969
+ "commitSeq": {
2970
+ "$ref": "#/$defs/Dec"
2971
+ },
2972
+ "contactId": {
2973
+ "type": "string"
2974
+ },
2975
+ "relationshipId": {
2976
+ "type": "string"
2977
+ },
2978
+ "salt": {
2979
+ "$ref": "#/$defs/Dec"
2980
+ },
2981
+ "actId": {
2982
+ "type": "string"
2983
+ }
2984
+ },
2985
+ "required": [
2986
+ "type",
2987
+ "eventId",
2988
+ "commitSeq",
2989
+ "contactId",
2990
+ "relationshipId",
2991
+ "salt"
2992
+ ],
2993
+ "additionalProperties": false
2994
+ },
2995
+ {
2996
+ "type": "object",
2997
+ "properties": {
2998
+ "type": {
2999
+ "const": "encounter.shown"
3000
+ },
3001
+ "eventId": {
3002
+ "type": "string"
3003
+ },
3004
+ "commitSeq": {
3005
+ "$ref": "#/$defs/Dec"
3006
+ },
3007
+ "challenge": {
3008
+ "type": "string"
3009
+ },
3010
+ "card": {
3011
+ "type": "object"
3012
+ },
3013
+ "actId": {
3014
+ "type": "string"
3015
+ }
3016
+ },
3017
+ "required": [
3018
+ "type",
3019
+ "eventId",
3020
+ "commitSeq",
3021
+ "challenge",
3022
+ "card"
3023
+ ],
3024
+ "additionalProperties": false
3025
+ },
3026
+ {
3027
+ "type": "object",
3028
+ "properties": {
3029
+ "type": {
3030
+ "const": "encounter.scanned"
3031
+ },
3032
+ "eventId": {
3033
+ "type": "string"
3034
+ },
3035
+ "commitSeq": {
3036
+ "$ref": "#/$defs/Dec"
3037
+ },
3038
+ "contactId": {
3039
+ "type": "string"
3040
+ },
3041
+ "card": {
3042
+ "type": "object"
3043
+ },
3044
+ "actId": {
3045
+ "type": "string"
3046
+ }
3047
+ },
3048
+ "required": [
3049
+ "type",
3050
+ "eventId",
3051
+ "commitSeq",
3052
+ "contactId",
3053
+ "card"
3054
+ ],
3055
+ "additionalProperties": false
3056
+ },
3057
+ {
3058
+ "type": "object",
3059
+ "properties": {
3060
+ "type": {
3061
+ "const": "encounter.recorded"
3062
+ },
3063
+ "eventId": {
3064
+ "type": "string"
3065
+ },
3066
+ "commitSeq": {
3067
+ "$ref": "#/$defs/Dec"
3068
+ },
3069
+ "contactId": {
3070
+ "type": "string"
3071
+ },
3072
+ "relationshipId": {
3073
+ "type": "string"
3074
+ },
3075
+ "role": {
3076
+ "enum": [
3077
+ "scanner",
3078
+ "displayer"
3079
+ ]
3080
+ },
3081
+ "actId": {
3082
+ "type": "string"
3083
+ }
3084
+ },
3085
+ "required": [
3086
+ "type",
3087
+ "eventId",
3088
+ "commitSeq",
3089
+ "contactId",
3090
+ "relationshipId",
3091
+ "role"
3092
+ ],
3093
+ "additionalProperties": false
3094
+ },
3095
+ {
3096
+ "type": "object",
3097
+ "properties": {
3098
+ "type": {
3099
+ "const": "encounter.accepted"
3100
+ },
3101
+ "eventId": {
3102
+ "type": "string"
3103
+ },
3104
+ "commitSeq": {
3105
+ "$ref": "#/$defs/Dec"
3106
+ },
3107
+ "contactId": {
3108
+ "type": "string"
3109
+ },
3110
+ "relationshipId": {
3111
+ "type": "string"
3112
+ },
3113
+ "mutual": {
3114
+ "type": "boolean"
3115
+ },
3116
+ "actId": {
3117
+ "type": "string"
3118
+ }
3119
+ },
3120
+ "required": [
3121
+ "type",
3122
+ "eventId",
3123
+ "commitSeq",
3124
+ "contactId",
3125
+ "relationshipId",
3126
+ "mutual"
3127
+ ],
3128
+ "additionalProperties": false
3129
+ },
3130
+ {
3131
+ "type": "object",
3132
+ "properties": {
3133
+ "type": {
3134
+ "const": "group.founded"
3135
+ },
3136
+ "eventId": {
3137
+ "type": "string"
3138
+ },
3139
+ "commitSeq": {
3140
+ "$ref": "#/$defs/Dec"
3141
+ },
3142
+ "groupId": {
3143
+ "type": "string"
3144
+ },
3145
+ "actId": {
3146
+ "type": "string"
3147
+ }
3148
+ },
3149
+ "required": [
3150
+ "type",
3151
+ "eventId",
3152
+ "commitSeq",
3153
+ "groupId"
3154
+ ],
3155
+ "additionalProperties": false
3156
+ },
3157
+ {
3158
+ "type": "object",
3159
+ "properties": {
3160
+ "type": {
3161
+ "const": "group.admitted"
3162
+ },
3163
+ "eventId": {
3164
+ "type": "string"
3165
+ },
3166
+ "commitSeq": {
3167
+ "$ref": "#/$defs/Dec"
3168
+ },
3169
+ "groupId": {
3170
+ "type": "string"
3171
+ },
3172
+ "member": {
3173
+ "type": "string"
3174
+ },
3175
+ "actId": {
3176
+ "type": "string"
3177
+ }
3178
+ },
3179
+ "required": [
3180
+ "type",
3181
+ "eventId",
3182
+ "commitSeq",
3183
+ "groupId",
3184
+ "member"
3185
+ ],
3186
+ "additionalProperties": false
3187
+ },
3188
+ {
3189
+ "type": "object",
3190
+ "properties": {
3191
+ "type": {
3192
+ "const": "group.vouched"
3193
+ },
3194
+ "eventId": {
3195
+ "type": "string"
3196
+ },
3197
+ "commitSeq": {
3198
+ "$ref": "#/$defs/Dec"
3199
+ },
3200
+ "groupId": {
3201
+ "type": "string"
3202
+ },
3203
+ "member": {
3204
+ "type": "string"
3205
+ },
3206
+ "actId": {
3207
+ "type": "string"
3208
+ }
3209
+ },
3210
+ "required": [
3211
+ "type",
3212
+ "eventId",
3213
+ "commitSeq",
3214
+ "groupId",
3215
+ "member"
3216
+ ],
3217
+ "additionalProperties": false
3218
+ }
3219
+ ]
3220
+ },
3221
+ "RosterEntry": {
3222
+ "type": "object",
3223
+ "properties": {
3224
+ "anchor": {
3225
+ "type": "string"
3226
+ },
3227
+ "op": {
3228
+ "type": "string"
3229
+ },
3230
+ "keyAgreement": {
3231
+ "type": "string"
3232
+ },
3233
+ "addedAt": {
3234
+ "$ref": "#/$defs/Millis"
3235
+ },
3236
+ "name": {
3237
+ "type": "string"
3238
+ },
3239
+ "contactId": {
3240
+ "type": "string"
3241
+ },
3242
+ "rkid": {
3243
+ "type": "string"
3244
+ }
3245
+ },
3246
+ "required": [
3247
+ "anchor",
3248
+ "op",
3249
+ "keyAgreement",
3250
+ "addedAt"
3251
+ ],
3252
+ "additionalProperties": false
3253
+ },
3254
+ "OpenInvitation": {
3255
+ "type": "object",
3256
+ "properties": {
3257
+ "invitee": {
3258
+ "type": "string"
3259
+ },
3260
+ "keyAgreement": {
3261
+ "type": "string"
3262
+ },
3263
+ "contactId": {
3264
+ "type": "string"
3265
+ },
3266
+ "rkid": {
3267
+ "type": "string"
3268
+ },
3269
+ "threadId": {
3270
+ "type": "string"
3271
+ },
3272
+ "credDigest": {
3273
+ "type": "string"
3274
+ },
3275
+ "invite": {
3276
+ "type": "object"
3277
+ },
3278
+ "validUntil": {
3279
+ "$ref": "#/$defs/Millis"
3280
+ }
3281
+ },
3282
+ "required": [
3283
+ "invitee",
3284
+ "keyAgreement",
3285
+ "contactId",
3286
+ "rkid",
3287
+ "threadId",
3288
+ "credDigest",
3289
+ "invite",
3290
+ "validUntil"
3291
+ ],
3292
+ "additionalProperties": false
3293
+ },
3294
+ "Evidence": {
3295
+ "type": "object",
3296
+ "properties": {
3297
+ "invite": {
3298
+ "type": "object"
3299
+ },
3300
+ "accept": {
3301
+ "type": "object"
3302
+ },
3303
+ "vouches": {
3304
+ "type": "array",
3305
+ "items": {
3306
+ "type": "object"
3307
+ }
3308
+ },
3309
+ "at": {
3310
+ "$ref": "#/$defs/Millis"
3311
+ }
3312
+ },
3313
+ "required": [
3314
+ "invite",
3315
+ "accept",
3316
+ "vouches",
3317
+ "at"
3318
+ ],
3319
+ "additionalProperties": false
3320
+ },
3321
+ "Group": {
3322
+ "description": "a group the holder is in; a listed group carries memberAnchor and memberOp (Trust 5400)",
3323
+ "type": "object",
3324
+ "properties": {
3325
+ "id": {
3326
+ "type": "string"
3327
+ },
3328
+ "name": {
3329
+ "type": "string"
3330
+ },
3331
+ "memberLabel": {
3332
+ "type": "string"
3333
+ },
3334
+ "rules": {
3335
+ "type": "object",
3336
+ "properties": {
3337
+ "vouchThreshold": {
3338
+ "$ref": "#/$defs/Dec"
3339
+ }
3340
+ },
3341
+ "required": [
3342
+ "vouchThreshold"
3343
+ ],
3344
+ "additionalProperties": false
3345
+ },
3346
+ "listed": {
3347
+ "type": "boolean"
3348
+ },
3349
+ "roster": {
3350
+ "type": "object",
3351
+ "additionalProperties": {
3352
+ "$ref": "#/$defs/RosterEntry"
3353
+ }
3354
+ },
3355
+ "invitations": {
3356
+ "type": "object",
3357
+ "additionalProperties": {
3358
+ "$ref": "#/$defs/OpenInvitation"
3359
+ }
3360
+ },
3361
+ "evidence": {
3362
+ "type": "object",
3363
+ "additionalProperties": {
3364
+ "$ref": "#/$defs/Evidence"
3365
+ }
3366
+ },
3367
+ "preludes": {
3368
+ "type": "object",
3369
+ "additionalProperties": {
3370
+ "type": "object",
3371
+ "properties": {
3372
+ "contactId": {
3373
+ "type": "string"
3374
+ },
3375
+ "rkid": {
3376
+ "type": "string"
3377
+ },
3378
+ "at": {
3379
+ "$ref": "#/$defs/Millis"
3380
+ }
3381
+ },
3382
+ "required": [
3383
+ "contactId",
3384
+ "rkid",
3385
+ "at"
3386
+ ],
3387
+ "additionalProperties": false
3388
+ }
3389
+ },
3390
+ "did": {
3391
+ "type": "string"
3392
+ },
3393
+ "genesis": {
3394
+ "type": "object"
3395
+ },
3396
+ "memberAnchor": {
3397
+ "type": "string"
3398
+ },
3399
+ "memberOp": {
3400
+ "type": "string"
3401
+ },
3402
+ "acceptDigest": {
3403
+ "type": "string"
3404
+ }
3405
+ },
3406
+ "required": [
3407
+ "id",
3408
+ "name",
3409
+ "memberLabel",
3410
+ "rules",
3411
+ "listed",
3412
+ "roster",
3413
+ "invitations",
3414
+ "evidence",
3415
+ "preludes"
3416
+ ],
3417
+ "additionalProperties": false,
3418
+ "if": {
3419
+ "properties": {
3420
+ "listed": {
3421
+ "const": true
3422
+ }
3423
+ },
3424
+ "required": [
3425
+ "listed"
3426
+ ]
3427
+ },
3428
+ "then": {
3429
+ "required": [
3430
+ "memberAnchor",
3431
+ "memberOp"
3432
+ ]
3433
+ }
3434
+ },
3435
+ "HeldCredential": {
3436
+ "type": "object",
3437
+ "properties": {
3438
+ "digest": {
3439
+ "type": "string"
3440
+ },
3441
+ "credential": {
3442
+ "type": "object"
3443
+ }
3444
+ },
3445
+ "required": [
3446
+ "digest",
3447
+ "credential"
3448
+ ],
3449
+ "additionalProperties": false
3450
+ },
3451
+ "EnactmentRecord": {
3452
+ "type": "object",
3453
+ "properties": {
3454
+ "ceremony": {
3455
+ "type": "string"
3456
+ },
3457
+ "own": {
3458
+ "type": "string"
3459
+ },
3460
+ "tCh": {
3461
+ "$ref": "#/$defs/Millis"
3462
+ },
3463
+ "peer": {
3464
+ "type": "string"
3465
+ },
3466
+ "counterpart": {
3467
+ "type": "string"
3468
+ },
3469
+ "card": {
3470
+ "type": "object"
3471
+ },
3472
+ "bind": {
3473
+ "type": "string"
3474
+ },
3475
+ "at": {
3476
+ "$ref": "#/$defs/Millis"
3477
+ },
3478
+ "label": {
3479
+ "type": "string"
3480
+ },
3481
+ "relId": {
3482
+ "type": "string"
3483
+ },
3484
+ "role": {
3485
+ "enum": [
3486
+ "scanner",
3487
+ "displayer"
3488
+ ]
3489
+ },
3490
+ "out": {
3491
+ "anyOf": [
3492
+ {
3493
+ "$ref": "#/$defs/HeldCredential"
3494
+ },
3495
+ {
3496
+ "type": "null"
3497
+ }
3498
+ ]
3499
+ },
3500
+ "in": {
3501
+ "anyOf": [
3502
+ {
3503
+ "$ref": "#/$defs/HeldCredential"
3504
+ },
3505
+ {
3506
+ "type": "null"
3507
+ }
3508
+ ]
3509
+ },
3510
+ "thread": {
3511
+ "anyOf": [
3512
+ {
3513
+ "type": "string"
3514
+ },
3515
+ {
3516
+ "type": "null"
3517
+ }
3518
+ ]
3519
+ },
3520
+ "bundleDigest": {
3521
+ "anyOf": [
3522
+ {
3523
+ "type": "string"
3524
+ },
3525
+ {
3526
+ "type": "null"
3527
+ }
3528
+ ]
3529
+ },
3530
+ "threads": {
3531
+ "type": "object",
3532
+ "additionalProperties": {
3533
+ "type": "string"
3534
+ }
3535
+ },
3536
+ "sentCard": {
3537
+ "anyOf": [
3538
+ {
3539
+ "type": "object"
3540
+ },
3541
+ {
3542
+ "type": "null"
3543
+ }
3544
+ ]
3545
+ },
3546
+ "counterPending": {
3547
+ "type": "boolean"
3548
+ }
3549
+ },
3550
+ "required": [
3551
+ "ceremony",
3552
+ "own",
3553
+ "tCh",
3554
+ "peer",
3555
+ "counterpart",
3556
+ "card",
3557
+ "bind",
3558
+ "at",
3559
+ "label",
3560
+ "relId",
3561
+ "role",
3562
+ "out",
3563
+ "in",
3564
+ "thread",
3565
+ "bundleDigest",
3566
+ "threads",
3567
+ "sentCard",
3568
+ "counterPending"
3569
+ ],
3570
+ "additionalProperties": false
3571
+ },
3572
+ "IntroAct": {
3573
+ "type": "object",
3574
+ "properties": {
3575
+ "key": {
3576
+ "type": "string"
3577
+ },
3578
+ "act": {
3579
+ "type": "string"
3580
+ },
3581
+ "role": {
3582
+ "enum": [
3583
+ "requester",
3584
+ "mediator",
3585
+ "target"
3586
+ ]
3587
+ },
3588
+ "status": {
3589
+ "enum": [
3590
+ "sent",
3591
+ "acked",
3592
+ "completed",
3593
+ "failed",
3594
+ "received",
3595
+ "forwarded",
3596
+ "consented",
3597
+ "refused"
3598
+ ]
3599
+ },
3600
+ "issuedAt": {
3601
+ "$ref": "#/$defs/Millis"
3602
+ },
3603
+ "request": {
3604
+ "type": "object"
3605
+ },
3606
+ "requestCard": {
3607
+ "type": "object"
3608
+ },
3609
+ "reply": {
3610
+ "anyOf": [
3611
+ {
3612
+ "type": "object"
3613
+ },
3614
+ {
3615
+ "type": "null"
3616
+ }
3617
+ ]
3618
+ },
3619
+ "replyCard": {
3620
+ "anyOf": [
3621
+ {
3622
+ "type": "object"
3623
+ },
3624
+ {
3625
+ "type": "null"
3626
+ }
3627
+ ]
3628
+ },
3629
+ "pins": {
3630
+ "type": "object",
3631
+ "properties": {
3632
+ "requester": {
3633
+ "type": "string"
3634
+ },
3635
+ "target": {
3636
+ "type": "string"
3637
+ },
3638
+ "mediator": {
3639
+ "type": "string"
3640
+ }
3641
+ },
3642
+ "required": [],
3643
+ "additionalProperties": false
3644
+ },
3645
+ "threads": {
3646
+ "type": "object",
3647
+ "properties": {
3648
+ "request": {
3649
+ "type": "string"
3650
+ },
3651
+ "forward": {
3652
+ "type": "string"
3653
+ }
3654
+ },
3655
+ "required": [
3656
+ "request"
3657
+ ],
3658
+ "additionalProperties": false
3659
+ },
3660
+ "at": {
3661
+ "$ref": "#/$defs/Millis"
3662
+ },
3663
+ "ackDelayMs": {
3664
+ "type": "integer",
3665
+ "minimum": 0,
3666
+ "maximum": 9007199254740991
3667
+ },
3668
+ "ownLabel": {
3669
+ "anyOf": [
3670
+ {
3671
+ "type": "string"
3672
+ },
3673
+ {
3674
+ "type": "null"
3675
+ }
3676
+ ]
3677
+ },
3678
+ "ack": {
3679
+ "anyOf": [
3680
+ {
3681
+ "type": "object"
3682
+ },
3683
+ {
3684
+ "type": "null"
3685
+ }
3686
+ ]
3687
+ },
3688
+ "replyForwarded": {
3689
+ "type": "boolean"
3690
+ },
3691
+ "vouchersSent": {
3692
+ "type": "boolean"
3693
+ },
3694
+ "pendingVoucher": {
3695
+ "anyOf": [
3696
+ {
3697
+ "type": "object"
3698
+ },
3699
+ {
3700
+ "type": "null"
3701
+ }
3702
+ ]
3703
+ },
3704
+ "voucher": {
3705
+ "anyOf": [
3706
+ {
3707
+ "type": "object"
3708
+ },
3709
+ {
3710
+ "type": "null"
3711
+ }
3712
+ ]
3713
+ },
3714
+ "vouched": {
3715
+ "type": "boolean"
3716
+ },
3717
+ "promptId": {
3718
+ "anyOf": [
3719
+ {
3720
+ "type": "string"
3721
+ },
3722
+ {
3723
+ "type": "null"
3724
+ }
3725
+ ]
3726
+ },
3727
+ "peerName": {
3728
+ "type": "string"
3729
+ }
3730
+ },
3731
+ "required": [
3732
+ "key",
3733
+ "act",
3734
+ "role",
3735
+ "status",
3736
+ "issuedAt",
3737
+ "request",
3738
+ "requestCard",
3739
+ "reply",
3740
+ "replyCard",
3741
+ "pins",
3742
+ "threads",
3743
+ "at",
3744
+ "ackDelayMs",
3745
+ "ownLabel",
3746
+ "ack",
3747
+ "replyForwarded",
3748
+ "vouchersSent",
3749
+ "pendingVoucher",
3750
+ "voucher",
3751
+ "vouched",
3752
+ "promptId"
3753
+ ],
3754
+ "additionalProperties": false
3755
+ },
3756
+ "Rotation": {
3757
+ "type": "object",
3758
+ "properties": {
3759
+ "id": {
3760
+ "type": "string"
3761
+ },
3762
+ "from": {
3763
+ "$ref": "#/$defs/Dec"
3764
+ },
3765
+ "to": {
3766
+ "$ref": "#/$defs/Dec"
3767
+ },
3768
+ "step": {
3769
+ "enum": [
3770
+ "register",
3771
+ "log",
3772
+ "duties"
3773
+ ]
3774
+ },
3775
+ "startedAt": {
3776
+ "$ref": "#/$defs/Millis"
3777
+ },
3778
+ "entry": true,
3779
+ "overHead": {
3780
+ "$ref": "#/$defs/LogHead"
3781
+ },
3782
+ "awaitHead": {
3783
+ "type": "object",
3784
+ "additionalProperties": {
3785
+ "anyOf": [
3786
+ {
3787
+ "type": "string"
3788
+ },
3789
+ {
3790
+ "type": "null"
3791
+ }
3792
+ ]
3793
+ }
3794
+ }
3795
+ },
3796
+ "required": [
3797
+ "id",
3798
+ "from",
3799
+ "to",
3800
+ "step",
3801
+ "startedAt",
3802
+ "entry",
3803
+ "overHead",
3804
+ "awaitHead"
3805
+ ],
3806
+ "additionalProperties": false
3807
+ },
3808
+ "Prompt": {
3809
+ "type": "object",
3810
+ "properties": {
3811
+ "id": {
3812
+ "type": "string"
3813
+ },
3814
+ "kind": {
3815
+ "enum": [
3816
+ "encounter-confirm",
3817
+ "group-invite",
3818
+ "introduction"
3819
+ ]
3820
+ },
3821
+ "openedAt": {
3822
+ "$ref": "#/$defs/Millis"
3823
+ },
3824
+ "contactId": {
3825
+ "type": "string"
3826
+ },
3827
+ "groupId": {
3828
+ "type": "string"
3829
+ },
3830
+ "expiresAt": {
3831
+ "$ref": "#/$defs/Millis"
3832
+ }
3833
+ },
3834
+ "required": [
3835
+ "id",
3836
+ "kind",
3837
+ "openedAt"
3838
+ ],
3839
+ "additionalProperties": false
3840
+ },
3841
+ "ActRecord": {
3842
+ "type": "object",
3843
+ "properties": {
3844
+ "actId": {
3845
+ "type": "string"
3846
+ },
3847
+ "inputHash": {
3848
+ "type": "string"
3849
+ },
3850
+ "commitSeq": {
3851
+ "$ref": "#/$defs/Dec"
3852
+ },
3853
+ "outboundDigests": {
3854
+ "type": "array",
3855
+ "items": {
3856
+ "type": "string"
3857
+ }
3858
+ },
3859
+ "events": {
3860
+ "type": "array",
3861
+ "items": {
3862
+ "$ref": "#/$defs/Event"
3863
+ }
3864
+ },
3865
+ "at": {
3866
+ "$ref": "#/$defs/Millis"
3867
+ }
3868
+ },
3869
+ "required": [
3870
+ "actId",
3871
+ "inputHash",
3872
+ "commitSeq",
3873
+ "outboundDigests",
3874
+ "events",
3875
+ "at"
3876
+ ],
3877
+ "additionalProperties": false
3878
+ }
3879
+ }
3880
+ }