@openvtc/trust-tasks 0.28.8 → 0.28.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (374) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/dist/_extends.d.ts.map +1 -1
  3. package/dist/_extends.js +5 -0
  4. package/dist/_extends.js.map +1 -1
  5. package/dist/_shared/components.d.ts +288 -0
  6. package/dist/_shared/components.d.ts.map +1 -1
  7. package/dist/index.d.ts +117 -0
  8. package/dist/index.d.ts.map +1 -1
  9. package/dist/index.js +117 -0
  10. package/dist/index.js.map +1 -1
  11. package/dist/notifications/_shared/0.1/notification.d.ts +22 -0
  12. package/dist/notifications/_shared/0.1/notification.d.ts.map +1 -0
  13. package/dist/notifications/_shared/0.1/notification.js +6 -0
  14. package/dist/notifications/_shared/0.1/notification.js.map +1 -0
  15. package/dist/notifications/notify/0.1/payload.d.ts +652 -0
  16. package/dist/notifications/notify/0.1/payload.d.ts.map +1 -0
  17. package/dist/notifications/notify/0.1/payload.js +383 -0
  18. package/dist/notifications/notify/0.1/payload.js.map +1 -0
  19. package/dist/notifications/relay/0.1/payload.d.ts +309 -0
  20. package/dist/notifications/relay/0.1/payload.d.ts.map +1 -0
  21. package/dist/notifications/relay/0.1/payload.js +179 -0
  22. package/dist/notifications/relay/0.1/payload.js.map +1 -0
  23. package/dist/voting/_shared/0.4/voting.d.ts +16 -0
  24. package/dist/voting/_shared/0.4/voting.d.ts.map +1 -0
  25. package/dist/voting/_shared/0.4/voting.js +6 -0
  26. package/dist/voting/_shared/0.4/voting.js.map +1 -0
  27. package/dist/voting/election/register/0.1/payload.d.ts +4 -4
  28. package/dist/voting/election/register/0.1/payload.js +1 -1
  29. package/dist/voting/election/register/0.2/payload.d.ts +4 -4
  30. package/dist/voting/election/register/0.2/payload.js +1 -1
  31. package/dist/voting/election/register/0.3/payload.d.ts +13 -2
  32. package/dist/voting/election/register/0.3/payload.d.ts.map +1 -1
  33. package/dist/voting/election/register/0.3/payload.js +1 -1
  34. package/dist/voting/election/register/0.3/payload.js.map +1 -1
  35. package/dist/voting/election/register/0.4/payload.d.ts +2054 -0
  36. package/dist/voting/election/register/0.4/payload.d.ts.map +1 -0
  37. package/dist/voting/election/register/0.4/payload.js +1264 -0
  38. package/dist/voting/election/register/0.4/payload.js.map +1 -0
  39. package/dist/voting/election/show/0.1/payload.d.ts +4 -4
  40. package/dist/voting/election/show/0.1/payload.js +1 -1
  41. package/dist/voting/election/show/0.2/payload.d.ts +4 -4
  42. package/dist/voting/election/show/0.2/payload.js +1 -1
  43. package/dist/voting/election/show/0.3/payload.d.ts +13 -2
  44. package/dist/voting/election/show/0.3/payload.d.ts.map +1 -1
  45. package/dist/voting/election/show/0.3/payload.js +1 -1
  46. package/dist/voting/election/show/0.3/payload.js.map +1 -1
  47. package/dist/voting/election/show/0.4/payload.d.ts +1958 -0
  48. package/dist/voting/election/show/0.4/payload.d.ts.map +1 -0
  49. package/dist/voting/election/show/0.4/payload.js +1210 -0
  50. package/dist/voting/election/show/0.4/payload.js.map +1 -0
  51. package/dist/vta/notifications/_shared/0.1/held-notification.d.ts +16 -0
  52. package/dist/vta/notifications/_shared/0.1/held-notification.d.ts.map +1 -0
  53. package/dist/vta/notifications/_shared/0.1/held-notification.js +6 -0
  54. package/dist/vta/notifications/_shared/0.1/held-notification.js.map +1 -0
  55. package/dist/vta/notifications/dismiss/0.1/payload.d.ts +300 -0
  56. package/dist/vta/notifications/dismiss/0.1/payload.d.ts.map +1 -0
  57. package/dist/vta/notifications/dismiss/0.1/payload.js +179 -0
  58. package/dist/vta/notifications/dismiss/0.1/payload.js.map +1 -0
  59. package/dist/vta/notifications/list/0.1/payload.d.ts +1100 -0
  60. package/dist/vta/notifications/list/0.1/payload.d.ts.map +1 -0
  61. package/dist/vta/notifications/list/0.1/payload.js +627 -0
  62. package/dist/vta/notifications/list/0.1/payload.js.map +1 -0
  63. package/dist/vta/notifications/show/0.1/payload.d.ts +1004 -0
  64. package/dist/vta/notifications/show/0.1/payload.d.ts.map +1 -0
  65. package/dist/vta/notifications/show/0.1/payload.js +595 -0
  66. package/dist/vta/notifications/show/0.1/payload.js.map +1 -0
  67. package/dist/vta/pcs/trustee/deal/0.2/payload.d.ts +4 -4
  68. package/dist/vta/pcs/trustee/deal/0.2/payload.js +1 -1
  69. package/dist/vta/pcs/trustee/deal/0.3/payload.d.ts +4 -4
  70. package/dist/vta/pcs/trustee/deal/0.3/payload.js +1 -1
  71. package/dist/vta/pcs/trustee/deal/0.4/payload.d.ts +13 -2
  72. package/dist/vta/pcs/trustee/deal/0.4/payload.d.ts.map +1 -1
  73. package/dist/vta/pcs/trustee/deal/0.4/payload.js +1 -1
  74. package/dist/vta/pcs/trustee/deal/0.4/payload.js.map +1 -1
  75. package/dist/vta/pcs/trustee/deal/0.5/payload.d.ts +1966 -0
  76. package/dist/vta/pcs/trustee/deal/0.5/payload.d.ts.map +1 -0
  77. package/dist/vta/pcs/trustee/deal/0.5/payload.js +1175 -0
  78. package/dist/vta/pcs/trustee/deal/0.5/payload.js.map +1 -0
  79. package/dist/vta/pcs/trustee/enrol/0.1/payload.d.ts +4 -4
  80. package/dist/vta/pcs/trustee/enrol/0.1/payload.js +1 -1
  81. package/dist/vta/pcs/trustee/enrol/0.2/payload.d.ts +4 -4
  82. package/dist/vta/pcs/trustee/enrol/0.2/payload.js +1 -1
  83. package/dist/vta/pcs/trustee/enrol/0.3/payload.d.ts +13 -2
  84. package/dist/vta/pcs/trustee/enrol/0.3/payload.d.ts.map +1 -1
  85. package/dist/vta/pcs/trustee/enrol/0.3/payload.js +1 -1
  86. package/dist/vta/pcs/trustee/enrol/0.3/payload.js.map +1 -1
  87. package/dist/vta/pcs/trustee/enrol/0.4/payload.d.ts +1890 -0
  88. package/dist/vta/pcs/trustee/enrol/0.4/payload.d.ts.map +1 -0
  89. package/dist/vta/pcs/trustee/enrol/0.4/payload.js +1138 -0
  90. package/dist/vta/pcs/trustee/enrol/0.4/payload.js.map +1 -0
  91. package/dist/vta/pcs/trustee/justify/0.2/payload.d.ts +4 -4
  92. package/dist/vta/pcs/trustee/justify/0.2/payload.js +1 -1
  93. package/dist/vta/pcs/trustee/justify/0.3/payload.d.ts +4 -4
  94. package/dist/vta/pcs/trustee/justify/0.3/payload.js +1 -1
  95. package/dist/vta/pcs/trustee/justify/0.4/payload.d.ts +13 -2
  96. package/dist/vta/pcs/trustee/justify/0.4/payload.d.ts.map +1 -1
  97. package/dist/vta/pcs/trustee/justify/0.4/payload.js +1 -1
  98. package/dist/vta/pcs/trustee/justify/0.4/payload.js.map +1 -1
  99. package/dist/vta/pcs/trustee/justify/0.5/payload.d.ts +2001 -0
  100. package/dist/vta/pcs/trustee/justify/0.5/payload.d.ts.map +1 -0
  101. package/dist/vta/pcs/trustee/justify/0.5/payload.js +1193 -0
  102. package/dist/vta/pcs/trustee/justify/0.5/payload.js.map +1 -0
  103. package/dist/vta/pcs/trustee/keys/0.2/payload.d.ts +4 -4
  104. package/dist/vta/pcs/trustee/keys/0.2/payload.js +1 -1
  105. package/dist/vta/pcs/trustee/keys/0.3/payload.d.ts +4 -4
  106. package/dist/vta/pcs/trustee/keys/0.3/payload.js +1 -1
  107. package/dist/vta/pcs/trustee/keys/0.4/payload.d.ts +13 -2
  108. package/dist/vta/pcs/trustee/keys/0.4/payload.d.ts.map +1 -1
  109. package/dist/vta/pcs/trustee/keys/0.4/payload.js +1 -1
  110. package/dist/vta/pcs/trustee/keys/0.4/payload.js.map +1 -1
  111. package/dist/vta/pcs/trustee/keys/0.5/payload.d.ts +2046 -0
  112. package/dist/vta/pcs/trustee/keys/0.5/payload.d.ts.map +1 -0
  113. package/dist/vta/pcs/trustee/keys/0.5/payload.js +1213 -0
  114. package/dist/vta/pcs/trustee/keys/0.5/payload.js.map +1 -0
  115. package/dist/vta/pcs/trustee/read/0.1/payload.d.ts +4 -4
  116. package/dist/vta/pcs/trustee/read/0.1/payload.js +1 -1
  117. package/dist/vta/pcs/trustee/read/0.2/payload.d.ts +4 -4
  118. package/dist/vta/pcs/trustee/read/0.2/payload.js +1 -1
  119. package/dist/vta/pcs/trustee/read/0.3/payload.d.ts +14 -2
  120. package/dist/vta/pcs/trustee/read/0.3/payload.d.ts.map +1 -1
  121. package/dist/vta/pcs/trustee/read/0.3/payload.js +1 -1
  122. package/dist/vta/pcs/trustee/read/0.3/payload.js.map +1 -1
  123. package/dist/vta/pcs/trustee/read/0.4/payload.d.ts +540 -0
  124. package/dist/vta/pcs/trustee/read/0.4/payload.d.ts.map +1 -0
  125. package/dist/vta/pcs/trustee/read/0.4/payload.js +304 -0
  126. package/dist/vta/pcs/trustee/read/0.4/payload.js.map +1 -0
  127. package/dist/vta/pcs/vote/0.1/payload.d.ts +4 -4
  128. package/dist/vta/pcs/vote/0.1/payload.js +1 -1
  129. package/dist/vta/pcs/vote/0.2/payload.d.ts +4 -4
  130. package/dist/vta/pcs/vote/0.2/payload.js +1 -1
  131. package/dist/vta/pcs/vote/0.3/payload.d.ts +13 -2
  132. package/dist/vta/pcs/vote/0.3/payload.d.ts.map +1 -1
  133. package/dist/vta/pcs/vote/0.3/payload.js +1 -1
  134. package/dist/vta/pcs/vote/0.3/payload.js.map +1 -1
  135. package/dist/vta/pcs/vote/0.4/payload.d.ts +2342 -0
  136. package/dist/vta/pcs/vote/0.4/payload.d.ts.map +1 -0
  137. package/dist/vta/pcs/vote/0.4/payload.js +1380 -0
  138. package/dist/vta/pcs/vote/0.4/payload.js.map +1 -0
  139. package/dist/vta/pcs/vote-encrypted/0.2/payload.d.ts +4 -4
  140. package/dist/vta/pcs/vote-encrypted/0.2/payload.js +1 -1
  141. package/dist/vta/pcs/vote-encrypted/0.3/payload.d.ts +4 -4
  142. package/dist/vta/pcs/vote-encrypted/0.3/payload.js +1 -1
  143. package/dist/vta/pcs/vote-encrypted/0.4/payload.d.ts +13 -2
  144. package/dist/vta/pcs/vote-encrypted/0.4/payload.d.ts.map +1 -1
  145. package/dist/vta/pcs/vote-encrypted/0.4/payload.js +1 -1
  146. package/dist/vta/pcs/vote-encrypted/0.4/payload.js.map +1 -1
  147. package/dist/vta/pcs/vote-encrypted/0.5/payload.d.ts +2362 -0
  148. package/dist/vta/pcs/vote-encrypted/0.5/payload.d.ts.map +1 -0
  149. package/dist/vta/pcs/vote-encrypted/0.5/payload.js +1398 -0
  150. package/dist/vta/pcs/vote-encrypted/0.5/payload.js.map +1 -0
  151. package/dist/vta/pcs/voter/accept/0.1/payload.d.ts +3 -3
  152. package/dist/vta/pcs/voter/accept/0.1/payload.js +1 -1
  153. package/dist/vta/pcs/voter/read/0.1/payload.d.ts +4 -4
  154. package/dist/vta/pcs/voter/read/0.1/payload.js +1 -1
  155. package/dist/vta/pcs/voter/read/0.2/payload.d.ts +4 -4
  156. package/dist/vta/pcs/voter/read/0.2/payload.js +1 -1
  157. package/dist/vta/pcs/voter/read/0.3/payload.d.ts +14 -2
  158. package/dist/vta/pcs/voter/read/0.3/payload.d.ts.map +1 -1
  159. package/dist/vta/pcs/voter/read/0.3/payload.js +1 -1
  160. package/dist/vta/pcs/voter/read/0.3/payload.js.map +1 -1
  161. package/dist/vta/pcs/voter/read/0.4/payload.d.ts +515 -0
  162. package/dist/vta/pcs/voter/read/0.4/payload.d.ts.map +1 -0
  163. package/dist/vta/pcs/voter/read/0.4/payload.js +285 -0
  164. package/dist/vta/pcs/voter/read/0.4/payload.js.map +1 -0
  165. package/dist/vta/pcs/voter/read/0.5/payload.d.ts +549 -0
  166. package/dist/vta/pcs/voter/read/0.5/payload.d.ts.map +1 -0
  167. package/dist/vta/pcs/voter/read/0.5/payload.js +300 -0
  168. package/dist/vta/pcs/voter/read/0.5/payload.js.map +1 -0
  169. package/dist/vta/pcs/voter/read/0.6/payload.d.ts +561 -0
  170. package/dist/vta/pcs/voter/read/0.6/payload.d.ts.map +1 -0
  171. package/dist/vta/pcs/voter/read/0.6/payload.js +312 -0
  172. package/dist/vta/pcs/voter/read/0.6/payload.js.map +1 -0
  173. package/dist/vta/pcs/voter/register/0.1/payload.d.ts +4 -4
  174. package/dist/vta/pcs/voter/register/0.1/payload.js +1 -1
  175. package/dist/vta/pcs/voter/register/0.2/payload.d.ts +4 -4
  176. package/dist/vta/pcs/voter/register/0.2/payload.js +1 -1
  177. package/dist/vta/pcs/voter/register/0.3/payload.d.ts +14 -2
  178. package/dist/vta/pcs/voter/register/0.3/payload.d.ts.map +1 -1
  179. package/dist/vta/pcs/voter/register/0.3/payload.js +1 -1
  180. package/dist/vta/pcs/voter/register/0.3/payload.js.map +1 -1
  181. package/dist/vta/pcs/voter/register/0.4/payload.d.ts +2324 -0
  182. package/dist/vta/pcs/voter/register/0.4/payload.d.ts.map +1 -0
  183. package/dist/vta/pcs/voter/register/0.4/payload.js +1352 -0
  184. package/dist/vta/pcs/voter/register/0.4/payload.js.map +1 -0
  185. package/dist/vta/pcs/voter/register/0.5/payload.d.ts +2312 -0
  186. package/dist/vta/pcs/voter/register/0.5/payload.d.ts.map +1 -0
  187. package/dist/vta/pcs/voter/register/0.5/payload.js +1352 -0
  188. package/dist/vta/pcs/voter/register/0.5/payload.js.map +1 -0
  189. package/dist/vtc/_shared/0.6/network-membership.d.ts +16 -0
  190. package/dist/vtc/_shared/0.6/network-membership.d.ts.map +1 -0
  191. package/dist/vtc/_shared/0.6/network-membership.js +6 -0
  192. package/dist/vtc/_shared/0.6/network-membership.js.map +1 -0
  193. package/dist/vtc/elections/create/0.1/payload.d.ts +4 -4
  194. package/dist/vtc/elections/create/0.1/payload.js +1 -1
  195. package/dist/vtc/elections/create/0.2/payload.d.ts +4 -4
  196. package/dist/vtc/elections/create/0.2/payload.js +1 -1
  197. package/dist/vtc/elections/create/0.3/payload.d.ts +4 -4
  198. package/dist/vtc/elections/create/0.3/payload.js +1 -1
  199. package/dist/vtc/elections/create/0.4/payload.d.ts +14 -2
  200. package/dist/vtc/elections/create/0.4/payload.d.ts.map +1 -1
  201. package/dist/vtc/elections/create/0.4/payload.js +1 -1
  202. package/dist/vtc/elections/create/0.4/payload.js.map +1 -1
  203. package/dist/vtc/elections/create/0.5/payload.d.ts +1790 -0
  204. package/dist/vtc/elections/create/0.5/payload.d.ts.map +1 -0
  205. package/dist/vtc/elections/create/0.5/payload.js +1092 -0
  206. package/dist/vtc/elections/create/0.5/payload.js.map +1 -0
  207. package/dist/vtc/elections/list/0.1/payload.d.ts +4 -4
  208. package/dist/vtc/elections/list/0.1/payload.js +1 -1
  209. package/dist/vtc/elections/list/0.2/payload.d.ts +4 -4
  210. package/dist/vtc/elections/list/0.2/payload.js +1 -1
  211. package/dist/vtc/elections/list/0.3/payload.d.ts +14 -2
  212. package/dist/vtc/elections/list/0.3/payload.d.ts.map +1 -1
  213. package/dist/vtc/elections/list/0.3/payload.js +1 -1
  214. package/dist/vtc/elections/list/0.3/payload.js.map +1 -1
  215. package/dist/vtc/elections/list/0.4/payload.d.ts +547 -0
  216. package/dist/vtc/elections/list/0.4/payload.d.ts.map +1 -0
  217. package/dist/vtc/elections/list/0.4/payload.js +304 -0
  218. package/dist/vtc/elections/list/0.4/payload.js.map +1 -0
  219. package/dist/vtc/elections/list/0.5/payload.d.ts +535 -0
  220. package/dist/vtc/elections/list/0.5/payload.d.ts.map +1 -0
  221. package/dist/vtc/elections/list/0.5/payload.js +304 -0
  222. package/dist/vtc/elections/list/0.5/payload.js.map +1 -0
  223. package/dist/vtc/elections/show/0.1/payload.d.ts +4 -4
  224. package/dist/vtc/elections/show/0.1/payload.js +1 -1
  225. package/dist/vtc/elections/show/0.2/payload.d.ts +4 -4
  226. package/dist/vtc/elections/show/0.2/payload.js +1 -1
  227. package/dist/vtc/elections/show/0.3/payload.d.ts +14 -2
  228. package/dist/vtc/elections/show/0.3/payload.d.ts.map +1 -1
  229. package/dist/vtc/elections/show/0.3/payload.js +1 -1
  230. package/dist/vtc/elections/show/0.3/payload.js.map +1 -1
  231. package/dist/vtc/elections/show/0.4/payload.d.ts +3290 -0
  232. package/dist/vtc/elections/show/0.4/payload.d.ts.map +1 -0
  233. package/dist/vtc/elections/show/0.4/payload.js +1931 -0
  234. package/dist/vtc/elections/show/0.4/payload.js.map +1 -0
  235. package/dist/vtc/elections/show/0.5/payload.d.ts +3318 -0
  236. package/dist/vtc/elections/show/0.5/payload.d.ts.map +1 -0
  237. package/dist/vtc/elections/show/0.5/payload.js +1946 -0
  238. package/dist/vtc/elections/show/0.5/payload.js.map +1 -0
  239. package/dist/vtc/elections/show/0.6/payload.d.ts +3306 -0
  240. package/dist/vtc/elections/show/0.6/payload.d.ts.map +1 -0
  241. package/dist/vtc/elections/show/0.6/payload.js +1946 -0
  242. package/dist/vtc/elections/show/0.6/payload.js.map +1 -0
  243. package/dist/vtc/elections/tickets/issue/0.1/payload.d.ts +14 -2
  244. package/dist/vtc/elections/tickets/issue/0.1/payload.d.ts.map +1 -1
  245. package/dist/vtc/elections/tickets/issue/0.1/payload.js +1 -1
  246. package/dist/vtc/elections/tickets/issue/0.1/payload.js.map +1 -1
  247. package/dist/vtc/elections/tickets/issue/0.2/payload.d.ts +651 -0
  248. package/dist/vtc/elections/tickets/issue/0.2/payload.d.ts.map +1 -0
  249. package/dist/vtc/elections/tickets/issue/0.2/payload.js +347 -0
  250. package/dist/vtc/elections/tickets/issue/0.2/payload.js.map +1 -0
  251. package/dist/vtc/elections/tickets/issue/0.3/payload.d.ts +639 -0
  252. package/dist/vtc/elections/tickets/issue/0.3/payload.d.ts.map +1 -0
  253. package/dist/vtc/elections/tickets/issue/0.3/payload.js +347 -0
  254. package/dist/vtc/elections/tickets/issue/0.3/payload.js.map +1 -0
  255. package/dist/vtc/networks/evidence/0.1/payload.d.ts +412 -0
  256. package/dist/vtc/networks/evidence/0.1/payload.d.ts.map +1 -0
  257. package/dist/vtc/networks/evidence/0.1/payload.js +233 -0
  258. package/dist/vtc/networks/evidence/0.1/payload.js.map +1 -0
  259. package/dist/vtc/networks/groups/register/0.1/payload.d.ts +680 -0
  260. package/dist/vtc/networks/groups/register/0.1/payload.d.ts.map +1 -0
  261. package/dist/vtc/networks/groups/register/0.1/payload.js +401 -0
  262. package/dist/vtc/networks/groups/register/0.1/payload.js.map +1 -0
  263. package/dist/vtc/networks/join/0.1/payload.d.ts +760 -0
  264. package/dist/vtc/networks/join/0.1/payload.d.ts.map +1 -0
  265. package/dist/vtc/networks/join/0.1/payload.js +445 -0
  266. package/dist/vtc/networks/join/0.1/payload.js.map +1 -0
  267. package/dist/vtc/networks/leave/0.1/payload.d.ts +664 -0
  268. package/dist/vtc/networks/leave/0.1/payload.d.ts.map +1 -0
  269. package/dist/vtc/networks/leave/0.1/payload.js +393 -0
  270. package/dist/vtc/networks/leave/0.1/payload.js.map +1 -0
  271. package/dist/vtc/networks/list/0.1/payload.d.ts +713 -0
  272. package/dist/vtc/networks/list/0.1/payload.d.ts.map +1 -0
  273. package/dist/vtc/networks/list/0.1/payload.js +417 -0
  274. package/dist/vtc/networks/list/0.1/payload.js.map +1 -0
  275. package/dist/vtc/networks/notice/0.1/payload.d.ts +210 -0
  276. package/dist/vtc/networks/notice/0.1/payload.d.ts.map +1 -0
  277. package/dist/vtc/networks/notice/0.1/payload.js +116 -0
  278. package/dist/vtc/networks/notice/0.1/payload.js.map +1 -0
  279. package/dist/vtc/networks/repudiate/0.1/payload.d.ts +680 -0
  280. package/dist/vtc/networks/repudiate/0.1/payload.d.ts.map +1 -0
  281. package/dist/vtc/networks/repudiate/0.1/payload.js +400 -0
  282. package/dist/vtc/networks/repudiate/0.1/payload.js.map +1 -0
  283. package/dist/vtc/networks/show/0.1/payload.d.ts +650 -0
  284. package/dist/vtc/networks/show/0.1/payload.d.ts.map +1 -0
  285. package/dist/vtc/networks/show/0.1/payload.js +388 -0
  286. package/dist/vtc/networks/show/0.1/payload.js.map +1 -0
  287. package/package.json +1 -1
  288. package/src/_extends.ts +5 -0
  289. package/src/_shared/components.ts +293 -0
  290. package/src/index.ts +117 -0
  291. package/src/notifications/_shared/0.1/notification.ts +23 -0
  292. package/src/notifications/notify/0.1/payload.ts +420 -0
  293. package/src/notifications/relay/0.1/payload.ts +220 -0
  294. package/src/voting/_shared/0.4/voting.ts +17 -0
  295. package/src/voting/election/register/0.1/payload.ts +5 -5
  296. package/src/voting/election/register/0.2/payload.ts +5 -5
  297. package/src/voting/election/register/0.3/payload.ts +14 -3
  298. package/src/voting/election/register/0.4/payload.ts +1307 -0
  299. package/src/voting/election/show/0.1/payload.ts +5 -5
  300. package/src/voting/election/show/0.2/payload.ts +5 -5
  301. package/src/voting/election/show/0.3/payload.ts +14 -3
  302. package/src/voting/election/show/0.4/payload.ts +1249 -0
  303. package/src/vta/notifications/_shared/0.1/held-notification.ts +17 -0
  304. package/src/vta/notifications/dismiss/0.1/payload.ts +214 -0
  305. package/src/vta/notifications/list/0.1/payload.ts +688 -0
  306. package/src/vta/notifications/show/0.1/payload.ts +630 -0
  307. package/src/vta/pcs/trustee/deal/0.2/payload.ts +5 -5
  308. package/src/vta/pcs/trustee/deal/0.3/payload.ts +5 -5
  309. package/src/vta/pcs/trustee/deal/0.4/payload.ts +14 -3
  310. package/src/vta/pcs/trustee/deal/0.5/payload.ts +1248 -0
  311. package/src/vta/pcs/trustee/enrol/0.1/payload.ts +5 -5
  312. package/src/vta/pcs/trustee/enrol/0.2/payload.ts +5 -5
  313. package/src/vta/pcs/trustee/enrol/0.3/payload.ts +14 -3
  314. package/src/vta/pcs/trustee/enrol/0.4/payload.ts +1207 -0
  315. package/src/vta/pcs/trustee/justify/0.2/payload.ts +5 -5
  316. package/src/vta/pcs/trustee/justify/0.3/payload.ts +5 -5
  317. package/src/vta/pcs/trustee/justify/0.4/payload.ts +14 -3
  318. package/src/vta/pcs/trustee/justify/0.5/payload.ts +1267 -0
  319. package/src/vta/pcs/trustee/keys/0.2/payload.ts +5 -5
  320. package/src/vta/pcs/trustee/keys/0.3/payload.ts +5 -5
  321. package/src/vta/pcs/trustee/keys/0.4/payload.ts +14 -3
  322. package/src/vta/pcs/trustee/keys/0.5/payload.ts +1294 -0
  323. package/src/vta/pcs/trustee/read/0.1/payload.ts +5 -5
  324. package/src/vta/pcs/trustee/read/0.2/payload.ts +5 -5
  325. package/src/vta/pcs/trustee/read/0.3/payload.ts +15 -3
  326. package/src/vta/pcs/trustee/read/0.4/payload.ts +385 -0
  327. package/src/vta/pcs/vote/0.1/payload.ts +5 -5
  328. package/src/vta/pcs/vote/0.2/payload.ts +5 -5
  329. package/src/vta/pcs/vote/0.3/payload.ts +14 -3
  330. package/src/vta/pcs/vote/0.4/payload.ts +1465 -0
  331. package/src/vta/pcs/vote-encrypted/0.2/payload.ts +5 -5
  332. package/src/vta/pcs/vote-encrypted/0.3/payload.ts +5 -5
  333. package/src/vta/pcs/vote-encrypted/0.4/payload.ts +14 -3
  334. package/src/vta/pcs/vote-encrypted/0.5/payload.ts +1469 -0
  335. package/src/vta/pcs/voter/accept/0.1/payload.ts +2 -2
  336. package/src/vta/pcs/voter/read/0.1/payload.ts +5 -5
  337. package/src/vta/pcs/voter/read/0.2/payload.ts +5 -5
  338. package/src/vta/pcs/voter/read/0.3/payload.ts +15 -3
  339. package/src/vta/pcs/voter/read/0.4/payload.ts +375 -0
  340. package/src/vta/pcs/voter/read/0.5/payload.ts +394 -0
  341. package/src/vta/pcs/voter/read/0.6/payload.ts +398 -0
  342. package/src/vta/pcs/voter/register/0.1/payload.ts +5 -5
  343. package/src/vta/pcs/voter/register/0.2/payload.ts +5 -5
  344. package/src/vta/pcs/voter/register/0.3/payload.ts +15 -3
  345. package/src/vta/pcs/voter/register/0.4/payload.ts +1478 -0
  346. package/src/vta/pcs/voter/register/0.5/payload.ts +1466 -0
  347. package/src/vtc/_shared/0.6/network-membership.ts +17 -0
  348. package/src/vtc/elections/create/0.1/payload.ts +5 -5
  349. package/src/vtc/elections/create/0.2/payload.ts +5 -5
  350. package/src/vtc/elections/create/0.3/payload.ts +5 -5
  351. package/src/vtc/elections/create/0.4/payload.ts +15 -3
  352. package/src/vtc/elections/create/0.5/payload.ts +1141 -0
  353. package/src/vtc/elections/list/0.1/payload.ts +5 -5
  354. package/src/vtc/elections/list/0.2/payload.ts +5 -5
  355. package/src/vtc/elections/list/0.3/payload.ts +15 -3
  356. package/src/vtc/elections/list/0.4/payload.ts +399 -0
  357. package/src/vtc/elections/list/0.5/payload.ts +387 -0
  358. package/src/vtc/elections/show/0.1/payload.ts +5 -5
  359. package/src/vtc/elections/show/0.2/payload.ts +5 -5
  360. package/src/vtc/elections/show/0.3/payload.ts +15 -3
  361. package/src/vtc/elections/show/0.4/payload.ts +2043 -0
  362. package/src/vtc/elections/show/0.5/payload.ts +2062 -0
  363. package/src/vtc/elections/show/0.6/payload.ts +2050 -0
  364. package/src/vtc/elections/tickets/issue/0.1/payload.ts +15 -3
  365. package/src/vtc/elections/tickets/issue/0.2/payload.ts +441 -0
  366. package/src/vtc/elections/tickets/issue/0.3/payload.ts +429 -0
  367. package/src/vtc/networks/evidence/0.1/payload.ts +290 -0
  368. package/src/vtc/networks/groups/register/0.1/payload.ts +446 -0
  369. package/src/vtc/networks/join/0.1/payload.ts +492 -0
  370. package/src/vtc/networks/leave/0.1/payload.ts +434 -0
  371. package/src/vtc/networks/list/0.1/payload.ts +463 -0
  372. package/src/vtc/networks/notice/0.1/payload.ts +172 -0
  373. package/src/vtc/networks/repudiate/0.1/payload.ts +445 -0
  374. package/src/vtc/networks/show/0.1/payload.ts +425 -0
@@ -0,0 +1,1294 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/pcs/trustee/keys/0.5/payload.schema.json
4
+ */
5
+
6
+ import type { BoardVisibility, ChoiceQuestion, ElectionId, Ext, Key_VotingV0_1 as Key, Manifest_VotingV0_4 as Manifest, Question, QuestionOption, RankingQuestion, Revote, RollRule_VotingV0_4 as RollRule, ScoreQuestion, SecrecyLevel, SignedRequest, TextQuestion, TrusteeCeremony, TrusteeIndex, Trustees } from "../../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * The trustee's VTA opens the shares it was dealt, checks each, keeps its share of the election key, and returns the voting/trustees/confirm request signed as the trustee.
11
+ */
12
+ export interface VTAPCSTrusteeKeysPayload {
13
+ /**
14
+ * The VTA context the trustee's keys live in.
15
+ */
16
+ contextId: string;
17
+ /**
18
+ * The community's DID.
19
+ */
20
+ community: string;
21
+ electionId: ElectionId;
22
+ /**
23
+ * The trustee's DID: a persona this VTA holds, named in the manifest's `trustees.dids`.
24
+ */
25
+ trustee: string;
26
+ manifest: Manifest;
27
+ /**
28
+ * The ceremony as the board holds it: voting/trustees/status's `steps`, passed on unchanged. The VTA verifies every step as its trustee's before taking it.
29
+ */
30
+ ceremony: TrusteeCeremony;
31
+ ext?: Ext;
32
+ }
33
+ export interface VTAPCSTrusteeKeysResponsePayload {
34
+ /**
35
+ * @maxItems 64
36
+ */
37
+ complaints: TrusteeIndex[];
38
+ /**
39
+ * Whether the VTA now holds the trustee's key share, checked against the election key's verification key.
40
+ */
41
+ keyHeld: boolean;
42
+ document?: ConfirmDocument;
43
+ ext?: Ext;
44
+ }
45
+ /**
46
+ * The voting/trustees/confirm request, signed as the trustee. Absent once the key share is held.
47
+ */
48
+ export interface ConfirmDocument {
49
+ id: string;
50
+ type: "https://trusttasks.org/spec/voting/trustees/confirm/0.1";
51
+ /**
52
+ * The signer.
53
+ */
54
+ issuer: string;
55
+ /**
56
+ * The ballot box.
57
+ */
58
+ recipient: string;
59
+ issuedAt: string;
60
+ expiresAt?: string;
61
+ /**
62
+ * That task's request payload.
63
+ */
64
+ payload: {};
65
+ /**
66
+ * A Data Integrity proof by an `authentication` key of `issuer`.
67
+ */
68
+ proof: {};
69
+ }
70
+
71
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
72
+ export type { BoardVisibility, ChoiceQuestion, ElectionId, Ext, Key, Manifest, Question, QuestionOption, RankingQuestion, Revote, RollRule, ScoreQuestion, SecrecyLevel, SignedRequest, TextQuestion, TrusteeCeremony, TrusteeIndex, Trustees };
73
+
74
+ /** Trust Task type URI. */
75
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/pcs/trustee/keys/0.5" as const;
76
+
77
+ /**
78
+ * The earlier version of this specification that this one declares it
79
+ * extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
80
+ * `null`. Only the direct declaration — follow the chain with
81
+ * `extendsChain` / `readForSpec`.
82
+ */
83
+ export const EXTENDS: string | null = null;
84
+
85
+ /**
86
+ * Why this version is deprecated, or `null` while it is current. A
87
+ * superseded or retired version is still supported, and is withdrawn from
88
+ * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
89
+ * Versions").
90
+ */
91
+ export const DEPRECATION: string | null = null;
92
+
93
+ /** Stable alias for this specification's request payload shape. */
94
+ export type Payload = VTAPCSTrusteeKeysPayload;
95
+
96
+ /** Trust Task response type URI (request type URI + "#response"). */
97
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/trustee/keys/0.5#response" as const;
98
+
99
+ /** Stable alias for this specification's success-response payload shape. */
100
+ export type Response = VTAPCSTrusteeKeysResponsePayload;
101
+
102
+ /**
103
+ * This specification's payload schema, as a value.
104
+ *
105
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
106
+ * rather than only as a `.json` file because TypeScript types are erased
107
+ * at runtime: without a schema a consumer has nothing to validate, and
108
+ * every REQUIRED payload member is optional in practice. Cross-file
109
+ * `$ref`s are already inlined, so it needs no resolver.
110
+ */
111
+ export const PAYLOAD_SCHEMA = {
112
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
113
+ "$id": "https://trusttasks.org/spec/vta/pcs/trustee/keys/0.5",
114
+ "title": "VTA PCS — Trustee Keys — payload",
115
+ "description": "The trustee's VTA opens the shares it was dealt, checks each, keeps its share of the election key, and returns the voting/trustees/confirm request signed as the trustee.",
116
+ "type": "object",
117
+ "additionalProperties": false,
118
+ "required": [
119
+ "contextId",
120
+ "community",
121
+ "electionId",
122
+ "trustee",
123
+ "manifest",
124
+ "ceremony"
125
+ ],
126
+ "properties": {
127
+ "contextId": {
128
+ "type": "string",
129
+ "minLength": 1,
130
+ "maxLength": 256,
131
+ "description": "The VTA context the trustee's keys live in."
132
+ },
133
+ "community": {
134
+ "type": "string",
135
+ "minLength": 1,
136
+ "maxLength": 2048,
137
+ "description": "The community's DID."
138
+ },
139
+ "electionId": {
140
+ "$ref": "#/$defs/ElectionId"
141
+ },
142
+ "trustee": {
143
+ "type": "string",
144
+ "minLength": 1,
145
+ "maxLength": 2048,
146
+ "description": "The trustee's DID: a persona this VTA holds, named in the manifest's `trustees.dids`."
147
+ },
148
+ "manifest": {
149
+ "$ref": "#/$defs/Manifest"
150
+ },
151
+ "ceremony": {
152
+ "$ref": "#/$defs/TrusteeCeremony",
153
+ "description": "The ceremony as the board holds it: voting/trustees/status's `steps`, passed on unchanged. The VTA verifies every step as its trustee's before taking it."
154
+ },
155
+ "ext": {
156
+ "$ref": "#/$defs/Ext"
157
+ }
158
+ },
159
+ "$defs": {
160
+ "Response": {
161
+ "$anchor": "response",
162
+ "title": "VTA PCS — Trustee Keys — response payload",
163
+ "type": "object",
164
+ "additionalProperties": false,
165
+ "required": [
166
+ "complaints",
167
+ "keyHeld"
168
+ ],
169
+ "properties": {
170
+ "complaints": {
171
+ "type": "array",
172
+ "maxItems": 64,
173
+ "items": {
174
+ "$ref": "#/$defs/TrusteeIndex"
175
+ }
176
+ },
177
+ "keyHeld": {
178
+ "type": "boolean",
179
+ "description": "Whether the VTA now holds the trustee's key share, checked against the election key's verification key."
180
+ },
181
+ "document": {
182
+ "title": "ConfirmDocument",
183
+ "description": "The voting/trustees/confirm request, signed as the trustee. Absent once the key share is held.",
184
+ "type": "object",
185
+ "required": [
186
+ "id",
187
+ "type",
188
+ "issuer",
189
+ "recipient",
190
+ "issuedAt",
191
+ "payload",
192
+ "proof"
193
+ ],
194
+ "properties": {
195
+ "id": {
196
+ "type": "string",
197
+ "pattern": "^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
198
+ },
199
+ "type": {
200
+ "const": "https://trusttasks.org/spec/voting/trustees/confirm/0.1"
201
+ },
202
+ "issuer": {
203
+ "type": "string",
204
+ "minLength": 1,
205
+ "maxLength": 2048,
206
+ "description": "The signer."
207
+ },
208
+ "recipient": {
209
+ "type": "string",
210
+ "minLength": 1,
211
+ "maxLength": 2048,
212
+ "description": "The ballot box."
213
+ },
214
+ "issuedAt": {
215
+ "type": "string",
216
+ "format": "date-time"
217
+ },
218
+ "expiresAt": {
219
+ "type": "string",
220
+ "format": "date-time"
221
+ },
222
+ "payload": {
223
+ "type": "object",
224
+ "description": "That task's request payload."
225
+ },
226
+ "proof": {
227
+ "type": "object",
228
+ "description": "A Data Integrity proof by an `authentication` key of `issuer`."
229
+ }
230
+ }
231
+ },
232
+ "ext": {
233
+ "$ref": "#/$defs/Ext"
234
+ }
235
+ }
236
+ },
237
+ "Ext": {
238
+ "title": "Ext",
239
+ "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.",
240
+ "type": "object",
241
+ "minProperties": 1,
242
+ "additionalProperties": true,
243
+ "propertyNames": {
244
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
245
+ }
246
+ },
247
+ "TrusteeIndex": {
248
+ "title": "TrusteeIndex",
249
+ "description": "A trustee's index: its position in the manifest's `trustees.dids`, counting from 1.",
250
+ "type": "integer",
251
+ "minimum": 1,
252
+ "maximum": 64
253
+ },
254
+ "TrusteeCeremony": {
255
+ "title": "TrusteeCeremony",
256
+ "description": "The trustees' ceremony as the board holds it: the `request` of every `trusteeStep` entry, in board order, each exactly as the ballot box received it (CONVENTIONS §9.6). Whoever acts on it verifies each step as its trustee's before taking it; nothing in it is believed for having been passed along.",
257
+ "type": "array",
258
+ "minItems": 1,
259
+ "maxItems": 4224,
260
+ "items": {
261
+ "$ref": "#/$defs/SignedRequest"
262
+ }
263
+ },
264
+ "SignedRequest": {
265
+ "title": "SignedRequest",
266
+ "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.",
267
+ "type": "object",
268
+ "minProperties": 1
269
+ },
270
+ "Manifest": {
271
+ "title": "Manifest",
272
+ "description": "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).",
273
+ "type": "object",
274
+ "additionalProperties": false,
275
+ "required": [
276
+ "electionId",
277
+ "community",
278
+ "questions",
279
+ "secrecy",
280
+ "roll",
281
+ "registrationOpensAt",
282
+ "votingOpensAt",
283
+ "votingClosesAt",
284
+ "revote",
285
+ "board",
286
+ "ballotBox",
287
+ "binding",
288
+ "allowEarlyClose",
289
+ "resultsBeforeClose",
290
+ "textReleaseThreshold"
291
+ ],
292
+ "properties": {
293
+ "electionId": {
294
+ "$ref": "#/$defs/ElectionId"
295
+ },
296
+ "community": {
297
+ "type": "string",
298
+ "minLength": 1,
299
+ "maxLength": 2048,
300
+ "description": "The community's DID."
301
+ },
302
+ "title": {
303
+ "type": "string",
304
+ "maxLength": 512
305
+ },
306
+ "description": {
307
+ "type": "string",
308
+ "maxLength": 8192
309
+ },
310
+ "questions": {
311
+ "type": "array",
312
+ "minItems": 1,
313
+ "maxItems": 128,
314
+ "items": {
315
+ "$ref": "#/$defs/Question"
316
+ }
317
+ },
318
+ "secrecy": {
319
+ "$ref": "#/$defs/SecrecyLevel"
320
+ },
321
+ "roll": {
322
+ "$ref": "#/$defs/RollRule"
323
+ },
324
+ "registrationOpensAt": {
325
+ "type": "string",
326
+ "format": "date-time"
327
+ },
328
+ "votingOpensAt": {
329
+ "type": "string",
330
+ "format": "date-time"
331
+ },
332
+ "votingClosesAt": {
333
+ "type": "string",
334
+ "format": "date-time"
335
+ },
336
+ "revote": {
337
+ "$ref": "#/$defs/Revote"
338
+ },
339
+ "board": {
340
+ "type": "object",
341
+ "additionalProperties": false,
342
+ "required": [
343
+ "visibility",
344
+ "auditors"
345
+ ],
346
+ "properties": {
347
+ "visibility": {
348
+ "$ref": "#/$defs/BoardVisibility"
349
+ },
350
+ "auditors": {
351
+ "type": "array",
352
+ "items": {
353
+ "type": "string",
354
+ "minLength": 1,
355
+ "maxLength": 2048
356
+ },
357
+ "uniqueItems": true
358
+ }
359
+ }
360
+ },
361
+ "ballotBox": {
362
+ "type": "string",
363
+ "minLength": 1,
364
+ "maxLength": 2048,
365
+ "description": "The DID of the voting service that holds the board."
366
+ },
367
+ "trustees": {
368
+ "$ref": "#/$defs/Trustees"
369
+ },
370
+ "binding": {
371
+ "type": "boolean",
372
+ "description": "Whether the community treats the result as deciding something; creating a binding election takes another administrator's consent (VTI-VOT-081)."
373
+ },
374
+ "allowEarlyClose": {
375
+ "type": "boolean"
376
+ },
377
+ "resultsBeforeClose": {
378
+ "type": "boolean",
379
+ "description": "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061)."
380
+ },
381
+ "textReleaseThreshold": {
382
+ "type": "integer",
383
+ "minimum": 1,
384
+ "description": "Counted ballots required before any text answer is disclosed (VTI-VOT-065). At least 1, and SHOULD be at least 10: a written answer can identify its author by what it says or how it is phrased, and the fewer the ballots released together, the easier that is. Where it is below 10, the disclosure a member is shown before they request a ticket MUST say so, and MUST say that a written answer may identify its author (VTI-VOT-090)."
385
+ }
386
+ }
387
+ },
388
+ "Trustees": {
389
+ "title": "Trustees",
390
+ "description": "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.",
391
+ "type": "object",
392
+ "additionalProperties": false,
393
+ "required": [
394
+ "dids",
395
+ "threshold"
396
+ ],
397
+ "properties": {
398
+ "dids": {
399
+ "type": "array",
400
+ "minItems": 2,
401
+ "items": {
402
+ "type": "string",
403
+ "minLength": 1,
404
+ "maxLength": 2048
405
+ },
406
+ "uniqueItems": true
407
+ },
408
+ "threshold": {
409
+ "type": "integer",
410
+ "minimum": 2
411
+ }
412
+ }
413
+ },
414
+ "BoardVisibility": {
415
+ "title": "BoardVisibility",
416
+ "description": "`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).",
417
+ "type": "string",
418
+ "enum": [
419
+ "public",
420
+ "private"
421
+ ]
422
+ },
423
+ "Revote": {
424
+ "title": "Revote",
425
+ "description": "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).",
426
+ "type": "string",
427
+ "enum": [
428
+ "replace",
429
+ "refuse"
430
+ ]
431
+ },
432
+ "RollRule": {
433
+ "title": "RollRule",
434
+ "description": "Who may be issued a ticket (VTI-VOT-021): the community's active members (`members`), its active members and the parties `listed` names (`membersAndListed`), only the parties `listed` names (`listed`), or the holders of a membership credential for the one DID `memberOf` names (`credential`), proven by presentation when the holder claims their ticket and never resolved when the election is created (VTI-VOT-025). `memberOf` is present exactly when `rule` is `credential`, and `listed` is never present with it.",
435
+ "type": "object",
436
+ "additionalProperties": false,
437
+ "required": [
438
+ "rule"
439
+ ],
440
+ "properties": {
441
+ "rule": {
442
+ "type": "string",
443
+ "enum": [
444
+ "members",
445
+ "membersAndListed",
446
+ "listed",
447
+ "credential"
448
+ ]
449
+ },
450
+ "listed": {
451
+ "type": "array",
452
+ "items": {
453
+ "type": "string",
454
+ "minLength": 1,
455
+ "maxLength": 2048,
456
+ "description": "A DID enfranchised by name."
457
+ },
458
+ "uniqueItems": true
459
+ },
460
+ "memberOf": {
461
+ "type": "string",
462
+ "minLength": 8,
463
+ "maxLength": 2048,
464
+ "pattern": "^did:[a-z0-9]+:\\S+$",
465
+ "description": "The DID whose membership credential admits its holder, under the `credential` rule: this community, one of its groups, or a party that is itself an active member of this community — holding a membership credential this community issued it — such as another community, a group of another community, or a network (VTI-VOT-026). Always a DID, never a group's local identifier or name. A community refuses to create an election naming any other DID (vtc/elections/create:rollUntrusted)."
466
+ }
467
+ },
468
+ "dependentSchemas": {
469
+ "rule": {
470
+ "anyOf": [
471
+ {
472
+ "required": [
473
+ "memberOf"
474
+ ]
475
+ },
476
+ {
477
+ "properties": {
478
+ "rule": {
479
+ "enum": [
480
+ "members",
481
+ "membersAndListed",
482
+ "listed"
483
+ ]
484
+ }
485
+ }
486
+ }
487
+ ]
488
+ },
489
+ "memberOf": {
490
+ "properties": {
491
+ "rule": {
492
+ "const": "credential"
493
+ }
494
+ },
495
+ "not": {
496
+ "required": [
497
+ "listed"
498
+ ]
499
+ }
500
+ }
501
+ }
502
+ },
503
+ "SecrecyLevel": {
504
+ "title": "SecrecyLevel",
505
+ "description": "`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). The encrypted levels are cast with `voting/ballot/cast-encrypted/0.1`, under an election key the trustees generate with `voting/trustees/*` (CONVENTIONS §9).",
506
+ "type": "string",
507
+ "enum": [
508
+ "open",
509
+ "sealed",
510
+ "talliedEncrypted"
511
+ ]
512
+ },
513
+ "Question": {
514
+ "title": "Question",
515
+ "description": "One question. Tagged union over `type`.",
516
+ "oneOf": [
517
+ {
518
+ "title": "ChoiceQuestion",
519
+ "description": "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.",
520
+ "type": "object",
521
+ "additionalProperties": false,
522
+ "required": [
523
+ "key",
524
+ "type",
525
+ "options",
526
+ "minSelections",
527
+ "maxSelections",
528
+ "optional"
529
+ ],
530
+ "properties": {
531
+ "key": {
532
+ "$ref": "#/$defs/Key"
533
+ },
534
+ "type": {
535
+ "const": "choice"
536
+ },
537
+ "text": {
538
+ "type": "string",
539
+ "maxLength": 2048
540
+ },
541
+ "options": {
542
+ "type": "array",
543
+ "minItems": 2,
544
+ "maxItems": 256,
545
+ "items": {
546
+ "$ref": "#/$defs/QuestionOption"
547
+ }
548
+ },
549
+ "minSelections": {
550
+ "type": "integer",
551
+ "minimum": 0
552
+ },
553
+ "maxSelections": {
554
+ "type": "integer",
555
+ "minimum": 1
556
+ },
557
+ "optional": {
558
+ "type": "boolean"
559
+ }
560
+ }
561
+ },
562
+ {
563
+ "title": "RankingQuestion",
564
+ "description": "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.",
565
+ "type": "object",
566
+ "additionalProperties": false,
567
+ "required": [
568
+ "key",
569
+ "type",
570
+ "options",
571
+ "partial",
572
+ "optional"
573
+ ],
574
+ "properties": {
575
+ "key": {
576
+ "$ref": "#/$defs/Key"
577
+ },
578
+ "type": {
579
+ "const": "ranking"
580
+ },
581
+ "text": {
582
+ "type": "string",
583
+ "maxLength": 2048
584
+ },
585
+ "options": {
586
+ "type": "array",
587
+ "minItems": 2,
588
+ "maxItems": 64,
589
+ "items": {
590
+ "$ref": "#/$defs/QuestionOption"
591
+ }
592
+ },
593
+ "partial": {
594
+ "type": "boolean"
595
+ },
596
+ "optional": {
597
+ "type": "boolean"
598
+ }
599
+ }
600
+ },
601
+ {
602
+ "title": "ScoreQuestion",
603
+ "description": "Give each option an integer score within [min, max].",
604
+ "type": "object",
605
+ "additionalProperties": false,
606
+ "required": [
607
+ "key",
608
+ "type",
609
+ "options",
610
+ "min",
611
+ "max",
612
+ "optional"
613
+ ],
614
+ "properties": {
615
+ "key": {
616
+ "$ref": "#/$defs/Key"
617
+ },
618
+ "type": {
619
+ "const": "score"
620
+ },
621
+ "text": {
622
+ "type": "string",
623
+ "maxLength": 2048
624
+ },
625
+ "options": {
626
+ "type": "array",
627
+ "minItems": 1,
628
+ "maxItems": 256,
629
+ "items": {
630
+ "$ref": "#/$defs/QuestionOption"
631
+ }
632
+ },
633
+ "min": {
634
+ "type": "integer"
635
+ },
636
+ "max": {
637
+ "type": "integer"
638
+ },
639
+ "optional": {
640
+ "type": "boolean"
641
+ }
642
+ }
643
+ },
644
+ {
645
+ "title": "TextQuestion",
646
+ "description": "Free text of at most `maxLength` characters.",
647
+ "type": "object",
648
+ "additionalProperties": false,
649
+ "required": [
650
+ "key",
651
+ "type",
652
+ "maxLength",
653
+ "optional"
654
+ ],
655
+ "properties": {
656
+ "key": {
657
+ "$ref": "#/$defs/Key"
658
+ },
659
+ "type": {
660
+ "const": "text"
661
+ },
662
+ "text": {
663
+ "type": "string",
664
+ "maxLength": 2048
665
+ },
666
+ "maxLength": {
667
+ "type": "integer",
668
+ "minimum": 1,
669
+ "maximum": 4096
670
+ },
671
+ "optional": {
672
+ "type": "boolean"
673
+ }
674
+ }
675
+ }
676
+ ]
677
+ },
678
+ "Key": {
679
+ "title": "Key",
680
+ "description": "A question or option key, unique within its manifest or question.",
681
+ "type": "string",
682
+ "pattern": "^[A-Za-z0-9._-]{1,64}$"
683
+ },
684
+ "QuestionOption": {
685
+ "title": "QuestionOption",
686
+ "type": "object",
687
+ "additionalProperties": false,
688
+ "required": [
689
+ "key"
690
+ ],
691
+ "properties": {
692
+ "key": {
693
+ "$ref": "#/$defs/Key"
694
+ },
695
+ "label": {
696
+ "type": "string",
697
+ "maxLength": 512,
698
+ "description": "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014)."
699
+ }
700
+ }
701
+ },
702
+ "ElectionId": {
703
+ "title": "ElectionId",
704
+ "description": "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.",
705
+ "type": "string",
706
+ "pattern": "^[A-Za-z0-9._-]{1,128}$"
707
+ }
708
+ }
709
+ } as const;
710
+
711
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
712
+ export const RESPONSE_PAYLOAD_SCHEMA = {
713
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
714
+ "$ref": "#/$defs/Response",
715
+ "$defs": {
716
+ "Response": {
717
+ "$anchor": "response",
718
+ "title": "VTA PCS — Trustee Keys — response payload",
719
+ "type": "object",
720
+ "additionalProperties": false,
721
+ "required": [
722
+ "complaints",
723
+ "keyHeld"
724
+ ],
725
+ "properties": {
726
+ "complaints": {
727
+ "type": "array",
728
+ "maxItems": 64,
729
+ "items": {
730
+ "$ref": "#/$defs/TrusteeIndex"
731
+ }
732
+ },
733
+ "keyHeld": {
734
+ "type": "boolean",
735
+ "description": "Whether the VTA now holds the trustee's key share, checked against the election key's verification key."
736
+ },
737
+ "document": {
738
+ "title": "ConfirmDocument",
739
+ "description": "The voting/trustees/confirm request, signed as the trustee. Absent once the key share is held.",
740
+ "type": "object",
741
+ "required": [
742
+ "id",
743
+ "type",
744
+ "issuer",
745
+ "recipient",
746
+ "issuedAt",
747
+ "payload",
748
+ "proof"
749
+ ],
750
+ "properties": {
751
+ "id": {
752
+ "type": "string",
753
+ "pattern": "^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
754
+ },
755
+ "type": {
756
+ "const": "https://trusttasks.org/spec/voting/trustees/confirm/0.1"
757
+ },
758
+ "issuer": {
759
+ "type": "string",
760
+ "minLength": 1,
761
+ "maxLength": 2048,
762
+ "description": "The signer."
763
+ },
764
+ "recipient": {
765
+ "type": "string",
766
+ "minLength": 1,
767
+ "maxLength": 2048,
768
+ "description": "The ballot box."
769
+ },
770
+ "issuedAt": {
771
+ "type": "string",
772
+ "format": "date-time"
773
+ },
774
+ "expiresAt": {
775
+ "type": "string",
776
+ "format": "date-time"
777
+ },
778
+ "payload": {
779
+ "type": "object",
780
+ "description": "That task's request payload."
781
+ },
782
+ "proof": {
783
+ "type": "object",
784
+ "description": "A Data Integrity proof by an `authentication` key of `issuer`."
785
+ }
786
+ }
787
+ },
788
+ "ext": {
789
+ "$ref": "#/$defs/Ext"
790
+ }
791
+ }
792
+ },
793
+ "Ext": {
794
+ "title": "Ext",
795
+ "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.",
796
+ "type": "object",
797
+ "minProperties": 1,
798
+ "additionalProperties": true,
799
+ "propertyNames": {
800
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
801
+ }
802
+ },
803
+ "TrusteeIndex": {
804
+ "title": "TrusteeIndex",
805
+ "description": "A trustee's index: its position in the manifest's `trustees.dids`, counting from 1.",
806
+ "type": "integer",
807
+ "minimum": 1,
808
+ "maximum": 64
809
+ },
810
+ "TrusteeCeremony": {
811
+ "title": "TrusteeCeremony",
812
+ "description": "The trustees' ceremony as the board holds it: the `request` of every `trusteeStep` entry, in board order, each exactly as the ballot box received it (CONVENTIONS §9.6). Whoever acts on it verifies each step as its trustee's before taking it; nothing in it is believed for having been passed along.",
813
+ "type": "array",
814
+ "minItems": 1,
815
+ "maxItems": 4224,
816
+ "items": {
817
+ "$ref": "#/$defs/SignedRequest"
818
+ }
819
+ },
820
+ "SignedRequest": {
821
+ "title": "SignedRequest",
822
+ "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.",
823
+ "type": "object",
824
+ "minProperties": 1
825
+ },
826
+ "Manifest": {
827
+ "title": "Manifest",
828
+ "description": "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).",
829
+ "type": "object",
830
+ "additionalProperties": false,
831
+ "required": [
832
+ "electionId",
833
+ "community",
834
+ "questions",
835
+ "secrecy",
836
+ "roll",
837
+ "registrationOpensAt",
838
+ "votingOpensAt",
839
+ "votingClosesAt",
840
+ "revote",
841
+ "board",
842
+ "ballotBox",
843
+ "binding",
844
+ "allowEarlyClose",
845
+ "resultsBeforeClose",
846
+ "textReleaseThreshold"
847
+ ],
848
+ "properties": {
849
+ "electionId": {
850
+ "$ref": "#/$defs/ElectionId"
851
+ },
852
+ "community": {
853
+ "type": "string",
854
+ "minLength": 1,
855
+ "maxLength": 2048,
856
+ "description": "The community's DID."
857
+ },
858
+ "title": {
859
+ "type": "string",
860
+ "maxLength": 512
861
+ },
862
+ "description": {
863
+ "type": "string",
864
+ "maxLength": 8192
865
+ },
866
+ "questions": {
867
+ "type": "array",
868
+ "minItems": 1,
869
+ "maxItems": 128,
870
+ "items": {
871
+ "$ref": "#/$defs/Question"
872
+ }
873
+ },
874
+ "secrecy": {
875
+ "$ref": "#/$defs/SecrecyLevel"
876
+ },
877
+ "roll": {
878
+ "$ref": "#/$defs/RollRule"
879
+ },
880
+ "registrationOpensAt": {
881
+ "type": "string",
882
+ "format": "date-time"
883
+ },
884
+ "votingOpensAt": {
885
+ "type": "string",
886
+ "format": "date-time"
887
+ },
888
+ "votingClosesAt": {
889
+ "type": "string",
890
+ "format": "date-time"
891
+ },
892
+ "revote": {
893
+ "$ref": "#/$defs/Revote"
894
+ },
895
+ "board": {
896
+ "type": "object",
897
+ "additionalProperties": false,
898
+ "required": [
899
+ "visibility",
900
+ "auditors"
901
+ ],
902
+ "properties": {
903
+ "visibility": {
904
+ "$ref": "#/$defs/BoardVisibility"
905
+ },
906
+ "auditors": {
907
+ "type": "array",
908
+ "items": {
909
+ "type": "string",
910
+ "minLength": 1,
911
+ "maxLength": 2048
912
+ },
913
+ "uniqueItems": true
914
+ }
915
+ }
916
+ },
917
+ "ballotBox": {
918
+ "type": "string",
919
+ "minLength": 1,
920
+ "maxLength": 2048,
921
+ "description": "The DID of the voting service that holds the board."
922
+ },
923
+ "trustees": {
924
+ "$ref": "#/$defs/Trustees"
925
+ },
926
+ "binding": {
927
+ "type": "boolean",
928
+ "description": "Whether the community treats the result as deciding something; creating a binding election takes another administrator's consent (VTI-VOT-081)."
929
+ },
930
+ "allowEarlyClose": {
931
+ "type": "boolean"
932
+ },
933
+ "resultsBeforeClose": {
934
+ "type": "boolean",
935
+ "description": "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061)."
936
+ },
937
+ "textReleaseThreshold": {
938
+ "type": "integer",
939
+ "minimum": 1,
940
+ "description": "Counted ballots required before any text answer is disclosed (VTI-VOT-065). At least 1, and SHOULD be at least 10: a written answer can identify its author by what it says or how it is phrased, and the fewer the ballots released together, the easier that is. Where it is below 10, the disclosure a member is shown before they request a ticket MUST say so, and MUST say that a written answer may identify its author (VTI-VOT-090)."
941
+ }
942
+ }
943
+ },
944
+ "Trustees": {
945
+ "title": "Trustees",
946
+ "description": "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.",
947
+ "type": "object",
948
+ "additionalProperties": false,
949
+ "required": [
950
+ "dids",
951
+ "threshold"
952
+ ],
953
+ "properties": {
954
+ "dids": {
955
+ "type": "array",
956
+ "minItems": 2,
957
+ "items": {
958
+ "type": "string",
959
+ "minLength": 1,
960
+ "maxLength": 2048
961
+ },
962
+ "uniqueItems": true
963
+ },
964
+ "threshold": {
965
+ "type": "integer",
966
+ "minimum": 2
967
+ }
968
+ }
969
+ },
970
+ "BoardVisibility": {
971
+ "title": "BoardVisibility",
972
+ "description": "`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).",
973
+ "type": "string",
974
+ "enum": [
975
+ "public",
976
+ "private"
977
+ ]
978
+ },
979
+ "Revote": {
980
+ "title": "Revote",
981
+ "description": "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).",
982
+ "type": "string",
983
+ "enum": [
984
+ "replace",
985
+ "refuse"
986
+ ]
987
+ },
988
+ "RollRule": {
989
+ "title": "RollRule",
990
+ "description": "Who may be issued a ticket (VTI-VOT-021): the community's active members (`members`), its active members and the parties `listed` names (`membersAndListed`), only the parties `listed` names (`listed`), or the holders of a membership credential for the one DID `memberOf` names (`credential`), proven by presentation when the holder claims their ticket and never resolved when the election is created (VTI-VOT-025). `memberOf` is present exactly when `rule` is `credential`, and `listed` is never present with it.",
991
+ "type": "object",
992
+ "additionalProperties": false,
993
+ "required": [
994
+ "rule"
995
+ ],
996
+ "properties": {
997
+ "rule": {
998
+ "type": "string",
999
+ "enum": [
1000
+ "members",
1001
+ "membersAndListed",
1002
+ "listed",
1003
+ "credential"
1004
+ ]
1005
+ },
1006
+ "listed": {
1007
+ "type": "array",
1008
+ "items": {
1009
+ "type": "string",
1010
+ "minLength": 1,
1011
+ "maxLength": 2048,
1012
+ "description": "A DID enfranchised by name."
1013
+ },
1014
+ "uniqueItems": true
1015
+ },
1016
+ "memberOf": {
1017
+ "type": "string",
1018
+ "minLength": 8,
1019
+ "maxLength": 2048,
1020
+ "pattern": "^did:[a-z0-9]+:\\S+$",
1021
+ "description": "The DID whose membership credential admits its holder, under the `credential` rule: this community, one of its groups, or a party that is itself an active member of this community — holding a membership credential this community issued it — such as another community, a group of another community, or a network (VTI-VOT-026). Always a DID, never a group's local identifier or name. A community refuses to create an election naming any other DID (vtc/elections/create:rollUntrusted)."
1022
+ }
1023
+ },
1024
+ "dependentSchemas": {
1025
+ "rule": {
1026
+ "anyOf": [
1027
+ {
1028
+ "required": [
1029
+ "memberOf"
1030
+ ]
1031
+ },
1032
+ {
1033
+ "properties": {
1034
+ "rule": {
1035
+ "enum": [
1036
+ "members",
1037
+ "membersAndListed",
1038
+ "listed"
1039
+ ]
1040
+ }
1041
+ }
1042
+ }
1043
+ ]
1044
+ },
1045
+ "memberOf": {
1046
+ "properties": {
1047
+ "rule": {
1048
+ "const": "credential"
1049
+ }
1050
+ },
1051
+ "not": {
1052
+ "required": [
1053
+ "listed"
1054
+ ]
1055
+ }
1056
+ }
1057
+ }
1058
+ },
1059
+ "SecrecyLevel": {
1060
+ "title": "SecrecyLevel",
1061
+ "description": "`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). The encrypted levels are cast with `voting/ballot/cast-encrypted/0.1`, under an election key the trustees generate with `voting/trustees/*` (CONVENTIONS §9).",
1062
+ "type": "string",
1063
+ "enum": [
1064
+ "open",
1065
+ "sealed",
1066
+ "talliedEncrypted"
1067
+ ]
1068
+ },
1069
+ "Question": {
1070
+ "title": "Question",
1071
+ "description": "One question. Tagged union over `type`.",
1072
+ "oneOf": [
1073
+ {
1074
+ "title": "ChoiceQuestion",
1075
+ "description": "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.",
1076
+ "type": "object",
1077
+ "additionalProperties": false,
1078
+ "required": [
1079
+ "key",
1080
+ "type",
1081
+ "options",
1082
+ "minSelections",
1083
+ "maxSelections",
1084
+ "optional"
1085
+ ],
1086
+ "properties": {
1087
+ "key": {
1088
+ "$ref": "#/$defs/Key"
1089
+ },
1090
+ "type": {
1091
+ "const": "choice"
1092
+ },
1093
+ "text": {
1094
+ "type": "string",
1095
+ "maxLength": 2048
1096
+ },
1097
+ "options": {
1098
+ "type": "array",
1099
+ "minItems": 2,
1100
+ "maxItems": 256,
1101
+ "items": {
1102
+ "$ref": "#/$defs/QuestionOption"
1103
+ }
1104
+ },
1105
+ "minSelections": {
1106
+ "type": "integer",
1107
+ "minimum": 0
1108
+ },
1109
+ "maxSelections": {
1110
+ "type": "integer",
1111
+ "minimum": 1
1112
+ },
1113
+ "optional": {
1114
+ "type": "boolean"
1115
+ }
1116
+ }
1117
+ },
1118
+ {
1119
+ "title": "RankingQuestion",
1120
+ "description": "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.",
1121
+ "type": "object",
1122
+ "additionalProperties": false,
1123
+ "required": [
1124
+ "key",
1125
+ "type",
1126
+ "options",
1127
+ "partial",
1128
+ "optional"
1129
+ ],
1130
+ "properties": {
1131
+ "key": {
1132
+ "$ref": "#/$defs/Key"
1133
+ },
1134
+ "type": {
1135
+ "const": "ranking"
1136
+ },
1137
+ "text": {
1138
+ "type": "string",
1139
+ "maxLength": 2048
1140
+ },
1141
+ "options": {
1142
+ "type": "array",
1143
+ "minItems": 2,
1144
+ "maxItems": 64,
1145
+ "items": {
1146
+ "$ref": "#/$defs/QuestionOption"
1147
+ }
1148
+ },
1149
+ "partial": {
1150
+ "type": "boolean"
1151
+ },
1152
+ "optional": {
1153
+ "type": "boolean"
1154
+ }
1155
+ }
1156
+ },
1157
+ {
1158
+ "title": "ScoreQuestion",
1159
+ "description": "Give each option an integer score within [min, max].",
1160
+ "type": "object",
1161
+ "additionalProperties": false,
1162
+ "required": [
1163
+ "key",
1164
+ "type",
1165
+ "options",
1166
+ "min",
1167
+ "max",
1168
+ "optional"
1169
+ ],
1170
+ "properties": {
1171
+ "key": {
1172
+ "$ref": "#/$defs/Key"
1173
+ },
1174
+ "type": {
1175
+ "const": "score"
1176
+ },
1177
+ "text": {
1178
+ "type": "string",
1179
+ "maxLength": 2048
1180
+ },
1181
+ "options": {
1182
+ "type": "array",
1183
+ "minItems": 1,
1184
+ "maxItems": 256,
1185
+ "items": {
1186
+ "$ref": "#/$defs/QuestionOption"
1187
+ }
1188
+ },
1189
+ "min": {
1190
+ "type": "integer"
1191
+ },
1192
+ "max": {
1193
+ "type": "integer"
1194
+ },
1195
+ "optional": {
1196
+ "type": "boolean"
1197
+ }
1198
+ }
1199
+ },
1200
+ {
1201
+ "title": "TextQuestion",
1202
+ "description": "Free text of at most `maxLength` characters.",
1203
+ "type": "object",
1204
+ "additionalProperties": false,
1205
+ "required": [
1206
+ "key",
1207
+ "type",
1208
+ "maxLength",
1209
+ "optional"
1210
+ ],
1211
+ "properties": {
1212
+ "key": {
1213
+ "$ref": "#/$defs/Key"
1214
+ },
1215
+ "type": {
1216
+ "const": "text"
1217
+ },
1218
+ "text": {
1219
+ "type": "string",
1220
+ "maxLength": 2048
1221
+ },
1222
+ "maxLength": {
1223
+ "type": "integer",
1224
+ "minimum": 1,
1225
+ "maximum": 4096
1226
+ },
1227
+ "optional": {
1228
+ "type": "boolean"
1229
+ }
1230
+ }
1231
+ }
1232
+ ]
1233
+ },
1234
+ "Key": {
1235
+ "title": "Key",
1236
+ "description": "A question or option key, unique within its manifest or question.",
1237
+ "type": "string",
1238
+ "pattern": "^[A-Za-z0-9._-]{1,64}$"
1239
+ },
1240
+ "QuestionOption": {
1241
+ "title": "QuestionOption",
1242
+ "type": "object",
1243
+ "additionalProperties": false,
1244
+ "required": [
1245
+ "key"
1246
+ ],
1247
+ "properties": {
1248
+ "key": {
1249
+ "$ref": "#/$defs/Key"
1250
+ },
1251
+ "label": {
1252
+ "type": "string",
1253
+ "maxLength": 512,
1254
+ "description": "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014)."
1255
+ }
1256
+ }
1257
+ },
1258
+ "ElectionId": {
1259
+ "title": "ElectionId",
1260
+ "description": "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.",
1261
+ "type": "string",
1262
+ "pattern": "^[A-Za-z0-9._-]{1,128}$"
1263
+ }
1264
+ }
1265
+ } as const;
1266
+
1267
+ /**
1268
+ * SPEC.md §7.2 policy for the request variant, from this specification's
1269
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
1270
+ * per-specification and cannot be derived from the document alone, and
1271
+ * item 2 needs the schema this carries.
1272
+ */
1273
+ export const SPEC = {
1274
+ typeUri: TYPE_URI,
1275
+ isBearer: false,
1276
+ isProofRequired: true,
1277
+ isRecipientRequired: true,
1278
+ isIssuedAtRequired: true,
1279
+ payloadSchema: PAYLOAD_SCHEMA,
1280
+ } as const;
1281
+
1282
+ /**
1283
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
1284
+ * tracks the *issuer* party's requirement because a response swaps the
1285
+ * parties (§7.3 item 5).
1286
+ */
1287
+ export const RESPONSE_SPEC = {
1288
+ typeUri: RESPONSE_TYPE_URI,
1289
+ isBearer: false,
1290
+ isProofRequired: false,
1291
+ isRecipientRequired: true,
1292
+ isIssuedAtRequired: true,
1293
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
1294
+ } as const;