@openvtc/trust-tasks 0.26.20 → 0.26.21

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 (211) hide show
  1. package/CHANGELOG.md +75 -0
  2. package/dist/_shared/components.d.ts +327 -16
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/device/list/0.2/payload.d.ts +4 -4
  5. package/dist/device/list/0.2/payload.d.ts.map +1 -1
  6. package/dist/device/list/0.2/payload.js +4 -2
  7. package/dist/device/list/0.2/payload.js.map +1 -1
  8. package/dist/device/register/0.2/payload.d.ts +4 -4
  9. package/dist/device/register/0.2/payload.d.ts.map +1 -1
  10. package/dist/device/register/0.2/payload.js +4 -2
  11. package/dist/device/register/0.2/payload.js.map +1 -1
  12. package/dist/index.d.ts +24 -0
  13. package/dist/index.d.ts.map +1 -1
  14. package/dist/index.js +24 -0
  15. package/dist/index.js.map +1 -1
  16. package/dist/voting/_shared/0.1/voting.d.ts +16 -0
  17. package/dist/voting/_shared/0.1/voting.d.ts.map +1 -0
  18. package/dist/voting/_shared/0.1/voting.js +6 -0
  19. package/dist/voting/_shared/0.1/voting.js.map +1 -0
  20. package/dist/voting/ballot/cast/0.1/payload.d.ts +887 -0
  21. package/dist/voting/ballot/cast/0.1/payload.d.ts.map +1 -0
  22. package/dist/voting/ballot/cast/0.1/payload.js +506 -0
  23. package/dist/voting/ballot/cast/0.1/payload.js.map +1 -0
  24. package/dist/voting/board/consistency/0.1/payload.d.ts +389 -0
  25. package/dist/voting/board/consistency/0.1/payload.d.ts.map +1 -0
  26. package/dist/voting/board/consistency/0.1/payload.js +218 -0
  27. package/dist/voting/board/consistency/0.1/payload.js.map +1 -0
  28. package/dist/voting/board/head/0.1/payload.d.ts +380 -0
  29. package/dist/voting/board/head/0.1/payload.d.ts.map +1 -0
  30. package/dist/voting/board/head/0.1/payload.js +224 -0
  31. package/dist/voting/board/head/0.1/payload.js.map +1 -0
  32. package/dist/voting/board/inclusion/0.1/payload.d.ts +449 -0
  33. package/dist/voting/board/inclusion/0.1/payload.d.ts.map +1 -0
  34. package/dist/voting/board/inclusion/0.1/payload.js +246 -0
  35. package/dist/voting/board/inclusion/0.1/payload.js.map +1 -0
  36. package/dist/voting/board/read/0.1/payload.d.ts +1596 -0
  37. package/dist/voting/board/read/0.1/payload.d.ts.map +1 -0
  38. package/dist/voting/board/read/0.1/payload.js +920 -0
  39. package/dist/voting/board/read/0.1/payload.js.map +1 -0
  40. package/dist/voting/election/cancel/0.1/payload.d.ts +540 -0
  41. package/dist/voting/election/cancel/0.1/payload.d.ts.map +1 -0
  42. package/dist/voting/election/cancel/0.1/payload.js +331 -0
  43. package/dist/voting/election/cancel/0.1/payload.js.map +1 -0
  44. package/dist/voting/election/close/0.1/payload.d.ts +540 -0
  45. package/dist/voting/election/close/0.1/payload.d.ts.map +1 -0
  46. package/dist/voting/election/close/0.1/payload.js +330 -0
  47. package/dist/voting/election/close/0.1/payload.js.map +1 -0
  48. package/dist/voting/election/register/0.1/payload.d.ts +1920 -0
  49. package/dist/voting/election/register/0.1/payload.d.ts.map +1 -0
  50. package/dist/voting/election/register/0.1/payload.js +1166 -0
  51. package/dist/voting/election/register/0.1/payload.js.map +1 -0
  52. package/dist/voting/election/show/0.1/payload.d.ts +1824 -0
  53. package/dist/voting/election/show/0.1/payload.d.ts.map +1 -0
  54. package/dist/voting/election/show/0.1/payload.js +1112 -0
  55. package/dist/voting/election/show/0.1/payload.js.map +1 -0
  56. package/dist/voting/result/show/0.1/payload.d.ts +849 -0
  57. package/dist/voting/result/show/0.1/payload.d.ts.map +1 -0
  58. package/dist/voting/result/show/0.1/payload.js +498 -0
  59. package/dist/voting/result/show/0.1/payload.js.map +1 -0
  60. package/dist/vta/_shared/0.1/app-state-record.d.ts +1 -1
  61. package/dist/vta/_shared/0.1/app-state-record.d.ts.map +1 -1
  62. package/dist/vta/_shared/0.4/pcs-engine.d.ts +1 -1
  63. package/dist/vta/_shared/0.4/pcs-engine.d.ts.map +1 -1
  64. package/dist/vta/app-state/delete/1.0/payload.d.ts +1 -1
  65. package/dist/vta/app-state/delete/1.0/payload.d.ts.map +1 -1
  66. package/dist/vta/app-state/get/1.0/payload.d.ts +1 -1
  67. package/dist/vta/app-state/get/1.0/payload.d.ts.map +1 -1
  68. package/dist/vta/app-state/get-many/1.0/payload.d.ts +1 -1
  69. package/dist/vta/app-state/get-many/1.0/payload.d.ts.map +1 -1
  70. package/dist/vta/app-state/list/1.0/payload.d.ts +1 -1
  71. package/dist/vta/app-state/list/1.0/payload.d.ts.map +1 -1
  72. package/dist/vta/app-state/put/1.0/payload.d.ts +1 -1
  73. package/dist/vta/app-state/put/1.0/payload.d.ts.map +1 -1
  74. package/dist/vta/app-state/put-many/1.0/payload.d.ts +1 -1
  75. package/dist/vta/app-state/put-many/1.0/payload.d.ts.map +1 -1
  76. package/dist/vta/pcs/applications/create/0.1/payload.d.ts +1 -1
  77. package/dist/vta/pcs/applications/create/0.1/payload.d.ts.map +1 -1
  78. package/dist/vta/pcs/applications/show/0.1/payload.d.ts +1 -1
  79. package/dist/vta/pcs/applications/show/0.1/payload.d.ts.map +1 -1
  80. package/dist/vta/pcs/attest/0.1/payload.d.ts +1 -1
  81. package/dist/vta/pcs/attest/0.1/payload.d.ts.map +1 -1
  82. package/dist/vta/pcs/prove/0.1/payload.d.ts +1 -1
  83. package/dist/vta/pcs/prove/0.1/payload.d.ts.map +1 -1
  84. package/dist/vta/pcs/root-accept/0.1/payload.d.ts +1 -1
  85. package/dist/vta/pcs/root-accept/0.1/payload.d.ts.map +1 -1
  86. package/dist/vta/pcs/tokens/abandon/0.1/payload.d.ts +1 -1
  87. package/dist/vta/pcs/tokens/abandon/0.1/payload.d.ts.map +1 -1
  88. package/dist/vta/pcs/tokens/accept/0.1/payload.d.ts +1 -1
  89. package/dist/vta/pcs/tokens/accept/0.1/payload.d.ts.map +1 -1
  90. package/dist/vta/pcs/verify-attestation/0.1/payload.d.ts +1 -1
  91. package/dist/vta/pcs/verify-attestation/0.1/payload.d.ts.map +1 -1
  92. package/dist/vta/pcs/vetter/show/0.1/payload.d.ts +1 -1
  93. package/dist/vta/pcs/vetter/show/0.1/payload.d.ts.map +1 -1
  94. package/dist/vta/pcs/vote/0.1/payload.d.ts +2208 -0
  95. package/dist/vta/pcs/vote/0.1/payload.d.ts.map +1 -0
  96. package/dist/vta/pcs/vote/0.1/payload.js +1282 -0
  97. package/dist/vta/pcs/vote/0.1/payload.js.map +1 -0
  98. package/dist/vta/pcs/voter/accept/0.1/payload.d.ts +450 -0
  99. package/dist/vta/pcs/voter/accept/0.1/payload.d.ts.map +1 -0
  100. package/dist/vta/pcs/voter/accept/0.1/payload.js +247 -0
  101. package/dist/vta/pcs/voter/accept/0.1/payload.js.map +1 -0
  102. package/dist/vta/pcs/voter/receipt/0.1/payload.d.ts +531 -0
  103. package/dist/vta/pcs/voter/receipt/0.1/payload.d.ts.map +1 -0
  104. package/dist/vta/pcs/voter/receipt/0.1/payload.js +301 -0
  105. package/dist/vta/pcs/voter/receipt/0.1/payload.js.map +1 -0
  106. package/dist/vta/pcs/voter/register/0.1/payload.d.ts +1934 -0
  107. package/dist/vta/pcs/voter/register/0.1/payload.d.ts.map +1 -0
  108. package/dist/vta/pcs/voter/register/0.1/payload.js +1133 -0
  109. package/dist/vta/pcs/voter/register/0.1/payload.js.map +1 -0
  110. package/dist/vtc/directory/card/present/0.1/payload.d.ts +2 -2
  111. package/dist/vtc/directory/card/present/0.1/payload.js +1 -1
  112. package/dist/vtc/directory/card/present/0.1/payload.js.map +1 -1
  113. package/dist/vtc/elections/cancel/0.1/payload.d.ts +301 -0
  114. package/dist/vtc/elections/cancel/0.1/payload.d.ts.map +1 -0
  115. package/dist/vtc/elections/cancel/0.1/payload.js +183 -0
  116. package/dist/vtc/elections/cancel/0.1/payload.js.map +1 -0
  117. package/dist/vtc/elections/certify/0.1/payload.d.ts +914 -0
  118. package/dist/vtc/elections/certify/0.1/payload.d.ts.map +1 -0
  119. package/dist/vtc/elections/certify/0.1/payload.js +512 -0
  120. package/dist/vtc/elections/certify/0.1/payload.js.map +1 -0
  121. package/dist/vtc/elections/close/0.1/payload.d.ts +301 -0
  122. package/dist/vtc/elections/close/0.1/payload.d.ts.map +1 -0
  123. package/dist/vtc/elections/close/0.1/payload.js +182 -0
  124. package/dist/vtc/elections/close/0.1/payload.js.map +1 -0
  125. package/dist/vtc/elections/create/0.1/payload.d.ts +1656 -0
  126. package/dist/vtc/elections/create/0.1/payload.d.ts.map +1 -0
  127. package/dist/vtc/elections/create/0.1/payload.js +994 -0
  128. package/dist/vtc/elections/create/0.1/payload.js.map +1 -0
  129. package/dist/vtc/elections/list/0.1/payload.d.ts +521 -0
  130. package/dist/vtc/elections/list/0.1/payload.d.ts.map +1 -0
  131. package/dist/vtc/elections/list/0.1/payload.js +290 -0
  132. package/dist/vtc/elections/list/0.1/payload.js.map +1 -0
  133. package/dist/vtc/elections/show/0.1/payload.d.ts +2688 -0
  134. package/dist/vtc/elections/show/0.1/payload.d.ts.map +1 -0
  135. package/dist/vtc/elections/show/0.1/payload.js +1581 -0
  136. package/dist/vtc/elections/show/0.1/payload.js.map +1 -0
  137. package/dist/vtc/elections/tickets/issue/0.1/payload.d.ts +597 -0
  138. package/dist/vtc/elections/tickets/issue/0.1/payload.d.ts.map +1 -0
  139. package/dist/vtc/elections/tickets/issue/0.1/payload.js +318 -0
  140. package/dist/vtc/elections/tickets/issue/0.1/payload.js.map +1 -0
  141. package/dist/vtc/groups/create/0.1/payload.d.ts +4 -4
  142. package/dist/vtc/groups/create/0.1/payload.js +2 -2
  143. package/dist/vtc/groups/create/0.1/payload.js.map +1 -1
  144. package/dist/vtc/groups/list/0.1/payload.d.ts +4 -4
  145. package/dist/vtc/groups/list/0.1/payload.js +2 -2
  146. package/dist/vtc/groups/list/0.1/payload.js.map +1 -1
  147. package/dist/vtc/groups/managers/add/0.1/payload.d.ts +337 -0
  148. package/dist/vtc/groups/managers/add/0.1/payload.d.ts.map +1 -0
  149. package/dist/vtc/groups/managers/add/0.1/payload.js +184 -0
  150. package/dist/vtc/groups/managers/add/0.1/payload.js.map +1 -0
  151. package/dist/vtc/groups/managers/remove/0.1/payload.d.ts +337 -0
  152. package/dist/vtc/groups/managers/remove/0.1/payload.d.ts.map +1 -0
  153. package/dist/vtc/groups/managers/remove/0.1/payload.js +184 -0
  154. package/dist/vtc/groups/managers/remove/0.1/payload.js.map +1 -0
  155. package/dist/vtc/groups/show/0.1/payload.d.ts +4 -4
  156. package/dist/vtc/groups/show/0.1/payload.js +2 -2
  157. package/dist/vtc/groups/show/0.1/payload.js.map +1 -1
  158. package/dist/vtc/groups/update/0.1/payload.d.ts +4 -4
  159. package/dist/vtc/groups/update/0.1/payload.js +2 -2
  160. package/dist/vtc/groups/update/0.1/payload.js.map +1 -1
  161. package/package.json +1 -1
  162. package/src/_shared/components.ts +330 -16
  163. package/src/device/list/0.2/payload.ts +4 -2
  164. package/src/device/register/0.2/payload.ts +4 -2
  165. package/src/index.ts +24 -0
  166. package/src/voting/_shared/0.1/voting.ts +17 -0
  167. package/src/voting/ballot/cast/0.1/payload.ts +560 -0
  168. package/src/voting/board/consistency/0.1/payload.ts +264 -0
  169. package/src/voting/board/head/0.1/payload.ts +257 -0
  170. package/src/voting/board/inclusion/0.1/payload.ts +300 -0
  171. package/src/voting/board/read/0.1/payload.ts +981 -0
  172. package/src/voting/election/cancel/0.1/payload.ts +368 -0
  173. package/src/voting/election/close/0.1/payload.ts +367 -0
  174. package/src/voting/election/register/0.1/payload.ts +1207 -0
  175. package/src/voting/election/show/0.1/payload.ts +1149 -0
  176. package/src/voting/result/show/0.1/payload.ts +536 -0
  177. package/src/vta/_shared/0.1/app-state-record.ts +1 -1
  178. package/src/vta/_shared/0.4/pcs-engine.ts +1 -1
  179. package/src/vta/app-state/delete/1.0/payload.ts +1 -1
  180. package/src/vta/app-state/get/1.0/payload.ts +1 -1
  181. package/src/vta/app-state/get-many/1.0/payload.ts +1 -1
  182. package/src/vta/app-state/list/1.0/payload.ts +1 -1
  183. package/src/vta/app-state/put/1.0/payload.ts +1 -1
  184. package/src/vta/app-state/put-many/1.0/payload.ts +1 -1
  185. package/src/vta/pcs/applications/create/0.1/payload.ts +1 -1
  186. package/src/vta/pcs/applications/show/0.1/payload.ts +1 -1
  187. package/src/vta/pcs/attest/0.1/payload.ts +1 -1
  188. package/src/vta/pcs/prove/0.1/payload.ts +1 -1
  189. package/src/vta/pcs/root-accept/0.1/payload.ts +1 -1
  190. package/src/vta/pcs/tokens/abandon/0.1/payload.ts +1 -1
  191. package/src/vta/pcs/tokens/accept/0.1/payload.ts +1 -1
  192. package/src/vta/pcs/verify-attestation/0.1/payload.ts +1 -1
  193. package/src/vta/pcs/vetter/show/0.1/payload.ts +1 -1
  194. package/src/vta/pcs/vote/0.1/payload.ts +1365 -0
  195. package/src/vta/pcs/voter/accept/0.1/payload.ts +306 -0
  196. package/src/vta/pcs/voter/receipt/0.1/payload.ts +367 -0
  197. package/src/vta/pcs/voter/register/0.1/payload.ts +1211 -0
  198. package/src/vtc/directory/card/present/0.1/payload.ts +1 -1
  199. package/src/vtc/elections/cancel/0.1/payload.ts +223 -0
  200. package/src/vtc/elections/certify/0.1/payload.ts +565 -0
  201. package/src/vtc/elections/close/0.1/payload.ts +222 -0
  202. package/src/vtc/elections/create/0.1/payload.ts +1041 -0
  203. package/src/vtc/elections/list/0.1/payload.ts +371 -0
  204. package/src/vtc/elections/show/0.1/payload.ts +1671 -0
  205. package/src/vtc/elections/tickets/issue/0.1/payload.ts +394 -0
  206. package/src/vtc/groups/create/0.1/payload.ts +2 -2
  207. package/src/vtc/groups/list/0.1/payload.ts +2 -2
  208. package/src/vtc/groups/managers/add/0.1/payload.ts +230 -0
  209. package/src/vtc/groups/managers/remove/0.1/payload.ts +230 -0
  210. package/src/vtc/groups/show/0.1/payload.ts +2 -2
  211. package/src/vtc/groups/update/0.1/payload.ts +2 -2
package/CHANGELOG.md CHANGED
@@ -11,6 +11,81 @@ The package versions over **its own API** — what a consumer compiles against
11
11
  not over `SPEC.md`. Below 1.0 a breaking change bumps the leading non-zero
12
12
  component.
13
13
 
14
+ ## 0.26.21 — 2026-10-19
15
+
16
+
17
+ ### Added
18
+
19
+ - **voting**: Community voting — voting/* (the ballot box), vtc/elections/* (the registrar) and vta/pcs/voter/* + vta/pcs/vote (the voter's agent) (#834)
20
+
21
+ * feat(voting): community voting — voting/* (the ballot box), vtc/elections/* (the registrar) and vta/pcs/voter/* + vta/pcs/vote (the voter's agent)
22
+
23
+ Twenty-one draft 0.1 tasks for VTI-VOT-001 – 100 (dtgwg-vti-spec, Community
24
+ Voting chapter). A member proves only that they may vote, never who they are,
25
+ and anyone permitted to read the board can recount it.
26
+
27
+ - voting/_shared/0.1: CONVENTIONS.md (separation of registrar and ballot box,
28
+ the exact cryptographic binding — deployment label, ticket class
29
+ voter/<electionId>, hash-to-G1 election point, framed ballot context, cast,
30
+ admission, RFC 9162 board hashing — authorization, VTA custody, privacy,
31
+ shared error local parts, retry safety) and voting.schema.json (Manifest,
32
+ Question, Ballot, Cast, BoardHead, BoardEntry, MerklePath, ElectionResult,
33
+ ElectionSummary, VotingParameters, Disclosure …).
34
+ - voting/*: election/{register,show,close,cancel}, ballot/cast (HTTPS binding
35
+ always accepted, one-time did:key issuer, signed receipt, idempotent),
36
+ board/{head,read,inclusion,consistency}, result/show. 0.1 serves open
37
+ elections only; sealed and tallied-encrypted await the trustee tasks.
38
+ - vtc/elections/*: create (binding elections park for a second
39
+ administrator), list, show (disclosure, kept checkpoints, certified result),
40
+ close, cancel, certify (the VTC verifies the board itself), tickets/issue
41
+ (blind, one per eligible party, recorded before answering).
42
+ - vta/pcs/voter/{register,accept,receipt} and vta/pcs/vote: a voter key per
43
+ election, the blinded ticket request, the signed cast document the client
44
+ sends itself, receipt keeping and inclusion checking. New capability
45
+ `pcsVoter` in device/_shared/0.2 Capability.
46
+
47
+ Bindings regenerated (Rust, TypeScript, Go, Dart); check-bindings agrees and
48
+ the Rust conformance suite passes. Reference implementation of the binding:
49
+ vti-voting in verifiable-trust-infrastructure.
50
+
51
+ - **vtc/groups**: Appointing group managers — vtc/groups/managers/{add,remove}/0.1; create refuses an unserved dynamic group (#833)
52
+
53
+ * feat(vtc/groups): appointing group managers — vtc/groups/managers/{add,remove}/0.1; create refuses an unserved dynamic group
54
+
55
+ The groups family made a manager an access-control resource grant,
56
+ `vtc.groups.manage` qualified `group:<groupId>`, "never this record". But no
57
+ task wrote that grant. The general `acl/grant` caps a grant by the holder's
58
+ role ceiling, so only an administrator could ever manage a group.
59
+
60
+ - vtc/groups/managers/add/0.1: a manager of the group, or a holder of the
61
+ unqualified capability, appoints an active member. The appointment is a
62
+ resource grant on the appointee's entry, delegated by the signer, which sits
63
+ beside the role and never inside its ceiling, so a member with no
64
+ administrative role may hold it. The signer must cover the grant. It is
65
+ reviewed like any delegated grant when its granter departs, and withdrawn
66
+ with the group or the holder's departure. The group's record never decides
67
+ who manages it. Codes: notFound, entryNotFound, alreadyManager.
68
+ - vtc/groups/managers/remove/0.1: a manager steps down, or a holder of the
69
+ unqualified capability removes another manager's appointment. Managers of
70
+ one group do not remove one another. Codes: notFound, notManager.
71
+ - vtc/groups/create: `kindNotServed` lets a community that serves only static
72
+ groups refuse a dynamic one after checking its rule. It never stores a
73
+ dynamic group it does not compute.
74
+ - group.schema.json: `managers` points at the new task.
75
+
76
+
77
+
78
+ ### Fixed
79
+
80
+ - **device**: PcsVoter is appended to Capability, not inserted — no existing variant moves (#835)
81
+ - **vtc/directory/card/present**: A Data Integrity presentation binds through its signed nonce and domain (#831)
82
+
83
+ Producer conformance required a Data Integrity presentation's proof to carry `challenge` equal to the document's `id` and `domain` equal to the community's DID. Neither member is signed by the Data Integrity libraries the implementations use: a proof stating them either fails to verify or carries them unsigned, where they bind nothing. The presentations this ecosystem already produces for a verifier (`vta_sdk::vp::build_di_vp`, the OpenID4VP DI path, the personhood assertion) put `nonce` and `domain` on the presentation itself, which the holder's proof covers.
84
+
85
+ The binding is now the presentation's own `nonce` (this document's `id`) and `domain` (the community's DID), signed by the holder proof; a proof that also states `challenge` or `domain` must state the same values. The consumer's item 3 is unchanged: it verifies "the binding above".
86
+
87
+ No schema change beyond the presentation's description; the generated libraries carry the new text in their documentation.
88
+
14
89
  ## 0.26.20 — 2026-10-19
15
90
 
16
91
 
@@ -385,6 +385,14 @@ export type BindingSpec = RoomBindingSpec | GrantsBindingSpec | RoleBindingSpec;
385
385
  * The name of one blob: the digest of its BlobManifest, taken over the manifest's RFC 8785 (JCS) canonicalization. sha2-256 is RECOMMENDED and MUST be implemented. Content addressing over ciphertext, never plaintext, so a BlobRef says nothing about what the file contains, and two uploads of one file have different BlobRefs (a fresh `fileId` gives a different key, and so different ciphertext). Rooms cannot be correlated by the files they share. Compared as decoded multihash bytes, never as encoded strings. A BlobRef is defined over the manifest's JSON, as this schema states it and RFC 8785 canonicalizes it, never over any binding's generated type: two bindings that model the manifest as distinct types still compute the same BlobRef from the same JSON.
386
386
  */
387
387
  export type BlobRef = DigestMultibase;
388
+ /**
389
+ * One leaf of a board. A leaf's hash is the RFC 9162 leaf hash of the JCS canonicalization of this object. Entries carry no time of arrival: the order is the board's, and a timestamp would hand anyone who reads the board the timing the registrar's log would need to pair a ticket with its cast.
390
+ */
391
+ export type BoardEntry = CastEntry | ReplacementEntry | LifecycleEntry | ResultEntry;
392
+ /**
393
+ * `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).
394
+ */
395
+ export type BoardVisibility = "public" | "private";
388
396
  /**
389
397
  * The control-plane account of a bundle transfer: which algorithm, on what terms, until when. Exactly one of the two shapes — they are mutually exclusive, since StreamDescriptor requires `transportUrl` and `transportToken` and forbids `chunks`, and ChunkedDescriptor requires `chunks` and forbids both.
390
398
  */
@@ -412,7 +420,7 @@ export type Capability_DeviceV0_1 = "vault-read" | "vault-write" | "proxy-login"
412
420
  /**
413
421
  * Fine-grained capability flag scoped to the device's allowed contexts. See SPEC.md for the full semantics of each. Capability values are additive: a consumer MUST ignore a value it does not recognise rather than reject the binding, and MUST NOT treat an unrecognised value as conferring anything.
414
422
  */
415
- export type Capability_DeviceV0_2 = "vaultRead" | "vaultWrite" | "proxyLogin" | "fillRelease" | "policyAdmin" | "deviceAdmin" | "sign" | "keyMint" | "signTrustTask" | "credentialWrite" | "memoryRead" | "memoryWrite" | "roomPresent" | "roomOpen" | "keyExport" | "signSshsig" | "signJws" | "signCsr" | "signDocument" | "externalAccountsManage" | "externalAuthUse" | "pcsVetter" | "pcsApplicant" | "witnessRequest";
423
+ export type Capability_DeviceV0_2 = "vaultRead" | "vaultWrite" | "proxyLogin" | "fillRelease" | "policyAdmin" | "deviceAdmin" | "sign" | "keyMint" | "signTrustTask" | "credentialWrite" | "memoryRead" | "memoryWrite" | "roomPresent" | "roomOpen" | "keyExport" | "signSshsig" | "signJws" | "signCsr" | "signDocument" | "externalAccountsManage" | "externalAuthUse" | "pcsVetter" | "pcsApplicant" | "witnessRequest" | "pcsVoter";
416
424
  /**
417
425
  * Number of chunks in the bundle, equal to ceil(expectedSizeBytes / chunkSize). Bounded at 4096 so that the manifest itself — one digest per chunk — fits in the single document that carries it under the same message-size reasoning as a chunk.
418
426
  */
@@ -564,6 +572,11 @@ export type Duration = string;
564
572
  * Whether the subject is permitted. The ABSENCE of any grant is treated as `deny` (default-deny).
565
573
  */
566
574
  export type Effect_ConsentV0_1 = "allow" | "deny";
575
+ /**
576
+ * An election's identifier, unique within its community. A closed alphabet: it appears in the ticket class label `voter/<electionId>` and is framed into every hash a cast is bound to.
577
+ */
578
+ export type ElectionId = string;
579
+ export type ElectionState = "registered" | "registration" | "voting" | "closed" | "tallied" | "cancelled";
567
580
  /**
568
581
  * The three rights that carry authority over other people's rights: `git.ns.admin`, `git.repo.create` (which makes its holder the owner of every repository they create) and `git.repo.own`. Separation of duties applies to these: nobody grants one to themselves through git-ns/right/grant, or records one for themselves through any other task that grants on the actor's own authority. The explicit self-grant is git-ns/right/break-glass. `git.repo.maintain` and `git.commit.sign` are not elevated.
569
582
  */
@@ -744,10 +757,6 @@ export type JoinRequestId = string;
744
757
  * An optional note from the member to the group's managers. Plain text.
745
758
  */
746
759
  export type JoinRequestMessage = string;
747
- /**
748
- * Application-chosen identifier for a record within a namespace. Opaque to the maintainer: it MUST NOT be parsed, normalized, or case-folded, and prefix matching in `list` is a byte-prefix comparison over the UTF-8 encoding. Applications SHOULD use `/`-delimited hierarchical keys (`community/acme`, `contact/z6Mk…`) so that `prefix` can address a record family, but the delimiter is a convention between an application and itself — the maintainer attaches no meaning to it.
749
- */
750
- export type Key = string;
751
760
  /**
752
761
  * Where the private key came from. `derived` means the maintainer generated it from a seed it holds and can reproduce it from `derivationPath`; `imported` means it arrived from outside and exists only as stored material; `internal` means the maintainer generated it from a CSPRNG and it is reproducible from nothing at all. The distinction is operationally load-bearing: a `derived` key survives a seed restore, an `imported` one is lost unless it was backed up separately, and an `internal` one cannot be recovered by any means once the maintainer's storage is gone. This member is also the only way a consumer can confirm that a `keys/create` request for an `internal` key was honoured rather than silently downgraded to a derived one — see that specification's `internal` member.
753
762
  */
@@ -776,6 +785,14 @@ export type KeyStatus = "active" | "revoked";
776
785
  * Cryptographic algorithm the key material belongs to. `ed25519` signs (EdDSA), `x25519` performs key agreement and never signs, `p256` signs (ES256), and `mldsa44` and `mldsa65` sign with the post-quantum ML-DSA scheme of US NIST FIPS 204. The set is expected to grow as algorithms are standardised, and growing it is a MINOR change under SPEC.md §5.2: `keyType` selects no schema branch, so adding a value relaxes a constraint rather than narrowing one, and the generated libraries mark this enumeration non-exhaustive so that a consumer absorbs a new value rather than failing to compile. Two ML-DSA parameter sets are carried because two specifications require different ones — W3C Quantum-Resistant Cryptosuites defines Data Integrity suites only for ML-DSA-44, while Trust Spanning Protocol Rev 3 §8.1 mandates ML-DSA-65 — so the parameter set is chosen by whatever consumes the key and the two are not redundant. A consumer that does not implement a value it receives MUST refuse the document rather than substitute one it does support.
777
786
  */
778
787
  export type KeyType = "ed25519" | "x25519" | "p256" | "mldsa44" | "mldsa65";
788
+ /**
789
+ * A question or option key, unique within its manifest or question.
790
+ */
791
+ export type Key_VotingV0_1 = string;
792
+ /**
793
+ * Application-chosen identifier for a record within a namespace. Opaque to the maintainer: it MUST NOT be parsed, normalized, or case-folded, and prefix matching in `list` is a byte-prefix comparison over the UTF-8 encoding. Applications SHOULD use `/`-delimited hierarchical keys (`community/acme`, `contact/z6Mk…`) so that `prefix` can address a record family, but the delimiter is a convention between an application and itself — the maintainer attaches no meaning to it.
794
+ */
795
+ export type Key_VtaV0_1 = string;
779
796
  /**
780
797
  * The interaction kind: a 1:1 direct message, a multi-party group, or a broadcast channel.
781
798
  */
@@ -842,14 +859,24 @@ export type MemberState = "offered" | "admitted" | "removed";
842
859
  * How the member came to be in the group. `added`: by a manager. `joined`: they joined an open group. `requestApproved`: a manager approved their request. `rule`: a dynamic group's rule admits them.
843
860
  */
844
861
  export type MembershipSource = "added" | "joined" | "requestApproved" | "rule";
862
+ /**
863
+ * An RFC 9162 audit or consistency path: the node hashes, in the order §2.1.3 / §2.1.4 define.
864
+ *
865
+ * @maxItems 64
866
+ */
867
+ export type MerklePath = DigestMultibase[];
845
868
  /**
846
869
  * How the request reaches the approver. A CLOSED list. Version 0.1 defines `scan`: the starter shows a trigger link (as a QR code that is also a clickable link, TRIGGER-LINK.md) and the approver's wallet reads it. `code` (a typed code of at least 8 characters, under strict rate limits) and `push` (sent to the approver's enrolled devices) are reserved names.
847
870
  */
848
871
  export type Mode = "scan";
872
+ /**
873
+ * A binary value, multibase base58btc over the suite's canonical (compressed) encoding.
874
+ */
875
+ export type Multibase_VotingV0_1 = string;
849
876
  /**
850
877
  * A binary value, multibase base58btc over the suite's canonical encoding.
851
878
  */
852
- export type Multibase = string;
879
+ export type Multibase_VtaV0_4 = string;
853
880
  /**
854
881
  * Scopes one application's records within a context, so several tools can share a context without colliding — `openvtc`, `cnm`, an agent runtime. The maintainer MUST NOT interpret the value; it is an opaque partition name. Namespaces are first-come and unreserved, so an application SHOULD pick a stable, specific one: a future per-namespace ACL would grant on this exact string, which makes renaming a namespace a migration rather than an edit.
855
882
  */
@@ -1157,6 +1184,10 @@ export type Purpose = "login";
1157
1184
  * A device's platform push channel — the body the device registers with its push GATEWAY (push wake-up binding, https://trusttasks.org/binding/push/0.1; modeled on Aries RFC 0699/0734). The gateway holds this token and returns an opaque WakeHandle in exchange; the token is held by the gateway ONLY, never by the mediator or the maintainer/VTA. The gateway uses it to send a contentless wake-up when an authorized trigger asks — the push payload never carries Trust Task content. Tagged union over the discriminator `platform`.
1158
1185
  */
1159
1186
  export type PushRegistration = Apns | Fcm | WebPush;
1187
+ /**
1188
+ * One question. Tagged union over `type`.
1189
+ */
1190
+ export type Question = ChoiceQuestion | RankingQuestion | ScoreQuestion | TextQuestion;
1160
1191
  /**
1161
1192
  * Which of an account's two queues. `receive` holds messages addressed to the account awaiting its pickup. `send` holds messages the account sent that are still held against it until their recipient deletes them — so a stalled recipient fills its senders' send queues.
1162
1193
  */
@@ -1265,6 +1296,10 @@ export type RetentionPolicy = "chained" | "fromJoin";
1265
1296
  * **Tiers.** On a `private` room a host MUST refuse a list carrying a `credential` or `subject` entry: a presentation there withholds the credential and its subject, so such an entry is one the host cannot apply and a disclosure of who was in the room. Only `room` entries are permitted, and a host serving a `private` room MUST refuse any presentation for which it cannot establish that no credential in it has a `validFrom` earlier than the latest `room` entry's `revokedAt`.
1266
1297
  */
1267
1298
  export type RevocationEntry = CredentialRevocation | SubjectRevocation | RoomRevocation;
1299
+ /**
1300
+ * What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).
1301
+ */
1302
+ export type Revote = "replace" | "refuse";
1268
1303
  /**
1269
1304
  * One of the five git rights. Each string is also the TRQP `action` the VTC publishes the right under in its Trust Registry, so it is carried verbatim. `git.ns.admin` and `git.repo.create` apply to a namespace resource; `git.repo.own` and `git.repo.maintain` to a repository resource; `git.commit.sign` to either.
1270
1305
  */
@@ -1343,6 +1378,10 @@ export type SealedEnvelope_VaultV0_2 = DidcommAuthcryptEnvelope_VaultV0_2 | Hpke
1343
1378
  * A sealed-transfer bundle: OpenPGP-style ASCII armor around an HPKE-sealed `SealedPayloadV1` (base mode, X25519-HKDF-SHA256 KEM, HKDF-SHA256 KDF, ChaCha20-Poly1305 AEAD, info string `vta-sealed-transfer/v1`), with a producer assertion and Bundle-Id, Chunk and Digest-Algo headers bound into the associated data. Each task states the key it is sealed to: a single-use wrapping key from keys/import-wrapping-key for external/accounts/secret/set, and the caller's key-agreement key for external/credentials/issue. Its cleartext is an ExternalSecretPayload, an ExternalCredentialPayload or, from external/credentials/issue 0.2 for `s3-static-presign`, a PresignedRequestSet. The only form in which secret material crosses the wire in this family, in either direction: the seal is what keeps a terminating proxy, a relay, a request log or a debug dump of "the response" from ever holding a usable secret, whatever transport carried the document.
1344
1379
  */
1345
1380
  export type SealedTransferBundle = string;
1381
+ /**
1382
+ * `open`: ballots are recorded on the board as cast. `sealed`: ballots are encrypted to a jointly generated election key and decrypted after voting closes. `talliedEncrypted`: ballots are encrypted and only the totals are ever decrypted (VTI-VOT-060). Version 0.1 of the voting tasks carries open ballots only; a ballot box refuses to register any other level with `voting/election/register:unsupportedSecrecy` until the trustee tasks are specified.
1383
+ */
1384
+ export type SecrecyLevel = "open" | "sealed" | "talliedEncrypted";
1346
1385
  /**
1347
1386
  * Which secret is set, without being a way to test guesses at it. `hmacsha256:` followed by the base64url encoding, without padding, of the first 16 bytes of HMAC-SHA256 over the secret's bytes under a fingerprint key the custodian holds and never discloses. Comparable only between fingerprints made by the same custodian: a re-entered value can be confirmed, while the same secret at two custodians gives unrelated fingerprints. Never a bare hash of the secret, which would let anyone who reads it run a dictionary against it offline; and deliberately not a DigestMultibase, since multihash has no code for a keyed digest.
1348
1387
  */
@@ -3936,6 +3975,19 @@ export interface AgentNameEntry {
3936
3975
  createdAt?: number;
3937
3976
  ext?: Ext;
3938
3977
  }
3978
+ /**
3979
+ * The answer to one question. Exactly one member besides `question` is present, matching the question's type, or `abstain` for an optional question left unanswered.
3980
+ */
3981
+ export interface Answer {
3982
+ question: Key_VotingV0_1;
3983
+ choice?: Key_VotingV0_1[];
3984
+ ranking?: Key_VotingV0_1[];
3985
+ scores?: {
3986
+ [k: string]: number | undefined;
3987
+ };
3988
+ text?: string;
3989
+ abstain?: true;
3990
+ }
3939
3991
  /**
3940
3992
  * A record as the maintainer holds it. `value` is absent in three distinct situations and a consumer MUST NOT conflate them: the record is a tombstone (`deleted` is true); the caller asked for a metadata-only view (`list` without `includeValues`); or the value genuinely is the JSON literal `null`, in which case `value` is PRESENT and null. This is why `deleted` is required rather than defaulted — a consumer that has to infer deletion from an absent value gets the tombstone case wrong exactly when convergence depends on it.
3941
3993
  */
@@ -3945,7 +3997,7 @@ export interface AppStateRecord {
3945
3997
  */
3946
3998
  contextId: string;
3947
3999
  namespace: Namespace;
3948
- key: Key;
4000
+ key: Key_VtaV0_1;
3949
4001
  /**
3950
4002
  * The namespace counter value this record's most recent write took. Supply it as `expectedVersion` on the next write to make that write conditional on nothing having changed in between.
3951
4003
  */
@@ -4001,7 +4053,7 @@ export interface ApplicationSummary {
4001
4053
  /**
4002
4054
  * The applicant's PCS identifier: what a vetter attests to, carried in a vetting/request's `ext`.
4003
4055
  */
4004
- id: Multibase;
4056
+ id: Multibase_VtaV0_4;
4005
4057
  /**
4006
4058
  * The metadata of each attestation held, in the order received. Metadata names no vetter.
4007
4059
  */
@@ -4125,7 +4177,7 @@ export interface Attestation {
4125
4177
  /**
4126
4178
  * The attestation: a tag, a shown class credential and a proof. It names no vetter.
4127
4179
  */
4128
- attestation: Multibase;
4180
+ attestation: Multibase_VtaV0_4;
4129
4181
  meta: StatementMeta;
4130
4182
  token: AttestationToken;
4131
4183
  }
@@ -4140,11 +4192,11 @@ export interface AttestationToken {
4140
4192
  /**
4141
4193
  * The serial revealed by the spend.
4142
4194
  */
4143
- serial: Multibase;
4195
+ serial: Multibase_VtaV0_4;
4144
4196
  /**
4145
4197
  * The re-randomised token signature, verifiable under the published token key.
4146
4198
  */
4147
- shown: Multibase;
4199
+ shown: Multibase_VtaV0_4;
4148
4200
  }
4149
4201
  /**
4150
4202
  * One atomic fact a holder keeps about themselves. Several attributes MAY share a `type` — three phone numbers, a legal name and a preferred name — which is why `attributeId` is the identity of a fact and `type` is not. The pool is flat and unordered; ordering is a profile's concern.
@@ -4432,6 +4484,18 @@ export interface BackupEnvelope {
4432
4484
  */
4433
4485
  ciphertext: string;
4434
4486
  }
4487
+ /**
4488
+ * 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.
4489
+ */
4490
+ export interface Ballot {
4491
+ electionId: ElectionId;
4492
+ manifestDigest: DigestMultibase;
4493
+ /**
4494
+ * @minItems 1
4495
+ * @maxItems 128
4496
+ */
4497
+ answers: [Answer, ...Answer[]];
4498
+ }
4435
4499
  /**
4436
4500
  * The ciphertext manifest of one blob, committed by the uploader before any byte moves. Its digest is the BlobRef. Every chunk is checked against `chunks.chunkDigests` on arrival and the reassembled blob against `digest`, so a host can neither accept nor serve bytes the uploader did not commit to. The manifest also appears, by its BlobRef, inside the sealed FileManifest the author signs; a reader who opens the record therefore knows which ciphertext its author meant, and a host cannot substitute a different blob under the same record.
4437
4501
  *
@@ -4450,6 +4514,39 @@ export interface BlobManifest {
4450
4514
  */
4451
4515
  digest: DigestMultibase;
4452
4516
  }
4517
+ export interface CastEntry {
4518
+ kind: "cast";
4519
+ cast: Cast;
4520
+ }
4521
+ /**
4522
+ * The cast at `replaces` is no longer counted: a later cast under the same tag is.
4523
+ */
4524
+ export interface ReplacementEntry {
4525
+ kind: "replaced";
4526
+ tag: Multibase_VotingV0_1;
4527
+ replaces: number;
4528
+ by: number;
4529
+ }
4530
+ export interface LifecycleEntry {
4531
+ kind: "opened" | "closed" | "closedEarly" | "cancelled";
4532
+ at: string;
4533
+ }
4534
+ export interface ResultEntry {
4535
+ kind: "result";
4536
+ result: ElectionResult;
4537
+ }
4538
+ /**
4539
+ * 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.
4540
+ */
4541
+ export interface BoardHead {
4542
+ electionId: ElectionId;
4543
+ treeSize: number;
4544
+ /**
4545
+ * The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash.
4546
+ */
4547
+ rootHash: DigestMultibase;
4548
+ issuedAt: string;
4549
+ }
4453
4550
  /**
4454
4551
  * Whether each step that turns commit trust on for a repository is in place, as last reported. A step that this forge's plan does not need reads `true`.
4455
4552
  */
@@ -4660,6 +4757,14 @@ export interface CardValues {
4660
4757
  */
4661
4758
  export interface CarriedDocument {
4662
4759
  }
4760
+ /**
4761
+ * A ballot and the PCS attestation that admits it (VTI-VOT-030). `attestation` is the suite's canonical encoding of the attestation made for the election point with the ballot context bound in (CONVENTIONS §3); `tag` repeats its tag so a ballot box can refuse a duplicate before the pairing check.
4762
+ */
4763
+ export interface Cast {
4764
+ ballot: Ballot;
4765
+ tag: Multibase_VotingV0_1;
4766
+ attestation: Multibase_VotingV0_1;
4767
+ }
4663
4768
  /**
4664
4769
  * The terms of a `chunkedTrustTask` transfer, committed before any chunk moves. On export the recipient states them in the descriptor; on import the producer pre-commits them in the request and the recipient echoes them. Either way the manifest arrives in a document whose proof is REQUIRED, so the per-chunk digests are authenticated by the party that computed them and each chunk can be verified — and a single bad chunk re-fetched or refused — on arrival rather than only after reassembly.
4665
4770
  *
@@ -5908,6 +6013,31 @@ export interface DisclosedField {
5908
6013
  */
5909
6014
  facet?: boolean;
5910
6015
  }
6016
+ /**
6017
+ * 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.
6018
+ */
6019
+ export interface Disclosure {
6020
+ /**
6021
+ * The ballot box's DID.
6022
+ */
6023
+ ballotBox: string;
6024
+ /**
6025
+ * Who operates the ballot box, as the community names them.
6026
+ */
6027
+ ballotBoxOperator: string;
6028
+ /**
6029
+ * Whether the party operating the community's VTC also operates the ballot box.
6030
+ */
6031
+ sameOperator: boolean;
6032
+ trustees?: Trustees;
6033
+ boardVisibility: BoardVisibility;
6034
+ auditors: string[];
6035
+ revote: Revote;
6036
+ /**
6037
+ * Always false: a voter can prove how they voted, so the community cannot protect a member against being made to vote a certain way.
6038
+ */
6039
+ coercionResistance: false;
6040
+ }
5911
6041
  /**
5912
6042
  * The member's three discoverability decisions, made separately.
5913
6043
  */
@@ -6167,6 +6297,33 @@ export interface EffectiveLimits {
6167
6297
  */
6168
6298
  hostCeilingBytes?: number;
6169
6299
  }
6300
+ /**
6301
+ * An election's result, computable by anyone who can read its board from the board and the registration alone (VTI-VOT-070).
6302
+ */
6303
+ export interface ElectionResult {
6304
+ electionId: ElectionId;
6305
+ manifestDigest: DigestMultibase;
6306
+ ballotsCounted: number;
6307
+ questions: QuestionResult[];
6308
+ /**
6309
+ * The head of the board as it stood at close: the result counts exactly its entries.
6310
+ */
6311
+ head: BoardHead;
6312
+ }
6313
+ /**
6314
+ * A ballot box's view of one election.
6315
+ */
6316
+ export interface ElectionSummary {
6317
+ electionId: ElectionId;
6318
+ community: string;
6319
+ manifestDigest: DigestMultibase;
6320
+ state: ElectionState;
6321
+ /**
6322
+ * Distinct tags with a counted ballot.
6323
+ */
6324
+ ballotsAdmitted: number;
6325
+ head: BoardHead;
6326
+ }
6170
6327
  export interface EncryptionParams {
6171
6328
  /**
6172
6329
  * AEAD identifier, e.g. `aes-256-gcm`.
@@ -6631,7 +6788,7 @@ export interface Group {
6631
6788
  */
6632
6789
  memberCount?: number;
6633
6790
  /**
6634
- * Entries holding `vtc.groups.manage` qualified to this group, read from the access-control list. Informational: managers are appointed by an access-control grant, never by this record.
6791
+ * Entries holding `vtc.groups.manage` qualified to this group, read from the access-control list. Informational: managers are appointed by an access-control grant (vtc/groups/managers/add), never by this record.
6635
6792
  *
6636
6793
  * @maxItems 256
6637
6794
  */
@@ -6715,7 +6872,7 @@ export interface HiddenVettingSubmission {
6715
6872
  /**
6716
6873
  * The applicant's PCS identifier for this application.
6717
6874
  */
6718
- id: Multibase;
6875
+ id: Multibase_VtaV0_4;
6719
6876
  /**
6720
6877
  * The DID the applicant joins as. Bound to `id` by `idBinding`.
6721
6878
  */
@@ -6737,7 +6894,7 @@ export interface HiddenVettingSubmission {
6737
6894
  /**
6738
6895
  * The issuance proof, which carries the attestations.
6739
6896
  */
6740
- proof: Multibase;
6897
+ proof: Multibase_VtaV0_4;
6741
6898
  }
6742
6899
  /**
6743
6900
  * One histogram's distribution, in the Prometheus cumulative-bucket convention: each bucket's `count` includes every observation at or below its `le`.
@@ -7200,6 +7357,51 @@ export interface LocalSettings {
7200
7357
  */
7201
7358
  root: string;
7202
7359
  }
7360
+ /**
7361
+ * What an election asks and how it is decided (VTI-VOT-010). Its digest (`manifestDigest`) is the SHA-256 multihash of its RFC 8785 (JCS) canonicalization, and every cast is bound to it (VTI-VOT-011).
7362
+ */
7363
+ export interface Manifest {
7364
+ electionId: ElectionId;
7365
+ /**
7366
+ * The community's DID.
7367
+ */
7368
+ community: string;
7369
+ title?: string;
7370
+ description?: string;
7371
+ /**
7372
+ * @minItems 1
7373
+ * @maxItems 128
7374
+ */
7375
+ questions: [Question, ...Question[]];
7376
+ secrecy: SecrecyLevel;
7377
+ roll: RollRule;
7378
+ registrationOpens: string;
7379
+ votingOpens: string;
7380
+ votingCloses: string;
7381
+ revote: Revote;
7382
+ board: {
7383
+ visibility: BoardVisibility;
7384
+ auditors: string[];
7385
+ };
7386
+ /**
7387
+ * The DID of the voting service that holds the board.
7388
+ */
7389
+ ballotBox: string;
7390
+ trustees?: Trustees;
7391
+ /**
7392
+ * Whether the community treats the result as deciding something; creating a binding election takes another administrator's consent (VTI-VOT-081).
7393
+ */
7394
+ binding: boolean;
7395
+ allowEarlyClose: boolean;
7396
+ /**
7397
+ * Open elections only: whether running totals may be read while voting is open (VTI-VOT-061).
7398
+ */
7399
+ resultsBeforeClose: boolean;
7400
+ /**
7401
+ * Counted ballots required before any text answer is disclosed (VTI-VOT-065).
7402
+ */
7403
+ textReleaseThreshold: number;
7404
+ }
7203
7405
  /**
7204
7406
  * The mediator's per-account access-control capability set, expressed as named booleans (the transport-agnostic form of the mediator's internal capability flags). On a set request, members omitted are left unchanged; a get/response carries the full realized set.
7205
7407
  */
@@ -8212,6 +8414,91 @@ export interface QueryContext {
8212
8414
  locator?: string;
8213
8415
  [k: string]: string | undefined;
8214
8416
  }
8417
+ /**
8418
+ * Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.
8419
+ */
8420
+ export interface ChoiceQuestion {
8421
+ key: Key_VotingV0_1;
8422
+ type: "choice";
8423
+ text?: string;
8424
+ /**
8425
+ * @minItems 2
8426
+ * @maxItems 256
8427
+ */
8428
+ options: [QuestionOption, QuestionOption, ...QuestionOption[]];
8429
+ minSelections: number;
8430
+ maxSelections: number;
8431
+ optional: boolean;
8432
+ }
8433
+ /**
8434
+ * Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.
8435
+ */
8436
+ export interface RankingQuestion {
8437
+ key: Key_VotingV0_1;
8438
+ type: "ranking";
8439
+ text?: string;
8440
+ /**
8441
+ * @minItems 2
8442
+ * @maxItems 64
8443
+ */
8444
+ options: [QuestionOption, QuestionOption, ...QuestionOption[]];
8445
+ partial: boolean;
8446
+ optional: boolean;
8447
+ }
8448
+ /**
8449
+ * Give each option an integer score within [min, max].
8450
+ */
8451
+ export interface ScoreQuestion {
8452
+ key: Key_VotingV0_1;
8453
+ type: "score";
8454
+ text?: string;
8455
+ /**
8456
+ * @minItems 1
8457
+ * @maxItems 256
8458
+ */
8459
+ options: [QuestionOption, ...QuestionOption[]];
8460
+ min: number;
8461
+ max: number;
8462
+ optional: boolean;
8463
+ }
8464
+ /**
8465
+ * Free text of at most `maxLength` characters.
8466
+ */
8467
+ export interface TextQuestion {
8468
+ key: Key_VotingV0_1;
8469
+ type: "text";
8470
+ text?: string;
8471
+ maxLength: number;
8472
+ optional: boolean;
8473
+ }
8474
+ export interface QuestionOption {
8475
+ key: Key_VotingV0_1;
8476
+ /**
8477
+ * Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014).
8478
+ */
8479
+ label?: string;
8480
+ }
8481
+ /**
8482
+ * One question's totals. `choice`: selections per option. `ranking`: per option, how many ballots placed it at each position (index 0 = first). `score`: per option, the sum and the number of ballots that scored it. `text`: the answers, in board order, withheld (`withheld: true`) below the manifest's `textReleaseThreshold`. `abstained` counts ballots that left the question unanswered.
8483
+ */
8484
+ export interface QuestionResult {
8485
+ question: Key_VotingV0_1;
8486
+ abstained: number;
8487
+ choice?: {
8488
+ [k: string]: number | undefined;
8489
+ };
8490
+ ranking?: {
8491
+ [k: string]: number[] | undefined;
8492
+ };
8493
+ score?: {
8494
+ [k: string]: {
8495
+ sum: number;
8496
+ count: number;
8497
+ } | undefined;
8498
+ };
8499
+ text?: string[];
8500
+ withheld?: boolean;
8501
+ }
8215
8502
  /**
8216
8503
  * The depth of one queue and its effective limit.
8217
8504
  */
@@ -8864,6 +9151,13 @@ export interface RoleSummary {
8864
9151
  */
8865
9152
  preRotationCommitments?: number;
8866
9153
  }
9154
+ /**
9155
+ * Who may be issued a ticket (VTI-VOT-021): the community's active members, its active members and the parties `listed` names, or only the parties `listed` names.
9156
+ */
9157
+ export interface RollRule {
9158
+ rule: "members" | "membersAndListed" | "listed";
9159
+ listed?: string[];
9160
+ }
8867
9161
  /**
8868
9162
  * The outcome of a rollback. Distinct from ServiceMutationResult because a rollback can legitimately publish nothing: if the previous state already equals the current one there is no change to write, and `kind: "noOp"` says so with `logEntryVersionId` absent. Treating that as a failure would be wrong — the requested state holds — and treating it as an ordinary success would report a log entry that does not exist.
8869
9163
  */
@@ -10017,6 +10311,16 @@ export interface TrustRecord {
10017
10311
  };
10018
10312
  record_type: RecordType;
10019
10313
  }
10314
+ /**
10315
+ * The trustees of a sealed or tallied-encrypted election and the number of them decryption needs (VTI-VOT-062). Neither the community nor the ballot box may be one.
10316
+ */
10317
+ export interface Trustees {
10318
+ /**
10319
+ * @minItems 2
10320
+ */
10321
+ dids: [string, string, ...string[]];
10322
+ threshold: number;
10323
+ }
10020
10324
  /**
10021
10325
  * Trust Spanning Protocol message (https://trustoverip.github.io/tswg-tsp-specification/). Reserved variant; no OpenVTC component reads or emits this today. Listed in the union so implementations can declare intent to use TSP in discovery and so consumers reject `tsp-message` envelopes explicitly (`envelopeUnsupported`) until they're wired up — rather than silently failing in DIDComm parsing.
10022
10326
  */
@@ -10477,7 +10781,7 @@ export interface VetterSummary {
10477
10781
  /**
10478
10782
  * The vetter's PCS identifier for this community.
10479
10783
  */
10480
- id: Multibase;
10784
+ id: Multibase_VtaV0_4;
10481
10785
  /**
10482
10786
  * Class labels this vetter holds a credential under, newest first.
10483
10787
  */
@@ -10656,6 +10960,13 @@ export interface VettingRequirements {
10656
10960
  extCritical?: ExtCritical;
10657
10961
  [k: string]: unknown | undefined;
10658
10962
  }
10963
+ /**
10964
+ * The community's published voting parameters: the PCS suite and the voting verification key tickets are issued under (VTI-VOT-020). Distinct from its hidden-vetting helper key.
10965
+ */
10966
+ export interface VotingParameters {
10967
+ suite: "ps-ddh-bls12381";
10968
+ votingKey: Multibase_VotingV0_1;
10969
+ }
10659
10970
  /**
10660
10971
  * An opaque, gateway-issued reference to a device's push channel (push wake-up binding, https://trusttasks.org/binding/push/0.1). The push gateway returns it to the device at registration; the device conveys it to its VTA (device/set-wake), and the VTA provisions it to authorized triggers (its mediator and/or itself). The raw platform push token (APNs/FCM/WebPush) is held ONLY by the gateway and is never represented here — the handle abstracts the platform, so adding new push methods (e.g. PWA Web Push) needs no change to triggers or VTA config. A handle is a bearer capability to *request* a wake (subject to the gateway's allowlist), never to read the channel.
10661
10972
  */
@@ -10781,7 +11092,7 @@ export interface WitnessKey {
10781
11092
  * The outcome of one write within a `vta/app-state/put-many` batch. Per-record rather than per-batch, because the default batch mode applies each write on its own merits: a caller flushing ten unrelated edits needs to know which one conflicted, not merely that something did.
10782
11093
  */
10783
11094
  export interface WriteResult {
10784
- key: Key;
11095
+ key: Key_VtaV0_1;
10785
11096
  /**
10786
11097
  * `written`: applied, and `version` carries the new value. `conflict`: `expectedVersion` did not match; `currentVersion`, `currentValue` and `currentDeleted` carry the maintainer's view so the caller can resolve without a re-read. `tooLarge`: the value exceeded the per-record cap; `limitBytes` and `actualBytes` say by how much. `notFound`: a `mergePatch` write named an address with no live record. `skipped`: atomic mode only — this write was not attempted because another in the batch failed.
10787
11098
  */