@openvtc/trust-tasks 0.19.18 → 0.19.20

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 (78) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/_shared/components.d.ts +38 -0
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/index.d.ts +3 -0
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +3 -0
  7. package/dist/index.js.map +1 -1
  8. package/dist/persona/_shared/0.1/persona-record.d.ts +1 -1
  9. package/dist/persona/_shared/0.1/persona-record.d.ts.map +1 -1
  10. package/dist/persona/attribute/list/1.0/payload.d.ts +124 -4
  11. package/dist/persona/attribute/list/1.0/payload.d.ts.map +1 -1
  12. package/dist/persona/attribute/list/1.0/payload.js +72 -2
  13. package/dist/persona/attribute/list/1.0/payload.js.map +1 -1
  14. package/dist/persona/attribute/put/1.0/payload.d.ts +110 -4
  15. package/dist/persona/attribute/put/1.0/payload.d.ts.map +1 -1
  16. package/dist/persona/attribute/put/1.0/payload.js +62 -2
  17. package/dist/persona/attribute/put/1.0/payload.js.map +1 -1
  18. package/dist/persona/binding/set/1.0/payload.d.ts +6 -6
  19. package/dist/persona/binding/set/1.0/payload.d.ts.map +1 -1
  20. package/dist/persona/binding/set/1.0/payload.js +2 -3
  21. package/dist/persona/binding/set/1.0/payload.js.map +1 -1
  22. package/dist/persona/contact/get/1.0/payload.d.ts +84 -4
  23. package/dist/persona/contact/get/1.0/payload.d.ts.map +1 -1
  24. package/dist/persona/contact/get/1.0/payload.js +52 -2
  25. package/dist/persona/contact/get/1.0/payload.js.map +1 -1
  26. package/dist/persona/contact/put/1.0/payload.d.ts +84 -4
  27. package/dist/persona/contact/put/1.0/payload.d.ts.map +1 -1
  28. package/dist/persona/contact/put/1.0/payload.js +52 -2
  29. package/dist/persona/contact/put/1.0/payload.js.map +1 -1
  30. package/dist/persona/disclosure/preview/1.0/payload.d.ts +5 -5
  31. package/dist/persona/disclosure/preview/1.0/payload.d.ts.map +1 -1
  32. package/dist/persona/disclosure/preview/1.0/payload.js +4 -2
  33. package/dist/persona/disclosure/preview/1.0/payload.js.map +1 -1
  34. package/dist/persona/profile/compose/1.0/payload.d.ts +31 -3
  35. package/dist/persona/profile/compose/1.0/payload.d.ts.map +1 -1
  36. package/dist/persona/profile/compose/1.0/payload.js +11 -1
  37. package/dist/persona/profile/compose/1.0/payload.js.map +1 -1
  38. package/dist/persona/profile/get/1.0/payload.d.ts +230 -6
  39. package/dist/persona/profile/get/1.0/payload.d.ts.map +1 -1
  40. package/dist/persona/profile/get/1.0/payload.js +140 -2
  41. package/dist/persona/profile/get/1.0/payload.js.map +1 -1
  42. package/dist/persona/profile/list/1.0/payload.d.ts +230 -6
  43. package/dist/persona/profile/list/1.0/payload.d.ts.map +1 -1
  44. package/dist/persona/profile/list/1.0/payload.js +140 -2
  45. package/dist/persona/profile/list/1.0/payload.js.map +1 -1
  46. package/dist/persona/profile/put/1.0/payload.d.ts +230 -6
  47. package/dist/persona/profile/put/1.0/payload.d.ts.map +1 -1
  48. package/dist/persona/profile/put/1.0/payload.js +138 -2
  49. package/dist/persona/profile/put/1.0/payload.js.map +1 -1
  50. package/dist/persona/profile/timeline/1.0/payload.d.ts +588 -0
  51. package/dist/persona/profile/timeline/1.0/payload.d.ts.map +1 -0
  52. package/dist/persona/profile/timeline/1.0/payload.js +322 -0
  53. package/dist/persona/profile/timeline/1.0/payload.js.map +1 -0
  54. package/dist/persona/profile/usage/1.0/payload.d.ts +533 -0
  55. package/dist/persona/profile/usage/1.0/payload.d.ts.map +1 -0
  56. package/dist/persona/profile/usage/1.0/payload.js +302 -0
  57. package/dist/persona/profile/usage/1.0/payload.js.map +1 -0
  58. package/dist/vtc/invitations/deliver/0.1/payload.d.ts +318 -0
  59. package/dist/vtc/invitations/deliver/0.1/payload.d.ts.map +1 -0
  60. package/dist/vtc/invitations/deliver/0.1/payload.js +183 -0
  61. package/dist/vtc/invitations/deliver/0.1/payload.js.map +1 -0
  62. package/package.json +1 -1
  63. package/src/_shared/components.ts +41 -0
  64. package/src/index.ts +3 -0
  65. package/src/persona/_shared/0.1/persona-record.ts +1 -1
  66. package/src/persona/attribute/list/1.0/payload.ts +72 -2
  67. package/src/persona/attribute/put/1.0/payload.ts +68 -2
  68. package/src/persona/binding/set/1.0/payload.ts +4 -5
  69. package/src/persona/contact/get/1.0/payload.ts +52 -2
  70. package/src/persona/contact/put/1.0/payload.ts +52 -2
  71. package/src/persona/disclosure/preview/1.0/payload.ts +5 -3
  72. package/src/persona/profile/compose/1.0/payload.ts +20 -2
  73. package/src/persona/profile/get/1.0/payload.ts +142 -4
  74. package/src/persona/profile/list/1.0/payload.ts +142 -4
  75. package/src/persona/profile/put/1.0/payload.ts +144 -4
  76. package/src/persona/profile/timeline/1.0/payload.ts +402 -0
  77. package/src/persona/profile/usage/1.0/payload.ts +354 -0
  78. package/src/vtc/invitations/deliver/0.1/payload.ts +234 -0
@@ -0,0 +1,533 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/persona/profile/usage/1.0/payload.schema.json
4
+ */
5
+ import type { Ext, FaceReach, Ulid } from "../../../../_shared/components.js";
6
+ /**
7
+ * Where one face is worn now: every context and persona wearing it. The answer a holder needs to audit a face's reach, and to see the contexts a face is part of before changing or retiring it.
8
+ */
9
+ export interface PersonaProfileUsagePayload {
10
+ profileId: Ulid;
11
+ /**
12
+ * The context of a context-local face. Omit for a pool face.
13
+ */
14
+ contextId?: string;
15
+ ext?: Ext;
16
+ }
17
+ /**
18
+ * Success response to persona/profile/usage. Type https://trusttasks.org/spec/persona/profile/usage/1.0#response. An empty `usage` is a face worn nowhere — a normal state, not an error.
19
+ */
20
+ export interface PersonaProfileUsageResponsePayload {
21
+ profileId: Ulid;
22
+ /**
23
+ * The face's reach, so the answer and the allow-list it is audited against arrive together. Absent for a context-local face.
24
+ */
25
+ reach?: FaceReach;
26
+ /**
27
+ * @maxItems 1024
28
+ */
29
+ usage: {
30
+ contextId: string;
31
+ personaDid: string;
32
+ boundAt: string;
33
+ /**
34
+ * When wearing it here ends on its own. Absent when it lasts until changed.
35
+ */
36
+ until?: string;
37
+ }[];
38
+ ext?: Ext;
39
+ }
40
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
41
+ export type { Ext, FaceReach, Ulid };
42
+ /** Trust Task type URI. */
43
+ export declare const TYPE_URI: "https://trusttasks.org/spec/persona/profile/usage/1.0";
44
+ /** Stable alias for this specification's request payload shape. */
45
+ export type Payload = PersonaProfileUsagePayload;
46
+ /** Trust Task response type URI (request type URI + "#response"). */
47
+ export declare const RESPONSE_TYPE_URI: "https://trusttasks.org/spec/persona/profile/usage/1.0#response";
48
+ /** Stable alias for this specification's success-response payload shape. */
49
+ export type Response = PersonaProfileUsageResponsePayload;
50
+ /**
51
+ * This specification's payload schema, as a value.
52
+ *
53
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
54
+ * rather than only as a `.json` file because TypeScript types are erased
55
+ * at runtime: without a schema a consumer has nothing to validate, and
56
+ * every REQUIRED payload member is optional in practice. Cross-file
57
+ * `$ref`s are already inlined, so it needs no resolver.
58
+ */
59
+ export declare const PAYLOAD_SCHEMA: {
60
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
61
+ readonly $id: "https://trusttasks.org/spec/persona/profile/usage/1.0";
62
+ readonly title: "Persona Profile Usage — payload";
63
+ readonly description: "Where one face is worn now: every context and persona wearing it. The answer a holder needs to audit a face's reach, and to see the contexts a face is part of before changing or retiring it.";
64
+ readonly type: "object";
65
+ readonly additionalProperties: false;
66
+ readonly required: readonly ["profileId"];
67
+ readonly properties: {
68
+ readonly profileId: {
69
+ readonly $ref: "#/$defs/Ulid";
70
+ };
71
+ readonly contextId: {
72
+ readonly type: "string";
73
+ readonly minLength: 1;
74
+ readonly description: "The context of a context-local face. Omit for a pool face.";
75
+ };
76
+ readonly ext: {
77
+ readonly $ref: "#/$defs/Ext";
78
+ };
79
+ };
80
+ readonly $defs: {
81
+ readonly Response: {
82
+ readonly $anchor: "response";
83
+ readonly title: "Persona Profile Usage — response payload";
84
+ readonly description: "Success response to persona/profile/usage. Type https://trusttasks.org/spec/persona/profile/usage/1.0#response. An empty `usage` is a face worn nowhere — a normal state, not an error.";
85
+ readonly type: "object";
86
+ readonly additionalProperties: false;
87
+ readonly required: readonly ["profileId", "usage"];
88
+ readonly properties: {
89
+ readonly profileId: {
90
+ readonly $ref: "#/$defs/Ulid";
91
+ };
92
+ readonly reach: {
93
+ readonly $ref: "#/$defs/FaceReach";
94
+ readonly description: "The face's reach, so the answer and the allow-list it is audited against arrive together. Absent for a context-local face.";
95
+ };
96
+ readonly usage: {
97
+ readonly type: "array";
98
+ readonly maxItems: 1024;
99
+ readonly items: {
100
+ readonly type: "object";
101
+ readonly additionalProperties: false;
102
+ readonly required: readonly ["contextId", "personaDid", "boundAt"];
103
+ readonly properties: {
104
+ readonly contextId: {
105
+ readonly type: "string";
106
+ readonly minLength: 1;
107
+ };
108
+ readonly personaDid: {
109
+ readonly type: "string";
110
+ readonly minLength: 1;
111
+ };
112
+ readonly boundAt: {
113
+ readonly type: "string";
114
+ readonly format: "date-time";
115
+ };
116
+ readonly until: {
117
+ readonly type: "string";
118
+ readonly format: "date-time";
119
+ readonly description: "When wearing it here ends on its own. Absent when it lasts until changed.";
120
+ };
121
+ };
122
+ };
123
+ };
124
+ readonly ext: {
125
+ readonly $ref: "#/$defs/Ext";
126
+ };
127
+ };
128
+ };
129
+ readonly Ext: {
130
+ readonly title: "Ext";
131
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
132
+ readonly type: "object";
133
+ readonly minProperties: 1;
134
+ readonly additionalProperties: true;
135
+ readonly propertyNames: {
136
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
137
+ };
138
+ };
139
+ readonly FaceReach: {
140
+ readonly title: "FaceReach";
141
+ readonly description: "Where a pool face may be worn. `anywhere` is the default and what an absent member means. `only` names the contexts it may be worn in, and a maintainer MUST refuse to wear it in any other (persona/binding/set `outsideReach`).\n\nA tagged object rather than a bare list of contexts, deliberately: an empty list has been read as both 'unrestricted' and 'nowhere' in this family's neighbours, and a shape where the two cannot be confused is worth more than one where they must be remembered. So `only` requires at least one context, and 'nowhere' is not a reach — it is a retired face.\n\nA context-local face has no reach: it lives in its context and is worn there by construction.";
142
+ readonly oneOf: readonly [{
143
+ readonly type: "object";
144
+ readonly additionalProperties: false;
145
+ readonly required: readonly ["kind"];
146
+ readonly properties: {
147
+ readonly kind: {
148
+ readonly const: "anywhere";
149
+ };
150
+ };
151
+ }, {
152
+ readonly type: "object";
153
+ readonly additionalProperties: false;
154
+ readonly required: readonly ["kind", "contextIds"];
155
+ readonly properties: {
156
+ readonly kind: {
157
+ readonly const: "only";
158
+ };
159
+ readonly contextIds: {
160
+ readonly type: "array";
161
+ readonly minItems: 1;
162
+ readonly maxItems: 256;
163
+ readonly uniqueItems: true;
164
+ readonly items: {
165
+ readonly type: "string";
166
+ readonly minLength: 1;
167
+ };
168
+ };
169
+ };
170
+ }];
171
+ };
172
+ readonly Ulid: {
173
+ readonly title: "Ulid";
174
+ readonly description: "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.";
175
+ readonly type: "string";
176
+ readonly pattern: "^[0-9A-HJKMNP-TV-Z]{26}$";
177
+ };
178
+ };
179
+ };
180
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
181
+ export declare const RESPONSE_PAYLOAD_SCHEMA: {
182
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
183
+ readonly $ref: "#/$defs/Response";
184
+ readonly $defs: {
185
+ readonly Response: {
186
+ readonly $anchor: "response";
187
+ readonly title: "Persona Profile Usage — response payload";
188
+ readonly description: "Success response to persona/profile/usage. Type https://trusttasks.org/spec/persona/profile/usage/1.0#response. An empty `usage` is a face worn nowhere — a normal state, not an error.";
189
+ readonly type: "object";
190
+ readonly additionalProperties: false;
191
+ readonly required: readonly ["profileId", "usage"];
192
+ readonly properties: {
193
+ readonly profileId: {
194
+ readonly $ref: "#/$defs/Ulid";
195
+ };
196
+ readonly reach: {
197
+ readonly $ref: "#/$defs/FaceReach";
198
+ readonly description: "The face's reach, so the answer and the allow-list it is audited against arrive together. Absent for a context-local face.";
199
+ };
200
+ readonly usage: {
201
+ readonly type: "array";
202
+ readonly maxItems: 1024;
203
+ readonly items: {
204
+ readonly type: "object";
205
+ readonly additionalProperties: false;
206
+ readonly required: readonly ["contextId", "personaDid", "boundAt"];
207
+ readonly properties: {
208
+ readonly contextId: {
209
+ readonly type: "string";
210
+ readonly minLength: 1;
211
+ };
212
+ readonly personaDid: {
213
+ readonly type: "string";
214
+ readonly minLength: 1;
215
+ };
216
+ readonly boundAt: {
217
+ readonly type: "string";
218
+ readonly format: "date-time";
219
+ };
220
+ readonly until: {
221
+ readonly type: "string";
222
+ readonly format: "date-time";
223
+ readonly description: "When wearing it here ends on its own. Absent when it lasts until changed.";
224
+ };
225
+ };
226
+ };
227
+ };
228
+ readonly ext: {
229
+ readonly $ref: "#/$defs/Ext";
230
+ };
231
+ };
232
+ };
233
+ readonly Ext: {
234
+ readonly title: "Ext";
235
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
236
+ readonly type: "object";
237
+ readonly minProperties: 1;
238
+ readonly additionalProperties: true;
239
+ readonly propertyNames: {
240
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
241
+ };
242
+ };
243
+ readonly FaceReach: {
244
+ readonly title: "FaceReach";
245
+ readonly description: "Where a pool face may be worn. `anywhere` is the default and what an absent member means. `only` names the contexts it may be worn in, and a maintainer MUST refuse to wear it in any other (persona/binding/set `outsideReach`).\n\nA tagged object rather than a bare list of contexts, deliberately: an empty list has been read as both 'unrestricted' and 'nowhere' in this family's neighbours, and a shape where the two cannot be confused is worth more than one where they must be remembered. So `only` requires at least one context, and 'nowhere' is not a reach — it is a retired face.\n\nA context-local face has no reach: it lives in its context and is worn there by construction.";
246
+ readonly oneOf: readonly [{
247
+ readonly type: "object";
248
+ readonly additionalProperties: false;
249
+ readonly required: readonly ["kind"];
250
+ readonly properties: {
251
+ readonly kind: {
252
+ readonly const: "anywhere";
253
+ };
254
+ };
255
+ }, {
256
+ readonly type: "object";
257
+ readonly additionalProperties: false;
258
+ readonly required: readonly ["kind", "contextIds"];
259
+ readonly properties: {
260
+ readonly kind: {
261
+ readonly const: "only";
262
+ };
263
+ readonly contextIds: {
264
+ readonly type: "array";
265
+ readonly minItems: 1;
266
+ readonly maxItems: 256;
267
+ readonly uniqueItems: true;
268
+ readonly items: {
269
+ readonly type: "string";
270
+ readonly minLength: 1;
271
+ };
272
+ };
273
+ };
274
+ }];
275
+ };
276
+ readonly Ulid: {
277
+ readonly title: "Ulid";
278
+ readonly description: "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.";
279
+ readonly type: "string";
280
+ readonly pattern: "^[0-9A-HJKMNP-TV-Z]{26}$";
281
+ };
282
+ };
283
+ };
284
+ /**
285
+ * SPEC.md §7.2 policy for the request variant, from this specification's
286
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
287
+ * per-specification and cannot be derived from the document alone, and
288
+ * item 2 needs the schema this carries.
289
+ */
290
+ export declare const SPEC: {
291
+ readonly typeUri: "https://trusttasks.org/spec/persona/profile/usage/1.0";
292
+ readonly isBearer: false;
293
+ readonly isProofRequired: false;
294
+ readonly isRecipientRequired: true;
295
+ readonly isIssuedAtRequired: false;
296
+ readonly payloadSchema: {
297
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
298
+ readonly $id: "https://trusttasks.org/spec/persona/profile/usage/1.0";
299
+ readonly title: "Persona Profile Usage — payload";
300
+ readonly description: "Where one face is worn now: every context and persona wearing it. The answer a holder needs to audit a face's reach, and to see the contexts a face is part of before changing or retiring it.";
301
+ readonly type: "object";
302
+ readonly additionalProperties: false;
303
+ readonly required: readonly ["profileId"];
304
+ readonly properties: {
305
+ readonly profileId: {
306
+ readonly $ref: "#/$defs/Ulid";
307
+ };
308
+ readonly contextId: {
309
+ readonly type: "string";
310
+ readonly minLength: 1;
311
+ readonly description: "The context of a context-local face. Omit for a pool face.";
312
+ };
313
+ readonly ext: {
314
+ readonly $ref: "#/$defs/Ext";
315
+ };
316
+ };
317
+ readonly $defs: {
318
+ readonly Response: {
319
+ readonly $anchor: "response";
320
+ readonly title: "Persona Profile Usage — response payload";
321
+ readonly description: "Success response to persona/profile/usage. Type https://trusttasks.org/spec/persona/profile/usage/1.0#response. An empty `usage` is a face worn nowhere — a normal state, not an error.";
322
+ readonly type: "object";
323
+ readonly additionalProperties: false;
324
+ readonly required: readonly ["profileId", "usage"];
325
+ readonly properties: {
326
+ readonly profileId: {
327
+ readonly $ref: "#/$defs/Ulid";
328
+ };
329
+ readonly reach: {
330
+ readonly $ref: "#/$defs/FaceReach";
331
+ readonly description: "The face's reach, so the answer and the allow-list it is audited against arrive together. Absent for a context-local face.";
332
+ };
333
+ readonly usage: {
334
+ readonly type: "array";
335
+ readonly maxItems: 1024;
336
+ readonly items: {
337
+ readonly type: "object";
338
+ readonly additionalProperties: false;
339
+ readonly required: readonly ["contextId", "personaDid", "boundAt"];
340
+ readonly properties: {
341
+ readonly contextId: {
342
+ readonly type: "string";
343
+ readonly minLength: 1;
344
+ };
345
+ readonly personaDid: {
346
+ readonly type: "string";
347
+ readonly minLength: 1;
348
+ };
349
+ readonly boundAt: {
350
+ readonly type: "string";
351
+ readonly format: "date-time";
352
+ };
353
+ readonly until: {
354
+ readonly type: "string";
355
+ readonly format: "date-time";
356
+ readonly description: "When wearing it here ends on its own. Absent when it lasts until changed.";
357
+ };
358
+ };
359
+ };
360
+ };
361
+ readonly ext: {
362
+ readonly $ref: "#/$defs/Ext";
363
+ };
364
+ };
365
+ };
366
+ readonly Ext: {
367
+ readonly title: "Ext";
368
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
369
+ readonly type: "object";
370
+ readonly minProperties: 1;
371
+ readonly additionalProperties: true;
372
+ readonly propertyNames: {
373
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
374
+ };
375
+ };
376
+ readonly FaceReach: {
377
+ readonly title: "FaceReach";
378
+ readonly description: "Where a pool face may be worn. `anywhere` is the default and what an absent member means. `only` names the contexts it may be worn in, and a maintainer MUST refuse to wear it in any other (persona/binding/set `outsideReach`).\n\nA tagged object rather than a bare list of contexts, deliberately: an empty list has been read as both 'unrestricted' and 'nowhere' in this family's neighbours, and a shape where the two cannot be confused is worth more than one where they must be remembered. So `only` requires at least one context, and 'nowhere' is not a reach — it is a retired face.\n\nA context-local face has no reach: it lives in its context and is worn there by construction.";
379
+ readonly oneOf: readonly [{
380
+ readonly type: "object";
381
+ readonly additionalProperties: false;
382
+ readonly required: readonly ["kind"];
383
+ readonly properties: {
384
+ readonly kind: {
385
+ readonly const: "anywhere";
386
+ };
387
+ };
388
+ }, {
389
+ readonly type: "object";
390
+ readonly additionalProperties: false;
391
+ readonly required: readonly ["kind", "contextIds"];
392
+ readonly properties: {
393
+ readonly kind: {
394
+ readonly const: "only";
395
+ };
396
+ readonly contextIds: {
397
+ readonly type: "array";
398
+ readonly minItems: 1;
399
+ readonly maxItems: 256;
400
+ readonly uniqueItems: true;
401
+ readonly items: {
402
+ readonly type: "string";
403
+ readonly minLength: 1;
404
+ };
405
+ };
406
+ };
407
+ }];
408
+ };
409
+ readonly Ulid: {
410
+ readonly title: "Ulid";
411
+ readonly description: "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.";
412
+ readonly type: "string";
413
+ readonly pattern: "^[0-9A-HJKMNP-TV-Z]{26}$";
414
+ };
415
+ };
416
+ };
417
+ };
418
+ /**
419
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
420
+ * tracks the *issuer* party's requirement because a response swaps the
421
+ * parties (§7.3 item 5).
422
+ */
423
+ export declare const RESPONSE_SPEC: {
424
+ readonly typeUri: "https://trusttasks.org/spec/persona/profile/usage/1.0#response";
425
+ readonly isBearer: false;
426
+ readonly isProofRequired: false;
427
+ readonly isRecipientRequired: true;
428
+ readonly isIssuedAtRequired: false;
429
+ readonly payloadSchema: {
430
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
431
+ readonly $ref: "#/$defs/Response";
432
+ readonly $defs: {
433
+ readonly Response: {
434
+ readonly $anchor: "response";
435
+ readonly title: "Persona Profile Usage — response payload";
436
+ readonly description: "Success response to persona/profile/usage. Type https://trusttasks.org/spec/persona/profile/usage/1.0#response. An empty `usage` is a face worn nowhere — a normal state, not an error.";
437
+ readonly type: "object";
438
+ readonly additionalProperties: false;
439
+ readonly required: readonly ["profileId", "usage"];
440
+ readonly properties: {
441
+ readonly profileId: {
442
+ readonly $ref: "#/$defs/Ulid";
443
+ };
444
+ readonly reach: {
445
+ readonly $ref: "#/$defs/FaceReach";
446
+ readonly description: "The face's reach, so the answer and the allow-list it is audited against arrive together. Absent for a context-local face.";
447
+ };
448
+ readonly usage: {
449
+ readonly type: "array";
450
+ readonly maxItems: 1024;
451
+ readonly items: {
452
+ readonly type: "object";
453
+ readonly additionalProperties: false;
454
+ readonly required: readonly ["contextId", "personaDid", "boundAt"];
455
+ readonly properties: {
456
+ readonly contextId: {
457
+ readonly type: "string";
458
+ readonly minLength: 1;
459
+ };
460
+ readonly personaDid: {
461
+ readonly type: "string";
462
+ readonly minLength: 1;
463
+ };
464
+ readonly boundAt: {
465
+ readonly type: "string";
466
+ readonly format: "date-time";
467
+ };
468
+ readonly until: {
469
+ readonly type: "string";
470
+ readonly format: "date-time";
471
+ readonly description: "When wearing it here ends on its own. Absent when it lasts until changed.";
472
+ };
473
+ };
474
+ };
475
+ };
476
+ readonly ext: {
477
+ readonly $ref: "#/$defs/Ext";
478
+ };
479
+ };
480
+ };
481
+ readonly Ext: {
482
+ readonly title: "Ext";
483
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
484
+ readonly type: "object";
485
+ readonly minProperties: 1;
486
+ readonly additionalProperties: true;
487
+ readonly propertyNames: {
488
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
489
+ };
490
+ };
491
+ readonly FaceReach: {
492
+ readonly title: "FaceReach";
493
+ readonly description: "Where a pool face may be worn. `anywhere` is the default and what an absent member means. `only` names the contexts it may be worn in, and a maintainer MUST refuse to wear it in any other (persona/binding/set `outsideReach`).\n\nA tagged object rather than a bare list of contexts, deliberately: an empty list has been read as both 'unrestricted' and 'nowhere' in this family's neighbours, and a shape where the two cannot be confused is worth more than one where they must be remembered. So `only` requires at least one context, and 'nowhere' is not a reach — it is a retired face.\n\nA context-local face has no reach: it lives in its context and is worn there by construction.";
494
+ readonly oneOf: readonly [{
495
+ readonly type: "object";
496
+ readonly additionalProperties: false;
497
+ readonly required: readonly ["kind"];
498
+ readonly properties: {
499
+ readonly kind: {
500
+ readonly const: "anywhere";
501
+ };
502
+ };
503
+ }, {
504
+ readonly type: "object";
505
+ readonly additionalProperties: false;
506
+ readonly required: readonly ["kind", "contextIds"];
507
+ readonly properties: {
508
+ readonly kind: {
509
+ readonly const: "only";
510
+ };
511
+ readonly contextIds: {
512
+ readonly type: "array";
513
+ readonly minItems: 1;
514
+ readonly maxItems: 256;
515
+ readonly uniqueItems: true;
516
+ readonly items: {
517
+ readonly type: "string";
518
+ readonly minLength: 1;
519
+ };
520
+ };
521
+ };
522
+ }];
523
+ };
524
+ readonly Ulid: {
525
+ readonly title: "Ulid";
526
+ readonly description: "A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.";
527
+ readonly type: "string";
528
+ readonly pattern: "^[0-9A-HJKMNP-TV-Z]{26}$";
529
+ };
530
+ };
531
+ };
532
+ };
533
+ //# sourceMappingURL=payload.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../../../src/persona/profile/usage/1.0/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,mCAAmC,CAAC;AAG9E;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC,SAAS,EAAE,IAAI,CAAC;IAChB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,kCAAkC;IACjD,SAAS,EAAE,IAAI,CAAC;IAChB;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB;;OAEG;IACH,KAAK,EAAE;QACL,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,OAAO,EAAE,MAAM,CAAC;QAChB;;WAEG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,EAAE,CAAC;IACJ,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AAED,kHAAkH;AAClH,YAAY,EAAE,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;AAErC,2BAA2B;AAC3B,eAAO,MAAM,QAAQ,EAAG,uDAAgE,CAAC;AAEzF,mEAAmE;AACnE,MAAM,MAAM,OAAO,GAAG,0BAA0B,CAAC;AAEjD,qEAAqE;AACrE,eAAO,MAAM,iBAAiB,EAAG,gEAAyE,CAAC;AAE3G,4EAA4E;AAC5E,MAAM,MAAM,QAAQ,GAAG,kCAAkC,CAAC;AAE1D;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyIjB,CAAC;AAEX,mEAAmE;AACnE,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqH1B,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOP,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOhB,CAAC"}