@openvtc/trust-tasks 0.28.3 → 0.28.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 (62) hide show
  1. package/CHANGELOG.md +85 -0
  2. package/dist/_extends.d.ts.map +1 -1
  3. package/dist/_extends.js +2 -0
  4. package/dist/_extends.js.map +1 -1
  5. package/dist/index.d.ts +12 -0
  6. package/dist/index.d.ts.map +1 -1
  7. package/dist/index.js +12 -0
  8. package/dist/index.js.map +1 -1
  9. package/dist/peer-check/ask/0.1/payload.d.ts +397 -0
  10. package/dist/peer-check/ask/0.1/payload.d.ts.map +1 -0
  11. package/dist/peer-check/ask/0.1/payload.js +235 -0
  12. package/dist/peer-check/ask/0.1/payload.js.map +1 -0
  13. package/dist/rooms/keys/act/0.1/payload.d.ts +4 -4
  14. package/dist/rooms/keys/act/0.1/payload.js +1 -1
  15. package/dist/rooms/keys/act/0.2/payload.d.ts +4 -4
  16. package/dist/rooms/keys/act/0.2/payload.js +1 -1
  17. package/dist/rooms/keys/act/0.3/payload.d.ts +4 -4
  18. package/dist/rooms/keys/act/0.3/payload.js +1 -1
  19. package/dist/rooms/keys/act/0.4/payload.d.ts +4 -4
  20. package/dist/rooms/keys/act/0.4/payload.js +1 -1
  21. package/dist/rooms/keys/act/0.5/payload.d.ts +4 -4
  22. package/dist/rooms/keys/act/0.5/payload.js +1 -1
  23. package/dist/rooms/keys/act/0.6/payload.d.ts +4 -4
  24. package/dist/rooms/keys/act/0.6/payload.js +1 -1
  25. package/dist/rooms/keys/act/0.7/payload.d.ts +4 -4
  26. package/dist/rooms/keys/act/0.7/payload.js +1 -1
  27. package/dist/rooms/keys/act/0.8/payload.d.ts +14 -2
  28. package/dist/rooms/keys/act/0.8/payload.d.ts.map +1 -1
  29. package/dist/rooms/keys/act/0.8/payload.js +1 -1
  30. package/dist/rooms/keys/act/0.8/payload.js.map +1 -1
  31. package/dist/rooms/keys/act/0.9/payload.d.ts +560 -0
  32. package/dist/rooms/keys/act/0.9/payload.d.ts.map +1 -0
  33. package/dist/rooms/keys/act/0.9/payload.js +319 -0
  34. package/dist/rooms/keys/act/0.9/payload.js.map +1 -0
  35. package/dist/vta/webvh/dids/update/1.0/payload.d.ts +14 -2
  36. package/dist/vta/webvh/dids/update/1.0/payload.d.ts.map +1 -1
  37. package/dist/vta/webvh/dids/update/1.0/payload.js +1 -1
  38. package/dist/vta/webvh/dids/update/1.0/payload.js.map +1 -1
  39. package/dist/vta/webvh/dids/update/1.1/payload.d.ts +511 -0
  40. package/dist/vta/webvh/dids/update/1.1/payload.d.ts.map +1 -0
  41. package/dist/vta/webvh/dids/update/1.1/payload.js +251 -0
  42. package/dist/vta/webvh/dids/update/1.1/payload.js.map +1 -0
  43. package/dist/vtc/elections/ballot-boxes/list/0.1/payload.d.ts +366 -0
  44. package/dist/vtc/elections/ballot-boxes/list/0.1/payload.d.ts.map +1 -0
  45. package/dist/vtc/elections/ballot-boxes/list/0.1/payload.js +205 -0
  46. package/dist/vtc/elections/ballot-boxes/list/0.1/payload.js.map +1 -0
  47. package/package.json +1 -1
  48. package/src/_extends.ts +2 -0
  49. package/src/index.ts +12 -0
  50. package/src/peer-check/ask/0.1/payload.ts +301 -0
  51. package/src/rooms/keys/act/0.1/payload.ts +5 -5
  52. package/src/rooms/keys/act/0.2/payload.ts +5 -5
  53. package/src/rooms/keys/act/0.3/payload.ts +5 -5
  54. package/src/rooms/keys/act/0.4/payload.ts +5 -5
  55. package/src/rooms/keys/act/0.5/payload.ts +5 -5
  56. package/src/rooms/keys/act/0.6/payload.ts +5 -5
  57. package/src/rooms/keys/act/0.7/payload.ts +5 -5
  58. package/src/rooms/keys/act/0.8/payload.ts +15 -3
  59. package/src/rooms/keys/act/0.9/payload.ts +396 -0
  60. package/src/vta/webvh/dids/update/1.0/payload.ts +15 -3
  61. package/src/vta/webvh/dids/update/1.1/payload.ts +351 -0
  62. package/src/vtc/elections/ballot-boxes/list/0.1/payload.ts +260 -0
@@ -0,0 +1,251 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/webvh/dids/update/1.1/payload.schema.json
4
+ */
5
+ /** Trust Task type URI. */
6
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/webvh/dids/update/1.1";
7
+ /**
8
+ * The earlier version of this specification that this one declares it
9
+ * extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
10
+ * `null`. Only the direct declaration — follow the chain with
11
+ * `extendsChain` / `readForSpec`.
12
+ */
13
+ export const EXTENDS = "1.0";
14
+ /**
15
+ * Why this version is deprecated, or `null` while it is current. A
16
+ * superseded or retired version is still supported, and is withdrawn from
17
+ * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
18
+ * Versions").
19
+ */
20
+ export const DEPRECATION = null;
21
+ /** Trust Task response type URI (request type URI + "#response"). */
22
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/webvh/dids/update/1.1#response";
23
+ /**
24
+ * This specification's payload schema, as a value.
25
+ *
26
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
27
+ * rather than only as a `.json` file because TypeScript types are erased
28
+ * at runtime: without a schema a consumer has nothing to validate, and
29
+ * every REQUIRED payload member is optional in practice. Cross-file
30
+ * `$ref`s are already inlined, so it needs no resolver.
31
+ */
32
+ export const PAYLOAD_SCHEMA = {
33
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
34
+ "$id": "https://trusttasks.org/spec/vta/webvh/dids/update/1.1",
35
+ "title": "WebVH DID Update — payload",
36
+ "description": "Ask a Verifiable Trust Agent to publish a new entry in a did:webvh log it holds the update key for. The agent decides whether to do so; the caller proposes.",
37
+ "type": "object",
38
+ "additionalProperties": false,
39
+ "required": [
40
+ "did"
41
+ ],
42
+ "properties": {
43
+ "did": {
44
+ "type": "string",
45
+ "minLength": 1,
46
+ "description": "The did:webvh being updated. The agent MUST verify it speaks for this subject."
47
+ },
48
+ "document": {
49
+ "type": "object",
50
+ "description": "The new DID document. Omit to leave it unchanged. Supplying this ROTATES the DID's update key and refreshes its pre-rotation commitments, as a parallel consequence of the change — a consequence not visible anywhere in this payload, because it lives in the executing handler's semantics. A consent surface MUST therefore render effects the executor computed, and MUST NOT derive them from this document."
51
+ },
52
+ "preRotationCount": {
53
+ "type": "integer",
54
+ "minimum": 0,
55
+ "description": "Number of pre-rotation commitments to publish. Omit to keep the current count; `0` disables pre-rotation going forward."
56
+ },
57
+ "witnesses": {
58
+ "description": "New witness configuration. Omit to keep the current one."
59
+ },
60
+ "watchers": {
61
+ "type": "array",
62
+ "items": {
63
+ "type": "string"
64
+ },
65
+ "description": "New watcher URLs. Omit to keep the current set; an empty array removes them."
66
+ },
67
+ "ttl": {
68
+ "type": "integer",
69
+ "minimum": 0,
70
+ "description": "New TTL in seconds. Omit to keep the current value."
71
+ },
72
+ "label": {
73
+ "type": "string",
74
+ "maxLength": 256,
75
+ "description": "Operator-facing audit label."
76
+ },
77
+ "expectedVersionId": {
78
+ "type": "string",
79
+ "minLength": 1,
80
+ "description": "Optimistic-concurrency precondition: the versionId the caller based this edit on. The agent MUST refuse the update if the DID's latest entry no longer matches. Without it a `get -> edit -> save` cycle silently overwrites a concurrent edit with a chain that is structurally valid, verifies perfectly, and is based on a stale read. Where a human approves the update the window is minutes wide, so this is a routine race rather than an exotic one. OPTIONAL because a scripted caller with no concurrent writers has nothing to protect against; not optional for anything a person looked at."
81
+ },
82
+ "scidAlsoKnownAs": {
83
+ "type": "boolean",
84
+ "description": "Whether the published document lists this log's `did:scid:vh:1:<scid>?src=<source>` DID URL in `alsoKnownAs`, linking the did:webvh and did:scid forms as one subject (VTI-KEY-164). `true` adds it, for the log's current location, after the entries the document already has; `false` removes every did:scid entry naming this log's SCID. Applied to `document` when one is supplied, otherwise to the current document. Omit to leave `alsoKnownAs` as `document` (or the current document) has it. The agent derives the DID URL itself — the caller never writes it. Changing it publishes an entry, and so ROTATES the update key exactly as supplying `document` does."
85
+ },
86
+ "ext": {
87
+ "$ref": "#/$defs/Ext"
88
+ }
89
+ },
90
+ "$defs": {
91
+ "Response": {
92
+ "$anchor": "response",
93
+ "title": "WebVH DID Update — response payload",
94
+ "description": "The published entry. camelCase per the framework convention — note the counts are the state AFTER the update, including the rotation the caller did not ask for.",
95
+ "type": "object",
96
+ "additionalProperties": false,
97
+ "required": [
98
+ "did",
99
+ "newVersionId"
100
+ ],
101
+ "properties": {
102
+ "did": {
103
+ "type": "string"
104
+ },
105
+ "newVersionId": {
106
+ "type": "string",
107
+ "description": "versionId of the entry just appended. A caller intending a further edit SHOULD pass this back as the next request's `expectedVersionId`."
108
+ },
109
+ "newScid": {
110
+ "type": "string"
111
+ },
112
+ "newLogEntry": {
113
+ "type": "string",
114
+ "description": "The appended log entry, as JSON text."
115
+ },
116
+ "updateKeysCount": {
117
+ "type": "integer",
118
+ "minimum": 0,
119
+ "description": "Update keys authorized AFTER this entry. Where `document` was supplied these are new keys — the previous ones no longer authorize anything."
120
+ },
121
+ "preRotationKeyCount": {
122
+ "type": "integer",
123
+ "minimum": 0,
124
+ "description": "Pre-rotation commitments published by this entry."
125
+ },
126
+ "serverless": {
127
+ "type": "boolean",
128
+ "description": "True when the agent holds the log itself and no hosting server was published to — the operator must fetch and redeploy `did.jsonl`."
129
+ },
130
+ "scidAlsoKnownAs": {
131
+ "type": "boolean",
132
+ "description": "Whether the published document lists `scidDidUrl` in `alsoKnownAs`. A 1.1 consumer MUST report it; it is optional in the schema only because 1.1 extends 1.0."
133
+ },
134
+ "scidDidUrl": {
135
+ "type": "string",
136
+ "description": "The `did:scid:vh:1:<scid>?src=<source>` DID URL of the log at its current location — the did:scid DID with the locator a recipient needs to resolve it. Reported whether or not it is listed. A 1.1 consumer MUST report it; it is optional in the schema only because 1.1 extends 1.0."
137
+ },
138
+ "ext": {
139
+ "$ref": "#/$defs/Ext"
140
+ }
141
+ }
142
+ },
143
+ "Ext": {
144
+ "title": "Ext",
145
+ "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.",
146
+ "type": "object",
147
+ "minProperties": 1,
148
+ "additionalProperties": true,
149
+ "propertyNames": {
150
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
151
+ }
152
+ }
153
+ }
154
+ };
155
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
156
+ export const RESPONSE_PAYLOAD_SCHEMA = {
157
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
158
+ "$ref": "#/$defs/Response",
159
+ "$defs": {
160
+ "Response": {
161
+ "$anchor": "response",
162
+ "title": "WebVH DID Update — response payload",
163
+ "description": "The published entry. camelCase per the framework convention — note the counts are the state AFTER the update, including the rotation the caller did not ask for.",
164
+ "type": "object",
165
+ "additionalProperties": false,
166
+ "required": [
167
+ "did",
168
+ "newVersionId"
169
+ ],
170
+ "properties": {
171
+ "did": {
172
+ "type": "string"
173
+ },
174
+ "newVersionId": {
175
+ "type": "string",
176
+ "description": "versionId of the entry just appended. A caller intending a further edit SHOULD pass this back as the next request's `expectedVersionId`."
177
+ },
178
+ "newScid": {
179
+ "type": "string"
180
+ },
181
+ "newLogEntry": {
182
+ "type": "string",
183
+ "description": "The appended log entry, as JSON text."
184
+ },
185
+ "updateKeysCount": {
186
+ "type": "integer",
187
+ "minimum": 0,
188
+ "description": "Update keys authorized AFTER this entry. Where `document` was supplied these are new keys — the previous ones no longer authorize anything."
189
+ },
190
+ "preRotationKeyCount": {
191
+ "type": "integer",
192
+ "minimum": 0,
193
+ "description": "Pre-rotation commitments published by this entry."
194
+ },
195
+ "serverless": {
196
+ "type": "boolean",
197
+ "description": "True when the agent holds the log itself and no hosting server was published to — the operator must fetch and redeploy `did.jsonl`."
198
+ },
199
+ "scidAlsoKnownAs": {
200
+ "type": "boolean",
201
+ "description": "Whether the published document lists `scidDidUrl` in `alsoKnownAs`. A 1.1 consumer MUST report it; it is optional in the schema only because 1.1 extends 1.0."
202
+ },
203
+ "scidDidUrl": {
204
+ "type": "string",
205
+ "description": "The `did:scid:vh:1:<scid>?src=<source>` DID URL of the log at its current location — the did:scid DID with the locator a recipient needs to resolve it. Reported whether or not it is listed. A 1.1 consumer MUST report it; it is optional in the schema only because 1.1 extends 1.0."
206
+ },
207
+ "ext": {
208
+ "$ref": "#/$defs/Ext"
209
+ }
210
+ }
211
+ },
212
+ "Ext": {
213
+ "title": "Ext",
214
+ "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.",
215
+ "type": "object",
216
+ "minProperties": 1,
217
+ "additionalProperties": true,
218
+ "propertyNames": {
219
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
220
+ }
221
+ }
222
+ }
223
+ };
224
+ /**
225
+ * SPEC.md §7.2 policy for the request variant, from this specification's
226
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
227
+ * per-specification and cannot be derived from the document alone, and
228
+ * item 2 needs the schema this carries.
229
+ */
230
+ export const SPEC = {
231
+ typeUri: TYPE_URI,
232
+ isBearer: false,
233
+ isProofRequired: true,
234
+ isRecipientRequired: true,
235
+ isIssuedAtRequired: true,
236
+ payloadSchema: PAYLOAD_SCHEMA,
237
+ };
238
+ /**
239
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
240
+ * tracks the *issuer* party's requirement because a response swaps the
241
+ * parties (§7.3 item 5).
242
+ */
243
+ export const RESPONSE_SPEC = {
244
+ typeUri: RESPONSE_TYPE_URI,
245
+ isBearer: false,
246
+ isProofRequired: true,
247
+ isRecipientRequired: true,
248
+ isIssuedAtRequired: true,
249
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
250
+ };
251
+ //# sourceMappingURL=payload.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payload.js","sourceRoot":"","sources":["../../../../../../src/vta/webvh/dids/update/1.1/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG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,MAAM,EAAE,aAAa;iBACtB;aACF;SACF;QACD,KAAK,EAAE;YACL,OAAO,EAAE,KAAK;YACd,aAAa,EAAE,uKAAuK;YACtL,MAAM,EAAE,QAAQ;YAChB,eAAe,EAAE,CAAC;YAClB,sBAAsB,EAAE,IAAI;YAC5B,eAAe,EAAE;gBACf,SAAS,EAAE,mCAAmC;aAC/C;SACF;KACF;CACO,CAAC;AAEX;;;;;GAKG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG;IAClB,OAAO,EAAE,QAAQ;IACjB,QAAQ,EAAE,KAAK;IACf,eAAe,EAAE,IAAI;IACrB,mBAAmB,EAAE,IAAI;IACzB,kBAAkB,EAAE,IAAI;IACxB,aAAa,EAAE,cAAc;CACrB,CAAC;AAEX;;;;GAIG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,OAAO,EAAE,iBAAiB;IAC1B,QAAQ,EAAE,KAAK;IACf,eAAe,EAAE,IAAI;IACrB,mBAAmB,EAAE,IAAI;IACzB,kBAAkB,EAAE,IAAI;IACxB,aAAa,EAAE,uBAAuB;CAC9B,CAAC"}
@@ -0,0 +1,366 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vtc/elections/ballot-boxes/list/0.1/payload.schema.json
4
+ */
5
+ import type { Ext } from "../../../../../_shared/components.js";
6
+ /**
7
+ * An administrator reads the voting services the community will register an election with — its trusted ballot boxes — so that a manifest names one the community accepts. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.
8
+ */
9
+ export interface VTCElectionsBallotBoxesListPayload {
10
+ ext?: Ext;
11
+ }
12
+ /**
13
+ * Success response to vtc/elections/ballot-boxes/list/0.1: every voting service the community trusts, as it trusts them now.
14
+ */
15
+ export interface VTCElectionsBallotBoxesListResponsePayload {
16
+ /**
17
+ * Every trusted ballot box, in the community's own order. Empty when the community trusts none, and so can create no election.
18
+ *
19
+ * @maxItems 256
20
+ */
21
+ ballotBoxes: TrustedBallotBox[];
22
+ ext?: Ext;
23
+ }
24
+ /**
25
+ * One voting service the community trusts (VTI-VOT-082), with what its members are told about it when an election names it (VTI-VOT-090).
26
+ */
27
+ export interface TrustedBallotBox {
28
+ /**
29
+ * The ballot box's DID, exactly as a manifest names it in `ballotBox`.
30
+ */
31
+ did: string;
32
+ /**
33
+ * Who operates it, as the community names them — the `ballotBoxOperator` a member is shown.
34
+ */
35
+ operator: string;
36
+ /**
37
+ * Whether the party operating the community's VTC also operates this ballot box — the `sameOperator` a member is shown.
38
+ */
39
+ sameOperator: boolean;
40
+ }
41
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
42
+ export type { Ext };
43
+ /** Trust Task type URI. */
44
+ export declare const TYPE_URI: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1";
45
+ /**
46
+ * The earlier version of this specification that this one declares it
47
+ * extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
48
+ * `null`. Only the direct declaration — follow the chain with
49
+ * `extendsChain` / `readForSpec`.
50
+ */
51
+ export declare const EXTENDS: string | null;
52
+ /**
53
+ * Why this version is deprecated, or `null` while it is current. A
54
+ * superseded or retired version is still supported, and is withdrawn from
55
+ * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
56
+ * Versions").
57
+ */
58
+ export declare const DEPRECATION: string | null;
59
+ /** Stable alias for this specification's request payload shape. */
60
+ export type Payload = VTCElectionsBallotBoxesListPayload;
61
+ /** Trust Task response type URI (request type URI + "#response"). */
62
+ export declare const RESPONSE_TYPE_URI: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1#response";
63
+ /** Stable alias for this specification's success-response payload shape. */
64
+ export type Response = VTCElectionsBallotBoxesListResponsePayload;
65
+ /**
66
+ * This specification's payload schema, as a value.
67
+ *
68
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
69
+ * rather than only as a `.json` file because TypeScript types are erased
70
+ * at runtime: without a schema a consumer has nothing to validate, and
71
+ * every REQUIRED payload member is optional in practice. Cross-file
72
+ * `$ref`s are already inlined, so it needs no resolver.
73
+ */
74
+ export declare const PAYLOAD_SCHEMA: {
75
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
76
+ readonly $id: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1";
77
+ readonly title: "VTC Elections — Ballot Boxes — List — payload";
78
+ readonly description: "An administrator reads the voting services the community will register an election with — its trusted ballot boxes — so that a manifest names one the community accepts. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.";
79
+ readonly type: "object";
80
+ readonly additionalProperties: false;
81
+ readonly properties: {
82
+ readonly ext: {
83
+ readonly $ref: "#/$defs/Ext";
84
+ };
85
+ };
86
+ readonly $defs: {
87
+ readonly TrustedBallotBox: {
88
+ readonly title: "TrustedBallotBox";
89
+ readonly description: "One voting service the community trusts (VTI-VOT-082), with what its members are told about it when an election names it (VTI-VOT-090).";
90
+ readonly type: "object";
91
+ readonly additionalProperties: false;
92
+ readonly required: readonly ["did", "operator", "sameOperator"];
93
+ readonly properties: {
94
+ readonly did: {
95
+ readonly type: "string";
96
+ readonly minLength: 1;
97
+ readonly maxLength: 2048;
98
+ readonly description: "The ballot box's DID, exactly as a manifest names it in `ballotBox`.";
99
+ };
100
+ readonly operator: {
101
+ readonly type: "string";
102
+ readonly minLength: 1;
103
+ readonly maxLength: 512;
104
+ readonly description: "Who operates it, as the community names them — the `ballotBoxOperator` a member is shown.";
105
+ };
106
+ readonly sameOperator: {
107
+ readonly type: "boolean";
108
+ readonly description: "Whether the party operating the community's VTC also operates this ballot box — the `sameOperator` a member is shown.";
109
+ };
110
+ };
111
+ };
112
+ readonly Response: {
113
+ readonly $anchor: "response";
114
+ readonly title: "VTC Elections — Ballot Boxes — List — response payload";
115
+ readonly description: "Success response to vtc/elections/ballot-boxes/list/0.1: every voting service the community trusts, as it trusts them now.";
116
+ readonly type: "object";
117
+ readonly additionalProperties: false;
118
+ readonly required: readonly ["ballotBoxes"];
119
+ readonly properties: {
120
+ readonly ballotBoxes: {
121
+ readonly type: "array";
122
+ readonly maxItems: 256;
123
+ readonly items: {
124
+ readonly $ref: "#/$defs/TrustedBallotBox";
125
+ };
126
+ readonly description: "Every trusted ballot box, in the community's own order. Empty when the community trusts none, and so can create no election.";
127
+ };
128
+ readonly ext: {
129
+ readonly $ref: "#/$defs/Ext";
130
+ };
131
+ };
132
+ };
133
+ readonly Ext: {
134
+ readonly title: "Ext";
135
+ 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.";
136
+ readonly type: "object";
137
+ readonly minProperties: 1;
138
+ readonly additionalProperties: true;
139
+ readonly propertyNames: {
140
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
141
+ };
142
+ };
143
+ };
144
+ };
145
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
146
+ export declare const RESPONSE_PAYLOAD_SCHEMA: {
147
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
148
+ readonly $ref: "#/$defs/Response";
149
+ readonly $defs: {
150
+ readonly TrustedBallotBox: {
151
+ readonly title: "TrustedBallotBox";
152
+ readonly description: "One voting service the community trusts (VTI-VOT-082), with what its members are told about it when an election names it (VTI-VOT-090).";
153
+ readonly type: "object";
154
+ readonly additionalProperties: false;
155
+ readonly required: readonly ["did", "operator", "sameOperator"];
156
+ readonly properties: {
157
+ readonly did: {
158
+ readonly type: "string";
159
+ readonly minLength: 1;
160
+ readonly maxLength: 2048;
161
+ readonly description: "The ballot box's DID, exactly as a manifest names it in `ballotBox`.";
162
+ };
163
+ readonly operator: {
164
+ readonly type: "string";
165
+ readonly minLength: 1;
166
+ readonly maxLength: 512;
167
+ readonly description: "Who operates it, as the community names them — the `ballotBoxOperator` a member is shown.";
168
+ };
169
+ readonly sameOperator: {
170
+ readonly type: "boolean";
171
+ readonly description: "Whether the party operating the community's VTC also operates this ballot box — the `sameOperator` a member is shown.";
172
+ };
173
+ };
174
+ };
175
+ readonly Response: {
176
+ readonly $anchor: "response";
177
+ readonly title: "VTC Elections — Ballot Boxes — List — response payload";
178
+ readonly description: "Success response to vtc/elections/ballot-boxes/list/0.1: every voting service the community trusts, as it trusts them now.";
179
+ readonly type: "object";
180
+ readonly additionalProperties: false;
181
+ readonly required: readonly ["ballotBoxes"];
182
+ readonly properties: {
183
+ readonly ballotBoxes: {
184
+ readonly type: "array";
185
+ readonly maxItems: 256;
186
+ readonly items: {
187
+ readonly $ref: "#/$defs/TrustedBallotBox";
188
+ };
189
+ readonly description: "Every trusted ballot box, in the community's own order. Empty when the community trusts none, and so can create no election.";
190
+ };
191
+ readonly ext: {
192
+ readonly $ref: "#/$defs/Ext";
193
+ };
194
+ };
195
+ };
196
+ readonly Ext: {
197
+ readonly title: "Ext";
198
+ 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.";
199
+ readonly type: "object";
200
+ readonly minProperties: 1;
201
+ readonly additionalProperties: true;
202
+ readonly propertyNames: {
203
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
204
+ };
205
+ };
206
+ };
207
+ };
208
+ /**
209
+ * SPEC.md §7.2 policy for the request variant, from this specification's
210
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
211
+ * per-specification and cannot be derived from the document alone, and
212
+ * item 2 needs the schema this carries.
213
+ */
214
+ export declare const SPEC: {
215
+ readonly typeUri: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1";
216
+ readonly isBearer: false;
217
+ readonly isProofRequired: false;
218
+ readonly isRecipientRequired: true;
219
+ readonly isIssuedAtRequired: false;
220
+ readonly payloadSchema: {
221
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
222
+ readonly $id: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1";
223
+ readonly title: "VTC Elections — Ballot Boxes — List — payload";
224
+ readonly description: "An administrator reads the voting services the community will register an election with — its trusted ballot boxes — so that a manifest names one the community accepts. The outer document members (id, type, issuer, recipient, issuedAt, expiresAt, proof) are owned by the framework — SPEC §6.3.";
225
+ readonly type: "object";
226
+ readonly additionalProperties: false;
227
+ readonly properties: {
228
+ readonly ext: {
229
+ readonly $ref: "#/$defs/Ext";
230
+ };
231
+ };
232
+ readonly $defs: {
233
+ readonly TrustedBallotBox: {
234
+ readonly title: "TrustedBallotBox";
235
+ readonly description: "One voting service the community trusts (VTI-VOT-082), with what its members are told about it when an election names it (VTI-VOT-090).";
236
+ readonly type: "object";
237
+ readonly additionalProperties: false;
238
+ readonly required: readonly ["did", "operator", "sameOperator"];
239
+ readonly properties: {
240
+ readonly did: {
241
+ readonly type: "string";
242
+ readonly minLength: 1;
243
+ readonly maxLength: 2048;
244
+ readonly description: "The ballot box's DID, exactly as a manifest names it in `ballotBox`.";
245
+ };
246
+ readonly operator: {
247
+ readonly type: "string";
248
+ readonly minLength: 1;
249
+ readonly maxLength: 512;
250
+ readonly description: "Who operates it, as the community names them — the `ballotBoxOperator` a member is shown.";
251
+ };
252
+ readonly sameOperator: {
253
+ readonly type: "boolean";
254
+ readonly description: "Whether the party operating the community's VTC also operates this ballot box — the `sameOperator` a member is shown.";
255
+ };
256
+ };
257
+ };
258
+ readonly Response: {
259
+ readonly $anchor: "response";
260
+ readonly title: "VTC Elections — Ballot Boxes — List — response payload";
261
+ readonly description: "Success response to vtc/elections/ballot-boxes/list/0.1: every voting service the community trusts, as it trusts them now.";
262
+ readonly type: "object";
263
+ readonly additionalProperties: false;
264
+ readonly required: readonly ["ballotBoxes"];
265
+ readonly properties: {
266
+ readonly ballotBoxes: {
267
+ readonly type: "array";
268
+ readonly maxItems: 256;
269
+ readonly items: {
270
+ readonly $ref: "#/$defs/TrustedBallotBox";
271
+ };
272
+ readonly description: "Every trusted ballot box, in the community's own order. Empty when the community trusts none, and so can create no election.";
273
+ };
274
+ readonly ext: {
275
+ readonly $ref: "#/$defs/Ext";
276
+ };
277
+ };
278
+ };
279
+ readonly Ext: {
280
+ readonly title: "Ext";
281
+ 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.";
282
+ readonly type: "object";
283
+ readonly minProperties: 1;
284
+ readonly additionalProperties: true;
285
+ readonly propertyNames: {
286
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
287
+ };
288
+ };
289
+ };
290
+ };
291
+ };
292
+ /**
293
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
294
+ * tracks the *issuer* party's requirement because a response swaps the
295
+ * parties (§7.3 item 5).
296
+ */
297
+ export declare const RESPONSE_SPEC: {
298
+ readonly typeUri: "https://trusttasks.org/spec/vtc/elections/ballot-boxes/list/0.1#response";
299
+ readonly isBearer: false;
300
+ readonly isProofRequired: false;
301
+ readonly isRecipientRequired: true;
302
+ readonly isIssuedAtRequired: false;
303
+ readonly payloadSchema: {
304
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
305
+ readonly $ref: "#/$defs/Response";
306
+ readonly $defs: {
307
+ readonly TrustedBallotBox: {
308
+ readonly title: "TrustedBallotBox";
309
+ readonly description: "One voting service the community trusts (VTI-VOT-082), with what its members are told about it when an election names it (VTI-VOT-090).";
310
+ readonly type: "object";
311
+ readonly additionalProperties: false;
312
+ readonly required: readonly ["did", "operator", "sameOperator"];
313
+ readonly properties: {
314
+ readonly did: {
315
+ readonly type: "string";
316
+ readonly minLength: 1;
317
+ readonly maxLength: 2048;
318
+ readonly description: "The ballot box's DID, exactly as a manifest names it in `ballotBox`.";
319
+ };
320
+ readonly operator: {
321
+ readonly type: "string";
322
+ readonly minLength: 1;
323
+ readonly maxLength: 512;
324
+ readonly description: "Who operates it, as the community names them — the `ballotBoxOperator` a member is shown.";
325
+ };
326
+ readonly sameOperator: {
327
+ readonly type: "boolean";
328
+ readonly description: "Whether the party operating the community's VTC also operates this ballot box — the `sameOperator` a member is shown.";
329
+ };
330
+ };
331
+ };
332
+ readonly Response: {
333
+ readonly $anchor: "response";
334
+ readonly title: "VTC Elections — Ballot Boxes — List — response payload";
335
+ readonly description: "Success response to vtc/elections/ballot-boxes/list/0.1: every voting service the community trusts, as it trusts them now.";
336
+ readonly type: "object";
337
+ readonly additionalProperties: false;
338
+ readonly required: readonly ["ballotBoxes"];
339
+ readonly properties: {
340
+ readonly ballotBoxes: {
341
+ readonly type: "array";
342
+ readonly maxItems: 256;
343
+ readonly items: {
344
+ readonly $ref: "#/$defs/TrustedBallotBox";
345
+ };
346
+ readonly description: "Every trusted ballot box, in the community's own order. Empty when the community trusts none, and so can create no election.";
347
+ };
348
+ readonly ext: {
349
+ readonly $ref: "#/$defs/Ext";
350
+ };
351
+ };
352
+ };
353
+ readonly Ext: {
354
+ readonly title: "Ext";
355
+ 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.";
356
+ readonly type: "object";
357
+ readonly minProperties: 1;
358
+ readonly additionalProperties: true;
359
+ readonly propertyNames: {
360
+ readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
361
+ };
362
+ };
363
+ };
364
+ };
365
+ };
366
+ //# sourceMappingURL=payload.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../../../../src/vtc/elections/ballot-boxes/list/0.1/payload.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,sCAAsC,CAAC;AAGhE;;GAEG;AACH,MAAM,WAAW,kCAAkC;IACjD,GAAG,CAAC,EAAE,GAAG,CAAC;CACX;AACD;;GAEG;AACH,MAAM,WAAW,0CAA0C;IACzD;;;;OAIG;IACH,WAAW,EAAE,gBAAgB,EAAE,CAAC;IAChC,GAAG,CAAC,EAA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