@openvtc/trust-tasks 0.21.3 → 0.21.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/CHANGELOG.md +72 -0
  2. package/dist/_shared/components.d.ts +210 -2
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/auth/_shared/0.1/passkey-invite.d.ts +16 -0
  5. package/dist/auth/_shared/0.1/passkey-invite.d.ts.map +1 -0
  6. package/dist/auth/_shared/0.1/passkey-invite.js +6 -0
  7. package/dist/auth/_shared/0.1/passkey-invite.js.map +1 -0
  8. package/dist/auth/passkey/admin-list/0.1/payload.d.ts +484 -0
  9. package/dist/auth/passkey/admin-list/0.1/payload.d.ts.map +1 -0
  10. package/dist/auth/passkey/admin-list/0.1/payload.js +257 -0
  11. package/dist/auth/passkey/admin-list/0.1/payload.js.map +1 -0
  12. package/dist/auth/passkey/enroll/invite/list/0.1/payload.d.ts +393 -0
  13. package/dist/auth/passkey/enroll/invite/list/0.1/payload.d.ts.map +1 -0
  14. package/dist/auth/passkey/enroll/invite/list/0.1/payload.js +234 -0
  15. package/dist/auth/passkey/enroll/invite/list/0.1/payload.js.map +1 -0
  16. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.d.ts +228 -0
  17. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.d.ts.map +1 -0
  18. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.js +138 -0
  19. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.js.map +1 -0
  20. package/dist/auth/passkey/enroll/invite/update/0.1/payload.d.ts +459 -0
  21. package/dist/auth/passkey/enroll/invite/update/0.1/payload.d.ts.map +1 -0
  22. package/dist/auth/passkey/enroll/invite/update/0.1/payload.js +286 -0
  23. package/dist/auth/passkey/enroll/invite/update/0.1/payload.js.map +1 -0
  24. package/dist/auth/step-up/start/0.1/payload.d.ts +420 -0
  25. package/dist/auth/step-up/start/0.1/payload.d.ts.map +1 -0
  26. package/dist/auth/step-up/start/0.1/payload.js +232 -0
  27. package/dist/auth/step-up/start/0.1/payload.js.map +1 -0
  28. package/dist/did-management/_shared/0.1/service-instance.d.ts +1 -1
  29. package/dist/did-management/_shared/0.1/service-instance.d.ts.map +1 -1
  30. package/dist/did-management/_shared/0.2/metrics-snapshot.d.ts +16 -0
  31. package/dist/did-management/_shared/0.2/metrics-snapshot.d.ts.map +1 -0
  32. package/dist/did-management/_shared/0.2/metrics-snapshot.js +6 -0
  33. package/dist/did-management/_shared/0.2/metrics-snapshot.js.map +1 -0
  34. package/dist/did-management/_shared/0.2/service-instance.d.ts +16 -0
  35. package/dist/did-management/_shared/0.2/service-instance.d.ts.map +1 -0
  36. package/dist/did-management/_shared/0.2/service-instance.js +6 -0
  37. package/dist/did-management/_shared/0.2/service-instance.js.map +1 -0
  38. package/dist/did-management/agent-name/resolve/0.1/payload.d.ts +318 -0
  39. package/dist/did-management/agent-name/resolve/0.1/payload.d.ts.map +1 -0
  40. package/dist/did-management/agent-name/resolve/0.1/payload.js +179 -0
  41. package/dist/did-management/agent-name/resolve/0.1/payload.js.map +1 -0
  42. package/dist/did-management/did/log/0.1/payload.d.ts +436 -0
  43. package/dist/did-management/did/log/0.1/payload.d.ts.map +1 -0
  44. package/dist/did-management/did/log/0.1/payload.js +228 -0
  45. package/dist/did-management/did/log/0.1/payload.js.map +1 -0
  46. package/dist/did-management/domain/list/0.1/payload.d.ts +423 -0
  47. package/dist/did-management/domain/list/0.1/payload.d.ts.map +1 -0
  48. package/dist/did-management/domain/list/0.1/payload.js +244 -0
  49. package/dist/did-management/domain/list/0.1/payload.js.map +1 -0
  50. package/dist/did-management/identity/list/0.1/payload.d.ts +494 -0
  51. package/dist/did-management/identity/list/0.1/payload.d.ts.map +1 -0
  52. package/dist/did-management/identity/list/0.1/payload.js +274 -0
  53. package/dist/did-management/identity/list/0.1/payload.js.map +1 -0
  54. package/dist/did-management/identity/retire/0.1/payload.d.ts +242 -0
  55. package/dist/did-management/identity/retire/0.1/payload.d.ts.map +1 -0
  56. package/dist/did-management/identity/retire/0.1/payload.js +142 -0
  57. package/dist/did-management/identity/retire/0.1/payload.js.map +1 -0
  58. package/dist/did-management/registry/admin-register/0.1/payload.d.ts +1 -1
  59. package/dist/did-management/registry/admin-register/0.1/payload.d.ts.map +1 -1
  60. package/dist/did-management/registry/check/0.1/payload.d.ts +639 -0
  61. package/dist/did-management/registry/check/0.1/payload.d.ts.map +1 -0
  62. package/dist/did-management/registry/check/0.1/payload.js +383 -0
  63. package/dist/did-management/registry/check/0.1/payload.js.map +1 -0
  64. package/dist/did-management/registry/get/0.1/payload.d.ts +632 -0
  65. package/dist/did-management/registry/get/0.1/payload.d.ts.map +1 -0
  66. package/dist/did-management/registry/get/0.1/payload.js +381 -0
  67. package/dist/did-management/registry/get/0.1/payload.js.map +1 -0
  68. package/dist/did-management/registry/list/0.1/payload.d.ts +661 -0
  69. package/dist/did-management/registry/list/0.1/payload.d.ts.map +1 -0
  70. package/dist/did-management/registry/list/0.1/payload.js +398 -0
  71. package/dist/did-management/registry/list/0.1/payload.js.map +1 -0
  72. package/dist/did-management/registry/purge-domain/0.1/payload.d.ts +269 -0
  73. package/dist/did-management/registry/purge-domain/0.1/payload.d.ts.map +1 -0
  74. package/dist/did-management/registry/purge-domain/0.1/payload.js +160 -0
  75. package/dist/did-management/registry/purge-domain/0.1/payload.js.map +1 -0
  76. package/dist/did-management/replica/domain/assign/0.1/payload.d.ts +233 -0
  77. package/dist/did-management/replica/domain/assign/0.1/payload.d.ts.map +1 -0
  78. package/dist/did-management/replica/domain/assign/0.1/payload.js +143 -0
  79. package/dist/did-management/replica/domain/assign/0.1/payload.js.map +1 -0
  80. package/dist/did-management/replica/domain/purge/0.1/payload.d.ts +257 -0
  81. package/dist/did-management/replica/domain/purge/0.1/payload.d.ts.map +1 -0
  82. package/dist/did-management/replica/domain/purge/0.1/payload.js +155 -0
  83. package/dist/did-management/replica/domain/purge/0.1/payload.js.map +1 -0
  84. package/dist/did-management/replica/domain/unassign/0.1/payload.d.ts +257 -0
  85. package/dist/did-management/replica/domain/unassign/0.1/payload.d.ts.map +1 -0
  86. package/dist/did-management/replica/domain/unassign/0.1/payload.js +155 -0
  87. package/dist/did-management/replica/domain/unassign/0.1/payload.js.map +1 -0
  88. package/dist/did-management/replica/domain/upsert/0.1/payload.d.ts +401 -0
  89. package/dist/did-management/replica/domain/upsert/0.1/payload.d.ts.map +1 -0
  90. package/dist/did-management/replica/domain/upsert/0.1/payload.js +241 -0
  91. package/dist/did-management/replica/domain/upsert/0.1/payload.js.map +1 -0
  92. package/dist/did-management/server/config/0.1/payload.d.ts +838 -0
  93. package/dist/did-management/server/config/0.1/payload.d.ts.map +1 -0
  94. package/dist/did-management/server/config/0.1/payload.js +444 -0
  95. package/dist/did-management/server/config/0.1/payload.js.map +1 -0
  96. package/dist/did-management/server/info/0.1/payload.d.ts +285 -0
  97. package/dist/did-management/server/info/0.1/payload.d.ts.map +1 -0
  98. package/dist/did-management/server/info/0.1/payload.js +160 -0
  99. package/dist/did-management/server/info/0.1/payload.js.map +1 -0
  100. package/dist/did-management/server/metrics/0.1/payload.d.ts +674 -0
  101. package/dist/did-management/server/metrics/0.1/payload.d.ts.map +1 -0
  102. package/dist/did-management/server/metrics/0.1/payload.js +387 -0
  103. package/dist/did-management/server/metrics/0.1/payload.js.map +1 -0
  104. package/dist/did-management/stats/get/0.1/payload.d.ts +349 -0
  105. package/dist/did-management/stats/get/0.1/payload.d.ts.map +1 -0
  106. package/dist/did-management/stats/get/0.1/payload.js +187 -0
  107. package/dist/did-management/stats/get/0.1/payload.js.map +1 -0
  108. package/dist/did-management/stats/timeseries/0.1/payload.d.ts +381 -0
  109. package/dist/did-management/stats/timeseries/0.1/payload.d.ts.map +1 -0
  110. package/dist/did-management/stats/timeseries/0.1/payload.js +227 -0
  111. package/dist/did-management/stats/timeseries/0.1/payload.js.map +1 -0
  112. package/dist/git-ns/namespace/list/0.1/payload.d.ts +1343 -0
  113. package/dist/git-ns/namespace/list/0.1/payload.d.ts.map +1 -0
  114. package/dist/git-ns/namespace/list/0.1/payload.js +704 -0
  115. package/dist/git-ns/namespace/list/0.1/payload.js.map +1 -0
  116. package/dist/git-ns/repo/list/0.1/payload.d.ts +1377 -0
  117. package/dist/git-ns/repo/list/0.1/payload.d.ts.map +1 -0
  118. package/dist/git-ns/repo/list/0.1/payload.js +744 -0
  119. package/dist/git-ns/repo/list/0.1/payload.js.map +1 -0
  120. package/dist/git-ns/view/0.5/payload.d.ts +1722 -0
  121. package/dist/git-ns/view/0.5/payload.d.ts.map +1 -0
  122. package/dist/git-ns/view/0.5/payload.js +1024 -0
  123. package/dist/git-ns/view/0.5/payload.js.map +1 -0
  124. package/dist/index.d.ts +38 -0
  125. package/dist/index.d.ts.map +1 -1
  126. package/dist/index.js +38 -0
  127. package/dist/index.js.map +1 -1
  128. package/dist/vtc/_shared/0.1/invite.d.ts +1 -1
  129. package/dist/vtc/_shared/0.1/invite.d.ts.map +1 -1
  130. package/dist/vtc/admin/invites/list/0.1/payload.d.ts +1 -1
  131. package/dist/vtc/admin/invites/list/0.1/payload.d.ts.map +1 -1
  132. package/dist/webvh/_shared/0.1/sync-update.d.ts +16 -0
  133. package/dist/webvh/_shared/0.1/sync-update.d.ts.map +1 -0
  134. package/dist/webvh/_shared/0.1/sync-update.js +6 -0
  135. package/dist/webvh/_shared/0.1/sync-update.js.map +1 -0
  136. package/dist/webvh/_shared/0.1/witness-key.d.ts +16 -0
  137. package/dist/webvh/_shared/0.1/witness-key.d.ts.map +1 -0
  138. package/dist/webvh/_shared/0.1/witness-key.js +6 -0
  139. package/dist/webvh/_shared/0.1/witness-key.js.map +1 -0
  140. package/dist/webvh/sync/batch/0.1/payload.d.ts +503 -0
  141. package/dist/webvh/sync/batch/0.1/payload.d.ts.map +1 -0
  142. package/dist/webvh/sync/batch/0.1/payload.js +290 -0
  143. package/dist/webvh/sync/batch/0.1/payload.js.map +1 -0
  144. package/dist/webvh/sync/delete/0.2/payload.d.ts +242 -0
  145. package/dist/webvh/sync/delete/0.2/payload.d.ts.map +1 -0
  146. package/dist/webvh/sync/delete/0.2/payload.js +148 -0
  147. package/dist/webvh/sync/delete/0.2/payload.js.map +1 -0
  148. package/dist/webvh/sync/update/0.2/payload.d.ts +315 -0
  149. package/dist/webvh/sync/update/0.2/payload.d.ts.map +1 -0
  150. package/dist/webvh/sync/update/0.2/payload.js +177 -0
  151. package/dist/webvh/sync/update/0.2/payload.js.map +1 -0
  152. package/dist/webvh/witness/key/create/0.1/payload.d.ts +346 -0
  153. package/dist/webvh/witness/key/create/0.1/payload.d.ts.map +1 -0
  154. package/dist/webvh/witness/key/create/0.1/payload.js +202 -0
  155. package/dist/webvh/witness/key/create/0.1/payload.js.map +1 -0
  156. package/dist/webvh/witness/key/delete/0.1/payload.d.ts +237 -0
  157. package/dist/webvh/witness/key/delete/0.1/payload.d.ts.map +1 -0
  158. package/dist/webvh/witness/key/delete/0.1/payload.js +141 -0
  159. package/dist/webvh/witness/key/delete/0.1/payload.js.map +1 -0
  160. package/dist/webvh/witness/key/list/0.1/payload.d.ts +349 -0
  161. package/dist/webvh/witness/key/list/0.1/payload.d.ts.map +1 -0
  162. package/dist/webvh/witness/key/list/0.1/payload.js +204 -0
  163. package/dist/webvh/witness/key/list/0.1/payload.js.map +1 -0
  164. package/dist/webvh/witness/sign/0.1/payload.d.ts +401 -0
  165. package/dist/webvh/witness/sign/0.1/payload.d.ts.map +1 -0
  166. package/dist/webvh/witness/sign/0.1/payload.js +229 -0
  167. package/dist/webvh/witness/sign/0.1/payload.js.map +1 -0
  168. package/package.json +1 -1
  169. package/src/_shared/components.ts +210 -2
  170. package/src/auth/_shared/0.1/passkey-invite.ts +17 -0
  171. package/src/auth/passkey/admin-list/0.1/payload.ts +338 -0
  172. package/src/auth/passkey/enroll/invite/list/0.1/payload.ts +266 -0
  173. package/src/auth/passkey/enroll/invite/revoke/0.1/payload.ts +165 -0
  174. package/src/auth/passkey/enroll/invite/update/0.1/payload.ts +327 -0
  175. package/src/auth/step-up/start/0.1/payload.ts +287 -0
  176. package/src/did-management/_shared/0.1/service-instance.ts +1 -1
  177. package/src/did-management/_shared/0.2/metrics-snapshot.ts +17 -0
  178. package/src/did-management/_shared/0.2/service-instance.ts +17 -0
  179. package/src/did-management/agent-name/resolve/0.1/payload.ts +222 -0
  180. package/src/did-management/did/log/0.1/payload.ts +295 -0
  181. package/src/did-management/domain/list/0.1/payload.ts +280 -0
  182. package/src/did-management/identity/list/0.1/payload.ts +335 -0
  183. package/src/did-management/identity/retire/0.1/payload.ts +175 -0
  184. package/src/did-management/registry/admin-register/0.1/payload.ts +1 -1
  185. package/src/did-management/registry/check/0.1/payload.ts +415 -0
  186. package/src/did-management/registry/get/0.1/payload.ts +410 -0
  187. package/src/did-management/registry/list/0.1/payload.ts +434 -0
  188. package/src/did-management/registry/purge-domain/0.1/payload.ts +198 -0
  189. package/src/did-management/replica/domain/assign/0.1/payload.ts +173 -0
  190. package/src/did-management/replica/domain/purge/0.1/payload.ts +189 -0
  191. package/src/did-management/replica/domain/unassign/0.1/payload.ts +189 -0
  192. package/src/did-management/replica/domain/upsert/0.1/payload.ts +271 -0
  193. package/src/did-management/server/config/0.1/payload.ts +545 -0
  194. package/src/did-management/server/info/0.1/payload.ts +200 -0
  195. package/src/did-management/server/metrics/0.1/payload.ts +418 -0
  196. package/src/did-management/stats/get/0.1/payload.ts +237 -0
  197. package/src/did-management/stats/timeseries/0.1/payload.ts +279 -0
  198. package/src/git-ns/namespace/list/0.1/payload.ts +883 -0
  199. package/src/git-ns/repo/list/0.1/payload.ts +909 -0
  200. package/src/git-ns/view/0.5/payload.ts +1095 -0
  201. package/src/index.ts +38 -0
  202. package/src/vtc/_shared/0.1/invite.ts +1 -1
  203. package/src/vtc/admin/invites/list/0.1/payload.ts +1 -1
  204. package/src/webvh/_shared/0.1/sync-update.ts +17 -0
  205. package/src/webvh/_shared/0.1/witness-key.ts +17 -0
  206. package/src/webvh/sync/batch/0.1/payload.ts +336 -0
  207. package/src/webvh/sync/delete/0.2/payload.ts +181 -0
  208. package/src/webvh/sync/update/0.2/payload.ts +233 -0
  209. package/src/webvh/witness/key/create/0.1/payload.ts +231 -0
  210. package/src/webvh/witness/key/delete/0.1/payload.ts +171 -0
  211. package/src/webvh/witness/key/list/0.1/payload.ts +232 -0
  212. package/src/webvh/witness/sign/0.1/payload.ts +279 -0
@@ -0,0 +1,171 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/webvh/witness/key/delete/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Ext } from "../../../../../_shared/components.js";
7
+
8
+
9
+ export interface WebVHWitnessKeyDeletePayload {
10
+ /**
11
+ * The witness identity to destroy.
12
+ */
13
+ witnessId: string;
14
+ ext?: Ext;
15
+ }
16
+ export interface WebVHWitnessKeyDeleteResponsePayload {
17
+ witnessId: string;
18
+ deletedAt: string;
19
+ ext?: Ext;
20
+ }
21
+
22
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
23
+ export type { Ext };
24
+
25
+ /** Trust Task type URI. */
26
+ export const TYPE_URI = "https://trusttasks.org/spec/webvh/witness/key/delete/0.1" as const;
27
+
28
+ /** Stable alias for this specification's request payload shape. */
29
+ export type Payload = WebVHWitnessKeyDeletePayload;
30
+
31
+ /** Trust Task response type URI (request type URI + "#response"). */
32
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/webvh/witness/key/delete/0.1#response" as const;
33
+
34
+ /** Stable alias for this specification's success-response payload shape. */
35
+ export type Response = WebVHWitnessKeyDeleteResponsePayload;
36
+
37
+ /**
38
+ * This specification's payload schema, as a value.
39
+ *
40
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
41
+ * rather than only as a `.json` file because TypeScript types are erased
42
+ * at runtime: without a schema a consumer has nothing to validate, and
43
+ * every REQUIRED payload member is optional in practice. Cross-file
44
+ * `$ref`s are already inlined, so it needs no resolver.
45
+ */
46
+ export const PAYLOAD_SCHEMA = {
47
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
48
+ "$id": "https://trusttasks.org/spec/webvh/witness/key/delete/0.1",
49
+ "title": "WebVH Witness Key Delete — payload",
50
+ "type": "object",
51
+ "additionalProperties": false,
52
+ "required": [
53
+ "witnessId"
54
+ ],
55
+ "properties": {
56
+ "witnessId": {
57
+ "type": "string",
58
+ "minLength": 1,
59
+ "maxLength": 256,
60
+ "description": "The witness identity to destroy."
61
+ },
62
+ "ext": {
63
+ "$ref": "#/$defs/Ext"
64
+ }
65
+ },
66
+ "$defs": {
67
+ "Response": {
68
+ "$anchor": "response",
69
+ "title": "WebVH Witness Key Delete — response payload",
70
+ "type": "object",
71
+ "additionalProperties": false,
72
+ "required": [
73
+ "witnessId",
74
+ "deletedAt"
75
+ ],
76
+ "properties": {
77
+ "witnessId": {
78
+ "type": "string",
79
+ "minLength": 1
80
+ },
81
+ "deletedAt": {
82
+ "type": "string",
83
+ "format": "date-time"
84
+ },
85
+ "ext": {
86
+ "$ref": "#/$defs/Ext"
87
+ }
88
+ }
89
+ },
90
+ "Ext": {
91
+ "title": "Ext",
92
+ "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.",
93
+ "type": "object",
94
+ "minProperties": 1,
95
+ "additionalProperties": true,
96
+ "propertyNames": {
97
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
98
+ }
99
+ }
100
+ }
101
+ } as const;
102
+
103
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
104
+ export const RESPONSE_PAYLOAD_SCHEMA = {
105
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
106
+ "$ref": "#/$defs/Response",
107
+ "$defs": {
108
+ "Response": {
109
+ "$anchor": "response",
110
+ "title": "WebVH Witness Key Delete — response payload",
111
+ "type": "object",
112
+ "additionalProperties": false,
113
+ "required": [
114
+ "witnessId",
115
+ "deletedAt"
116
+ ],
117
+ "properties": {
118
+ "witnessId": {
119
+ "type": "string",
120
+ "minLength": 1
121
+ },
122
+ "deletedAt": {
123
+ "type": "string",
124
+ "format": "date-time"
125
+ },
126
+ "ext": {
127
+ "$ref": "#/$defs/Ext"
128
+ }
129
+ }
130
+ },
131
+ "Ext": {
132
+ "title": "Ext",
133
+ "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.",
134
+ "type": "object",
135
+ "minProperties": 1,
136
+ "additionalProperties": true,
137
+ "propertyNames": {
138
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
139
+ }
140
+ }
141
+ }
142
+ } as const;
143
+
144
+ /**
145
+ * SPEC.md §7.2 policy for the request variant, from this specification's
146
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
147
+ * per-specification and cannot be derived from the document alone, and
148
+ * item 2 needs the schema this carries.
149
+ */
150
+ export const SPEC = {
151
+ typeUri: TYPE_URI,
152
+ isBearer: false,
153
+ isProofRequired: true,
154
+ isRecipientRequired: true,
155
+ isIssuedAtRequired: true,
156
+ payloadSchema: PAYLOAD_SCHEMA,
157
+ } as const;
158
+
159
+ /**
160
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
161
+ * tracks the *issuer* party's requirement because a response swaps the
162
+ * parties (§7.3 item 5).
163
+ */
164
+ export const RESPONSE_SPEC = {
165
+ typeUri: RESPONSE_TYPE_URI,
166
+ isBearer: false,
167
+ isProofRequired: true,
168
+ isRecipientRequired: true,
169
+ isIssuedAtRequired: true,
170
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
171
+ } as const;
@@ -0,0 +1,232 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/webvh/witness/key/list/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Ext, WitnessKey } from "../../../../../_shared/components.js";
7
+
8
+
9
+ export interface WebVHWitnessKeyListPayload {
10
+ ext?: Ext;
11
+ }
12
+ export interface WebVHWitnessKeyListResponsePayload {
13
+ /**
14
+ * Every witness identity the service holds, ordered by createdAt. Empty when it holds none.
15
+ */
16
+ keys: WitnessKey[];
17
+ ext?: Ext;
18
+ }
19
+
20
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
21
+ export type { Ext, WitnessKey };
22
+
23
+ /** Trust Task type URI. */
24
+ export const TYPE_URI = "https://trusttasks.org/spec/webvh/witness/key/list/0.1" as const;
25
+
26
+ /** Stable alias for this specification's request payload shape. */
27
+ export type Payload = WebVHWitnessKeyListPayload;
28
+
29
+ /** Trust Task response type URI (request type URI + "#response"). */
30
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/webvh/witness/key/list/0.1#response" as const;
31
+
32
+ /** Stable alias for this specification's success-response payload shape. */
33
+ export type Response = WebVHWitnessKeyListResponsePayload;
34
+
35
+ /**
36
+ * This specification's payload schema, as a value.
37
+ *
38
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
39
+ * rather than only as a `.json` file because TypeScript types are erased
40
+ * at runtime: without a schema a consumer has nothing to validate, and
41
+ * every REQUIRED payload member is optional in practice. Cross-file
42
+ * `$ref`s are already inlined, so it needs no resolver.
43
+ */
44
+ export const PAYLOAD_SCHEMA = {
45
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
46
+ "$id": "https://trusttasks.org/spec/webvh/witness/key/list/0.1",
47
+ "title": "WebVH Witness Key List — payload",
48
+ "type": "object",
49
+ "additionalProperties": false,
50
+ "properties": {
51
+ "ext": {
52
+ "$ref": "#/$defs/Ext"
53
+ }
54
+ },
55
+ "$defs": {
56
+ "Response": {
57
+ "$anchor": "response",
58
+ "title": "WebVH Witness Key List — response payload",
59
+ "type": "object",
60
+ "additionalProperties": false,
61
+ "required": [
62
+ "keys"
63
+ ],
64
+ "properties": {
65
+ "keys": {
66
+ "type": "array",
67
+ "items": {
68
+ "$ref": "#/$defs/WitnessKey"
69
+ },
70
+ "description": "Every witness identity the service holds, ordered by createdAt. Empty when it holds none."
71
+ },
72
+ "ext": {
73
+ "$ref": "#/$defs/Ext"
74
+ }
75
+ }
76
+ },
77
+ "Ext": {
78
+ "title": "Ext",
79
+ "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.",
80
+ "type": "object",
81
+ "minProperties": 1,
82
+ "additionalProperties": true,
83
+ "propertyNames": {
84
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
85
+ }
86
+ },
87
+ "WitnessKey": {
88
+ "title": "WitnessKey",
89
+ "type": "object",
90
+ "additionalProperties": false,
91
+ "required": [
92
+ "witnessId",
93
+ "did",
94
+ "createdAt",
95
+ "proofsSigned"
96
+ ],
97
+ "properties": {
98
+ "witnessId": {
99
+ "type": "string",
100
+ "minLength": 1,
101
+ "maxLength": 256,
102
+ "description": "The witness service's identifier for this identity. Opaque to the requester."
103
+ },
104
+ "did": {
105
+ "type": "string",
106
+ "minLength": 1,
107
+ "description": "The witness identity's DID (for example a `did:key`) — the value a did:webvh log names in its `witness` parameter, and the controller of the key that signs its proofs."
108
+ },
109
+ "label": {
110
+ "type": "string",
111
+ "maxLength": 256,
112
+ "description": "Operator-chosen display label. Untrusted free text. Absent when none was given."
113
+ },
114
+ "createdAt": {
115
+ "type": "string",
116
+ "format": "date-time"
117
+ },
118
+ "proofsSigned": {
119
+ "type": "integer",
120
+ "minimum": 0,
121
+ "description": "How many witness proofs this identity has signed."
122
+ }
123
+ }
124
+ }
125
+ }
126
+ } as const;
127
+
128
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
129
+ export const RESPONSE_PAYLOAD_SCHEMA = {
130
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
131
+ "$ref": "#/$defs/Response",
132
+ "$defs": {
133
+ "Response": {
134
+ "$anchor": "response",
135
+ "title": "WebVH Witness Key List — response payload",
136
+ "type": "object",
137
+ "additionalProperties": false,
138
+ "required": [
139
+ "keys"
140
+ ],
141
+ "properties": {
142
+ "keys": {
143
+ "type": "array",
144
+ "items": {
145
+ "$ref": "#/$defs/WitnessKey"
146
+ },
147
+ "description": "Every witness identity the service holds, ordered by createdAt. Empty when it holds none."
148
+ },
149
+ "ext": {
150
+ "$ref": "#/$defs/Ext"
151
+ }
152
+ }
153
+ },
154
+ "Ext": {
155
+ "title": "Ext",
156
+ "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.",
157
+ "type": "object",
158
+ "minProperties": 1,
159
+ "additionalProperties": true,
160
+ "propertyNames": {
161
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
162
+ }
163
+ },
164
+ "WitnessKey": {
165
+ "title": "WitnessKey",
166
+ "type": "object",
167
+ "additionalProperties": false,
168
+ "required": [
169
+ "witnessId",
170
+ "did",
171
+ "createdAt",
172
+ "proofsSigned"
173
+ ],
174
+ "properties": {
175
+ "witnessId": {
176
+ "type": "string",
177
+ "minLength": 1,
178
+ "maxLength": 256,
179
+ "description": "The witness service's identifier for this identity. Opaque to the requester."
180
+ },
181
+ "did": {
182
+ "type": "string",
183
+ "minLength": 1,
184
+ "description": "The witness identity's DID (for example a `did:key`) — the value a did:webvh log names in its `witness` parameter, and the controller of the key that signs its proofs."
185
+ },
186
+ "label": {
187
+ "type": "string",
188
+ "maxLength": 256,
189
+ "description": "Operator-chosen display label. Untrusted free text. Absent when none was given."
190
+ },
191
+ "createdAt": {
192
+ "type": "string",
193
+ "format": "date-time"
194
+ },
195
+ "proofsSigned": {
196
+ "type": "integer",
197
+ "minimum": 0,
198
+ "description": "How many witness proofs this identity has signed."
199
+ }
200
+ }
201
+ }
202
+ }
203
+ } as const;
204
+
205
+ /**
206
+ * SPEC.md §7.2 policy for the request variant, from this specification's
207
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
208
+ * per-specification and cannot be derived from the document alone, and
209
+ * item 2 needs the schema this carries.
210
+ */
211
+ export const SPEC = {
212
+ typeUri: TYPE_URI,
213
+ isBearer: false,
214
+ isProofRequired: true,
215
+ isRecipientRequired: true,
216
+ isIssuedAtRequired: false,
217
+ payloadSchema: PAYLOAD_SCHEMA,
218
+ } as const;
219
+
220
+ /**
221
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
222
+ * tracks the *issuer* party's requirement because a response swaps the
223
+ * parties (§7.3 item 5).
224
+ */
225
+ export const RESPONSE_SPEC = {
226
+ typeUri: RESPONSE_TYPE_URI,
227
+ isBearer: false,
228
+ isProofRequired: true,
229
+ isRecipientRequired: true,
230
+ isIssuedAtRequired: false,
231
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
232
+ } as const;
@@ -0,0 +1,279 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/webvh/witness/sign/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Ext } from "../../../../_shared/components.js";
7
+
8
+
9
+ export interface WebVHWitnessSignPayload {
10
+ /**
11
+ * The witness identity to sign with, as webvh/witness/key/list reports it.
12
+ */
13
+ witnessId: string;
14
+ /**
15
+ * The versionId of the log entry to witness. MUST be the last entry of `logContent`.
16
+ */
17
+ versionId: string;
18
+ /**
19
+ * The did.jsonl up to and including the entry to witness, so the witness can verify what it signs.
20
+ */
21
+ logContent: string;
22
+ ext?: Ext;
23
+ }
24
+ export interface WebVHWitnessSignResponsePayload {
25
+ witnessId: string;
26
+ versionId: string;
27
+ /**
28
+ * The W3C Data Integrity proof over {versionId}, by the witness identity's key. Carried verbatim into the DID's did-witness.json; further Data Integrity members are permitted.
29
+ */
30
+ proof: {
31
+ type: "DataIntegrityProof";
32
+ cryptosuite: string;
33
+ verificationMethod: string;
34
+ proofPurpose: string;
35
+ proofValue: string;
36
+ created?: string;
37
+ [k: string]: unknown | undefined;
38
+ };
39
+ ext?: Ext;
40
+ }
41
+
42
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
43
+ export type { Ext };
44
+
45
+ /** Trust Task type URI. */
46
+ export const TYPE_URI = "https://trusttasks.org/spec/webvh/witness/sign/0.1" as const;
47
+
48
+ /** Stable alias for this specification's request payload shape. */
49
+ export type Payload = WebVHWitnessSignPayload;
50
+
51
+ /** Trust Task response type URI (request type URI + "#response"). */
52
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/webvh/witness/sign/0.1#response" as const;
53
+
54
+ /** Stable alias for this specification's success-response payload shape. */
55
+ export type Response = WebVHWitnessSignResponsePayload;
56
+
57
+ /**
58
+ * This specification's payload schema, as a value.
59
+ *
60
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
61
+ * rather than only as a `.json` file because TypeScript types are erased
62
+ * at runtime: without a schema a consumer has nothing to validate, and
63
+ * every REQUIRED payload member is optional in practice. Cross-file
64
+ * `$ref`s are already inlined, so it needs no resolver.
65
+ */
66
+ export const PAYLOAD_SCHEMA = {
67
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
68
+ "$id": "https://trusttasks.org/spec/webvh/witness/sign/0.1",
69
+ "title": "WebVH Witness Sign — payload",
70
+ "type": "object",
71
+ "additionalProperties": false,
72
+ "required": [
73
+ "witnessId",
74
+ "versionId",
75
+ "logContent"
76
+ ],
77
+ "properties": {
78
+ "witnessId": {
79
+ "type": "string",
80
+ "minLength": 1,
81
+ "maxLength": 256,
82
+ "description": "The witness identity to sign with, as webvh/witness/key/list reports it."
83
+ },
84
+ "versionId": {
85
+ "type": "string",
86
+ "minLength": 1,
87
+ "description": "The versionId of the log entry to witness. MUST be the last entry of `logContent`."
88
+ },
89
+ "logContent": {
90
+ "type": "string",
91
+ "minLength": 1,
92
+ "description": "The did.jsonl up to and including the entry to witness, so the witness can verify what it signs."
93
+ },
94
+ "ext": {
95
+ "$ref": "#/$defs/Ext"
96
+ }
97
+ },
98
+ "$defs": {
99
+ "Response": {
100
+ "$anchor": "response",
101
+ "title": "WebVH Witness Sign — response payload",
102
+ "type": "object",
103
+ "additionalProperties": false,
104
+ "required": [
105
+ "witnessId",
106
+ "versionId",
107
+ "proof"
108
+ ],
109
+ "properties": {
110
+ "witnessId": {
111
+ "type": "string",
112
+ "minLength": 1
113
+ },
114
+ "versionId": {
115
+ "type": "string",
116
+ "minLength": 1
117
+ },
118
+ "proof": {
119
+ "type": "object",
120
+ "description": "The W3C Data Integrity proof over {versionId}, by the witness identity's key. Carried verbatim into the DID's did-witness.json; further Data Integrity members are permitted.",
121
+ "additionalProperties": true,
122
+ "required": [
123
+ "type",
124
+ "cryptosuite",
125
+ "verificationMethod",
126
+ "proofPurpose",
127
+ "proofValue"
128
+ ],
129
+ "properties": {
130
+ "type": {
131
+ "const": "DataIntegrityProof"
132
+ },
133
+ "cryptosuite": {
134
+ "type": "string",
135
+ "minLength": 1
136
+ },
137
+ "verificationMethod": {
138
+ "type": "string",
139
+ "minLength": 1
140
+ },
141
+ "proofPurpose": {
142
+ "type": "string",
143
+ "minLength": 1
144
+ },
145
+ "proofValue": {
146
+ "type": "string",
147
+ "minLength": 1
148
+ },
149
+ "created": {
150
+ "type": "string",
151
+ "format": "date-time"
152
+ }
153
+ }
154
+ },
155
+ "ext": {
156
+ "$ref": "#/$defs/Ext"
157
+ }
158
+ }
159
+ },
160
+ "Ext": {
161
+ "title": "Ext",
162
+ "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.",
163
+ "type": "object",
164
+ "minProperties": 1,
165
+ "additionalProperties": true,
166
+ "propertyNames": {
167
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
168
+ }
169
+ }
170
+ }
171
+ } as const;
172
+
173
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
174
+ export const RESPONSE_PAYLOAD_SCHEMA = {
175
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
176
+ "$ref": "#/$defs/Response",
177
+ "$defs": {
178
+ "Response": {
179
+ "$anchor": "response",
180
+ "title": "WebVH Witness Sign — response payload",
181
+ "type": "object",
182
+ "additionalProperties": false,
183
+ "required": [
184
+ "witnessId",
185
+ "versionId",
186
+ "proof"
187
+ ],
188
+ "properties": {
189
+ "witnessId": {
190
+ "type": "string",
191
+ "minLength": 1
192
+ },
193
+ "versionId": {
194
+ "type": "string",
195
+ "minLength": 1
196
+ },
197
+ "proof": {
198
+ "type": "object",
199
+ "description": "The W3C Data Integrity proof over {versionId}, by the witness identity's key. Carried verbatim into the DID's did-witness.json; further Data Integrity members are permitted.",
200
+ "additionalProperties": true,
201
+ "required": [
202
+ "type",
203
+ "cryptosuite",
204
+ "verificationMethod",
205
+ "proofPurpose",
206
+ "proofValue"
207
+ ],
208
+ "properties": {
209
+ "type": {
210
+ "const": "DataIntegrityProof"
211
+ },
212
+ "cryptosuite": {
213
+ "type": "string",
214
+ "minLength": 1
215
+ },
216
+ "verificationMethod": {
217
+ "type": "string",
218
+ "minLength": 1
219
+ },
220
+ "proofPurpose": {
221
+ "type": "string",
222
+ "minLength": 1
223
+ },
224
+ "proofValue": {
225
+ "type": "string",
226
+ "minLength": 1
227
+ },
228
+ "created": {
229
+ "type": "string",
230
+ "format": "date-time"
231
+ }
232
+ }
233
+ },
234
+ "ext": {
235
+ "$ref": "#/$defs/Ext"
236
+ }
237
+ }
238
+ },
239
+ "Ext": {
240
+ "title": "Ext",
241
+ "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.",
242
+ "type": "object",
243
+ "minProperties": 1,
244
+ "additionalProperties": true,
245
+ "propertyNames": {
246
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
247
+ }
248
+ }
249
+ }
250
+ } as const;
251
+
252
+ /**
253
+ * SPEC.md §7.2 policy for the request variant, from this specification's
254
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
255
+ * per-specification and cannot be derived from the document alone, and
256
+ * item 2 needs the schema this carries.
257
+ */
258
+ export const SPEC = {
259
+ typeUri: TYPE_URI,
260
+ isBearer: false,
261
+ isProofRequired: true,
262
+ isRecipientRequired: true,
263
+ isIssuedAtRequired: true,
264
+ payloadSchema: PAYLOAD_SCHEMA,
265
+ } as const;
266
+
267
+ /**
268
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
269
+ * tracks the *issuer* party's requirement because a response swaps the
270
+ * parties (§7.3 item 5).
271
+ */
272
+ export const RESPONSE_SPEC = {
273
+ typeUri: RESPONSE_TYPE_URI,
274
+ isBearer: false,
275
+ isProofRequired: true,
276
+ isRecipientRequired: true,
277
+ isIssuedAtRequired: true,
278
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
279
+ } as const;