@openvtc/trust-tasks 0.28.2 → 0.28.3
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.
- package/CHANGELOG.md +83 -0
- package/dist/_extends.d.ts.map +1 -1
- package/dist/_extends.js +7 -1
- package/dist/_extends.js.map +1 -1
- package/dist/_shared/components.d.ts +530 -3
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/index.d.ts +57 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +57 -0
- package/dist/index.js.map +1 -1
- package/dist/rooms/records/put/0.1/payload.d.ts +4 -4
- package/dist/rooms/records/put/0.1/payload.js +1 -1
- package/dist/rooms/records/put/0.2/payload.d.ts +4 -4
- package/dist/rooms/records/put/0.2/payload.js +1 -1
- package/dist/rooms/records/put/0.3/payload.d.ts +14 -2
- package/dist/rooms/records/put/0.3/payload.d.ts.map +1 -1
- package/dist/rooms/records/put/0.3/payload.js +1 -1
- package/dist/rooms/records/put/0.3/payload.js.map +1 -1
- package/dist/rooms/records/put/0.4/payload.d.ts +1474 -0
- package/dist/rooms/records/put/0.4/payload.d.ts.map +1 -0
- package/dist/rooms/records/put/0.4/payload.js +804 -0
- package/dist/rooms/records/put/0.4/payload.js.map +1 -0
- package/dist/vta/_shared/0.3/did-key-roles.d.ts +1 -1
- package/dist/vta/_shared/0.9/did-template.d.ts +16 -0
- package/dist/vta/_shared/0.9/did-template.d.ts.map +1 -0
- package/dist/vta/_shared/0.9/did-template.js +6 -0
- package/dist/vta/_shared/0.9/did-template.js.map +1 -0
- package/dist/vta/did-templates/create/2.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/create/2.0/payload.js +1 -1
- package/dist/vta/did-templates/create/3.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/create/3.0/payload.js +1 -1
- package/dist/vta/did-templates/create/3.1/payload.d.ts +12 -2
- package/dist/vta/did-templates/create/3.1/payload.d.ts.map +1 -1
- package/dist/vta/did-templates/create/3.1/payload.js +1 -1
- package/dist/vta/did-templates/create/3.1/payload.js.map +1 -1
- package/dist/vta/did-templates/create/3.2/payload.d.ts +1310 -0
- package/dist/vta/did-templates/create/3.2/payload.d.ts.map +1 -0
- package/dist/vta/did-templates/create/3.2/payload.js +832 -0
- package/dist/vta/did-templates/create/3.2/payload.js.map +1 -0
- package/dist/vta/did-templates/get/2.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/get/2.0/payload.js +1 -1
- package/dist/vta/did-templates/get/3.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/get/3.0/payload.js +1 -1
- package/dist/vta/did-templates/get/3.1/payload.d.ts +12 -2
- package/dist/vta/did-templates/get/3.1/payload.d.ts.map +1 -1
- package/dist/vta/did-templates/get/3.1/payload.js +1 -1
- package/dist/vta/did-templates/get/3.1/payload.js.map +1 -1
- package/dist/vta/did-templates/get/3.2/payload.d.ts +928 -0
- package/dist/vta/did-templates/get/3.2/payload.d.ts.map +1 -0
- package/dist/vta/did-templates/get/3.2/payload.js +593 -0
- package/dist/vta/did-templates/get/3.2/payload.js.map +1 -0
- package/dist/vta/did-templates/list/2.0/payload.d.ts +4 -4
- package/dist/vta/did-templates/list/2.0/payload.js +1 -1
- package/dist/vta/did-templates/list/3.0/payload.d.ts +4 -4
- package/dist/vta/did-templates/list/3.0/payload.js +1 -1
- package/dist/vta/did-templates/list/3.1/payload.d.ts +14 -2
- package/dist/vta/did-templates/list/3.1/payload.d.ts.map +1 -1
- package/dist/vta/did-templates/list/3.1/payload.js +1 -1
- package/dist/vta/did-templates/list/3.1/payload.js.map +1 -1
- package/dist/vta/did-templates/list/3.2/payload.d.ts +985 -0
- package/dist/vta/did-templates/list/3.2/payload.d.ts.map +1 -0
- package/dist/vta/did-templates/list/3.2/payload.js +619 -0
- package/dist/vta/did-templates/list/3.2/payload.js.map +1 -0
- package/dist/vta/did-templates/update/2.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/update/2.0/payload.js +1 -1
- package/dist/vta/did-templates/update/3.0/payload.d.ts +3 -3
- package/dist/vta/did-templates/update/3.0/payload.js +1 -1
- package/dist/vta/did-templates/update/3.1/payload.d.ts +12 -2
- package/dist/vta/did-templates/update/3.1/payload.d.ts.map +1 -1
- package/dist/vta/did-templates/update/3.1/payload.js +1 -1
- package/dist/vta/did-templates/update/3.1/payload.js.map +1 -1
- package/dist/vta/did-templates/update/3.2/payload.d.ts +1324 -0
- package/dist/vta/did-templates/update/3.2/payload.d.ts.map +1 -0
- package/dist/vta/did-templates/update/3.2/payload.js +838 -0
- package/dist/vta/did-templates/update/3.2/payload.js.map +1 -0
- package/dist/vta/dids/_shared/0.1/key-roles.d.ts +16 -0
- package/dist/vta/dids/_shared/0.1/key-roles.d.ts.map +1 -0
- package/dist/vta/dids/_shared/0.1/key-roles.js +6 -0
- package/dist/vta/dids/_shared/0.1/key-roles.js.map +1 -0
- package/dist/vta/dids/_shared/0.1/method-profiles/webvh-parameters.d.ts +11 -0
- package/dist/vta/dids/_shared/0.1/method-profiles/webvh-parameters.d.ts.map +1 -0
- package/dist/vta/dids/_shared/0.1/method-profiles/webvh-parameters.js +6 -0
- package/dist/vta/dids/_shared/0.1/method-profiles/webvh-parameters.js.map +1 -0
- package/dist/vta/dids/create/1.0/payload.d.ts +2613 -0
- package/dist/vta/dids/create/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/create/1.0/payload.js +1554 -0
- package/dist/vta/dids/create/1.0/payload.js.map +1 -0
- package/dist/vta/dids/keys/add/1.0/payload.d.ts +2447 -0
- package/dist/vta/dids/keys/add/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/keys/add/1.0/payload.js +1469 -0
- package/dist/vta/dids/keys/add/1.0/payload.js.map +1 -0
- package/dist/vta/dids/keys/list/1.0/payload.d.ts +1855 -0
- package/dist/vta/dids/keys/list/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/keys/list/1.0/payload.js +1116 -0
- package/dist/vta/dids/keys/list/1.0/payload.js.map +1 -0
- package/dist/vta/dids/keys/retire/1.0/payload.d.ts +2449 -0
- package/dist/vta/dids/keys/retire/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/keys/retire/1.0/payload.js +1469 -0
- package/dist/vta/dids/keys/retire/1.0/payload.js.map +1 -0
- package/dist/vta/dids/keys/revoke/1.0/payload.d.ts +2701 -0
- package/dist/vta/dids/keys/revoke/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/keys/revoke/1.0/payload.js +1597 -0
- package/dist/vta/dids/keys/revoke/1.0/payload.js.map +1 -0
- package/dist/vta/dids/keys/rotate/1.0/payload.d.ts +2628 -0
- package/dist/vta/dids/keys/rotate/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/keys/rotate/1.0/payload.js +1555 -0
- package/dist/vta/dids/keys/rotate/1.0/payload.js.map +1 -0
- package/dist/vta/dids/recover/1.0/payload.d.ts +2702 -0
- package/dist/vta/dids/recover/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/recover/1.0/payload.js +1597 -0
- package/dist/vta/dids/recover/1.0/payload.js.map +1 -0
- package/dist/vta/dids/update/1.0/payload.d.ts +1422 -0
- package/dist/vta/dids/update/1.0/payload.d.ts.map +1 -0
- package/dist/vta/dids/update/1.0/payload.js +861 -0
- package/dist/vta/dids/update/1.0/payload.js.map +1 -0
- package/dist/vta/webvh/dids/keys/add/1.0/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/keys/add/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/keys/add/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/keys/add/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/keys/list/1.0/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/keys/list/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/keys/list/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/keys/list/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/keys/retire/1.0/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/keys/retire/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/keys/retire/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/keys/retire/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/keys/revoke/1.0/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/keys/revoke/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/keys/revoke/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/keys/revoke/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.d.ts +2 -14
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/rotate-keys/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/rotate-keys/2.0/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/rotate-keys/2.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/rotate-keys/2.0/payload.js +1 -1
- package/dist/vta/webvh/dids/rotate-keys/2.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/update/1.0/payload.d.ts +2 -14
- package/dist/vta/webvh/dids/update/1.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/update/1.0/payload.js +1 -1
- package/dist/vta/webvh/dids/update/1.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/update/2.0/payload.d.ts +4 -4
- package/dist/vta/webvh/dids/update/2.0/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/update/2.0/payload.js +1 -1
- package/dist/vta/webvh/dids/update/2.0/payload.js.map +1 -1
- package/dist/vta/webvh/dids/update/2.1/payload.d.ts +14 -2
- package/dist/vta/webvh/dids/update/2.1/payload.d.ts.map +1 -1
- package/dist/vta/webvh/dids/update/2.1/payload.js +1 -1
- package/dist/vta/webvh/dids/update/2.1/payload.js.map +1 -1
- package/dist/vtc/_shared/0.2/invite.d.ts +16 -0
- package/dist/vtc/_shared/0.2/invite.d.ts.map +1 -0
- package/dist/vtc/_shared/0.2/invite.js +6 -0
- package/dist/vtc/_shared/0.2/invite.js.map +1 -0
- package/dist/vtc/admin/invites/create/0.1/payload.d.ts +12 -2
- package/dist/vtc/admin/invites/create/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/admin/invites/create/0.1/payload.js +1 -1
- package/dist/vtc/admin/invites/create/0.1/payload.js.map +1 -1
- package/dist/vtc/admin/invites/create/0.2/payload.d.ts +404 -0
- package/dist/vtc/admin/invites/create/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/admin/invites/create/0.2/payload.js +230 -0
- package/dist/vtc/admin/invites/create/0.2/payload.js.map +1 -0
- package/dist/vtc/admin/invites/list/0.1/payload.d.ts +12 -2
- package/dist/vtc/admin/invites/list/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/admin/invites/list/0.1/payload.js +1 -1
- package/dist/vtc/admin/invites/list/0.1/payload.js.map +1 -1
- package/dist/vtc/admin/invites/list/0.2/payload.d.ts +431 -0
- package/dist/vtc/admin/invites/list/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/admin/invites/list/0.2/payload.js +264 -0
- package/dist/vtc/admin/invites/list/0.2/payload.js.map +1 -0
- package/dist/vtc/credentials/reissue/0.1/payload.d.ts +3 -3
- package/dist/vtc/credentials/reissue/0.1/payload.js +1 -1
- package/dist/vtc/credentials/reissue/0.1/payload.js.map +1 -1
- package/package.json +1 -1
- package/src/_extends.ts +5 -0
- package/src/_shared/components.ts +556 -3
- package/src/index.ts +57 -0
- package/src/rooms/records/put/0.1/payload.ts +5 -5
- package/src/rooms/records/put/0.2/payload.ts +5 -5
- package/src/rooms/records/put/0.3/payload.ts +15 -3
- package/src/rooms/records/put/0.4/payload.ts +905 -0
- package/src/vta/_shared/0.3/did-key-roles.ts +1 -1
- package/src/vta/_shared/0.9/did-template.ts +17 -0
- package/src/vta/did-templates/create/2.0/payload.ts +4 -4
- package/src/vta/did-templates/create/3.0/payload.ts +4 -4
- package/src/vta/did-templates/create/3.1/payload.ts +13 -3
- package/src/vta/did-templates/create/3.2/payload.ts +869 -0
- package/src/vta/did-templates/get/2.0/payload.ts +4 -4
- package/src/vta/did-templates/get/3.0/payload.ts +4 -4
- package/src/vta/did-templates/get/3.1/payload.ts +13 -3
- package/src/vta/did-templates/get/3.2/payload.ts +630 -0
- package/src/vta/did-templates/list/2.0/payload.ts +5 -5
- package/src/vta/did-templates/list/3.0/payload.ts +5 -5
- package/src/vta/did-templates/list/3.1/payload.ts +15 -3
- package/src/vta/did-templates/list/3.2/payload.ts +665 -0
- package/src/vta/did-templates/update/2.0/payload.ts +4 -4
- package/src/vta/did-templates/update/3.0/payload.ts +4 -4
- package/src/vta/did-templates/update/3.1/payload.ts +13 -3
- package/src/vta/did-templates/update/3.2/payload.ts +879 -0
- package/src/vta/dids/_shared/0.1/key-roles.ts +17 -0
- package/src/vta/dids/_shared/0.1/method-profiles/webvh-parameters.ts +11 -0
- package/src/vta/dids/create/1.0/payload.ts +1648 -0
- package/src/vta/dids/keys/add/1.0/payload.ts +1553 -0
- package/src/vta/dids/keys/list/1.0/payload.ts +1178 -0
- package/src/vta/dids/keys/retire/1.0/payload.ts +1553 -0
- package/src/vta/dids/keys/revoke/1.0/payload.ts +1697 -0
- package/src/vta/dids/keys/rotate/1.0/payload.ts +1658 -0
- package/src/vta/dids/recover/1.0/payload.ts +1700 -0
- package/src/vta/dids/update/1.0/payload.ts +940 -0
- package/src/vta/webvh/dids/keys/add/1.0/payload.ts +15 -3
- package/src/vta/webvh/dids/keys/list/1.0/payload.ts +15 -3
- package/src/vta/webvh/dids/keys/retire/1.0/payload.ts +15 -3
- package/src/vta/webvh/dids/keys/revoke/1.0/payload.ts +15 -3
- package/src/vta/webvh/dids/rotate-keys/1.0/payload.ts +3 -15
- package/src/vta/webvh/dids/rotate-keys/2.0/payload.ts +15 -3
- package/src/vta/webvh/dids/update/1.0/payload.ts +3 -15
- package/src/vta/webvh/dids/update/2.0/payload.ts +5 -5
- package/src/vta/webvh/dids/update/2.1/payload.ts +15 -3
- package/src/vtc/_shared/0.2/invite.ts +17 -0
- package/src/vtc/admin/invites/create/0.1/payload.ts +13 -3
- package/src/vtc/admin/invites/create/0.2/payload.ts +289 -0
- package/src/vtc/admin/invites/list/0.1/payload.ts +13 -3
- package/src/vtc/admin/invites/list/0.2/payload.ts +294 -0
- package/src/vtc/credentials/reissue/0.1/payload.ts +2 -2
|
@@ -0,0 +1,879 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/vta/did-templates/update/3.2/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { Builtin_VtaV0_1 as Builtin, Context_VtaV0_1 as Context, DidTemplate_VtaV0_9 as DidTemplate, DidTemplateRecord_VtaV0_9 as DidTemplateRecord, Ext, Global_VtaV0_1 as Global, IdentityKeyRole, KeyType, RoleLayout, Scope_VtaV0_1 as Scope } from "../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Replace an existing DID template on a VTA. Omit `contextId` to replace in the global scope (super-admin gated); set it to replace a template scoped to that context (gated on the context's admin, or a super-admin). The `name` is the resource id within the selected scope and MUST equal `template.name`; the VTA replaces the stored body, preserving createdAt/createdBy and advancing updatedAt. The success response is the persisted DidTemplateRecord.
|
|
11
|
+
*/
|
|
12
|
+
export interface VTADIDTemplateUpdatePayload {
|
|
13
|
+
/**
|
|
14
|
+
* Scope selector. Absent: the global scope, gated on a super-administrator. Present: the context the template is scoped to, gated on that context's administrator (or a super-administrator).
|
|
15
|
+
*/
|
|
16
|
+
contextId?: string;
|
|
17
|
+
/**
|
|
18
|
+
* Resource id — the template's name within the selected scope. MUST equal `template.name` or the VTA rejects with the framework's `malformedRequest`.
|
|
19
|
+
*/
|
|
20
|
+
name: string;
|
|
21
|
+
/**
|
|
22
|
+
* Full replacement template document. Validated against the v1 template schema before persistence; an invalid shape is rejected with the framework's `malformedRequest`.
|
|
23
|
+
*/
|
|
24
|
+
template: DidTemplate;
|
|
25
|
+
/**
|
|
26
|
+
* Ecosystem-defined extension members per SPEC.md §4.5.1.
|
|
27
|
+
*/
|
|
28
|
+
ext?: Ext;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
32
|
+
export type { Builtin, Context, DidTemplate, DidTemplateRecord, Ext, Global, IdentityKeyRole, KeyType, RoleLayout, Scope };
|
|
33
|
+
|
|
34
|
+
/** Trust Task type URI. */
|
|
35
|
+
export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/update/3.2" as const;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* The earlier version of this specification that this one declares it
|
|
39
|
+
* extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
|
|
40
|
+
* `null`. Only the direct declaration — follow the chain with
|
|
41
|
+
* `extendsChain` / `readForSpec`.
|
|
42
|
+
*/
|
|
43
|
+
export const EXTENDS: string | null = "3.1";
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Why this version is deprecated, or `null` while it is current. A
|
|
47
|
+
* superseded or retired version is still supported, and is withdrawn from
|
|
48
|
+
* this package in a later scheduled batch (SPEC "Superseded and Withdrawn
|
|
49
|
+
* Versions").
|
|
50
|
+
*/
|
|
51
|
+
export const DEPRECATION: string | null = null;
|
|
52
|
+
|
|
53
|
+
/** Stable alias for this specification's request payload shape. */
|
|
54
|
+
export type Payload = VTADIDTemplateUpdatePayload;
|
|
55
|
+
|
|
56
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
57
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/update/3.2#response" as const;
|
|
58
|
+
|
|
59
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
60
|
+
export type Response = DidTemplateRecord;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* This specification's payload schema, as a value.
|
|
64
|
+
*
|
|
65
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
66
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
67
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
68
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
69
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
70
|
+
*/
|
|
71
|
+
export const PAYLOAD_SCHEMA = {
|
|
72
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
73
|
+
"$id": "https://trusttasks.org/spec/vta/did-templates/update/3.2",
|
|
74
|
+
"title": "VTA DID-Template Update — payload",
|
|
75
|
+
"description": "Replace an existing DID template on a VTA. Omit `contextId` to replace in the global scope (super-admin gated); set it to replace a template scoped to that context (gated on the context's admin, or a super-admin). The `name` is the resource id within the selected scope and MUST equal `template.name`; the VTA replaces the stored body, preserving createdAt/createdBy and advancing updatedAt. The success response is the persisted DidTemplateRecord.",
|
|
76
|
+
"type": "object",
|
|
77
|
+
"additionalProperties": false,
|
|
78
|
+
"required": [
|
|
79
|
+
"name",
|
|
80
|
+
"template"
|
|
81
|
+
],
|
|
82
|
+
"properties": {
|
|
83
|
+
"contextId": {
|
|
84
|
+
"type": "string",
|
|
85
|
+
"minLength": 1,
|
|
86
|
+
"description": "Scope selector. Absent: the global scope, gated on a super-administrator. Present: the context the template is scoped to, gated on that context's administrator (or a super-administrator)."
|
|
87
|
+
},
|
|
88
|
+
"name": {
|
|
89
|
+
"type": "string",
|
|
90
|
+
"minLength": 1,
|
|
91
|
+
"description": "Resource id — the template's name within the selected scope. MUST equal `template.name` or the VTA rejects with the framework's `malformedRequest`."
|
|
92
|
+
},
|
|
93
|
+
"template": {
|
|
94
|
+
"$ref": "#/$defs/DidTemplate",
|
|
95
|
+
"description": "Full replacement template document. Validated against the v1 template schema before persistence; an invalid shape is rejected with the framework's `malformedRequest`."
|
|
96
|
+
},
|
|
97
|
+
"ext": {
|
|
98
|
+
"$ref": "#/$defs/Ext",
|
|
99
|
+
"description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"$defs": {
|
|
103
|
+
"Response": {
|
|
104
|
+
"$anchor": "response",
|
|
105
|
+
"title": "VTA DID-Template Update — response payload",
|
|
106
|
+
"description": "The persisted DidTemplateRecord after replacement. The DidTemplate fields are flattened at the top level alongside the resolved scope and provenance metadata (createdAt/createdBy preserved, updatedAt advanced). Same shape returned by create/get.",
|
|
107
|
+
"$ref": "#/$defs/DidTemplateRecord"
|
|
108
|
+
},
|
|
109
|
+
"DidTemplateRecord": {
|
|
110
|
+
"title": "DidTemplateRecord",
|
|
111
|
+
"description": "A persisted template. The DidTemplate fields are flattened at the top level alongside the resolved scope and provenance metadata. Same shape returned by get/create/update and carried per-item by list.",
|
|
112
|
+
"type": "object",
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"required": [
|
|
115
|
+
"schemaVersion",
|
|
116
|
+
"name",
|
|
117
|
+
"kind",
|
|
118
|
+
"document",
|
|
119
|
+
"scope",
|
|
120
|
+
"createdAt",
|
|
121
|
+
"updatedAt",
|
|
122
|
+
"createdBy"
|
|
123
|
+
],
|
|
124
|
+
"properties": {
|
|
125
|
+
"schemaVersion": {
|
|
126
|
+
"type": "integer",
|
|
127
|
+
"enum": [
|
|
128
|
+
1,
|
|
129
|
+
2,
|
|
130
|
+
3
|
|
131
|
+
],
|
|
132
|
+
"description": "Template schema version. 1 is the historical shape, whose keys are implicitly an Ed25519 signing key and an X25519 key-agreement key. 2 adds the `keys` block, which makes those explicit and allows others."
|
|
133
|
+
},
|
|
134
|
+
"name": {
|
|
135
|
+
"type": "string",
|
|
136
|
+
"minLength": 1,
|
|
137
|
+
"maxLength": 64,
|
|
138
|
+
"pattern": "^[a-z0-9-]+$"
|
|
139
|
+
},
|
|
140
|
+
"kind": {
|
|
141
|
+
"type": "string",
|
|
142
|
+
"minLength": 1
|
|
143
|
+
},
|
|
144
|
+
"description": {
|
|
145
|
+
"type": [
|
|
146
|
+
"string",
|
|
147
|
+
"null"
|
|
148
|
+
],
|
|
149
|
+
"maxLength": 1024
|
|
150
|
+
},
|
|
151
|
+
"methods": {
|
|
152
|
+
"type": "array",
|
|
153
|
+
"items": {
|
|
154
|
+
"type": "string"
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
"requiredVars": {
|
|
158
|
+
"type": "array",
|
|
159
|
+
"items": {
|
|
160
|
+
"type": "string"
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
"optionalVars": {
|
|
164
|
+
"type": "object",
|
|
165
|
+
"additionalProperties": true
|
|
166
|
+
},
|
|
167
|
+
"defaults": {
|
|
168
|
+
"type": "object",
|
|
169
|
+
"additionalProperties": true
|
|
170
|
+
},
|
|
171
|
+
"keys": {
|
|
172
|
+
"type": "object",
|
|
173
|
+
"minProperties": 1,
|
|
174
|
+
"additionalProperties": {
|
|
175
|
+
"type": "object",
|
|
176
|
+
"additionalProperties": false,
|
|
177
|
+
"required": [
|
|
178
|
+
"purpose",
|
|
179
|
+
"algorithms"
|
|
180
|
+
],
|
|
181
|
+
"properties": {
|
|
182
|
+
"purpose": {
|
|
183
|
+
"type": "string",
|
|
184
|
+
"enum": [
|
|
185
|
+
"signing",
|
|
186
|
+
"keyAgreement"
|
|
187
|
+
],
|
|
188
|
+
"description": "What the key is for. Deliberately coarser than DID Core's five verification relationships: the template says what the key is, and the `document` body says where it appears. Encoding the relationship here as well would let the two disagree."
|
|
189
|
+
},
|
|
190
|
+
"algorithms": {
|
|
191
|
+
"type": "array",
|
|
192
|
+
"minItems": 1,
|
|
193
|
+
"items": {
|
|
194
|
+
"type": "string",
|
|
195
|
+
"enum": [
|
|
196
|
+
"ed25519",
|
|
197
|
+
"x25519",
|
|
198
|
+
"p256",
|
|
199
|
+
"mldsa44",
|
|
200
|
+
"mldsa65"
|
|
201
|
+
]
|
|
202
|
+
},
|
|
203
|
+
"description": "Acceptable algorithms, MOST PREFERRED FIRST. A list rather than a single value because a fleet does not migrate atomically: `[\"mldsa44\", \"ed25519\"]` means mint ML-DSA-44 where the implementation can and Ed25519 otherwise, so one template serves a VTA with post-quantum support and one without. An implementation MUST NOT substitute an algorithm absent from this list; running out of candidates is an error, never a silent downgrade — a deployment intended to be post-quantum would otherwise ship classical keys with nothing reporting it. `minItems: 1` for the same reason: an empty list would express no preference and inherit whatever the implementation defaulted to."
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
"propertyNames": {
|
|
208
|
+
"pattern": "^[a-z0-9-]+$"
|
|
209
|
+
},
|
|
210
|
+
"description": "The keys this template needs, by slot name. REQUIRES `schemaVersion` 2.\n\nA slot's name becomes a document placeholder by an explicit rule — uppercase, `-` to `_`, suffix `_KEY_MB` — so slot `signing` is rendered into `{SIGNING_KEY_MB}` and slot `ka` into `{KA_KEY_MB}`. Those are the two names a `schemaVersion` 1 template already uses, which is deliberate: a v1 template is exactly a v2 template whose `keys` block is `{signing: [ed25519], ka: [x25519]}`, so an implementation can read both through one path and raising the version cannot change how a v1 template renders.\n\nAn implementation MUST refuse a template that declares a slot whose placeholder never appears in `document` — the key would be minted and never published, so verifiers would continue to see only the keys that are, while the operator believes the template migrated. It MUST likewise refuse a slot placeholder in `document` that no slot declares, which would render as an unsubstituted literal."
|
|
211
|
+
},
|
|
212
|
+
"keyRoles": {
|
|
213
|
+
"type": "array",
|
|
214
|
+
"minItems": 1,
|
|
215
|
+
"items": {
|
|
216
|
+
"$ref": "#/$defs/RoleLayout"
|
|
217
|
+
},
|
|
218
|
+
"description": "The key roles of a key-role identity, one `RoleLayout` per role (vta/dids/_shared/0.1/CONVENTIONS.md §4). REQUIRED for, and only for, `schemaVersion` 3, which then MUST NOT carry `keys`. A v3 template describes only an identity's non-key members: its `document` MUST NOT contain `verificationMethod`, `authentication`, `assertionMethod`, `keyAgreement`, `capabilityInvocation`, `capabilityDelegation` or `keyRoles`, and the VTA renders all of them from this layout and the key-role registry — so a template can never place a key in a relationship its role does not own. Each listed algorithm is minted, one key each; unlike v2's `keys`, the list is not a preference order, and a VTA that cannot mint one refuses rather than substitutes. Used by vta/dids/create; a v1 or v2 template cannot create a key-role identity."
|
|
219
|
+
},
|
|
220
|
+
"document": {
|
|
221
|
+
"type": "object"
|
|
222
|
+
},
|
|
223
|
+
"scope": {
|
|
224
|
+
"$ref": "#/$defs/Scope",
|
|
225
|
+
"description": "Resolved scope of the stored template."
|
|
226
|
+
},
|
|
227
|
+
"createdAt": {
|
|
228
|
+
"type": "string",
|
|
229
|
+
"format": "date-time",
|
|
230
|
+
"description": "When the template was first stored (RFC 3339)."
|
|
231
|
+
},
|
|
232
|
+
"updatedAt": {
|
|
233
|
+
"type": "string",
|
|
234
|
+
"format": "date-time",
|
|
235
|
+
"description": "When the template was last written (RFC 3339)."
|
|
236
|
+
},
|
|
237
|
+
"createdBy": {
|
|
238
|
+
"type": "string",
|
|
239
|
+
"description": "DID of the admin who last wrote the template."
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
"Scope": {
|
|
244
|
+
"title": "Scope",
|
|
245
|
+
"description": "Where a stored template lives. Tagged by `type`.",
|
|
246
|
+
"type": "object",
|
|
247
|
+
"oneOf": [
|
|
248
|
+
{
|
|
249
|
+
"title": "Builtin",
|
|
250
|
+
"type": "object",
|
|
251
|
+
"additionalProperties": false,
|
|
252
|
+
"required": [
|
|
253
|
+
"type"
|
|
254
|
+
],
|
|
255
|
+
"properties": {
|
|
256
|
+
"type": {
|
|
257
|
+
"const": "builtin"
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
"title": "Global",
|
|
263
|
+
"type": "object",
|
|
264
|
+
"additionalProperties": false,
|
|
265
|
+
"required": [
|
|
266
|
+
"type"
|
|
267
|
+
],
|
|
268
|
+
"properties": {
|
|
269
|
+
"type": {
|
|
270
|
+
"const": "global"
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
"title": "Context",
|
|
276
|
+
"type": "object",
|
|
277
|
+
"additionalProperties": false,
|
|
278
|
+
"required": [
|
|
279
|
+
"type",
|
|
280
|
+
"contextId"
|
|
281
|
+
],
|
|
282
|
+
"properties": {
|
|
283
|
+
"type": {
|
|
284
|
+
"const": "context"
|
|
285
|
+
},
|
|
286
|
+
"contextId": {
|
|
287
|
+
"type": "string",
|
|
288
|
+
"minLength": 1
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
]
|
|
293
|
+
},
|
|
294
|
+
"RoleLayout": {
|
|
295
|
+
"title": "RoleLayout",
|
|
296
|
+
"type": "object",
|
|
297
|
+
"additionalProperties": false,
|
|
298
|
+
"required": [
|
|
299
|
+
"role",
|
|
300
|
+
"algorithms"
|
|
301
|
+
],
|
|
302
|
+
"description": "The keys an identity is created with in one role (CONVENTIONS.md §4). A key-role DID template carries one per role; a creation request may narrow it but never widen it.",
|
|
303
|
+
"properties": {
|
|
304
|
+
"role": {
|
|
305
|
+
"$ref": "#/$defs/IdentityKeyRole"
|
|
306
|
+
},
|
|
307
|
+
"algorithms": {
|
|
308
|
+
"type": "array",
|
|
309
|
+
"minItems": 1,
|
|
310
|
+
"uniqueItems": true,
|
|
311
|
+
"items": {
|
|
312
|
+
"$ref": "#/$defs/KeyType"
|
|
313
|
+
},
|
|
314
|
+
"description": "The algorithms to mint, one key each, in publication order — `[\"ed25519\", \"mldsa44\"]` mints a classical and a post-quantum attestation key that sign as a proof set. Every entry MUST suit the role (CONVENTIONS.md §2.2). A VTA that cannot mint one of them MUST refuse the creation with `vta/dids:unsupportedKeyType`; it never substitutes an algorithm or omits a key."
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
},
|
|
318
|
+
"IdentityKeyRole": {
|
|
319
|
+
"title": "IdentityKeyRole",
|
|
320
|
+
"type": "string",
|
|
321
|
+
"enum": [
|
|
322
|
+
"attestation",
|
|
323
|
+
"operational",
|
|
324
|
+
"messaging",
|
|
325
|
+
"update",
|
|
326
|
+
"authenticator"
|
|
327
|
+
],
|
|
328
|
+
"description": "The named key role a key occupies in an identity (CONVENTIONS.md §2; VTI-KEY-070 onward). `attestation` — the only keys in `assertionMethod`; sign the identity's attestation artefacts (credentials, endorsements, status lists) through the VTA's signing service and nowhere else. Generated inside the VTA, never derived, never exportable, never in a backup. `operational` — the only keys the identity's own process uses in `authentication`; sign the node's own traffic (Trust Task requests and responses, DIDComm and TSP signatures, invitations, notices, audit checkpoints). Derived. `messaging` — the only keys in `keyAgreement`; sign nothing. X25519, derived or generated in its own right and never converted from a signing key. `update` — the identifier's change authority as its DID method states it (a did:webvh log's `updateKeys` and `nextKeyHashes`, a KERI key event log's current and next keys); never a role-bound verification method, never in `keyRoles`. Generated inside the VTA, never derived, never exportable, never in a backup, and always accompanied by a committed recovery key held outside the VTA's protection boundary. `authenticator` — a key held on a person's own authenticator (a WebAuthn passkey), listed in `authentication` of that person's identity only; used only to verify the person's WebAuthn assertions (sign-in and step-up evidence) and never to accept a Data Integrity proof. The VTA never holds its private half, so it is enrolled by the passkey ceremony and never generated, added or rotated by these tasks. Never permitted on the durable identity of a VTA, a VTC or a VTN. No role permits `capabilityInvocation` or `capabilityDelegation` (VTI-KEY-075). The set is an extensible registry: a consumer that meets a role it does not implement MUST rely on the key for nothing, and MUST NOT map it onto a role it does know (VTI-KEY-074)."
|
|
329
|
+
},
|
|
330
|
+
"KeyType": {
|
|
331
|
+
"title": "KeyType",
|
|
332
|
+
"type": "string",
|
|
333
|
+
"enum": [
|
|
334
|
+
"ed25519",
|
|
335
|
+
"x25519",
|
|
336
|
+
"p256",
|
|
337
|
+
"mldsa44",
|
|
338
|
+
"mldsa65"
|
|
339
|
+
],
|
|
340
|
+
"description": "Cryptographic algorithm the key material belongs to. `ed25519` signs (EdDSA), `x25519` performs key agreement and never signs, `p256` signs (ES256), and `mldsa44` and `mldsa65` sign with the post-quantum ML-DSA scheme of US NIST FIPS 204. The set is expected to grow as algorithms are standardised, and growing it is a MINOR change under SPEC.md §5.2: `keyType` selects no schema branch, so adding a value relaxes a constraint rather than narrowing one, and the generated libraries mark this enumeration non-exhaustive so that a consumer absorbs a new value rather than failing to compile. Two ML-DSA parameter sets are carried because two specifications require different ones — W3C Quantum-Resistant Cryptosuites defines Data Integrity suites only for ML-DSA-44, while Trust Spanning Protocol Rev 3 §8.1 mandates ML-DSA-65 — so the parameter set is chosen by whatever consumes the key and the two are not redundant. A consumer that does not implement a value it receives MUST refuse the document rather than substitute one it does support."
|
|
341
|
+
},
|
|
342
|
+
"Ext": {
|
|
343
|
+
"title": "Ext",
|
|
344
|
+
"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.",
|
|
345
|
+
"type": "object",
|
|
346
|
+
"minProperties": 1,
|
|
347
|
+
"additionalProperties": true,
|
|
348
|
+
"propertyNames": {
|
|
349
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
350
|
+
}
|
|
351
|
+
},
|
|
352
|
+
"DidTemplate": {
|
|
353
|
+
"title": "DidTemplate",
|
|
354
|
+
"description": "Authored template shape: a DID document with `{TOKEN}` placeholders plus the variable contract the VTA's renderer enforces.",
|
|
355
|
+
"type": "object",
|
|
356
|
+
"additionalProperties": false,
|
|
357
|
+
"required": [
|
|
358
|
+
"schemaVersion",
|
|
359
|
+
"name",
|
|
360
|
+
"kind",
|
|
361
|
+
"document"
|
|
362
|
+
],
|
|
363
|
+
"properties": {
|
|
364
|
+
"schemaVersion": {
|
|
365
|
+
"type": "integer",
|
|
366
|
+
"description": "Template schema version. 1 is the historical shape, whose keys are implicitly an Ed25519 signing key and an X25519 key-agreement key. 2 adds the `keys` block, which makes those explicit and allows others. 3 is a key-role template (`keyRoles`), whose document carries no key members.",
|
|
367
|
+
"enum": [
|
|
368
|
+
1,
|
|
369
|
+
2,
|
|
370
|
+
3
|
|
371
|
+
]
|
|
372
|
+
},
|
|
373
|
+
"name": {
|
|
374
|
+
"type": "string",
|
|
375
|
+
"minLength": 1,
|
|
376
|
+
"maxLength": 64,
|
|
377
|
+
"pattern": "^[a-z0-9-]+$",
|
|
378
|
+
"description": "Template id within its scope. Lowercase alphanumeric and hyphen only."
|
|
379
|
+
},
|
|
380
|
+
"kind": {
|
|
381
|
+
"type": "string",
|
|
382
|
+
"minLength": 1,
|
|
383
|
+
"description": "Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour."
|
|
384
|
+
},
|
|
385
|
+
"description": {
|
|
386
|
+
"type": [
|
|
387
|
+
"string",
|
|
388
|
+
"null"
|
|
389
|
+
],
|
|
390
|
+
"maxLength": 1024,
|
|
391
|
+
"description": "Human-readable description of what the template provisions."
|
|
392
|
+
},
|
|
393
|
+
"methods": {
|
|
394
|
+
"type": "array",
|
|
395
|
+
"items": {
|
|
396
|
+
"type": "string"
|
|
397
|
+
},
|
|
398
|
+
"description": "DID methods this template targets, e.g. [\"webvh\", \"web\"] for a hosted DID or [\"key\"] for a did:key."
|
|
399
|
+
},
|
|
400
|
+
"requiredVars": {
|
|
401
|
+
"type": "array",
|
|
402
|
+
"items": {
|
|
403
|
+
"type": "string"
|
|
404
|
+
},
|
|
405
|
+
"description": "Variables the caller MUST supply at render time. MUST NOT include reserved ambient names (DID, SIGNING_KEY_MB, KA_KEY_MB, VTA_DID, VTA_URL, CONTEXT_ID, CONTEXT_DID, NOW)."
|
|
406
|
+
},
|
|
407
|
+
"optionalVars": {
|
|
408
|
+
"type": "object",
|
|
409
|
+
"description": "Variables with default values, keyed by variable name.",
|
|
410
|
+
"additionalProperties": true
|
|
411
|
+
},
|
|
412
|
+
"defaults": {
|
|
413
|
+
"type": "object",
|
|
414
|
+
"description": "Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).",
|
|
415
|
+
"additionalProperties": true
|
|
416
|
+
},
|
|
417
|
+
"keys": {
|
|
418
|
+
"type": "object",
|
|
419
|
+
"minProperties": 1,
|
|
420
|
+
"additionalProperties": {
|
|
421
|
+
"type": "object",
|
|
422
|
+
"additionalProperties": false,
|
|
423
|
+
"required": [
|
|
424
|
+
"purpose",
|
|
425
|
+
"algorithms"
|
|
426
|
+
],
|
|
427
|
+
"properties": {
|
|
428
|
+
"purpose": {
|
|
429
|
+
"type": "string",
|
|
430
|
+
"enum": [
|
|
431
|
+
"signing",
|
|
432
|
+
"keyAgreement"
|
|
433
|
+
],
|
|
434
|
+
"description": "What the key is for. Deliberately coarser than DID Core's five verification relationships: the template says what the key is, and the `document` body says where it appears. Encoding the relationship here as well would let the two disagree."
|
|
435
|
+
},
|
|
436
|
+
"algorithms": {
|
|
437
|
+
"type": "array",
|
|
438
|
+
"minItems": 1,
|
|
439
|
+
"items": {
|
|
440
|
+
"type": "string",
|
|
441
|
+
"enum": [
|
|
442
|
+
"ed25519",
|
|
443
|
+
"x25519",
|
|
444
|
+
"p256",
|
|
445
|
+
"mldsa44",
|
|
446
|
+
"mldsa65"
|
|
447
|
+
]
|
|
448
|
+
},
|
|
449
|
+
"description": "Acceptable algorithms, MOST PREFERRED FIRST. A list rather than a single value because a fleet does not migrate atomically: `[\"mldsa44\", \"ed25519\"]` means mint ML-DSA-44 where the implementation can and Ed25519 otherwise, so one template serves a VTA with post-quantum support and one without. An implementation MUST NOT substitute an algorithm absent from this list; running out of candidates is an error, never a silent downgrade — a deployment intended to be post-quantum would otherwise ship classical keys with nothing reporting it. `minItems: 1` for the same reason: an empty list would express no preference and inherit whatever the implementation defaulted to."
|
|
450
|
+
}
|
|
451
|
+
}
|
|
452
|
+
},
|
|
453
|
+
"propertyNames": {
|
|
454
|
+
"pattern": "^[a-z0-9-]+$"
|
|
455
|
+
},
|
|
456
|
+
"description": "The keys this template needs, by slot name. REQUIRES `schemaVersion` 2.\n\nA slot's name becomes a document placeholder by an explicit rule — uppercase, `-` to `_`, suffix `_KEY_MB` — so slot `signing` is rendered into `{SIGNING_KEY_MB}` and slot `ka` into `{KA_KEY_MB}`. Those are the two names a `schemaVersion` 1 template already uses, which is deliberate: a v1 template is exactly a v2 template whose `keys` block is `{signing: [ed25519], ka: [x25519]}`, so an implementation can read both through one path and raising the version cannot change how a v1 template renders.\n\nAn implementation MUST refuse a template that declares a slot whose placeholder never appears in `document` — the key would be minted and never published, so verifiers would continue to see only the keys that are, while the operator believes the template migrated. It MUST likewise refuse a slot placeholder in `document` that no slot declares, which would render as an unsubstituted literal."
|
|
457
|
+
},
|
|
458
|
+
"keyRoles": {
|
|
459
|
+
"type": "array",
|
|
460
|
+
"minItems": 1,
|
|
461
|
+
"items": {
|
|
462
|
+
"$ref": "#/$defs/RoleLayout"
|
|
463
|
+
},
|
|
464
|
+
"description": "The key roles of a key-role identity, one `RoleLayout` per role (vta/dids/_shared/0.1/CONVENTIONS.md §4). REQUIRED for, and only for, `schemaVersion` 3, which then MUST NOT carry `keys`. A v3 template describes only an identity's non-key members: its `document` MUST NOT contain `verificationMethod`, `authentication`, `assertionMethod`, `keyAgreement`, `capabilityInvocation`, `capabilityDelegation` or `keyRoles`, and the VTA renders all of them from this layout and the key-role registry — so a template can never place a key in a relationship its role does not own. Each listed algorithm is minted, one key each; unlike v2's `keys`, the list is not a preference order, and a VTA that cannot mint one refuses rather than substitutes. Used by vta/dids/create; a v1 or v2 template cannot create a key-role identity."
|
|
465
|
+
},
|
|
466
|
+
"document": {
|
|
467
|
+
"type": "object",
|
|
468
|
+
"description": "The DID document body with `{TOKEN}` placeholders. `document.id` MUST contain the `{DID}` placeholder. Every `{TOKEN}` MUST be declared in requiredVars/optionalVars or be a reserved ambient name."
|
|
469
|
+
}
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
} as const;
|
|
474
|
+
|
|
475
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
476
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
477
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
478
|
+
"$ref": "#/$defs/Response",
|
|
479
|
+
"$defs": {
|
|
480
|
+
"Response": {
|
|
481
|
+
"$anchor": "response",
|
|
482
|
+
"title": "VTA DID-Template Update — response payload",
|
|
483
|
+
"description": "The persisted DidTemplateRecord after replacement. The DidTemplate fields are flattened at the top level alongside the resolved scope and provenance metadata (createdAt/createdBy preserved, updatedAt advanced). Same shape returned by create/get.",
|
|
484
|
+
"$ref": "#/$defs/DidTemplateRecord"
|
|
485
|
+
},
|
|
486
|
+
"DidTemplateRecord": {
|
|
487
|
+
"title": "DidTemplateRecord",
|
|
488
|
+
"description": "A persisted template. The DidTemplate fields are flattened at the top level alongside the resolved scope and provenance metadata. Same shape returned by get/create/update and carried per-item by list.",
|
|
489
|
+
"type": "object",
|
|
490
|
+
"additionalProperties": false,
|
|
491
|
+
"required": [
|
|
492
|
+
"schemaVersion",
|
|
493
|
+
"name",
|
|
494
|
+
"kind",
|
|
495
|
+
"document",
|
|
496
|
+
"scope",
|
|
497
|
+
"createdAt",
|
|
498
|
+
"updatedAt",
|
|
499
|
+
"createdBy"
|
|
500
|
+
],
|
|
501
|
+
"properties": {
|
|
502
|
+
"schemaVersion": {
|
|
503
|
+
"type": "integer",
|
|
504
|
+
"enum": [
|
|
505
|
+
1,
|
|
506
|
+
2,
|
|
507
|
+
3
|
|
508
|
+
],
|
|
509
|
+
"description": "Template schema version. 1 is the historical shape, whose keys are implicitly an Ed25519 signing key and an X25519 key-agreement key. 2 adds the `keys` block, which makes those explicit and allows others."
|
|
510
|
+
},
|
|
511
|
+
"name": {
|
|
512
|
+
"type": "string",
|
|
513
|
+
"minLength": 1,
|
|
514
|
+
"maxLength": 64,
|
|
515
|
+
"pattern": "^[a-z0-9-]+$"
|
|
516
|
+
},
|
|
517
|
+
"kind": {
|
|
518
|
+
"type": "string",
|
|
519
|
+
"minLength": 1
|
|
520
|
+
},
|
|
521
|
+
"description": {
|
|
522
|
+
"type": [
|
|
523
|
+
"string",
|
|
524
|
+
"null"
|
|
525
|
+
],
|
|
526
|
+
"maxLength": 1024
|
|
527
|
+
},
|
|
528
|
+
"methods": {
|
|
529
|
+
"type": "array",
|
|
530
|
+
"items": {
|
|
531
|
+
"type": "string"
|
|
532
|
+
}
|
|
533
|
+
},
|
|
534
|
+
"requiredVars": {
|
|
535
|
+
"type": "array",
|
|
536
|
+
"items": {
|
|
537
|
+
"type": "string"
|
|
538
|
+
}
|
|
539
|
+
},
|
|
540
|
+
"optionalVars": {
|
|
541
|
+
"type": "object",
|
|
542
|
+
"additionalProperties": true
|
|
543
|
+
},
|
|
544
|
+
"defaults": {
|
|
545
|
+
"type": "object",
|
|
546
|
+
"additionalProperties": true
|
|
547
|
+
},
|
|
548
|
+
"keys": {
|
|
549
|
+
"type": "object",
|
|
550
|
+
"minProperties": 1,
|
|
551
|
+
"additionalProperties": {
|
|
552
|
+
"type": "object",
|
|
553
|
+
"additionalProperties": false,
|
|
554
|
+
"required": [
|
|
555
|
+
"purpose",
|
|
556
|
+
"algorithms"
|
|
557
|
+
],
|
|
558
|
+
"properties": {
|
|
559
|
+
"purpose": {
|
|
560
|
+
"type": "string",
|
|
561
|
+
"enum": [
|
|
562
|
+
"signing",
|
|
563
|
+
"keyAgreement"
|
|
564
|
+
],
|
|
565
|
+
"description": "What the key is for. Deliberately coarser than DID Core's five verification relationships: the template says what the key is, and the `document` body says where it appears. Encoding the relationship here as well would let the two disagree."
|
|
566
|
+
},
|
|
567
|
+
"algorithms": {
|
|
568
|
+
"type": "array",
|
|
569
|
+
"minItems": 1,
|
|
570
|
+
"items": {
|
|
571
|
+
"type": "string",
|
|
572
|
+
"enum": [
|
|
573
|
+
"ed25519",
|
|
574
|
+
"x25519",
|
|
575
|
+
"p256",
|
|
576
|
+
"mldsa44",
|
|
577
|
+
"mldsa65"
|
|
578
|
+
]
|
|
579
|
+
},
|
|
580
|
+
"description": "Acceptable algorithms, MOST PREFERRED FIRST. A list rather than a single value because a fleet does not migrate atomically: `[\"mldsa44\", \"ed25519\"]` means mint ML-DSA-44 where the implementation can and Ed25519 otherwise, so one template serves a VTA with post-quantum support and one without. An implementation MUST NOT substitute an algorithm absent from this list; running out of candidates is an error, never a silent downgrade — a deployment intended to be post-quantum would otherwise ship classical keys with nothing reporting it. `minItems: 1` for the same reason: an empty list would express no preference and inherit whatever the implementation defaulted to."
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
},
|
|
584
|
+
"propertyNames": {
|
|
585
|
+
"pattern": "^[a-z0-9-]+$"
|
|
586
|
+
},
|
|
587
|
+
"description": "The keys this template needs, by slot name. REQUIRES `schemaVersion` 2.\n\nA slot's name becomes a document placeholder by an explicit rule — uppercase, `-` to `_`, suffix `_KEY_MB` — so slot `signing` is rendered into `{SIGNING_KEY_MB}` and slot `ka` into `{KA_KEY_MB}`. Those are the two names a `schemaVersion` 1 template already uses, which is deliberate: a v1 template is exactly a v2 template whose `keys` block is `{signing: [ed25519], ka: [x25519]}`, so an implementation can read both through one path and raising the version cannot change how a v1 template renders.\n\nAn implementation MUST refuse a template that declares a slot whose placeholder never appears in `document` — the key would be minted and never published, so verifiers would continue to see only the keys that are, while the operator believes the template migrated. It MUST likewise refuse a slot placeholder in `document` that no slot declares, which would render as an unsubstituted literal."
|
|
588
|
+
},
|
|
589
|
+
"keyRoles": {
|
|
590
|
+
"type": "array",
|
|
591
|
+
"minItems": 1,
|
|
592
|
+
"items": {
|
|
593
|
+
"$ref": "#/$defs/RoleLayout"
|
|
594
|
+
},
|
|
595
|
+
"description": "The key roles of a key-role identity, one `RoleLayout` per role (vta/dids/_shared/0.1/CONVENTIONS.md §4). REQUIRED for, and only for, `schemaVersion` 3, which then MUST NOT carry `keys`. A v3 template describes only an identity's non-key members: its `document` MUST NOT contain `verificationMethod`, `authentication`, `assertionMethod`, `keyAgreement`, `capabilityInvocation`, `capabilityDelegation` or `keyRoles`, and the VTA renders all of them from this layout and the key-role registry — so a template can never place a key in a relationship its role does not own. Each listed algorithm is minted, one key each; unlike v2's `keys`, the list is not a preference order, and a VTA that cannot mint one refuses rather than substitutes. Used by vta/dids/create; a v1 or v2 template cannot create a key-role identity."
|
|
596
|
+
},
|
|
597
|
+
"document": {
|
|
598
|
+
"type": "object"
|
|
599
|
+
},
|
|
600
|
+
"scope": {
|
|
601
|
+
"$ref": "#/$defs/Scope",
|
|
602
|
+
"description": "Resolved scope of the stored template."
|
|
603
|
+
},
|
|
604
|
+
"createdAt": {
|
|
605
|
+
"type": "string",
|
|
606
|
+
"format": "date-time",
|
|
607
|
+
"description": "When the template was first stored (RFC 3339)."
|
|
608
|
+
},
|
|
609
|
+
"updatedAt": {
|
|
610
|
+
"type": "string",
|
|
611
|
+
"format": "date-time",
|
|
612
|
+
"description": "When the template was last written (RFC 3339)."
|
|
613
|
+
},
|
|
614
|
+
"createdBy": {
|
|
615
|
+
"type": "string",
|
|
616
|
+
"description": "DID of the admin who last wrote the template."
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
},
|
|
620
|
+
"Scope": {
|
|
621
|
+
"title": "Scope",
|
|
622
|
+
"description": "Where a stored template lives. Tagged by `type`.",
|
|
623
|
+
"type": "object",
|
|
624
|
+
"oneOf": [
|
|
625
|
+
{
|
|
626
|
+
"title": "Builtin",
|
|
627
|
+
"type": "object",
|
|
628
|
+
"additionalProperties": false,
|
|
629
|
+
"required": [
|
|
630
|
+
"type"
|
|
631
|
+
],
|
|
632
|
+
"properties": {
|
|
633
|
+
"type": {
|
|
634
|
+
"const": "builtin"
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
},
|
|
638
|
+
{
|
|
639
|
+
"title": "Global",
|
|
640
|
+
"type": "object",
|
|
641
|
+
"additionalProperties": false,
|
|
642
|
+
"required": [
|
|
643
|
+
"type"
|
|
644
|
+
],
|
|
645
|
+
"properties": {
|
|
646
|
+
"type": {
|
|
647
|
+
"const": "global"
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
"title": "Context",
|
|
653
|
+
"type": "object",
|
|
654
|
+
"additionalProperties": false,
|
|
655
|
+
"required": [
|
|
656
|
+
"type",
|
|
657
|
+
"contextId"
|
|
658
|
+
],
|
|
659
|
+
"properties": {
|
|
660
|
+
"type": {
|
|
661
|
+
"const": "context"
|
|
662
|
+
},
|
|
663
|
+
"contextId": {
|
|
664
|
+
"type": "string",
|
|
665
|
+
"minLength": 1
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
]
|
|
670
|
+
},
|
|
671
|
+
"RoleLayout": {
|
|
672
|
+
"title": "RoleLayout",
|
|
673
|
+
"type": "object",
|
|
674
|
+
"additionalProperties": false,
|
|
675
|
+
"required": [
|
|
676
|
+
"role",
|
|
677
|
+
"algorithms"
|
|
678
|
+
],
|
|
679
|
+
"description": "The keys an identity is created with in one role (CONVENTIONS.md §4). A key-role DID template carries one per role; a creation request may narrow it but never widen it.",
|
|
680
|
+
"properties": {
|
|
681
|
+
"role": {
|
|
682
|
+
"$ref": "#/$defs/IdentityKeyRole"
|
|
683
|
+
},
|
|
684
|
+
"algorithms": {
|
|
685
|
+
"type": "array",
|
|
686
|
+
"minItems": 1,
|
|
687
|
+
"uniqueItems": true,
|
|
688
|
+
"items": {
|
|
689
|
+
"$ref": "#/$defs/KeyType"
|
|
690
|
+
},
|
|
691
|
+
"description": "The algorithms to mint, one key each, in publication order — `[\"ed25519\", \"mldsa44\"]` mints a classical and a post-quantum attestation key that sign as a proof set. Every entry MUST suit the role (CONVENTIONS.md §2.2). A VTA that cannot mint one of them MUST refuse the creation with `vta/dids:unsupportedKeyType`; it never substitutes an algorithm or omits a key."
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
},
|
|
695
|
+
"IdentityKeyRole": {
|
|
696
|
+
"title": "IdentityKeyRole",
|
|
697
|
+
"type": "string",
|
|
698
|
+
"enum": [
|
|
699
|
+
"attestation",
|
|
700
|
+
"operational",
|
|
701
|
+
"messaging",
|
|
702
|
+
"update",
|
|
703
|
+
"authenticator"
|
|
704
|
+
],
|
|
705
|
+
"description": "The named key role a key occupies in an identity (CONVENTIONS.md §2; VTI-KEY-070 onward). `attestation` — the only keys in `assertionMethod`; sign the identity's attestation artefacts (credentials, endorsements, status lists) through the VTA's signing service and nowhere else. Generated inside the VTA, never derived, never exportable, never in a backup. `operational` — the only keys the identity's own process uses in `authentication`; sign the node's own traffic (Trust Task requests and responses, DIDComm and TSP signatures, invitations, notices, audit checkpoints). Derived. `messaging` — the only keys in `keyAgreement`; sign nothing. X25519, derived or generated in its own right and never converted from a signing key. `update` — the identifier's change authority as its DID method states it (a did:webvh log's `updateKeys` and `nextKeyHashes`, a KERI key event log's current and next keys); never a role-bound verification method, never in `keyRoles`. Generated inside the VTA, never derived, never exportable, never in a backup, and always accompanied by a committed recovery key held outside the VTA's protection boundary. `authenticator` — a key held on a person's own authenticator (a WebAuthn passkey), listed in `authentication` of that person's identity only; used only to verify the person's WebAuthn assertions (sign-in and step-up evidence) and never to accept a Data Integrity proof. The VTA never holds its private half, so it is enrolled by the passkey ceremony and never generated, added or rotated by these tasks. Never permitted on the durable identity of a VTA, a VTC or a VTN. No role permits `capabilityInvocation` or `capabilityDelegation` (VTI-KEY-075). The set is an extensible registry: a consumer that meets a role it does not implement MUST rely on the key for nothing, and MUST NOT map it onto a role it does know (VTI-KEY-074)."
|
|
706
|
+
},
|
|
707
|
+
"KeyType": {
|
|
708
|
+
"title": "KeyType",
|
|
709
|
+
"type": "string",
|
|
710
|
+
"enum": [
|
|
711
|
+
"ed25519",
|
|
712
|
+
"x25519",
|
|
713
|
+
"p256",
|
|
714
|
+
"mldsa44",
|
|
715
|
+
"mldsa65"
|
|
716
|
+
],
|
|
717
|
+
"description": "Cryptographic algorithm the key material belongs to. `ed25519` signs (EdDSA), `x25519` performs key agreement and never signs, `p256` signs (ES256), and `mldsa44` and `mldsa65` sign with the post-quantum ML-DSA scheme of US NIST FIPS 204. The set is expected to grow as algorithms are standardised, and growing it is a MINOR change under SPEC.md §5.2: `keyType` selects no schema branch, so adding a value relaxes a constraint rather than narrowing one, and the generated libraries mark this enumeration non-exhaustive so that a consumer absorbs a new value rather than failing to compile. Two ML-DSA parameter sets are carried because two specifications require different ones — W3C Quantum-Resistant Cryptosuites defines Data Integrity suites only for ML-DSA-44, while Trust Spanning Protocol Rev 3 §8.1 mandates ML-DSA-65 — so the parameter set is chosen by whatever consumes the key and the two are not redundant. A consumer that does not implement a value it receives MUST refuse the document rather than substitute one it does support."
|
|
718
|
+
},
|
|
719
|
+
"Ext": {
|
|
720
|
+
"title": "Ext",
|
|
721
|
+
"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.",
|
|
722
|
+
"type": "object",
|
|
723
|
+
"minProperties": 1,
|
|
724
|
+
"additionalProperties": true,
|
|
725
|
+
"propertyNames": {
|
|
726
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
727
|
+
}
|
|
728
|
+
},
|
|
729
|
+
"DidTemplate": {
|
|
730
|
+
"title": "DidTemplate",
|
|
731
|
+
"description": "Authored template shape: a DID document with `{TOKEN}` placeholders plus the variable contract the VTA's renderer enforces.",
|
|
732
|
+
"type": "object",
|
|
733
|
+
"additionalProperties": false,
|
|
734
|
+
"required": [
|
|
735
|
+
"schemaVersion",
|
|
736
|
+
"name",
|
|
737
|
+
"kind",
|
|
738
|
+
"document"
|
|
739
|
+
],
|
|
740
|
+
"properties": {
|
|
741
|
+
"schemaVersion": {
|
|
742
|
+
"type": "integer",
|
|
743
|
+
"description": "Template schema version. 1 is the historical shape, whose keys are implicitly an Ed25519 signing key and an X25519 key-agreement key. 2 adds the `keys` block, which makes those explicit and allows others. 3 is a key-role template (`keyRoles`), whose document carries no key members.",
|
|
744
|
+
"enum": [
|
|
745
|
+
1,
|
|
746
|
+
2,
|
|
747
|
+
3
|
|
748
|
+
]
|
|
749
|
+
},
|
|
750
|
+
"name": {
|
|
751
|
+
"type": "string",
|
|
752
|
+
"minLength": 1,
|
|
753
|
+
"maxLength": 64,
|
|
754
|
+
"pattern": "^[a-z0-9-]+$",
|
|
755
|
+
"description": "Template id within its scope. Lowercase alphanumeric and hyphen only."
|
|
756
|
+
},
|
|
757
|
+
"kind": {
|
|
758
|
+
"type": "string",
|
|
759
|
+
"minLength": 1,
|
|
760
|
+
"description": "Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour."
|
|
761
|
+
},
|
|
762
|
+
"description": {
|
|
763
|
+
"type": [
|
|
764
|
+
"string",
|
|
765
|
+
"null"
|
|
766
|
+
],
|
|
767
|
+
"maxLength": 1024,
|
|
768
|
+
"description": "Human-readable description of what the template provisions."
|
|
769
|
+
},
|
|
770
|
+
"methods": {
|
|
771
|
+
"type": "array",
|
|
772
|
+
"items": {
|
|
773
|
+
"type": "string"
|
|
774
|
+
},
|
|
775
|
+
"description": "DID methods this template targets, e.g. [\"webvh\", \"web\"] for a hosted DID or [\"key\"] for a did:key."
|
|
776
|
+
},
|
|
777
|
+
"requiredVars": {
|
|
778
|
+
"type": "array",
|
|
779
|
+
"items": {
|
|
780
|
+
"type": "string"
|
|
781
|
+
},
|
|
782
|
+
"description": "Variables the caller MUST supply at render time. MUST NOT include reserved ambient names (DID, SIGNING_KEY_MB, KA_KEY_MB, VTA_DID, VTA_URL, CONTEXT_ID, CONTEXT_DID, NOW)."
|
|
783
|
+
},
|
|
784
|
+
"optionalVars": {
|
|
785
|
+
"type": "object",
|
|
786
|
+
"description": "Variables with default values, keyed by variable name.",
|
|
787
|
+
"additionalProperties": true
|
|
788
|
+
},
|
|
789
|
+
"defaults": {
|
|
790
|
+
"type": "object",
|
|
791
|
+
"description": "Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).",
|
|
792
|
+
"additionalProperties": true
|
|
793
|
+
},
|
|
794
|
+
"keys": {
|
|
795
|
+
"type": "object",
|
|
796
|
+
"minProperties": 1,
|
|
797
|
+
"additionalProperties": {
|
|
798
|
+
"type": "object",
|
|
799
|
+
"additionalProperties": false,
|
|
800
|
+
"required": [
|
|
801
|
+
"purpose",
|
|
802
|
+
"algorithms"
|
|
803
|
+
],
|
|
804
|
+
"properties": {
|
|
805
|
+
"purpose": {
|
|
806
|
+
"type": "string",
|
|
807
|
+
"enum": [
|
|
808
|
+
"signing",
|
|
809
|
+
"keyAgreement"
|
|
810
|
+
],
|
|
811
|
+
"description": "What the key is for. Deliberately coarser than DID Core's five verification relationships: the template says what the key is, and the `document` body says where it appears. Encoding the relationship here as well would let the two disagree."
|
|
812
|
+
},
|
|
813
|
+
"algorithms": {
|
|
814
|
+
"type": "array",
|
|
815
|
+
"minItems": 1,
|
|
816
|
+
"items": {
|
|
817
|
+
"type": "string",
|
|
818
|
+
"enum": [
|
|
819
|
+
"ed25519",
|
|
820
|
+
"x25519",
|
|
821
|
+
"p256",
|
|
822
|
+
"mldsa44",
|
|
823
|
+
"mldsa65"
|
|
824
|
+
]
|
|
825
|
+
},
|
|
826
|
+
"description": "Acceptable algorithms, MOST PREFERRED FIRST. A list rather than a single value because a fleet does not migrate atomically: `[\"mldsa44\", \"ed25519\"]` means mint ML-DSA-44 where the implementation can and Ed25519 otherwise, so one template serves a VTA with post-quantum support and one without. An implementation MUST NOT substitute an algorithm absent from this list; running out of candidates is an error, never a silent downgrade — a deployment intended to be post-quantum would otherwise ship classical keys with nothing reporting it. `minItems: 1` for the same reason: an empty list would express no preference and inherit whatever the implementation defaulted to."
|
|
827
|
+
}
|
|
828
|
+
}
|
|
829
|
+
},
|
|
830
|
+
"propertyNames": {
|
|
831
|
+
"pattern": "^[a-z0-9-]+$"
|
|
832
|
+
},
|
|
833
|
+
"description": "The keys this template needs, by slot name. REQUIRES `schemaVersion` 2.\n\nA slot's name becomes a document placeholder by an explicit rule — uppercase, `-` to `_`, suffix `_KEY_MB` — so slot `signing` is rendered into `{SIGNING_KEY_MB}` and slot `ka` into `{KA_KEY_MB}`. Those are the two names a `schemaVersion` 1 template already uses, which is deliberate: a v1 template is exactly a v2 template whose `keys` block is `{signing: [ed25519], ka: [x25519]}`, so an implementation can read both through one path and raising the version cannot change how a v1 template renders.\n\nAn implementation MUST refuse a template that declares a slot whose placeholder never appears in `document` — the key would be minted and never published, so verifiers would continue to see only the keys that are, while the operator believes the template migrated. It MUST likewise refuse a slot placeholder in `document` that no slot declares, which would render as an unsubstituted literal."
|
|
834
|
+
},
|
|
835
|
+
"keyRoles": {
|
|
836
|
+
"type": "array",
|
|
837
|
+
"minItems": 1,
|
|
838
|
+
"items": {
|
|
839
|
+
"$ref": "#/$defs/RoleLayout"
|
|
840
|
+
},
|
|
841
|
+
"description": "The key roles of a key-role identity, one `RoleLayout` per role (vta/dids/_shared/0.1/CONVENTIONS.md §4). REQUIRED for, and only for, `schemaVersion` 3, which then MUST NOT carry `keys`. A v3 template describes only an identity's non-key members: its `document` MUST NOT contain `verificationMethod`, `authentication`, `assertionMethod`, `keyAgreement`, `capabilityInvocation`, `capabilityDelegation` or `keyRoles`, and the VTA renders all of them from this layout and the key-role registry — so a template can never place a key in a relationship its role does not own. Each listed algorithm is minted, one key each; unlike v2's `keys`, the list is not a preference order, and a VTA that cannot mint one refuses rather than substitutes. Used by vta/dids/create; a v1 or v2 template cannot create a key-role identity."
|
|
842
|
+
},
|
|
843
|
+
"document": {
|
|
844
|
+
"type": "object",
|
|
845
|
+
"description": "The DID document body with `{TOKEN}` placeholders. `document.id` MUST contain the `{DID}` placeholder. Every `{TOKEN}` MUST be declared in requiredVars/optionalVars or be a reserved ambient name."
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
}
|
|
850
|
+
} as const;
|
|
851
|
+
|
|
852
|
+
/**
|
|
853
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
854
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
855
|
+
* per-specification and cannot be derived from the document alone, and
|
|
856
|
+
* item 2 needs the schema this carries.
|
|
857
|
+
*/
|
|
858
|
+
export const SPEC = {
|
|
859
|
+
typeUri: TYPE_URI,
|
|
860
|
+
isBearer: false,
|
|
861
|
+
isProofRequired: true,
|
|
862
|
+
isRecipientRequired: true,
|
|
863
|
+
isIssuedAtRequired: true,
|
|
864
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
865
|
+
} as const;
|
|
866
|
+
|
|
867
|
+
/**
|
|
868
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
869
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
870
|
+
* parties (§7.3 item 5).
|
|
871
|
+
*/
|
|
872
|
+
export const RESPONSE_SPEC = {
|
|
873
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
874
|
+
isBearer: false,
|
|
875
|
+
isProofRequired: true,
|
|
876
|
+
isRecipientRequired: true,
|
|
877
|
+
isIssuedAtRequired: true,
|
|
878
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
879
|
+
} as const;
|