@openvtc/trust-tasks 0.28.6 → 0.28.8

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