@openvtc/trust-tasks 0.2.4 → 0.2.6

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.4",
3
+ "version": "0.2.6",
4
4
  "description": "Generated TypeScript bindings for the Trust Tasks framework registry.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
- * Source: specs/chat/message/1.0/payload.schema.json
3
+ * Source: specs/chat/message/0.1/payload.schema.json
4
4
  */
5
5
 
6
6
  /**
@@ -23,6 +23,10 @@ export interface ChatMessagePayload {
23
23
  * OPTIONAL. Plain-text body. Absent for attachment-only messages.
24
24
  */
25
25
  text?: string;
26
+ /**
27
+ * OPTIONAL. @-mentions carried by the message, ordered to match the U+FFFC sentinel placeholders in `text`: the Nth U+FFFC binds to the Nth entry. Absent/empty when the message mentions no one. The producer is responsible for emitting one U+FFFC sentinel per mention, in order — translating each platform's native mention encoding into this neutral form.
28
+ */
29
+ mentions?: Mention[];
26
30
  /**
27
31
  * OPTIONAL. Attachments carried by reference, never inline.
28
32
  */
@@ -38,6 +42,24 @@ export interface ChatMessagePayload {
38
42
  sentAt: string;
39
43
  ext?: Ext;
40
44
  }
45
+ export interface Mention {
46
+ /**
47
+ * Opaque, bridge-issued handle for the mentioned participant. MUST NOT be a raw platform address; like `conversationId` it carries no platform-native identifier (phone number, UUID, member id) upstream.
48
+ */
49
+ participant: string;
50
+ /**
51
+ * OPTIONAL. Human-readable name the source platform supplied for the participant. A non-authoritative rendering hint — never used for identity. Absent when the platform exposes no name in the mention.
52
+ */
53
+ displayName?: string;
54
+ /**
55
+ * Source-platform native start offset of the sentinel span in `text`. Advisory: offset units differ across platforms, so the authoritative binding is positional (Nth U+FFFC → Nth mention), not by offset.
56
+ */
57
+ start: number;
58
+ /**
59
+ * Source-platform native length of the sentinel span in `text`. Advisory; see `start`.
60
+ */
61
+ length: number;
62
+ }
41
63
  export interface AttachmentRef {
42
64
  /**
43
65
  * Opaque attachment id, resolvable via the bridge's attachment fetch.
@@ -81,7 +103,7 @@ export interface Ext {
81
103
  }
82
104
 
83
105
  /** Trust Task type URI. */
84
- export const TYPE_URI = "https://trusttasks.org/spec/chat/message/1.0" as const;
106
+ export const TYPE_URI = "https://trusttasks.org/spec/chat/message/0.1" as const;
85
107
 
86
108
  /** Trust Task response type URI (request type URI + "#response"). */
87
- export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/chat/message/1.0#response" as const;
109
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/chat/message/0.1#response" as const;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/approver-list/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * Fetch approver bindings, optionally filtered by platform or context.
8
+ */
9
+ export interface ConsentListApproversPayload {
10
+ /**
11
+ * Optional. Restrict to this platform tag.
12
+ */
13
+ platform?: string;
14
+ /**
15
+ * Optional. Restrict to this context path.
16
+ */
17
+ context?: string;
18
+ ext?: Ext;
19
+ }
20
+ /**
21
+ * 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.
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/consent/approver-list/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/consent/approver-list/1.0#response" as const;
@@ -0,0 +1,43 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/consent/approver-set/1.0/payload.schema.json
4
+ */
5
+
6
+ /**
7
+ * An admin binds the operator who approves inbound-messaging consent for a platform within a context.
8
+ */
9
+ export interface ConsentSetApproverPayload {
10
+ /**
11
+ * Messaging-platform tag, e.g. "signal".
12
+ */
13
+ platform: string;
14
+ /**
15
+ * The VTA context path this binding applies to.
16
+ */
17
+ context: string;
18
+ /**
19
+ * VID of the operator authorized to decide consent.
20
+ */
21
+ approver: string;
22
+ /**
23
+ * How the prompt reaches the approver; defaults to bridge-relay.
24
+ */
25
+ route?: "wake" | "bridge-relay";
26
+ /**
27
+ * Optional routing detail (e.g. the operator's opaque conversationRef).
28
+ */
29
+ routeHint?: string;
30
+ ext?: Ext;
31
+ }
32
+ /**
33
+ * 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.
34
+ */
35
+ export interface Ext {
36
+ [k: string]: unknown | undefined;
37
+ }
38
+
39
+ /** Trust Task type URI. */
40
+ export const TYPE_URI = "https://trusttasks.org/spec/consent/approver-set/1.0" as const;
41
+
42
+ /** Trust Task response type URI (request type URI + "#response"). */
43
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/consent/approver-set/1.0#response" as const;
package/src/index.ts CHANGED
@@ -31,10 +31,12 @@ export * as AuthStepUpApproveResponse_v0_2 from "./auth/step-up/approve-response
31
31
  export * as AuthStepUpPolicy_v0_1 from "./auth/step-up/policy/0.1/payload";
32
32
  export * as AuthStepUpPolicy_v0_2 from "./auth/step-up/policy/0.2/payload";
33
33
  export * as AuthWhoami_v0_1 from "./auth/whoami/0.1/payload";
34
- export * as ChatMessage_v1_0 from "./chat/message/1.0/payload";
34
+ export * as ChatMessage_v0_1 from "./chat/message/0.1/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
37
  export * as ConsentShared_v0_1 from "./consent/_shared/0.1/consent";
38
+ export * as ConsentApproverList_v1_0 from "./consent/approver-list/1.0/payload";
39
+ export * as ConsentApproverSet_v1_0 from "./consent/approver-set/1.0/payload";
38
40
  export * as ConsentDecision_v1_0 from "./consent/decision/1.0/payload";
39
41
  export * as ConsentList_v1_0 from "./consent/list/1.0/payload";
40
42
  export * as ConsentRequest_v1_0 from "./consent/request/1.0/payload";