@openvtc/trust-tasks 0.16.7 → 0.16.9

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 (90) hide show
  1. package/CHANGELOG.md +144 -0
  2. package/dist/_shared/components.d.ts +2 -2
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/device/list/0.1/payload.d.ts +4 -4
  5. package/dist/device/list/0.1/payload.d.ts.map +1 -1
  6. package/dist/device/list/0.1/payload.js +6 -2
  7. package/dist/device/list/0.1/payload.js.map +1 -1
  8. package/dist/device/list/0.2/payload.d.ts +4 -4
  9. package/dist/device/list/0.2/payload.d.ts.map +1 -1
  10. package/dist/device/list/0.2/payload.js +6 -2
  11. package/dist/device/list/0.2/payload.js.map +1 -1
  12. package/dist/device/register/0.1/payload.d.ts +4 -4
  13. package/dist/device/register/0.1/payload.d.ts.map +1 -1
  14. package/dist/device/register/0.1/payload.js +6 -2
  15. package/dist/device/register/0.1/payload.js.map +1 -1
  16. package/dist/device/register/0.2/payload.d.ts +4 -4
  17. package/dist/device/register/0.2/payload.d.ts.map +1 -1
  18. package/dist/device/register/0.2/payload.js +6 -2
  19. package/dist/device/register/0.2/payload.js.map +1 -1
  20. package/dist/index.d.ts +12 -0
  21. package/dist/index.d.ts.map +1 -1
  22. package/dist/index.js +12 -0
  23. package/dist/index.js.map +1 -1
  24. package/dist/rooms/keys/commit/0.1/payload.d.ts +266 -0
  25. package/dist/rooms/keys/commit/0.1/payload.d.ts.map +1 -0
  26. package/dist/rooms/keys/commit/0.1/payload.js +146 -0
  27. package/dist/rooms/keys/commit/0.1/payload.js.map +1 -0
  28. package/dist/rooms/keys/key-package/0.1/payload.d.ts +272 -0
  29. package/dist/rooms/keys/key-package/0.1/payload.d.ts.map +1 -0
  30. package/dist/rooms/keys/key-package/0.1/payload.js +147 -0
  31. package/dist/rooms/keys/key-package/0.1/payload.js.map +1 -0
  32. package/dist/rooms/keys/open/0.1/payload.d.ts +323 -0
  33. package/dist/rooms/keys/open/0.1/payload.d.ts.map +1 -0
  34. package/dist/rooms/keys/open/0.1/payload.js +171 -0
  35. package/dist/rooms/keys/open/0.1/payload.js.map +1 -0
  36. package/dist/rooms/keys/present/0.1/payload.d.ts +306 -0
  37. package/dist/rooms/keys/present/0.1/payload.d.ts.map +1 -0
  38. package/dist/rooms/keys/present/0.1/payload.js +165 -0
  39. package/dist/rooms/keys/present/0.1/payload.js.map +1 -0
  40. package/dist/rooms/keys/welcome/0.1/payload.d.ts +276 -0
  41. package/dist/rooms/keys/welcome/0.1/payload.d.ts.map +1 -0
  42. package/dist/rooms/keys/welcome/0.1/payload.js +148 -0
  43. package/dist/rooms/keys/welcome/0.1/payload.js.map +1 -0
  44. package/dist/rooms/records/curate/0.1/payload.d.ts +500 -0
  45. package/dist/rooms/records/curate/0.1/payload.d.ts.map +1 -0
  46. package/dist/rooms/records/curate/0.1/payload.js +277 -0
  47. package/dist/rooms/records/curate/0.1/payload.js.map +1 -0
  48. package/dist/vta/backup/abort/1.0/payload.d.ts +262 -0
  49. package/dist/vta/backup/abort/1.0/payload.d.ts.map +1 -0
  50. package/dist/vta/backup/abort/1.0/payload.js +146 -0
  51. package/dist/vta/backup/abort/1.0/payload.js.map +1 -0
  52. package/dist/vta/backup/complete-export/1.0/payload.d.ts +262 -0
  53. package/dist/vta/backup/complete-export/1.0/payload.d.ts.map +1 -0
  54. package/dist/vta/backup/complete-export/1.0/payload.js +146 -0
  55. package/dist/vta/backup/complete-export/1.0/payload.js.map +1 -0
  56. package/dist/vta/backup/finalize-import/1.0/payload.d.ts +477 -0
  57. package/dist/vta/backup/finalize-import/1.0/payload.d.ts.map +1 -0
  58. package/dist/vta/backup/finalize-import/1.0/payload.js +249 -0
  59. package/dist/vta/backup/finalize-import/1.0/payload.js.map +1 -0
  60. package/dist/vta/backup/initiate-export/1.0/payload.d.ts +514 -0
  61. package/dist/vta/backup/initiate-export/1.0/payload.d.ts.map +1 -0
  62. package/dist/vta/backup/initiate-export/1.0/payload.js +267 -0
  63. package/dist/vta/backup/initiate-export/1.0/payload.js.map +1 -0
  64. package/dist/vta/backup/initiate-import/1.0/payload.d.ts +510 -0
  65. package/dist/vta/backup/initiate-import/1.0/payload.d.ts.map +1 -0
  66. package/dist/vta/backup/initiate-import/1.0/payload.js +266 -0
  67. package/dist/vta/backup/initiate-import/1.0/payload.js.map +1 -0
  68. package/dist/vta/management/reload-services/1.0/payload.d.ts +230 -0
  69. package/dist/vta/management/reload-services/1.0/payload.d.ts.map +1 -0
  70. package/dist/vta/management/reload-services/1.0/payload.js +130 -0
  71. package/dist/vta/management/reload-services/1.0/payload.js.map +1 -0
  72. package/package.json +1 -1
  73. package/src/_shared/components.ts +6 -2
  74. package/src/device/list/0.1/payload.ts +6 -2
  75. package/src/device/list/0.2/payload.ts +6 -2
  76. package/src/device/register/0.1/payload.ts +6 -2
  77. package/src/device/register/0.2/payload.ts +6 -2
  78. package/src/index.ts +12 -0
  79. package/src/rooms/keys/commit/0.1/payload.ts +195 -0
  80. package/src/rooms/keys/key-package/0.1/payload.ts +196 -0
  81. package/src/rooms/keys/open/0.1/payload.ts +237 -0
  82. package/src/rooms/keys/present/0.1/payload.ts +224 -0
  83. package/src/rooms/keys/welcome/0.1/payload.ts +201 -0
  84. package/src/rooms/records/curate/0.1/payload.ts +357 -0
  85. package/src/vta/backup/abort/1.0/payload.ts +191 -0
  86. package/src/vta/backup/complete-export/1.0/payload.ts +191 -0
  87. package/src/vta/backup/finalize-import/1.0/payload.ts +333 -0
  88. package/src/vta/backup/initiate-export/1.0/payload.ts +350 -0
  89. package/src/vta/backup/initiate-import/1.0/payload.ts +349 -0
  90. package/src/vta/management/reload-services/1.0/payload.ts +167 -0
@@ -0,0 +1,514 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/backup/initiate-export/1.0/payload.schema.json
4
+ */
5
+ import type { Ext } from "../../../../_shared/components.js";
6
+ /**
7
+ * Asks the recipient to serialize its entire state into a password-encrypted bundle and return the descriptor that fetches it. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.
8
+ */
9
+ export interface VTABackupInitiateExportPayload {
10
+ /**
11
+ * Key-derivation input protecting the bundle. Chosen by the producer and never recoverable from the recipient. `writeOnly` is the machine-readable form of the rule in Data carried: this member goes in and never comes back, so a generated client must not surface it in a response type, and a recipient must never log, echo or persist it. The minLength floor is a shape check only — a recipient may require more, and refuses with weakPassword.
12
+ */
13
+ password: string;
14
+ /**
15
+ * Serialize the audit trail alongside the operational state. Absent means false — stated in prose rather than as a schema `default`, because a materialised default turns an omitted member into an asserted one in generated bindings, which is a different document.
16
+ */
17
+ includeAudit?: boolean;
18
+ /**
19
+ * Requested transport mechanism — how the bytes move, not how they are encrypted. `stream` is the only value this version defines and is what an absent member means. Deliberately not an enum: a recipient offering more must be askable for it without a specification revision, and one that does not implement the request refuses with unsupportedAlgorithm.
20
+ */
21
+ algorithm?: string;
22
+ /**
23
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
24
+ */
25
+ ext?: Ext;
26
+ }
27
+ export interface VTABackupInitiateExportResponsePayload {
28
+ descriptor: BundleDescriptor;
29
+ /**
30
+ * Operator-facing text describing how to complete the download. Advisory: a producer must not parse it or derive behaviour from it, and a recipient must not put a secret in it.
31
+ */
32
+ completionHint?: string;
33
+ /**
34
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
35
+ */
36
+ ext?: Ext;
37
+ }
38
+ /**
39
+ * Where the bytes are, what they should be, and until when.
40
+ */
41
+ export interface BundleDescriptor {
42
+ /**
43
+ * Handle for this bundle across its whole lifecycle. Quoted back by complete-export and abort. Recipient-generated and unguessable, which is what lets an unauthorized reference be answered as not-found without confirming existence.
44
+ */
45
+ bundleId: string;
46
+ /**
47
+ * The mechanism actually used, which is authoritative over what was requested.
48
+ */
49
+ algorithm: string;
50
+ /**
51
+ * Where to fetch the bytes. A recipient with no address at which it is reachable cannot produce this and refuses with transportUnavailable rather than returning an unfetchable one.
52
+ */
53
+ transportUrl: string;
54
+ /**
55
+ * Bearer credential for transportUrl, presented in the X-Backup-Token header. Minted per bundle and never reused. A recipient should store only a hash of it and should accept it once — the token plus the URL is the export.
56
+ */
57
+ transportToken: string;
58
+ /**
59
+ * Lowercase hex SHA-256 of the byte stream. Independent of the encrypted envelope's own authentication tag, so a truncated or substituted transfer is caught before the password is applied to it.
60
+ */
61
+ expectedSha256: string;
62
+ /**
63
+ * Total byte count. A zero-length bundle is not a degenerate success — nothing was serialized — so the floor is 1.
64
+ */
65
+ expectedSizeBytes: number;
66
+ /**
67
+ * After which the bytes are collected and the token refused. Short by design: the window is how long a fetchable copy of the agent exists.
68
+ */
69
+ expiresAt: string;
70
+ }
71
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
72
+ export type { Ext };
73
+ /** Trust Task type URI. */
74
+ export declare const TYPE_URI: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0";
75
+ /** Stable alias for this specification's request payload shape. */
76
+ export type Payload = VTABackupInitiateExportPayload;
77
+ /** Trust Task response type URI (request type URI + "#response"). */
78
+ export declare const RESPONSE_TYPE_URI: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0#response";
79
+ /** Stable alias for this specification's success-response payload shape. */
80
+ export type Response = VTABackupInitiateExportResponsePayload;
81
+ /**
82
+ * This specification's payload schema, as a value.
83
+ *
84
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
85
+ * rather than only as a `.json` file because TypeScript types are erased
86
+ * at runtime: without a schema a consumer has nothing to validate, and
87
+ * every REQUIRED payload member is optional in practice. Cross-file
88
+ * `$ref`s are already inlined, so it needs no resolver.
89
+ */
90
+ export declare const PAYLOAD_SCHEMA: {
91
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
92
+ readonly $id: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0";
93
+ readonly title: "VTA Backup — Initiate Export — payload";
94
+ readonly description: "Asks the recipient to serialize its entire state into a password-encrypted bundle and return the descriptor that fetches it. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.";
95
+ readonly type: "object";
96
+ readonly additionalProperties: false;
97
+ readonly required: readonly ["password"];
98
+ readonly properties: {
99
+ readonly password: {
100
+ readonly type: "string";
101
+ readonly minLength: 15;
102
+ readonly maxLength: 1024;
103
+ readonly writeOnly: true;
104
+ readonly description: "Key-derivation input protecting the bundle. Chosen by the producer and never recoverable from the recipient. `writeOnly` is the machine-readable form of the rule in Data carried: this member goes in and never comes back, so a generated client must not surface it in a response type, and a recipient must never log, echo or persist it. The minLength floor is a shape check only — a recipient may require more, and refuses with weakPassword.";
105
+ readonly $comment: "No `format: password` — the annotation is advisory in 2020-12 and says less than writeOnly does. No example value anywhere in this directory: a specimen password is the one thing implementers copy.";
106
+ };
107
+ readonly includeAudit: {
108
+ readonly type: "boolean";
109
+ readonly description: "Serialize the audit trail alongside the operational state. Absent means false — stated in prose rather than as a schema `default`, because a materialised default turns an omitted member into an asserted one in generated bindings, which is a different document.";
110
+ };
111
+ readonly algorithm: {
112
+ readonly type: "string";
113
+ readonly minLength: 1;
114
+ readonly maxLength: 64;
115
+ readonly description: "Requested transport mechanism — how the bytes move, not how they are encrypted. `stream` is the only value this version defines and is what an absent member means. Deliberately not an enum: a recipient offering more must be askable for it without a specification revision, and one that does not implement the request refuses with unsupportedAlgorithm.";
116
+ };
117
+ readonly ext: {
118
+ readonly $ref: "#/$defs/Ext";
119
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
120
+ };
121
+ };
122
+ readonly $defs: {
123
+ readonly Response: {
124
+ readonly $anchor: "response";
125
+ readonly title: "VTA Backup Initiate Export — response payload";
126
+ readonly type: "object";
127
+ readonly additionalProperties: false;
128
+ readonly required: readonly ["descriptor"];
129
+ readonly properties: {
130
+ readonly descriptor: {
131
+ readonly $ref: "#/$defs/BundleDescriptor";
132
+ readonly description: "Where the bytes are, what they should be, and until when.";
133
+ };
134
+ readonly completionHint: {
135
+ readonly type: "string";
136
+ readonly maxLength: 1024;
137
+ readonly description: "Operator-facing text describing how to complete the download. Advisory: a producer must not parse it or derive behaviour from it, and a recipient must not put a secret in it.";
138
+ };
139
+ readonly ext: {
140
+ readonly $ref: "#/$defs/Ext";
141
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
142
+ };
143
+ };
144
+ };
145
+ readonly BundleDescriptor: {
146
+ readonly title: "Bundle descriptor";
147
+ readonly type: "object";
148
+ readonly additionalProperties: false;
149
+ readonly description: "The control-plane account of an out-of-band byte transfer. Shared in shape with initiate-import, where it describes an upload rather than a download.";
150
+ readonly required: readonly ["bundleId", "algorithm", "transportUrl", "transportToken", "expectedSha256", "expectedSizeBytes", "expiresAt"];
151
+ readonly properties: {
152
+ readonly bundleId: {
153
+ readonly type: "string";
154
+ readonly pattern: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$";
155
+ readonly description: "Handle for this bundle across its whole lifecycle. Quoted back by complete-export and abort. Recipient-generated and unguessable, which is what lets an unauthorized reference be answered as not-found without confirming existence.";
156
+ };
157
+ readonly algorithm: {
158
+ readonly type: "string";
159
+ readonly minLength: 1;
160
+ readonly maxLength: 64;
161
+ readonly description: "The mechanism actually used, which is authoritative over what was requested.";
162
+ };
163
+ readonly transportUrl: {
164
+ readonly type: "string";
165
+ readonly format: "uri";
166
+ readonly maxLength: 2048;
167
+ readonly description: "Where to fetch the bytes. A recipient with no address at which it is reachable cannot produce this and refuses with transportUnavailable rather than returning an unfetchable one.";
168
+ };
169
+ readonly transportToken: {
170
+ readonly type: "string";
171
+ readonly minLength: 1;
172
+ readonly maxLength: 1024;
173
+ readonly description: "Bearer credential for transportUrl, presented in the X-Backup-Token header. Minted per bundle and never reused. A recipient should store only a hash of it and should accept it once — the token plus the URL is the export.";
174
+ };
175
+ readonly expectedSha256: {
176
+ readonly type: "string";
177
+ readonly pattern: "^[0-9a-f]{64}$";
178
+ readonly description: "Lowercase hex SHA-256 of the byte stream. Independent of the encrypted envelope's own authentication tag, so a truncated or substituted transfer is caught before the password is applied to it.";
179
+ };
180
+ readonly expectedSizeBytes: {
181
+ readonly type: "integer";
182
+ readonly minimum: 1;
183
+ readonly description: "Total byte count. A zero-length bundle is not a degenerate success — nothing was serialized — so the floor is 1.";
184
+ };
185
+ readonly expiresAt: {
186
+ readonly type: "string";
187
+ readonly format: "date-time";
188
+ readonly description: "After which the bytes are collected and the token refused. Short by design: the window is how long a fetchable copy of the agent exists.";
189
+ };
190
+ };
191
+ };
192
+ readonly Ext: {
193
+ readonly title: "Ext";
194
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
195
+ readonly type: "object";
196
+ readonly minProperties: 1;
197
+ readonly additionalProperties: true;
198
+ readonly propertyNames: {
199
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
200
+ };
201
+ };
202
+ };
203
+ };
204
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
205
+ export declare const RESPONSE_PAYLOAD_SCHEMA: {
206
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
207
+ readonly $ref: "#/$defs/Response";
208
+ readonly $defs: {
209
+ readonly Response: {
210
+ readonly $anchor: "response";
211
+ readonly title: "VTA Backup Initiate Export — response payload";
212
+ readonly type: "object";
213
+ readonly additionalProperties: false;
214
+ readonly required: readonly ["descriptor"];
215
+ readonly properties: {
216
+ readonly descriptor: {
217
+ readonly $ref: "#/$defs/BundleDescriptor";
218
+ readonly description: "Where the bytes are, what they should be, and until when.";
219
+ };
220
+ readonly completionHint: {
221
+ readonly type: "string";
222
+ readonly maxLength: 1024;
223
+ readonly description: "Operator-facing text describing how to complete the download. Advisory: a producer must not parse it or derive behaviour from it, and a recipient must not put a secret in it.";
224
+ };
225
+ readonly ext: {
226
+ readonly $ref: "#/$defs/Ext";
227
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
228
+ };
229
+ };
230
+ };
231
+ readonly BundleDescriptor: {
232
+ readonly title: "Bundle descriptor";
233
+ readonly type: "object";
234
+ readonly additionalProperties: false;
235
+ readonly description: "The control-plane account of an out-of-band byte transfer. Shared in shape with initiate-import, where it describes an upload rather than a download.";
236
+ readonly required: readonly ["bundleId", "algorithm", "transportUrl", "transportToken", "expectedSha256", "expectedSizeBytes", "expiresAt"];
237
+ readonly properties: {
238
+ readonly bundleId: {
239
+ readonly type: "string";
240
+ readonly pattern: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$";
241
+ readonly description: "Handle for this bundle across its whole lifecycle. Quoted back by complete-export and abort. Recipient-generated and unguessable, which is what lets an unauthorized reference be answered as not-found without confirming existence.";
242
+ };
243
+ readonly algorithm: {
244
+ readonly type: "string";
245
+ readonly minLength: 1;
246
+ readonly maxLength: 64;
247
+ readonly description: "The mechanism actually used, which is authoritative over what was requested.";
248
+ };
249
+ readonly transportUrl: {
250
+ readonly type: "string";
251
+ readonly format: "uri";
252
+ readonly maxLength: 2048;
253
+ readonly description: "Where to fetch the bytes. A recipient with no address at which it is reachable cannot produce this and refuses with transportUnavailable rather than returning an unfetchable one.";
254
+ };
255
+ readonly transportToken: {
256
+ readonly type: "string";
257
+ readonly minLength: 1;
258
+ readonly maxLength: 1024;
259
+ readonly description: "Bearer credential for transportUrl, presented in the X-Backup-Token header. Minted per bundle and never reused. A recipient should store only a hash of it and should accept it once — the token plus the URL is the export.";
260
+ };
261
+ readonly expectedSha256: {
262
+ readonly type: "string";
263
+ readonly pattern: "^[0-9a-f]{64}$";
264
+ readonly description: "Lowercase hex SHA-256 of the byte stream. Independent of the encrypted envelope's own authentication tag, so a truncated or substituted transfer is caught before the password is applied to it.";
265
+ };
266
+ readonly expectedSizeBytes: {
267
+ readonly type: "integer";
268
+ readonly minimum: 1;
269
+ readonly description: "Total byte count. A zero-length bundle is not a degenerate success — nothing was serialized — so the floor is 1.";
270
+ };
271
+ readonly expiresAt: {
272
+ readonly type: "string";
273
+ readonly format: "date-time";
274
+ readonly description: "After which the bytes are collected and the token refused. Short by design: the window is how long a fetchable copy of the agent exists.";
275
+ };
276
+ };
277
+ };
278
+ readonly Ext: {
279
+ readonly title: "Ext";
280
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
281
+ readonly type: "object";
282
+ readonly minProperties: 1;
283
+ readonly additionalProperties: true;
284
+ readonly propertyNames: {
285
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
286
+ };
287
+ };
288
+ };
289
+ };
290
+ /**
291
+ * SPEC.md §7.2 policy for the request variant, from this specification's
292
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
293
+ * per-specification and cannot be derived from the document alone, and
294
+ * item 2 needs the schema this carries.
295
+ */
296
+ export declare const SPEC: {
297
+ readonly typeUri: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0";
298
+ readonly isBearer: false;
299
+ readonly isProofRequired: true;
300
+ readonly isRecipientRequired: true;
301
+ readonly isIssuedAtRequired: true;
302
+ readonly payloadSchema: {
303
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
304
+ readonly $id: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0";
305
+ readonly title: "VTA Backup — Initiate Export — payload";
306
+ readonly description: "Asks the recipient to serialize its entire state into a password-encrypted bundle and return the descriptor that fetches it. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.";
307
+ readonly type: "object";
308
+ readonly additionalProperties: false;
309
+ readonly required: readonly ["password"];
310
+ readonly properties: {
311
+ readonly password: {
312
+ readonly type: "string";
313
+ readonly minLength: 15;
314
+ readonly maxLength: 1024;
315
+ readonly writeOnly: true;
316
+ readonly description: "Key-derivation input protecting the bundle. Chosen by the producer and never recoverable from the recipient. `writeOnly` is the machine-readable form of the rule in Data carried: this member goes in and never comes back, so a generated client must not surface it in a response type, and a recipient must never log, echo or persist it. The minLength floor is a shape check only — a recipient may require more, and refuses with weakPassword.";
317
+ readonly $comment: "No `format: password` — the annotation is advisory in 2020-12 and says less than writeOnly does. No example value anywhere in this directory: a specimen password is the one thing implementers copy.";
318
+ };
319
+ readonly includeAudit: {
320
+ readonly type: "boolean";
321
+ readonly description: "Serialize the audit trail alongside the operational state. Absent means false — stated in prose rather than as a schema `default`, because a materialised default turns an omitted member into an asserted one in generated bindings, which is a different document.";
322
+ };
323
+ readonly algorithm: {
324
+ readonly type: "string";
325
+ readonly minLength: 1;
326
+ readonly maxLength: 64;
327
+ readonly description: "Requested transport mechanism — how the bytes move, not how they are encrypted. `stream` is the only value this version defines and is what an absent member means. Deliberately not an enum: a recipient offering more must be askable for it without a specification revision, and one that does not implement the request refuses with unsupportedAlgorithm.";
328
+ };
329
+ readonly ext: {
330
+ readonly $ref: "#/$defs/Ext";
331
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
332
+ };
333
+ };
334
+ readonly $defs: {
335
+ readonly Response: {
336
+ readonly $anchor: "response";
337
+ readonly title: "VTA Backup Initiate Export — response payload";
338
+ readonly type: "object";
339
+ readonly additionalProperties: false;
340
+ readonly required: readonly ["descriptor"];
341
+ readonly properties: {
342
+ readonly descriptor: {
343
+ readonly $ref: "#/$defs/BundleDescriptor";
344
+ readonly description: "Where the bytes are, what they should be, and until when.";
345
+ };
346
+ readonly completionHint: {
347
+ readonly type: "string";
348
+ readonly maxLength: 1024;
349
+ readonly description: "Operator-facing text describing how to complete the download. Advisory: a producer must not parse it or derive behaviour from it, and a recipient must not put a secret in it.";
350
+ };
351
+ readonly ext: {
352
+ readonly $ref: "#/$defs/Ext";
353
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
354
+ };
355
+ };
356
+ };
357
+ readonly BundleDescriptor: {
358
+ readonly title: "Bundle descriptor";
359
+ readonly type: "object";
360
+ readonly additionalProperties: false;
361
+ readonly description: "The control-plane account of an out-of-band byte transfer. Shared in shape with initiate-import, where it describes an upload rather than a download.";
362
+ readonly required: readonly ["bundleId", "algorithm", "transportUrl", "transportToken", "expectedSha256", "expectedSizeBytes", "expiresAt"];
363
+ readonly properties: {
364
+ readonly bundleId: {
365
+ readonly type: "string";
366
+ readonly pattern: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$";
367
+ readonly description: "Handle for this bundle across its whole lifecycle. Quoted back by complete-export and abort. Recipient-generated and unguessable, which is what lets an unauthorized reference be answered as not-found without confirming existence.";
368
+ };
369
+ readonly algorithm: {
370
+ readonly type: "string";
371
+ readonly minLength: 1;
372
+ readonly maxLength: 64;
373
+ readonly description: "The mechanism actually used, which is authoritative over what was requested.";
374
+ };
375
+ readonly transportUrl: {
376
+ readonly type: "string";
377
+ readonly format: "uri";
378
+ readonly maxLength: 2048;
379
+ readonly description: "Where to fetch the bytes. A recipient with no address at which it is reachable cannot produce this and refuses with transportUnavailable rather than returning an unfetchable one.";
380
+ };
381
+ readonly transportToken: {
382
+ readonly type: "string";
383
+ readonly minLength: 1;
384
+ readonly maxLength: 1024;
385
+ readonly description: "Bearer credential for transportUrl, presented in the X-Backup-Token header. Minted per bundle and never reused. A recipient should store only a hash of it and should accept it once — the token plus the URL is the export.";
386
+ };
387
+ readonly expectedSha256: {
388
+ readonly type: "string";
389
+ readonly pattern: "^[0-9a-f]{64}$";
390
+ readonly description: "Lowercase hex SHA-256 of the byte stream. Independent of the encrypted envelope's own authentication tag, so a truncated or substituted transfer is caught before the password is applied to it.";
391
+ };
392
+ readonly expectedSizeBytes: {
393
+ readonly type: "integer";
394
+ readonly minimum: 1;
395
+ readonly description: "Total byte count. A zero-length bundle is not a degenerate success — nothing was serialized — so the floor is 1.";
396
+ };
397
+ readonly expiresAt: {
398
+ readonly type: "string";
399
+ readonly format: "date-time";
400
+ readonly description: "After which the bytes are collected and the token refused. Short by design: the window is how long a fetchable copy of the agent exists.";
401
+ };
402
+ };
403
+ };
404
+ readonly Ext: {
405
+ readonly title: "Ext";
406
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
407
+ readonly type: "object";
408
+ readonly minProperties: 1;
409
+ readonly additionalProperties: true;
410
+ readonly propertyNames: {
411
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
412
+ };
413
+ };
414
+ };
415
+ };
416
+ };
417
+ /**
418
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
419
+ * tracks the *issuer* party's requirement because a response swaps the
420
+ * parties (§7.3 item 5).
421
+ */
422
+ export declare const RESPONSE_SPEC: {
423
+ readonly typeUri: "https://trusttasks.org/spec/vta/backup/initiate-export/1.0#response";
424
+ readonly isBearer: false;
425
+ readonly isProofRequired: true;
426
+ readonly isRecipientRequired: true;
427
+ readonly isIssuedAtRequired: true;
428
+ readonly payloadSchema: {
429
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
430
+ readonly $ref: "#/$defs/Response";
431
+ readonly $defs: {
432
+ readonly Response: {
433
+ readonly $anchor: "response";
434
+ readonly title: "VTA Backup Initiate Export — response payload";
435
+ readonly type: "object";
436
+ readonly additionalProperties: false;
437
+ readonly required: readonly ["descriptor"];
438
+ readonly properties: {
439
+ readonly descriptor: {
440
+ readonly $ref: "#/$defs/BundleDescriptor";
441
+ readonly description: "Where the bytes are, what they should be, and until when.";
442
+ };
443
+ readonly completionHint: {
444
+ readonly type: "string";
445
+ readonly maxLength: 1024;
446
+ readonly description: "Operator-facing text describing how to complete the download. Advisory: a producer must not parse it or derive behaviour from it, and a recipient must not put a secret in it.";
447
+ };
448
+ readonly ext: {
449
+ readonly $ref: "#/$defs/Ext";
450
+ readonly description: "Ecosystem-defined extension members per SPEC.md §4.5.1.";
451
+ };
452
+ };
453
+ };
454
+ readonly BundleDescriptor: {
455
+ readonly title: "Bundle descriptor";
456
+ readonly type: "object";
457
+ readonly additionalProperties: false;
458
+ readonly description: "The control-plane account of an out-of-band byte transfer. Shared in shape with initiate-import, where it describes an upload rather than a download.";
459
+ readonly required: readonly ["bundleId", "algorithm", "transportUrl", "transportToken", "expectedSha256", "expectedSizeBytes", "expiresAt"];
460
+ readonly properties: {
461
+ readonly bundleId: {
462
+ readonly type: "string";
463
+ readonly pattern: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$";
464
+ readonly description: "Handle for this bundle across its whole lifecycle. Quoted back by complete-export and abort. Recipient-generated and unguessable, which is what lets an unauthorized reference be answered as not-found without confirming existence.";
465
+ };
466
+ readonly algorithm: {
467
+ readonly type: "string";
468
+ readonly minLength: 1;
469
+ readonly maxLength: 64;
470
+ readonly description: "The mechanism actually used, which is authoritative over what was requested.";
471
+ };
472
+ readonly transportUrl: {
473
+ readonly type: "string";
474
+ readonly format: "uri";
475
+ readonly maxLength: 2048;
476
+ readonly description: "Where to fetch the bytes. A recipient with no address at which it is reachable cannot produce this and refuses with transportUnavailable rather than returning an unfetchable one.";
477
+ };
478
+ readonly transportToken: {
479
+ readonly type: "string";
480
+ readonly minLength: 1;
481
+ readonly maxLength: 1024;
482
+ readonly description: "Bearer credential for transportUrl, presented in the X-Backup-Token header. Minted per bundle and never reused. A recipient should store only a hash of it and should accept it once — the token plus the URL is the export.";
483
+ };
484
+ readonly expectedSha256: {
485
+ readonly type: "string";
486
+ readonly pattern: "^[0-9a-f]{64}$";
487
+ readonly description: "Lowercase hex SHA-256 of the byte stream. Independent of the encrypted envelope's own authentication tag, so a truncated or substituted transfer is caught before the password is applied to it.";
488
+ };
489
+ readonly expectedSizeBytes: {
490
+ readonly type: "integer";
491
+ readonly minimum: 1;
492
+ readonly description: "Total byte count. A zero-length bundle is not a degenerate success — nothing was serialized — so the floor is 1.";
493
+ };
494
+ readonly expiresAt: {
495
+ readonly type: "string";
496
+ readonly format: "date-time";
497
+ readonly description: "After which the bytes are collected and the token refused. Short by design: the window is how long a fetchable copy of the agent exists.";
498
+ };
499
+ };
500
+ };
501
+ readonly Ext: {
502
+ readonly title: "Ext";
503
+ readonly description: "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.";
504
+ readonly type: "object";
505
+ readonly minProperties: 1;
506
+ readonly additionalProperties: true;
507
+ readonly propertyNames: {
508
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
509
+ };
510
+ };
511
+ };
512
+ };
513
+ };
514
+ //# sourceMappingURL=payload.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../../../src/vta/backup/initiate-export/1.0/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,mCAAmC,CAAC;AAG7D;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC7C;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD,MAAM,WAAW,sCAAsC;IACrD,UAAU,EAAE,gBAAgB,CAAC;IAC7B;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;OAEG;IACH,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IACvB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IACvB;;OAEG;IACH,iBAAiB,EAAE,MAAM,CAAC;IAC1B;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,kHAAkH;AAClH,YAAY,EAAE,GAAG,EAAE,CAAC;AAEpB,2BAA2B;AAC3B,eAAO,MAAM,QAAQ,EAAG,4DAAqE,CAAC;AAE9F,mEAAmE;AACnE,MAAM,MAAM,OAAO,GAAG,8BAA8B,CAAC;AAErD,qEAAqE;AACrE,eAAO,MAAM,iBAAiB,EAAG,qEAA8E,CAAC;AAEhH,4EAA4E;AAC5E,MAAM,MAAM,QAAQ,GAAG,sCAAsC,CAAC;AAE9D;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6HjB,CAAC;AAEX,mEAAmE;AACnE,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8F1B,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOP,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOhB,CAAC"}