@openvtc/trust-tasks 0.26.26 → 0.26.28

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.
@@ -435,7 +435,8 @@ export type BoardEntry =
435
435
  | ElectionKeyEntry
436
436
  | PartialDecryptionsEntry
437
437
  | UnsealedEntry
438
- | SpoiledEntry;
438
+ | SpoiledEntry
439
+ | TrusteeStepEntry;
439
440
  /**
440
441
  * `public`: anyone reads the board. `private`: the community, the auditors the manifest names and, for one cast's inclusion, the holder of its receipt (VTI-VOT-052).
441
442
  */
@@ -4900,14 +4901,23 @@ export interface EncryptedCastEntry {
4900
4901
  kind: "encryptedCast";
4901
4902
  cast: EncryptedCast;
4902
4903
  }
4904
+ /**
4905
+ * Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind.
4906
+ */
4903
4907
  export interface TransportKeyEntry {
4904
4908
  kind: "transportKey";
4905
4909
  transportKey: TransportKey;
4906
4910
  }
4911
+ /**
4912
+ * Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind.
4913
+ */
4907
4914
  export interface DealingEntry {
4908
4915
  kind: "dealing";
4909
4916
  dealing: Dealing;
4910
4917
  }
4918
+ /**
4919
+ * Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind.
4920
+ */
4911
4921
  export interface ConfirmationEntry {
4912
4922
  kind: "confirmation";
4913
4923
  trustee: TrusteeIndex;
@@ -4916,6 +4926,9 @@ export interface ConfirmationEntry {
4916
4926
  */
4917
4927
  complaints: TrusteeIndex[];
4918
4928
  }
4929
+ /**
4930
+ * Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind.
4931
+ */
4919
4932
  export interface JustificationEntry {
4920
4933
  kind: "justification";
4921
4934
  dealer: TrusteeIndex;
@@ -4947,6 +4960,13 @@ export interface SpoiledEntry {
4947
4960
  kind: "spoiled";
4948
4961
  leafIndex: number;
4949
4962
  }
4963
+ /**
4964
+ * One step of the trustees' ceremony — an enrolment, a dealing, a confirmation or a justification — as the trustee's own signed request, so that anyone reading the board can tell who took it (CONVENTIONS §9.6).
4965
+ */
4966
+ export interface TrusteeStepEntry {
4967
+ kind: "trusteeStep";
4968
+ request: SignedRequest;
4969
+ }
4950
4970
  /**
4951
4971
  * A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.
4952
4972
  */
@@ -10401,6 +10421,10 @@ export interface SigmaProof {
10401
10421
  c: GroupScalar;
10402
10422
  z: GroupScalar;
10403
10423
  }
10424
+ /**
10425
+ * A whole Trust Task request document — `id`, `type`, `issuer`, `payload` and every other member, `proof` included — exactly as the ballot box received it, never re-serialised: its proof is taken over its members, and a re-serialised copy does not reliably reproduce them. Typed as an open object so every member survives; CONVENTIONS §9.6 gives the checks that make it a trustee's step.
10426
+ */
10427
+ export interface SignedRequest {}
10404
10428
  /**
10405
10429
  * One signing-key delegation, as its holder sees it. A delegation confers nothing of its own: it names an identity that already holds whatever standing it holds, and a document signed by the key is authorized by that identity's standing read at execution time.
10406
10430
  */
package/src/index.ts CHANGED
@@ -813,6 +813,7 @@ export * as VtcCommunityRequestedAttributesShow_v0_1 from "./vtc/community/reque
813
813
  export * as VtcCommunityRequestedAttributesUpdate_v0_1 from "./vtc/community/requested-attributes/update/0.1/payload.js";
814
814
  export * as VtcCommunityThemeShow_v0_1 from "./vtc/community/theme/show/0.1/payload.js";
815
815
  export * as VtcCommunityThemeUpdate_v0_1 from "./vtc/community/theme/update/0.1/payload.js";
816
+ export * as VtcConfigDidHostingList_v0_1 from "./vtc/config/did-hosting/list/0.1/payload.js";
816
817
  export * as VtcConfigExport_v0_1 from "./vtc/config/export/0.1/payload.js";
817
818
  export * as VtcConfigImport_v0_1 from "./vtc/config/import/0.1/payload.js";
818
819
  export * as VtcCredentialsReissue_v0_1 from "./vtc/credentials/reissue/0.1/payload.js";
@@ -14,4 +14,4 @@ export interface CommunityVotingSharedDefinitions {
14
14
  * The definitions this shared schema publishes, hoisted to one declaration each.
15
15
  * See "../../../_shared/components.js".
16
16
  */
17
- export type { Answer, Ballot, BoardEntry, BoardHead, BoardVisibility, Cast, Dealing, DecryptionTarget, Disclosure, DisjunctiveProof, ElectionId, ElectionKey, ElectionResult, ElectionState, ElectionSummary, ElGamalCiphertext, EncryptedBallot, EncryptedCast, EncryptedOption, EncryptedQuestion, GroupElement, GroupScalar, Key_VotingV0_1 as Key, Manifest, MerklePath, Multibase_VotingV0_1 as Multibase, PartialDecryption, Question, QuestionOption, QuestionResult, Revote, RollRule, SealedPayload, SealedShare, SecrecyLevel, SigmaProof, TransportKey, TrusteeIndex, TrusteePhase, Trustees, VotingParameters } from "../../../_shared/components.js";
17
+ export type { Answer, Ballot, BoardEntry, BoardHead, BoardVisibility, Cast, Dealing, DecryptionTarget, Disclosure, DisjunctiveProof, ElectionId, ElectionKey, ElectionResult, ElectionState, ElectionSummary, ElGamalCiphertext, EncryptedBallot, EncryptedCast, EncryptedOption, EncryptedQuestion, GroupElement, GroupScalar, Key_VotingV0_1 as Key, Manifest, MerklePath, Multibase_VotingV0_1 as Multibase, PartialDecryption, Question, QuestionOption, QuestionResult, Revote, RollRule, SealedPayload, SealedShare, SecrecyLevel, SigmaProof, SignedRequest, TransportKey, TrusteeIndex, TrusteePhase, Trustees, VotingParameters } from "../../../_shared/components.js";
@@ -3,7 +3,7 @@
3
3
  * Source: specs/voting/board/read/0.1/payload.schema.json
4
4
  */
5
5
 
6
- import type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key_VotingV0_1 as Key, LifecycleEntry, Multibase_VotingV0_1 as Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, UnsealedEntry } from "../../../../_shared/components.js";
6
+ import type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key_VotingV0_1 as Key, LifecycleEntry, Multibase_VotingV0_1 as Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry } from "../../../../_shared/components.js";
7
7
 
8
8
 
9
9
  /**
@@ -51,7 +51,7 @@ export interface VotingBoardReadResponsePayload {
51
51
  }
52
52
 
53
53
  /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
54
- export type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key, LifecycleEntry, Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, UnsealedEntry };
54
+ export type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key, LifecycleEntry, Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry };
55
55
 
56
56
  /** Trust Task type URI. */
57
57
  export const TYPE_URI = "https://trusttasks.org/spec/voting/board/read/0.1" as const;
@@ -296,7 +296,8 @@ export const PAYLOAD_SCHEMA = {
296
296
  "transportKey": {
297
297
  "$ref": "#/$defs/TransportKey"
298
298
  }
299
- }
299
+ },
300
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
300
301
  },
301
302
  {
302
303
  "title": "DealingEntry",
@@ -313,7 +314,8 @@ export const PAYLOAD_SCHEMA = {
313
314
  "dealing": {
314
315
  "$ref": "#/$defs/Dealing"
315
316
  }
316
- }
317
+ },
318
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
317
319
  },
318
320
  {
319
321
  "title": "ConfirmationEntry",
@@ -338,7 +340,8 @@ export const PAYLOAD_SCHEMA = {
338
340
  "$ref": "#/$defs/TrusteeIndex"
339
341
  }
340
342
  }
341
- }
343
+ },
344
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
342
345
  },
343
346
  {
344
347
  "title": "JustificationEntry",
@@ -363,7 +366,8 @@ export const PAYLOAD_SCHEMA = {
363
366
  "share": {
364
367
  "$ref": "#/$defs/GroupScalar"
365
368
  }
366
- }
369
+ },
370
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
367
371
  },
368
372
  {
369
373
  "title": "ElectionKeyEntry",
@@ -448,9 +452,33 @@ export const PAYLOAD_SCHEMA = {
448
452
  "minimum": 0
449
453
  }
450
454
  }
455
+ },
456
+ {
457
+ "title": "TrusteeStepEntry",
458
+ "description": "One step of the trustees' ceremony — an enrolment, a dealing, a confirmation or a justification — as the trustee's own signed request, so that anyone reading the board can tell who took it (CONVENTIONS §9.6).",
459
+ "type": "object",
460
+ "additionalProperties": false,
461
+ "required": [
462
+ "kind",
463
+ "request"
464
+ ],
465
+ "properties": {
466
+ "kind": {
467
+ "const": "trusteeStep"
468
+ },
469
+ "request": {
470
+ "$ref": "#/$defs/SignedRequest"
471
+ }
472
+ }
451
473
  }
452
474
  ]
453
475
  },
476
+ "SignedRequest": {
477
+ "title": "SignedRequest",
478
+ "description": "A whole Trust Task request document — `id`, `type`, `issuer`, `payload` and every other member, `proof` included — exactly as the ballot box received it, never re-serialised: its proof is taken over its members, and a re-serialised copy does not reliably reproduce them. Typed as an open object so every member survives; CONVENTIONS §9.6 gives the checks that make it a trustee's step.",
479
+ "type": "object",
480
+ "minProperties": 1
481
+ },
454
482
  "Ballot": {
455
483
  "title": "Ballot",
456
484
  "description": "An open ballot: one answer per question of the manifest, in any order. The bytes a cast's proof binds are the RFC 8785 (JCS) canonicalization of this object as received.",
@@ -1278,7 +1306,8 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1278
1306
  "transportKey": {
1279
1307
  "$ref": "#/$defs/TransportKey"
1280
1308
  }
1281
- }
1309
+ },
1310
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
1282
1311
  },
1283
1312
  {
1284
1313
  "title": "DealingEntry",
@@ -1295,7 +1324,8 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1295
1324
  "dealing": {
1296
1325
  "$ref": "#/$defs/Dealing"
1297
1326
  }
1298
- }
1327
+ },
1328
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
1299
1329
  },
1300
1330
  {
1301
1331
  "title": "ConfirmationEntry",
@@ -1320,7 +1350,8 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1320
1350
  "$ref": "#/$defs/TrusteeIndex"
1321
1351
  }
1322
1352
  }
1323
- }
1353
+ },
1354
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
1324
1355
  },
1325
1356
  {
1326
1357
  "title": "JustificationEntry",
@@ -1345,7 +1376,8 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1345
1376
  "share": {
1346
1377
  "$ref": "#/$defs/GroupScalar"
1347
1378
  }
1348
- }
1379
+ },
1380
+ "description": "Not appended: each enrolment, dealing, confirmation and justification is a `trusteeStep` entry carrying the trustee's signed request (CONVENTIONS §9.6). A consumer MUST refuse a board holding this kind."
1349
1381
  },
1350
1382
  {
1351
1383
  "title": "ElectionKeyEntry",
@@ -1430,9 +1462,33 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1430
1462
  "minimum": 0
1431
1463
  }
1432
1464
  }
1465
+ },
1466
+ {
1467
+ "title": "TrusteeStepEntry",
1468
+ "description": "One step of the trustees' ceremony — an enrolment, a dealing, a confirmation or a justification — as the trustee's own signed request, so that anyone reading the board can tell who took it (CONVENTIONS §9.6).",
1469
+ "type": "object",
1470
+ "additionalProperties": false,
1471
+ "required": [
1472
+ "kind",
1473
+ "request"
1474
+ ],
1475
+ "properties": {
1476
+ "kind": {
1477
+ "const": "trusteeStep"
1478
+ },
1479
+ "request": {
1480
+ "$ref": "#/$defs/SignedRequest"
1481
+ }
1482
+ }
1433
1483
  }
1434
1484
  ]
1435
1485
  },
1486
+ "SignedRequest": {
1487
+ "title": "SignedRequest",
1488
+ "description": "A whole Trust Task request document — `id`, `type`, `issuer`, `payload` and every other member, `proof` included — exactly as the ballot box received it, never re-serialised: its proof is taken over its members, and a re-serialised copy does not reliably reproduce them. Typed as an open object so every member survives; CONVENTIONS §9.6 gives the checks that make it a trustee's step.",
1489
+ "type": "object",
1490
+ "minProperties": 1
1491
+ },
1436
1492
  "Ballot": {
1437
1493
  "title": "Ballot",
1438
1494
  "description": "An open ballot: one answer per question of the manifest, in any order. The bytes a cast's proof binds are the RFC 8785 (JCS) canonicalization of this object as received.",
@@ -0,0 +1,233 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vtc/config/did-hosting/list/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Ext } from "../../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * List the did:webvh hosting servers the community's VTA can publish its identities through. The outer document members are owned by the framework — SPEC §6.3.
11
+ */
12
+ export interface VTCConfigDIDHostingListPayload {
13
+ ext?: Ext;
14
+ }
15
+ /**
16
+ * The success response to a vtc/config/did-hosting/list/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1#response.
17
+ */
18
+ export interface VTCConfigDIDHostingListResponsePayload {
19
+ /**
20
+ * @maxItems 256
21
+ */
22
+ servers: HostingServer[];
23
+ ext?: Ext;
24
+ }
25
+ /**
26
+ * A did:webvh hosting server registered at the community's VTA, as that VTA reports it. Carries no credential.
27
+ */
28
+ export interface HostingServer {
29
+ /**
30
+ * The server's id at the VTA: the value that names it in the community's configuration.
31
+ */
32
+ id: string;
33
+ /**
34
+ * The server's own DID.
35
+ */
36
+ did: string;
37
+ label?: string;
38
+ }
39
+
40
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
41
+ export type { Ext };
42
+
43
+ /** Trust Task type URI. */
44
+ export const TYPE_URI = "https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1" as const;
45
+
46
+ /** Stable alias for this specification's request payload shape. */
47
+ export type Payload = VTCConfigDIDHostingListPayload;
48
+
49
+ /** Trust Task response type URI (request type URI + "#response"). */
50
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1#response" as const;
51
+
52
+ /** Stable alias for this specification's success-response payload shape. */
53
+ export type Response = VTCConfigDIDHostingListResponsePayload;
54
+
55
+ /**
56
+ * This specification's payload schema, as a value.
57
+ *
58
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
59
+ * rather than only as a `.json` file because TypeScript types are erased
60
+ * at runtime: without a schema a consumer has nothing to validate, and
61
+ * every REQUIRED payload member is optional in practice. Cross-file
62
+ * `$ref`s are already inlined, so it needs no resolver.
63
+ */
64
+ export const PAYLOAD_SCHEMA = {
65
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
66
+ "$id": "https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1",
67
+ "title": "VTC Config — DID Hosting — List — payload",
68
+ "description": "List the did:webvh hosting servers the community's VTA can publish its identities through. The outer document members are owned by the framework — SPEC §6.3.",
69
+ "type": "object",
70
+ "additionalProperties": false,
71
+ "properties": {
72
+ "ext": {
73
+ "$ref": "#/$defs/Ext"
74
+ }
75
+ },
76
+ "$defs": {
77
+ "HostingServer": {
78
+ "title": "HostingServer",
79
+ "description": "A did:webvh hosting server registered at the community's VTA, as that VTA reports it. Carries no credential.",
80
+ "type": "object",
81
+ "additionalProperties": false,
82
+ "required": [
83
+ "id",
84
+ "did"
85
+ ],
86
+ "properties": {
87
+ "id": {
88
+ "type": "string",
89
+ "pattern": "^[A-Za-z0-9._:-]{1,128}$",
90
+ "description": "The server's id at the VTA: the value that names it in the community's configuration."
91
+ },
92
+ "did": {
93
+ "type": "string",
94
+ "pattern": "^did:",
95
+ "maxLength": 2048,
96
+ "description": "The server's own DID."
97
+ },
98
+ "label": {
99
+ "type": "string",
100
+ "maxLength": 256
101
+ }
102
+ }
103
+ },
104
+ "Response": {
105
+ "$anchor": "response",
106
+ "title": "VTC Config — DID Hosting — List — response payload",
107
+ "description": "The success response to a vtc/config/did-hosting/list/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1#response.",
108
+ "type": "object",
109
+ "additionalProperties": false,
110
+ "required": [
111
+ "servers"
112
+ ],
113
+ "properties": {
114
+ "servers": {
115
+ "type": "array",
116
+ "maxItems": 256,
117
+ "items": {
118
+ "$ref": "#/$defs/HostingServer"
119
+ }
120
+ },
121
+ "ext": {
122
+ "$ref": "#/$defs/Ext"
123
+ }
124
+ }
125
+ },
126
+ "Ext": {
127
+ "title": "Ext",
128
+ "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.",
129
+ "type": "object",
130
+ "minProperties": 1,
131
+ "additionalProperties": true,
132
+ "propertyNames": {
133
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
134
+ }
135
+ }
136
+ }
137
+ } as const;
138
+
139
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
140
+ export const RESPONSE_PAYLOAD_SCHEMA = {
141
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
142
+ "$ref": "#/$defs/Response",
143
+ "$defs": {
144
+ "HostingServer": {
145
+ "title": "HostingServer",
146
+ "description": "A did:webvh hosting server registered at the community's VTA, as that VTA reports it. Carries no credential.",
147
+ "type": "object",
148
+ "additionalProperties": false,
149
+ "required": [
150
+ "id",
151
+ "did"
152
+ ],
153
+ "properties": {
154
+ "id": {
155
+ "type": "string",
156
+ "pattern": "^[A-Za-z0-9._:-]{1,128}$",
157
+ "description": "The server's id at the VTA: the value that names it in the community's configuration."
158
+ },
159
+ "did": {
160
+ "type": "string",
161
+ "pattern": "^did:",
162
+ "maxLength": 2048,
163
+ "description": "The server's own DID."
164
+ },
165
+ "label": {
166
+ "type": "string",
167
+ "maxLength": 256
168
+ }
169
+ }
170
+ },
171
+ "Response": {
172
+ "$anchor": "response",
173
+ "title": "VTC Config — DID Hosting — List — response payload",
174
+ "description": "The success response to a vtc/config/did-hosting/list/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/config/did-hosting/list/0.1#response.",
175
+ "type": "object",
176
+ "additionalProperties": false,
177
+ "required": [
178
+ "servers"
179
+ ],
180
+ "properties": {
181
+ "servers": {
182
+ "type": "array",
183
+ "maxItems": 256,
184
+ "items": {
185
+ "$ref": "#/$defs/HostingServer"
186
+ }
187
+ },
188
+ "ext": {
189
+ "$ref": "#/$defs/Ext"
190
+ }
191
+ }
192
+ },
193
+ "Ext": {
194
+ "title": "Ext",
195
+ "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.",
196
+ "type": "object",
197
+ "minProperties": 1,
198
+ "additionalProperties": true,
199
+ "propertyNames": {
200
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
201
+ }
202
+ }
203
+ }
204
+ } as const;
205
+
206
+ /**
207
+ * SPEC.md §7.2 policy for the request variant, from this specification's
208
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
209
+ * per-specification and cannot be derived from the document alone, and
210
+ * item 2 needs the schema this carries.
211
+ */
212
+ export const SPEC = {
213
+ typeUri: TYPE_URI,
214
+ isBearer: false,
215
+ isProofRequired: true,
216
+ isRecipientRequired: true,
217
+ isIssuedAtRequired: true,
218
+ payloadSchema: PAYLOAD_SCHEMA,
219
+ } as const;
220
+
221
+ /**
222
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
223
+ * tracks the *issuer* party's requirement because a response swaps the
224
+ * parties (§7.3 item 5).
225
+ */
226
+ export const RESPONSE_SPEC = {
227
+ typeUri: RESPONSE_TYPE_URI,
228
+ isBearer: false,
229
+ isProofRequired: true,
230
+ isRecipientRequired: true,
231
+ isIssuedAtRequired: true,
232
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
233
+ } as const;
@@ -3,7 +3,7 @@
3
3
  * Source: specs/vtc/elections/show/0.1/payload.schema.json
4
4
  */
5
5
 
6
- import type { BoardHead, BoardVisibility, ChoiceQuestion, DigestMultibase, Disclosure, ElectionId, ElectionResult, Ext, Key_VotingV0_1 as Key, Manifest, Multibase_VotingV0_1 as Multibase, Question, QuestionOption, QuestionResult, RankingQuestion, Revote, RollRule, ScoreQuestion, SecrecyLevel, TextQuestion, Trustees, VotingParameters } from "../../../../_shared/components.js";
6
+ import type { BoardHead, BoardVisibility, ChoiceQuestion, DigestMultibase, Disclosure, ElectionId, ElectionKey, ElectionResult, Ext, GroupElement, Key_VotingV0_1 as Key, Manifest, Multibase_VotingV0_1 as Multibase, Question, QuestionOption, QuestionResult, RankingQuestion, Revote, RollRule, ScoreQuestion, SecrecyLevel, TextQuestion, TrusteeIndex, Trustees, VotingParameters } from "../../../../_shared/components.js";
7
7
 
8
8
 
9
9
  /**
@@ -54,6 +54,10 @@ export interface VTCElectionsShowResponsePayload {
54
54
  * How many tickets the community has issued for the election. Present only to a caller holding vtc.elections.manage.
55
55
  */
56
56
  ticketsIssued?: number;
57
+ /**
58
+ * The key a sealed or tallied-encrypted election's ballots are encrypted under, once its trustees have formed it (CONVENTIONS §9.6).
59
+ */
60
+ electionKey?: ElectionKey;
57
61
  certified?: Certification;
58
62
  ext?: Ext;
59
63
  }
@@ -80,7 +84,7 @@ export interface Certification {
80
84
  }
81
85
 
82
86
  /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
83
- export type { BoardHead, BoardVisibility, ChoiceQuestion, DigestMultibase, Disclosure, ElectionId, ElectionResult, Ext, Key, Manifest, Multibase, Question, QuestionOption, QuestionResult, RankingQuestion, Revote, RollRule, ScoreQuestion, SecrecyLevel, TextQuestion, Trustees, VotingParameters };
87
+ export type { BoardHead, BoardVisibility, ChoiceQuestion, DigestMultibase, Disclosure, ElectionId, ElectionKey, ElectionResult, Ext, GroupElement, Key, Manifest, Multibase, Question, QuestionOption, QuestionResult, RankingQuestion, Revote, RollRule, ScoreQuestion, SecrecyLevel, TextQuestion, TrusteeIndex, Trustees, VotingParameters };
84
88
 
85
89
  /** Trust Task type URI. */
86
90
  export const TYPE_URI = "https://trusttasks.org/spec/vtc/elections/show/0.1" as const;
@@ -231,6 +235,10 @@ export const PAYLOAD_SCHEMA = {
231
235
  "minimum": 0,
232
236
  "description": "How many tickets the community has issued for the election. Present only to a caller holding vtc.elections.manage."
233
237
  },
238
+ "electionKey": {
239
+ "$ref": "#/$defs/ElectionKey",
240
+ "description": "The key a sealed or tallied-encrypted election's ballots are encrypted under, once its trustees have formed it (CONVENTIONS §9.6)."
241
+ },
234
242
  "certified": {
235
243
  "$ref": "#/$defs/Certification",
236
244
  "description": "Present once the community has certified the result."
@@ -250,6 +258,67 @@ export const PAYLOAD_SCHEMA = {
250
258
  "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
251
259
  }
252
260
  },
261
+ "ElectionKey": {
262
+ "title": "ElectionKey",
263
+ "description": "The election key and each trustee's public verification key, computed from the qualified dealings (CONVENTIONS §9.6). Anyone can recompute it from the board.",
264
+ "type": "object",
265
+ "additionalProperties": false,
266
+ "required": [
267
+ "key",
268
+ "qualified",
269
+ "verification"
270
+ ],
271
+ "properties": {
272
+ "key": {
273
+ "$ref": "#/$defs/GroupElement"
274
+ },
275
+ "qualified": {
276
+ "type": "array",
277
+ "minItems": 1,
278
+ "maxItems": 64,
279
+ "items": {
280
+ "$ref": "#/$defs/TrusteeIndex"
281
+ },
282
+ "description": "The dealers whose dealings the key is formed from."
283
+ },
284
+ "verification": {
285
+ "type": "array",
286
+ "minItems": 2,
287
+ "maxItems": 64,
288
+ "items": {
289
+ "type": "object",
290
+ "additionalProperties": false,
291
+ "required": [
292
+ "trustee",
293
+ "key"
294
+ ],
295
+ "properties": {
296
+ "trustee": {
297
+ "$ref": "#/$defs/TrusteeIndex"
298
+ },
299
+ "key": {
300
+ "$ref": "#/$defs/GroupElement"
301
+ }
302
+ }
303
+ }
304
+ }
305
+ }
306
+ },
307
+ "GroupElement": {
308
+ "title": "GroupElement",
309
+ "description": "A Ristretto group element: its 32-byte compression, multibase base58btc. Never the identity (CONVENTIONS §9.1).",
310
+ "type": "string",
311
+ "minLength": 2,
312
+ "maxLength": 64,
313
+ "pattern": "^z[1-9A-HJ-NP-Za-km-z]+$"
314
+ },
315
+ "TrusteeIndex": {
316
+ "title": "TrusteeIndex",
317
+ "description": "A trustee's index: its position in the manifest's `trustees.dids`, counting from 1.",
318
+ "type": "integer",
319
+ "minimum": 1,
320
+ "maximum": 64
321
+ },
253
322
  "Disclosure": {
254
323
  "title": "Disclosure",
255
324
  "description": "The statement a community publishes, and shows a member before they request a ticket, about how one election is run (VTI-VOT-090). Generated from the election's manifest and the community's configuration, never written by hand.",
@@ -993,6 +1062,10 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
993
1062
  "minimum": 0,
994
1063
  "description": "How many tickets the community has issued for the election. Present only to a caller holding vtc.elections.manage."
995
1064
  },
1065
+ "electionKey": {
1066
+ "$ref": "#/$defs/ElectionKey",
1067
+ "description": "The key a sealed or tallied-encrypted election's ballots are encrypted under, once its trustees have formed it (CONVENTIONS §9.6)."
1068
+ },
996
1069
  "certified": {
997
1070
  "$ref": "#/$defs/Certification",
998
1071
  "description": "Present once the community has certified the result."
@@ -1012,6 +1085,67 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
1012
1085
  "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
1013
1086
  }
1014
1087
  },
1088
+ "ElectionKey": {
1089
+ "title": "ElectionKey",
1090
+ "description": "The election key and each trustee's public verification key, computed from the qualified dealings (CONVENTIONS §9.6). Anyone can recompute it from the board.",
1091
+ "type": "object",
1092
+ "additionalProperties": false,
1093
+ "required": [
1094
+ "key",
1095
+ "qualified",
1096
+ "verification"
1097
+ ],
1098
+ "properties": {
1099
+ "key": {
1100
+ "$ref": "#/$defs/GroupElement"
1101
+ },
1102
+ "qualified": {
1103
+ "type": "array",
1104
+ "minItems": 1,
1105
+ "maxItems": 64,
1106
+ "items": {
1107
+ "$ref": "#/$defs/TrusteeIndex"
1108
+ },
1109
+ "description": "The dealers whose dealings the key is formed from."
1110
+ },
1111
+ "verification": {
1112
+ "type": "array",
1113
+ "minItems": 2,
1114
+ "maxItems": 64,
1115
+ "items": {
1116
+ "type": "object",
1117
+ "additionalProperties": false,
1118
+ "required": [
1119
+ "trustee",
1120
+ "key"
1121
+ ],
1122
+ "properties": {
1123
+ "trustee": {
1124
+ "$ref": "#/$defs/TrusteeIndex"
1125
+ },
1126
+ "key": {
1127
+ "$ref": "#/$defs/GroupElement"
1128
+ }
1129
+ }
1130
+ }
1131
+ }
1132
+ }
1133
+ },
1134
+ "GroupElement": {
1135
+ "title": "GroupElement",
1136
+ "description": "A Ristretto group element: its 32-byte compression, multibase base58btc. Never the identity (CONVENTIONS §9.1).",
1137
+ "type": "string",
1138
+ "minLength": 2,
1139
+ "maxLength": 64,
1140
+ "pattern": "^z[1-9A-HJ-NP-Za-km-z]+$"
1141
+ },
1142
+ "TrusteeIndex": {
1143
+ "title": "TrusteeIndex",
1144
+ "description": "A trustee's index: its position in the manifest's `trustees.dids`, counting from 1.",
1145
+ "type": "integer",
1146
+ "minimum": 1,
1147
+ "maximum": 64
1148
+ },
1015
1149
  "Disclosure": {
1016
1150
  "title": "Disclosure",
1017
1151
  "description": "The statement a community publishes, and shows a member before they request a ticket, about how one election is run (VTI-VOT-090). Generated from the election's manifest and the community's configuration, never written by hand.",