@openvtc/trust-tasks 0.2.2 → 0.2.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openvtc/trust-tasks",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
4
  "description": "Generated TypeScript bindings for the Trust Tasks framework registry.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/_shared/0.1/consent.schema.json
4
+ */
5
+
6
+ /**
7
+ * Platform-agnostic definitions shared across the consent/* tasks.
8
+ */
9
+ export interface ConsentSharedDefinitions {
10
+ [k: string]: unknown | undefined;
11
+ }
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/decision/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * An approver allows or denies an AI agent's access to a messaging conversation.
8
+ */
9
+ export interface ConsentDecisionPayload {
10
+ subject: ConsentSubject;
11
+ /**
12
+ * Whether the subject is permitted. The ABSENCE of any grant is treated as `deny` (default-deny).
13
+ */
14
+ effect: "allow" | "deny";
15
+ /**
16
+ * Granted scope. REQUIRED when `effect` is `allow`.
17
+ */
18
+ scope?: "receive" | "converse";
19
+ /**
20
+ * Echoes the consent/request challenge this decision answers. Omit only for an operator-initiated pre-authorization.
21
+ */
22
+ challenge?: string;
23
+ /**
24
+ * Optional grant TTL; after it the subject must be re-consented.
25
+ */
26
+ expiresAt?: string;
27
+ ext?: Ext;
28
+ }
29
+ /**
30
+ * The platform-agnostic identifier of WHAT is being consented to: one conversation, for one agent.
31
+ */
32
+ export interface ConsentSubject {
33
+ /**
34
+ * Messaging-platform tag, e.g. "signal", "whatsapp", "slack".
35
+ */
36
+ platform: string;
37
+ /**
38
+ * The bridge's OPAQUE conversation handle (e.g. "sig-1a2b3c4d"). NEVER the raw platform address — the VTA never learns the phone number / chat id.
39
+ */
40
+ conversationRef: string;
41
+ /**
42
+ * The interaction kind: a 1:1 direct message, a multi-party group, or a broadcast channel.
43
+ */
44
+ kind: "dm" | "group" | "channel";
45
+ /**
46
+ * VID (DID) of the AI agent the conversation would reach.
47
+ */
48
+ agent: string;
49
+ }
50
+ /**
51
+ * 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.
52
+ */
53
+ export interface Ext {
54
+ [k: string]: unknown | undefined;
55
+ }
56
+
57
+ /** Trust Task type URI. */
58
+ export const TYPE_URI = "https://trusttasks.org/spec/consent/decision/1.0" as const;
59
+
60
+ /** Trust Task response type URI (request type URI + "#response"). */
61
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/consent/decision/1.0#response" as const;
@@ -0,0 +1,57 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/list/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * A bridge fetches the consent grants it should enforce.
8
+ */
9
+ export interface ConsentListPayload {
10
+ /**
11
+ * Optional. Restrict to grants for this agent VID.
12
+ */
13
+ agent?: string;
14
+ /**
15
+ * Optional. Restrict to this platform tag.
16
+ */
17
+ platform?: string;
18
+ subject?: ConsentSubject;
19
+ /**
20
+ * Optional opaque cursor; return only grants changed after it.
21
+ */
22
+ since?: string;
23
+ ext?: Ext;
24
+ }
25
+ /**
26
+ * Optional. A full subject, to point-check a single conversation.
27
+ */
28
+ export interface ConsentSubject {
29
+ /**
30
+ * Messaging-platform tag, e.g. "signal", "whatsapp", "slack".
31
+ */
32
+ platform: string;
33
+ /**
34
+ * The bridge's OPAQUE conversation handle (e.g. "sig-1a2b3c4d"). NEVER the raw platform address — the VTA never learns the phone number / chat id.
35
+ */
36
+ conversationRef: string;
37
+ /**
38
+ * The interaction kind: a 1:1 direct message, a multi-party group, or a broadcast channel.
39
+ */
40
+ kind: "dm" | "group" | "channel";
41
+ /**
42
+ * VID (DID) of the AI agent the conversation would reach.
43
+ */
44
+ agent: string;
45
+ }
46
+ /**
47
+ * 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.
48
+ */
49
+ export interface Ext {
50
+ [k: string]: unknown | undefined;
51
+ }
52
+
53
+ /** Trust Task type URI. */
54
+ export const TYPE_URI = "https://trusttasks.org/spec/consent/list/1.0" as const;
55
+
56
+ /** Trust Task response type URI (request type URI + "#response"). */
57
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/consent/list/1.0#response" as const;
@@ -0,0 +1,65 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/request/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * A bridge asks the VTA whether an inbound conversation may reach an AI agent, prompting operator consent on first contact.
8
+ */
9
+ export interface ConsentRequestPayload {
10
+ subject: ConsentSubject;
11
+ /**
12
+ * The access the bridge seeks for the agent on this conversation.
13
+ */
14
+ scope: "receive" | "converse";
15
+ /**
16
+ * base64url-encoded nonce (≥128 bits entropy) echoed by the matching consent/decision, so the bridge can correlate the decision to this request.
17
+ */
18
+ challenge: string;
19
+ /**
20
+ * Optional operator-facing label (e.g. "Signal group 'Family'"). MUST NOT contain a raw platform address.
21
+ */
22
+ displayHint?: string;
23
+ /**
24
+ * Optional multihash digest of the held first message, binding the request to concrete content.
25
+ */
26
+ firstMessageDigest?: string;
27
+ /**
28
+ * Optional VTA context path the bridge runs under, to scope approver resolution.
29
+ */
30
+ contextHint?: string;
31
+ ext?: Ext;
32
+ }
33
+ /**
34
+ * The platform-agnostic identifier of WHAT is being consented to: one conversation, for one agent.
35
+ */
36
+ export interface ConsentSubject {
37
+ /**
38
+ * Messaging-platform tag, e.g. "signal", "whatsapp", "slack".
39
+ */
40
+ platform: string;
41
+ /**
42
+ * The bridge's OPAQUE conversation handle (e.g. "sig-1a2b3c4d"). NEVER the raw platform address — the VTA never learns the phone number / chat id.
43
+ */
44
+ conversationRef: string;
45
+ /**
46
+ * The interaction kind: a 1:1 direct message, a multi-party group, or a broadcast channel.
47
+ */
48
+ kind: "dm" | "group" | "channel";
49
+ /**
50
+ * VID (DID) of the AI agent the conversation would reach.
51
+ */
52
+ agent: string;
53
+ }
54
+ /**
55
+ * 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.
56
+ */
57
+ export interface Ext {
58
+ [k: string]: unknown | undefined;
59
+ }
60
+
61
+ /** Trust Task type URI. */
62
+ export const TYPE_URI = "https://trusttasks.org/spec/consent/request/1.0" as const;
63
+
64
+ /** Trust Task response type URI (request type URI + "#response"). */
65
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/consent/request/1.0#response" as const;
@@ -0,0 +1,49 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/revoke/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * An operator revokes a standing consent grant.
8
+ */
9
+ export interface ConsentRevokePayload {
10
+ subject: ConsentSubject;
11
+ /**
12
+ * Optional operator note recorded in the audit trail.
13
+ */
14
+ reason?: string;
15
+ ext?: Ext;
16
+ }
17
+ /**
18
+ * The platform-agnostic identifier of WHAT is being consented to: one conversation, for one agent.
19
+ */
20
+ export interface ConsentSubject {
21
+ /**
22
+ * Messaging-platform tag, e.g. "signal", "whatsapp", "slack".
23
+ */
24
+ platform: string;
25
+ /**
26
+ * The bridge's OPAQUE conversation handle (e.g. "sig-1a2b3c4d"). NEVER the raw platform address — the VTA never learns the phone number / chat id.
27
+ */
28
+ conversationRef: string;
29
+ /**
30
+ * The interaction kind: a 1:1 direct message, a multi-party group, or a broadcast channel.
31
+ */
32
+ kind: "dm" | "group" | "channel";
33
+ /**
34
+ * VID (DID) of the AI agent the conversation would reach.
35
+ */
36
+ agent: string;
37
+ }
38
+ /**
39
+ * 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.
40
+ */
41
+ export interface Ext {
42
+ [k: string]: unknown | undefined;
43
+ }
44
+
45
+ /** Trust Task type URI. */
46
+ export const TYPE_URI = "https://trusttasks.org/spec/consent/revoke/1.0" as const;
47
+
48
+ /** Trust Task response type URI (request type URI + "#response"). */
49
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/consent/revoke/1.0#response" as const;
package/src/index.ts CHANGED
@@ -34,6 +34,11 @@ export * as AuthWhoami_v0_1 from "./auth/whoami/0.1/payload";
34
34
  export * as ChatMessage_v1_0 from "./chat/message/1.0/payload";
35
35
  export * as ConfirmRequest_v0_1 from "./confirm/request/0.1/payload";
36
36
  export * as ConfirmResponse_v0_1 from "./confirm/response/0.1/payload";
37
+ export * as ConsentShared_v0_1 from "./consent/_shared/0.1/consent";
38
+ export * as ConsentDecision_v1_0 from "./consent/decision/1.0/payload";
39
+ export * as ConsentList_v1_0 from "./consent/list/1.0/payload";
40
+ export * as ConsentRequest_v1_0 from "./consent/request/1.0/payload";
41
+ export * as ConsentRevoke_v1_0 from "./consent/revoke/1.0/payload";
37
42
  export * as DeviceBindingShared_v0_1 from "./device/_shared/0.1/device-binding";
38
43
  export * as DeviceBindingShared_v0_2 from "./device/_shared/0.2/device-binding";
39
44
  export * as DeviceDisable_v0_1 from "./device/disable/0.1/payload";
@@ -128,6 +133,18 @@ export * as VaultUpsert_v0_2 from "./vault/upsert/0.2/payload";
128
133
  export * as VaultUsage_v0_1 from "./vault/usage/0.1/payload";
129
134
  export * as VaultUsage_v0_2 from "./vault/usage/0.2/payload";
130
135
  export * as PasskeyVmShared_v0_1 from "./vta/_shared/0.1/passkey-vm";
136
+ export * as VtaContextsDidTemplatesCreate_v1_0 from "./vta/contexts/did-templates/create/1.0/payload";
137
+ export * as VtaContextsDidTemplatesDelete_v1_0 from "./vta/contexts/did-templates/delete/1.0/payload";
138
+ export * as VtaContextsDidTemplatesGet_v1_0 from "./vta/contexts/did-templates/get/1.0/payload";
139
+ export * as VtaContextsDidTemplatesList_v1_0 from "./vta/contexts/did-templates/list/1.0/payload";
140
+ export * as VtaContextsDidTemplatesRender_v1_0 from "./vta/contexts/did-templates/render/1.0/payload";
141
+ export * as VtaContextsDidTemplatesUpdate_v1_0 from "./vta/contexts/did-templates/update/1.0/payload";
142
+ export * as VtaDidTemplatesCreate_v1_0 from "./vta/did-templates/create/1.0/payload";
143
+ export * as VtaDidTemplatesDelete_v1_0 from "./vta/did-templates/delete/1.0/payload";
144
+ export * as VtaDidTemplatesGet_v1_0 from "./vta/did-templates/get/1.0/payload";
145
+ export * as VtaDidTemplatesList_v1_0 from "./vta/did-templates/list/1.0/payload";
146
+ export * as VtaDidTemplatesRender_v1_0 from "./vta/did-templates/render/1.0/payload";
147
+ export * as VtaDidTemplatesUpdate_v1_0 from "./vta/did-templates/update/1.0/payload";
131
148
  export * as VtaPasskeyVmsEnrollChallenge_v0_1 from "./vta/passkey-vms/enroll-challenge/0.1/payload";
132
149
  export * as VtaPasskeyVmsEnrollSubmit_v0_1 from "./vta/passkey-vms/enroll-submit/0.1/payload";
133
150
  export * as VtaPasskeyVmsList_v0_1 from "./vta/passkey-vms/list/0.1/payload";
@@ -0,0 +1,73 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/create/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Create a new DID template scoped to a context on a VTA. Gated on the context's admin (or super-admin). The template's own `name` is the resource id within the context scope; the VTA refuses duplicates (use update to replace). The success response is the persisted DidTemplateRecord.
8
+ */
9
+ export interface VTAContextDIDTemplateCreatePayload {
10
+ /**
11
+ * The context the template is scoped to.
12
+ */
13
+ contextId: string;
14
+ template: DidTemplate;
15
+ ext?: Ext;
16
+ }
17
+ /**
18
+ * Full template document to store. Validated against the v1 template schema before persistence; an invalid shape is rejected with the framework's `malformedRequest`.
19
+ */
20
+ export interface DidTemplate {
21
+ /**
22
+ * Template schema version. Currently always 1.
23
+ */
24
+ schemaVersion: 1;
25
+ /**
26
+ * Template id within its scope. Lowercase alphanumeric and hyphen only.
27
+ */
28
+ name: string;
29
+ /**
30
+ * Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour.
31
+ */
32
+ kind: string;
33
+ /**
34
+ * Human-readable description of what the template provisions.
35
+ */
36
+ description?: string | null;
37
+ /**
38
+ * DID methods this template targets, e.g. ["webvh", "web"] for a hosted DID or ["key"] for a did:key.
39
+ */
40
+ methods?: string[];
41
+ /**
42
+ * 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).
43
+ */
44
+ requiredVars?: string[];
45
+ /**
46
+ * Variables with default values, keyed by variable name.
47
+ */
48
+ optionalVars?: {
49
+ [k: string]: unknown | undefined;
50
+ };
51
+ /**
52
+ * Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).
53
+ */
54
+ defaults?: {
55
+ [k: string]: unknown | undefined;
56
+ };
57
+ /**
58
+ * 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.
59
+ */
60
+ document: {};
61
+ }
62
+ /**
63
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
64
+ */
65
+ export interface Ext {
66
+ [k: string]: unknown | undefined;
67
+ }
68
+
69
+ /** Trust Task type URI. */
70
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/create/1.0" as const;
71
+
72
+ /** Trust Task response type URI (request type URI + "#response"). */
73
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/create/1.0#response" as const;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/delete/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Remove a DID template scoped to a context on a VTA by name. Gated on the context's admin (or super-admin). The success response echoes the name and confirms deletion.
8
+ */
9
+ export interface VTAContextDIDTemplateDeletePayload {
10
+ /**
11
+ * The context the template is scoped to.
12
+ */
13
+ contextId: string;
14
+ /**
15
+ * Resource id of the template to remove within the context scope.
16
+ */
17
+ name: string;
18
+ ext?: Ext;
19
+ }
20
+ /**
21
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
22
+ */
23
+ export interface Ext {
24
+ [k: string]: unknown | undefined;
25
+ }
26
+
27
+ /** Trust Task type URI. */
28
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/delete/1.0" as const;
29
+
30
+ /** Trust Task response type URI (request type URI + "#response"). */
31
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/delete/1.0#response" as const;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/get/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Fetch one context-scoped DID template by name from a VTA. Gated on context access. The success response is the persisted DidTemplateRecord.
8
+ */
9
+ export interface VTAContextDIDTemplateGetPayload {
10
+ /**
11
+ * The context the template is scoped to.
12
+ */
13
+ contextId: string;
14
+ /**
15
+ * Template id within the context scope.
16
+ */
17
+ name: string;
18
+ ext?: Ext;
19
+ }
20
+ /**
21
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
22
+ */
23
+ export interface Ext {
24
+ [k: string]: unknown | undefined;
25
+ }
26
+
27
+ /** Trust Task type URI. */
28
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/get/1.0" as const;
29
+
30
+ /** Trust Task response type URI (request type URI + "#response"). */
31
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/get/1.0#response" as const;
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/list/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * List the DID templates scoped to a context on a VTA. Gated on context access. The success response is the set of persisted DidTemplateRecords for the context.
8
+ */
9
+ export interface VTAContextDIDTemplateListPayload {
10
+ /**
11
+ * The context the templates are scoped to.
12
+ */
13
+ contextId: string;
14
+ ext?: Ext;
15
+ }
16
+ /**
17
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
18
+ */
19
+ export interface Ext {
20
+ [k: string]: unknown | undefined;
21
+ }
22
+
23
+ /** Trust Task type URI. */
24
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/list/1.0" as const;
25
+
26
+ /** Trust Task response type URI (request type URI + "#response"). */
27
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/list/1.0#response" as const;
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/render/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Render a context-scoped DID template to a DID document on a VTA. Gated on context access. The VTA fills `{TOKEN}` placeholders with caller-supplied variables plus ambient values it injects server-side. The success response is the rendered DID document.
8
+ */
9
+ export interface VTAContextDIDTemplateRenderPayload {
10
+ /**
11
+ * The context the template is scoped to.
12
+ */
13
+ contextId: string;
14
+ /**
15
+ * Resource id of the template to render within the context scope.
16
+ */
17
+ name: string;
18
+ /**
19
+ * Caller-supplied variables; the VTA also injects ambient VTA_DID, VTA_URL, NOW, CONTEXT_ID, and CONTEXT_DID (if set on the context) server-side.
20
+ */
21
+ vars?: {
22
+ [k: string]: unknown | undefined;
23
+ };
24
+ ext?: Ext;
25
+ }
26
+ /**
27
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
28
+ */
29
+ export interface Ext {
30
+ [k: string]: unknown | undefined;
31
+ }
32
+
33
+ /** Trust Task type URI. */
34
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/render/1.0" as const;
35
+
36
+ /** Trust Task response type URI (request type URI + "#response"). */
37
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/render/1.0#response" as const;
@@ -0,0 +1,77 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/contexts/did-templates/update/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Replace an existing DID template scoped to a context on a VTA. Gated on the context's admin (or super-admin). `name` is the resource id within the context scope and MUST equal `template.name`. The VTA preserves the original createdAt/createdBy and advances updatedAt. The success response is the persisted DidTemplateRecord.
8
+ */
9
+ export interface VTAContextDIDTemplateUpdatePayload {
10
+ /**
11
+ * The context the template is scoped to.
12
+ */
13
+ contextId: string;
14
+ /**
15
+ * Resource id of the template to replace; MUST equal `template.name`.
16
+ */
17
+ name: string;
18
+ template: DidTemplate;
19
+ ext?: Ext;
20
+ }
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
+ export interface DidTemplate {
25
+ /**
26
+ * Template schema version. Currently always 1.
27
+ */
28
+ schemaVersion: 1;
29
+ /**
30
+ * Template id within its scope. Lowercase alphanumeric and hyphen only.
31
+ */
32
+ name: string;
33
+ /**
34
+ * Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour.
35
+ */
36
+ kind: string;
37
+ /**
38
+ * Human-readable description of what the template provisions.
39
+ */
40
+ description?: string | null;
41
+ /**
42
+ * DID methods this template targets, e.g. ["webvh", "web"] for a hosted DID or ["key"] for a did:key.
43
+ */
44
+ methods?: string[];
45
+ /**
46
+ * 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).
47
+ */
48
+ requiredVars?: string[];
49
+ /**
50
+ * Variables with default values, keyed by variable name.
51
+ */
52
+ optionalVars?: {
53
+ [k: string]: unknown | undefined;
54
+ };
55
+ /**
56
+ * Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).
57
+ */
58
+ defaults?: {
59
+ [k: string]: unknown | undefined;
60
+ };
61
+ /**
62
+ * 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.
63
+ */
64
+ document: {};
65
+ }
66
+ /**
67
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
68
+ */
69
+ export interface Ext {
70
+ [k: string]: unknown | undefined;
71
+ }
72
+
73
+ /** Trust Task type URI. */
74
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/update/1.0" as const;
75
+
76
+ /** Trust Task response type URI (request type URI + "#response"). */
77
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/contexts/did-templates/update/1.0#response" as const;
@@ -0,0 +1,69 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/create/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Create a new global DID template on a VTA. Super-admin gated. The template's own `name` is the resource id within the global scope; the VTA refuses duplicates (use update to replace). The success response is the persisted DidTemplateRecord.
8
+ */
9
+ export interface VTADIDTemplateCreatePayload {
10
+ template: DidTemplate;
11
+ ext?: Ext;
12
+ }
13
+ /**
14
+ * Full template document to store. Validated against the v1 template schema before persistence; an invalid shape is rejected with the framework's `malformedRequest`.
15
+ */
16
+ export interface DidTemplate {
17
+ /**
18
+ * Template schema version. Currently always 1.
19
+ */
20
+ schemaVersion: 1;
21
+ /**
22
+ * Template id within its scope. Lowercase alphanumeric and hyphen only.
23
+ */
24
+ name: string;
25
+ /**
26
+ * Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour.
27
+ */
28
+ kind: string;
29
+ /**
30
+ * Human-readable description of what the template provisions.
31
+ */
32
+ description?: string | null;
33
+ /**
34
+ * DID methods this template targets, e.g. ["webvh", "web"] for a hosted DID or ["key"] for a did:key.
35
+ */
36
+ methods?: string[];
37
+ /**
38
+ * 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).
39
+ */
40
+ requiredVars?: string[];
41
+ /**
42
+ * Variables with default values, keyed by variable name.
43
+ */
44
+ optionalVars?: {
45
+ [k: string]: unknown | undefined;
46
+ };
47
+ /**
48
+ * Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).
49
+ */
50
+ defaults?: {
51
+ [k: string]: unknown | undefined;
52
+ };
53
+ /**
54
+ * 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.
55
+ */
56
+ document: {};
57
+ }
58
+ /**
59
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
60
+ */
61
+ export interface Ext {
62
+ [k: string]: unknown | undefined;
63
+ }
64
+
65
+ /** Trust Task type URI. */
66
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/create/1.0" as const;
67
+
68
+ /** Trust Task response type URI (request type URI + "#response"). */
69
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/create/1.0#response" as const;
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/delete/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Remove a global DID template from a VTA by name. Super-admin gated. The success response echoes the deleted name for audit pipelines.
8
+ */
9
+ export interface VTADIDTemplateDeletePayload {
10
+ /**
11
+ * Resource id — the name of the global template to remove.
12
+ */
13
+ name: string;
14
+ ext?: Ext;
15
+ }
16
+ /**
17
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
18
+ */
19
+ export interface Ext {
20
+ [k: string]: unknown | undefined;
21
+ }
22
+
23
+ /** Trust Task type URI. */
24
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/delete/1.0" as const;
25
+
26
+ /** Trust Task response type URI (request type URI + "#response"). */
27
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/delete/1.0#response" as const;
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/get/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Fetch one global DID template on a VTA by name. Open to any authenticated caller. The success response is the persisted DidTemplateRecord.
8
+ */
9
+ export interface VTADIDTemplateGetPayload {
10
+ /**
11
+ * Template name to fetch.
12
+ */
13
+ name: string;
14
+ ext?: Ext;
15
+ }
16
+ /**
17
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
18
+ */
19
+ export interface Ext {
20
+ [k: string]: unknown | undefined;
21
+ }
22
+
23
+ /** Trust Task type URI. */
24
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/get/1.0" as const;
25
+
26
+ /** Trust Task response type URI (request type URI + "#response"). */
27
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/get/1.0#response" as const;
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/list/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * List all global DID templates on a VTA. Open to any authenticated caller. The request takes no parameters. The success response is the array of persisted DidTemplateRecords.
8
+ */
9
+ export interface VTADIDTemplateListPayload {
10
+ ext?: Ext;
11
+ }
12
+ /**
13
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
14
+ */
15
+ export interface Ext {
16
+ [k: string]: unknown | undefined;
17
+ }
18
+
19
+ /** Trust Task type URI. */
20
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/list/1.0" as const;
21
+
22
+ /** Trust Task response type URI (request type URI + "#response"). */
23
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/list/1.0#response" as const;
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/render/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Render a global DID template to a DID document. Authenticated callers supply variables; the VTA injects ambient variables (VTA_DID, VTA_URL, NOW) server-side, merges the caller's on top, substitutes every placeholder, and returns the rendered document.
8
+ */
9
+ export interface VTADIDTemplateRenderPayload {
10
+ /**
11
+ * Resource id — the name of the global template to render.
12
+ */
13
+ name: string;
14
+ /**
15
+ * Caller-supplied template variables, keyed by name. The VTA injects ambient variables VTA_DID, VTA_URL, NOW server-side and merges these on top.
16
+ */
17
+ vars?: {
18
+ [k: string]: unknown | undefined;
19
+ };
20
+ ext?: Ext;
21
+ }
22
+ /**
23
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
24
+ */
25
+ export interface Ext {
26
+ [k: string]: unknown | undefined;
27
+ }
28
+
29
+ /** Trust Task type URI. */
30
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/render/1.0" as const;
31
+
32
+ /** Trust Task response type URI (request type URI + "#response"). */
33
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/render/1.0#response" as const;
@@ -0,0 +1,73 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/did-templates/update/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Replace an existing global DID template on a VTA. Super-admin gated. The `name` is the resource id within the global 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.
8
+ */
9
+ export interface VTADIDTemplateUpdatePayload {
10
+ /**
11
+ * Resource id — the template's name. MUST equal `template.name` or the VTA rejects with the framework's `malformedRequest`.
12
+ */
13
+ name: string;
14
+ template: DidTemplate;
15
+ ext?: Ext;
16
+ }
17
+ /**
18
+ * Full replacement template document. Validated against the v1 template schema before persistence; an invalid shape is rejected with the framework's `malformedRequest`.
19
+ */
20
+ export interface DidTemplate {
21
+ /**
22
+ * Template schema version. Currently always 1.
23
+ */
24
+ schemaVersion: 1;
25
+ /**
26
+ * Template id within its scope. Lowercase alphanumeric and hyphen only.
27
+ */
28
+ name: string;
29
+ /**
30
+ * Classification hint, e.g. `mediator`, `did-host-http`, `app`. Drives downstream provisioning behaviour.
31
+ */
32
+ kind: string;
33
+ /**
34
+ * Human-readable description of what the template provisions.
35
+ */
36
+ description?: string | null;
37
+ /**
38
+ * DID methods this template targets, e.g. ["webvh", "web"] for a hosted DID or ["key"] for a did:key.
39
+ */
40
+ methods?: string[];
41
+ /**
42
+ * 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).
43
+ */
44
+ requiredVars?: string[];
45
+ /**
46
+ * Variables with default values, keyed by variable name.
47
+ */
48
+ optionalVars?: {
49
+ [k: string]: unknown | undefined;
50
+ };
51
+ /**
52
+ * Hints for CLI / setup wizards (e.g. preRotationCount, portable, addMediatorService).
53
+ */
54
+ defaults?: {
55
+ [k: string]: unknown | undefined;
56
+ };
57
+ /**
58
+ * 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.
59
+ */
60
+ document: {};
61
+ }
62
+ /**
63
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
64
+ */
65
+ export interface Ext {
66
+ [k: string]: unknown | undefined;
67
+ }
68
+
69
+ /** Trust Task type URI. */
70
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/update/1.0" as const;
71
+
72
+ /** Trust Task response type URI (request type URI + "#response"). */
73
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/did-templates/update/1.0#response" as const;