@openvtc/trust-tasks 0.28.6 → 0.28.7

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 (187) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/_shared/components.d.ts +45 -0
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/index.d.ts +42 -0
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +42 -0
  7. package/dist/index.js.map +1 -1
  8. package/dist/voting/_shared/0.3/voting.d.ts +16 -0
  9. package/dist/voting/_shared/0.3/voting.d.ts.map +1 -0
  10. package/dist/voting/_shared/0.3/voting.js +6 -0
  11. package/dist/voting/_shared/0.3/voting.js.map +1 -0
  12. package/dist/voting/election/register/0.1/payload.d.ts +4 -4
  13. package/dist/voting/election/register/0.1/payload.js +1 -1
  14. package/dist/voting/election/register/0.2/payload.d.ts +13 -2
  15. package/dist/voting/election/register/0.2/payload.d.ts.map +1 -1
  16. package/dist/voting/election/register/0.2/payload.js +1 -1
  17. package/dist/voting/election/register/0.2/payload.js.map +1 -1
  18. package/dist/voting/election/register/0.3/payload.d.ts +1934 -0
  19. package/dist/voting/election/register/0.3/payload.d.ts.map +1 -0
  20. package/dist/voting/election/register/0.3/payload.js +1180 -0
  21. package/dist/voting/election/register/0.3/payload.js.map +1 -0
  22. package/dist/voting/election/show/0.1/payload.d.ts +4 -4
  23. package/dist/voting/election/show/0.1/payload.js +1 -1
  24. package/dist/voting/election/show/0.2/payload.d.ts +13 -2
  25. package/dist/voting/election/show/0.2/payload.d.ts.map +1 -1
  26. package/dist/voting/election/show/0.2/payload.js +1 -1
  27. package/dist/voting/election/show/0.2/payload.js.map +1 -1
  28. package/dist/voting/election/show/0.3/payload.d.ts +1838 -0
  29. package/dist/voting/election/show/0.3/payload.d.ts.map +1 -0
  30. package/dist/voting/election/show/0.3/payload.js +1126 -0
  31. package/dist/voting/election/show/0.3/payload.js.map +1 -0
  32. package/dist/vta/pcs/trustee/deal/0.2/payload.d.ts +4 -4
  33. package/dist/vta/pcs/trustee/deal/0.2/payload.js +1 -1
  34. package/dist/vta/pcs/trustee/deal/0.3/payload.d.ts +13 -2
  35. package/dist/vta/pcs/trustee/deal/0.3/payload.d.ts.map +1 -1
  36. package/dist/vta/pcs/trustee/deal/0.3/payload.js +1 -1
  37. package/dist/vta/pcs/trustee/deal/0.3/payload.js.map +1 -1
  38. package/dist/vta/pcs/trustee/deal/0.4/payload.d.ts +1846 -0
  39. package/dist/vta/pcs/trustee/deal/0.4/payload.d.ts.map +1 -0
  40. package/dist/vta/pcs/trustee/deal/0.4/payload.js +1091 -0
  41. package/dist/vta/pcs/trustee/deal/0.4/payload.js.map +1 -0
  42. package/dist/vta/pcs/trustee/enrol/0.1/payload.d.ts +4 -4
  43. package/dist/vta/pcs/trustee/enrol/0.1/payload.js +1 -1
  44. package/dist/vta/pcs/trustee/enrol/0.2/payload.d.ts +13 -2
  45. package/dist/vta/pcs/trustee/enrol/0.2/payload.d.ts.map +1 -1
  46. package/dist/vta/pcs/trustee/enrol/0.2/payload.js +1 -1
  47. package/dist/vta/pcs/trustee/enrol/0.2/payload.js.map +1 -1
  48. package/dist/vta/pcs/trustee/enrol/0.3/payload.d.ts +1770 -0
  49. package/dist/vta/pcs/trustee/enrol/0.3/payload.d.ts.map +1 -0
  50. package/dist/vta/pcs/trustee/enrol/0.3/payload.js +1054 -0
  51. package/dist/vta/pcs/trustee/enrol/0.3/payload.js.map +1 -0
  52. package/dist/vta/pcs/trustee/justify/0.2/payload.d.ts +4 -4
  53. package/dist/vta/pcs/trustee/justify/0.2/payload.js +1 -1
  54. package/dist/vta/pcs/trustee/justify/0.3/payload.d.ts +13 -2
  55. package/dist/vta/pcs/trustee/justify/0.3/payload.d.ts.map +1 -1
  56. package/dist/vta/pcs/trustee/justify/0.3/payload.js +1 -1
  57. package/dist/vta/pcs/trustee/justify/0.3/payload.js.map +1 -1
  58. package/dist/vta/pcs/trustee/justify/0.4/payload.d.ts +1881 -0
  59. package/dist/vta/pcs/trustee/justify/0.4/payload.d.ts.map +1 -0
  60. package/dist/vta/pcs/trustee/justify/0.4/payload.js +1109 -0
  61. package/dist/vta/pcs/trustee/justify/0.4/payload.js.map +1 -0
  62. package/dist/vta/pcs/trustee/keys/0.2/payload.d.ts +4 -4
  63. package/dist/vta/pcs/trustee/keys/0.2/payload.js +1 -1
  64. package/dist/vta/pcs/trustee/keys/0.3/payload.d.ts +13 -2
  65. package/dist/vta/pcs/trustee/keys/0.3/payload.d.ts.map +1 -1
  66. package/dist/vta/pcs/trustee/keys/0.3/payload.js +1 -1
  67. package/dist/vta/pcs/trustee/keys/0.3/payload.js.map +1 -1
  68. package/dist/vta/pcs/trustee/keys/0.4/payload.d.ts +1926 -0
  69. package/dist/vta/pcs/trustee/keys/0.4/payload.d.ts.map +1 -0
  70. package/dist/vta/pcs/trustee/keys/0.4/payload.js +1129 -0
  71. package/dist/vta/pcs/trustee/keys/0.4/payload.js.map +1 -0
  72. package/dist/vta/pcs/trustee/read/0.1/payload.d.ts +4 -4
  73. package/dist/vta/pcs/trustee/read/0.1/payload.js +1 -1
  74. package/dist/vta/pcs/trustee/read/0.2/payload.d.ts +14 -2
  75. package/dist/vta/pcs/trustee/read/0.2/payload.d.ts.map +1 -1
  76. package/dist/vta/pcs/trustee/read/0.2/payload.js +1 -1
  77. package/dist/vta/pcs/trustee/read/0.2/payload.js.map +1 -1
  78. package/dist/vta/pcs/trustee/read/0.3/payload.d.ts +540 -0
  79. package/dist/vta/pcs/trustee/read/0.3/payload.d.ts.map +1 -0
  80. package/dist/vta/pcs/trustee/read/0.3/payload.js +304 -0
  81. package/dist/vta/pcs/trustee/read/0.3/payload.js.map +1 -0
  82. package/dist/vta/pcs/vote/0.1/payload.d.ts +4 -4
  83. package/dist/vta/pcs/vote/0.1/payload.js +1 -1
  84. package/dist/vta/pcs/vote/0.2/payload.d.ts +13 -2
  85. package/dist/vta/pcs/vote/0.2/payload.d.ts.map +1 -1
  86. package/dist/vta/pcs/vote/0.2/payload.js +1 -1
  87. package/dist/vta/pcs/vote/0.2/payload.js.map +1 -1
  88. package/dist/vta/pcs/vote/0.3/payload.d.ts +2222 -0
  89. package/dist/vta/pcs/vote/0.3/payload.d.ts.map +1 -0
  90. package/dist/vta/pcs/vote/0.3/payload.js +1296 -0
  91. package/dist/vta/pcs/vote/0.3/payload.js.map +1 -0
  92. package/dist/vta/pcs/vote-encrypted/0.2/payload.d.ts +4 -4
  93. package/dist/vta/pcs/vote-encrypted/0.2/payload.js +1 -1
  94. package/dist/vta/pcs/vote-encrypted/0.3/payload.d.ts +13 -2
  95. package/dist/vta/pcs/vote-encrypted/0.3/payload.d.ts.map +1 -1
  96. package/dist/vta/pcs/vote-encrypted/0.3/payload.js +1 -1
  97. package/dist/vta/pcs/vote-encrypted/0.3/payload.js.map +1 -1
  98. package/dist/vta/pcs/vote-encrypted/0.4/payload.d.ts +2242 -0
  99. package/dist/vta/pcs/vote-encrypted/0.4/payload.d.ts.map +1 -0
  100. package/dist/vta/pcs/vote-encrypted/0.4/payload.js +1314 -0
  101. package/dist/vta/pcs/vote-encrypted/0.4/payload.js.map +1 -0
  102. package/dist/vta/pcs/voter/read/0.1/payload.d.ts +4 -4
  103. package/dist/vta/pcs/voter/read/0.1/payload.js +1 -1
  104. package/dist/vta/pcs/voter/read/0.2/payload.d.ts +14 -2
  105. package/dist/vta/pcs/voter/read/0.2/payload.d.ts.map +1 -1
  106. package/dist/vta/pcs/voter/read/0.2/payload.js +1 -1
  107. package/dist/vta/pcs/voter/read/0.2/payload.js.map +1 -1
  108. package/dist/vta/pcs/voter/read/0.3/payload.d.ts +503 -0
  109. package/dist/vta/pcs/voter/read/0.3/payload.d.ts.map +1 -0
  110. package/dist/vta/pcs/voter/read/0.3/payload.js +285 -0
  111. package/dist/vta/pcs/voter/read/0.3/payload.js.map +1 -0
  112. package/dist/vta/pcs/voter/register/0.1/payload.d.ts +4 -4
  113. package/dist/vta/pcs/voter/register/0.1/payload.js +1 -1
  114. package/dist/vta/pcs/voter/register/0.2/payload.d.ts +14 -2
  115. package/dist/vta/pcs/voter/register/0.2/payload.d.ts.map +1 -1
  116. package/dist/vta/pcs/voter/register/0.2/payload.js +1 -1
  117. package/dist/vta/pcs/voter/register/0.2/payload.js.map +1 -1
  118. package/dist/vta/pcs/voter/register/0.3/payload.d.ts +2176 -0
  119. package/dist/vta/pcs/voter/register/0.3/payload.d.ts.map +1 -0
  120. package/dist/vta/pcs/voter/register/0.3/payload.js +1262 -0
  121. package/dist/vta/pcs/voter/register/0.3/payload.js.map +1 -0
  122. package/dist/vtc/elections/create/0.1/payload.d.ts +4 -4
  123. package/dist/vtc/elections/create/0.1/payload.js +1 -1
  124. package/dist/vtc/elections/create/0.2/payload.d.ts +4 -4
  125. package/dist/vtc/elections/create/0.2/payload.js +1 -1
  126. package/dist/vtc/elections/create/0.3/payload.d.ts +14 -2
  127. package/dist/vtc/elections/create/0.3/payload.d.ts.map +1 -1
  128. package/dist/vtc/elections/create/0.3/payload.js +1 -1
  129. package/dist/vtc/elections/create/0.3/payload.js.map +1 -1
  130. package/dist/vtc/elections/create/0.4/payload.d.ts +1670 -0
  131. package/dist/vtc/elections/create/0.4/payload.d.ts.map +1 -0
  132. package/dist/vtc/elections/create/0.4/payload.js +1008 -0
  133. package/dist/vtc/elections/create/0.4/payload.js.map +1 -0
  134. package/dist/vtc/elections/show/0.1/payload.d.ts +4 -4
  135. package/dist/vtc/elections/show/0.1/payload.js +1 -1
  136. package/dist/vtc/elections/show/0.2/payload.d.ts +14 -2
  137. package/dist/vtc/elections/show/0.2/payload.d.ts.map +1 -1
  138. package/dist/vtc/elections/show/0.2/payload.js +1 -1
  139. package/dist/vtc/elections/show/0.2/payload.js.map +1 -1
  140. package/dist/vtc/elections/show/0.3/payload.d.ts +3022 -0
  141. package/dist/vtc/elections/show/0.3/payload.d.ts.map +1 -0
  142. package/dist/vtc/elections/show/0.3/payload.js +1765 -0
  143. package/dist/vtc/elections/show/0.3/payload.js.map +1 -0
  144. package/package.json +1 -1
  145. package/src/_shared/components.ts +45 -0
  146. package/src/index.ts +42 -0
  147. package/src/voting/_shared/0.3/voting.ts +17 -0
  148. package/src/voting/election/register/0.1/payload.ts +5 -5
  149. package/src/voting/election/register/0.2/payload.ts +14 -3
  150. package/src/voting/election/register/0.3/payload.ts +1223 -0
  151. package/src/voting/election/show/0.1/payload.ts +5 -5
  152. package/src/voting/election/show/0.2/payload.ts +14 -3
  153. package/src/voting/election/show/0.3/payload.ts +1165 -0
  154. package/src/vta/pcs/trustee/deal/0.2/payload.ts +5 -5
  155. package/src/vta/pcs/trustee/deal/0.3/payload.ts +14 -3
  156. package/src/vta/pcs/trustee/deal/0.4/payload.ts +1164 -0
  157. package/src/vta/pcs/trustee/enrol/0.1/payload.ts +5 -5
  158. package/src/vta/pcs/trustee/enrol/0.2/payload.ts +14 -3
  159. package/src/vta/pcs/trustee/enrol/0.3/payload.ts +1123 -0
  160. package/src/vta/pcs/trustee/justify/0.2/payload.ts +5 -5
  161. package/src/vta/pcs/trustee/justify/0.3/payload.ts +14 -3
  162. package/src/vta/pcs/trustee/justify/0.4/payload.ts +1183 -0
  163. package/src/vta/pcs/trustee/keys/0.2/payload.ts +5 -5
  164. package/src/vta/pcs/trustee/keys/0.3/payload.ts +14 -3
  165. package/src/vta/pcs/trustee/keys/0.4/payload.ts +1210 -0
  166. package/src/vta/pcs/trustee/read/0.1/payload.ts +5 -5
  167. package/src/vta/pcs/trustee/read/0.2/payload.ts +15 -3
  168. package/src/vta/pcs/trustee/read/0.3/payload.ts +385 -0
  169. package/src/vta/pcs/vote/0.1/payload.ts +5 -5
  170. package/src/vta/pcs/vote/0.2/payload.ts +14 -3
  171. package/src/vta/pcs/vote/0.3/payload.ts +1381 -0
  172. package/src/vta/pcs/vote-encrypted/0.2/payload.ts +5 -5
  173. package/src/vta/pcs/vote-encrypted/0.3/payload.ts +14 -3
  174. package/src/vta/pcs/vote-encrypted/0.4/payload.ts +1385 -0
  175. package/src/vta/pcs/voter/read/0.1/payload.ts +5 -5
  176. package/src/vta/pcs/voter/read/0.2/payload.ts +15 -3
  177. package/src/vta/pcs/voter/read/0.3/payload.ts +363 -0
  178. package/src/vta/pcs/voter/register/0.1/payload.ts +5 -5
  179. package/src/vta/pcs/voter/register/0.2/payload.ts +15 -3
  180. package/src/vta/pcs/voter/register/0.3/payload.ts +1372 -0
  181. package/src/vtc/elections/create/0.1/payload.ts +5 -5
  182. package/src/vtc/elections/create/0.2/payload.ts +5 -5
  183. package/src/vtc/elections/create/0.3/payload.ts +15 -3
  184. package/src/vtc/elections/create/0.4/payload.ts +1057 -0
  185. package/src/vtc/elections/show/0.1/payload.ts +5 -5
  186. package/src/vtc/elections/show/0.2/payload.ts +15 -3
  187. package/src/vtc/elections/show/0.3/payload.ts +1865 -0
@@ -9,7 +9,7 @@ import type { Ext } from "../../../../../_shared/components.js";
9
9
  /**
10
10
  * A voter's client asks its VTA for a vtc/elections/list or vtc/elections/show request signed as the voter's membership DID, so the client can read the community's elections as the member without holding the member's key.
11
11
  *
12
- * @deprecated superseded by vta/pcs/voter/read/0.2
12
+ * @deprecated superseded by vta/pcs/voter/read/0.3
13
13
  */
14
14
  export interface VTAPCSVoterReadPayload {
15
15
  /**
@@ -37,7 +37,7 @@ export interface VTAPCSVoterReadPayload {
37
37
  /**
38
38
  * The signed read, to send to the community.
39
39
  *
40
- * @deprecated superseded by vta/pcs/voter/read/0.2
40
+ * @deprecated superseded by vta/pcs/voter/read/0.3
41
41
  */
42
42
  export interface VTAPCSVoterReadResponsePayload {
43
43
  document: ReadDocument;
@@ -89,12 +89,12 @@ export const EXTENDS: string | null = null;
89
89
  * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
90
90
  * Versions").
91
91
  */
92
- export const DEPRECATION: string | null = "superseded by vta/pcs/voter/read/0.2";
92
+ export const DEPRECATION: string | null = "superseded by vta/pcs/voter/read/0.3";
93
93
 
94
94
  /**
95
95
  * Stable alias for this specification's request payload shape.
96
96
  *
97
- * @deprecated superseded by vta/pcs/voter/read/0.2
97
+ * @deprecated superseded by vta/pcs/voter/read/0.3
98
98
  */
99
99
  export type Payload = VTAPCSVoterReadPayload;
100
100
 
@@ -104,7 +104,7 @@ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/read
104
104
  /**
105
105
  * Stable alias for this specification's success-response payload shape.
106
106
  *
107
- * @deprecated superseded by vta/pcs/voter/read/0.2
107
+ * @deprecated superseded by vta/pcs/voter/read/0.3
108
108
  */
109
109
  export type Response = VTAPCSVoterReadResponsePayload;
110
110
 
@@ -8,6 +8,8 @@ import type { Ext } from "../../../../../_shared/components.js";
8
8
 
9
9
  /**
10
10
  * A voter's client asks its VTA for a vtc/elections/list or vtc/elections/show request signed as the voter's membership DID, so the client can read the community's elections as the member without holding the member's key.
11
+ *
12
+ * @deprecated superseded by vta/pcs/voter/read/0.3
11
13
  */
12
14
  export interface VTAPCSVoterReadPayload {
13
15
  /**
@@ -34,6 +36,8 @@ export interface VTAPCSVoterReadPayload {
34
36
  }
35
37
  /**
36
38
  * The signed read, to send to the community.
39
+ *
40
+ * @deprecated superseded by vta/pcs/voter/read/0.3
37
41
  */
38
42
  export interface VTAPCSVoterReadResponsePayload {
39
43
  document: ReadDocument;
@@ -85,15 +89,23 @@ export const EXTENDS: string | null = null;
85
89
  * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
86
90
  * Versions").
87
91
  */
88
- export const DEPRECATION: string | null = null;
92
+ export const DEPRECATION: string | null = "superseded by vta/pcs/voter/read/0.3";
89
93
 
90
- /** Stable alias for this specification's request payload shape. */
94
+ /**
95
+ * Stable alias for this specification's request payload shape.
96
+ *
97
+ * @deprecated superseded by vta/pcs/voter/read/0.3
98
+ */
91
99
  export type Payload = VTAPCSVoterReadPayload;
92
100
 
93
101
  /** Trust Task response type URI (request type URI + "#response"). */
94
102
  export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/read/0.2#response" as const;
95
103
 
96
- /** Stable alias for this specification's success-response payload shape. */
104
+ /**
105
+ * Stable alias for this specification's success-response payload shape.
106
+ *
107
+ * @deprecated superseded by vta/pcs/voter/read/0.3
108
+ */
97
109
  export type Response = VTAPCSVoterReadResponsePayload;
98
110
 
99
111
  /**
@@ -0,0 +1,363 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/vta/pcs/voter/read/0.3/payload.schema.json
4
+ */
5
+
6
+ import type { Ext } from "../../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * A voter's client asks its VTA for a vtc/elections/list or vtc/elections/show request signed as the voter's membership DID, so the client can read the community's elections as the member without holding the member's key.
11
+ */
12
+ export interface VTAPCSVoterReadPayload {
13
+ /**
14
+ * The context the voter belongs to.
15
+ */
16
+ contextId: string;
17
+ /**
18
+ * The community's DID: the recipient of the signed request.
19
+ */
20
+ community: string;
21
+ /**
22
+ * The voter's membership DID at the community. MUST be a DID the engine holds an authentication key of that the caller may act as.
23
+ */
24
+ member: string;
25
+ /**
26
+ * Which read to sign: vtc/elections/list/0.3 or vtc/elections/show/0.3.
27
+ */
28
+ read: "list" | "show";
29
+ /**
30
+ * The request payload of that task, validated against its own schema.
31
+ */
32
+ payload: {};
33
+ ext?: Ext;
34
+ }
35
+ /**
36
+ * The signed read, to send to the community.
37
+ */
38
+ export interface VTAPCSVoterReadResponsePayload {
39
+ document: ReadDocument;
40
+ ext?: Ext;
41
+ }
42
+ /**
43
+ * A complete, signed vtc/elections/list/0.3 or vtc/elections/show/0.3 request document, ready to send to the community unchanged.
44
+ */
45
+ export interface ReadDocument {
46
+ id: string;
47
+ type: "https://trusttasks.org/spec/vtc/elections/list/0.3" | "https://trusttasks.org/spec/vtc/elections/show/0.3";
48
+ /**
49
+ * The request's `member`.
50
+ */
51
+ issuer: string;
52
+ /**
53
+ * The request's `community`.
54
+ */
55
+ recipient: string;
56
+ issuedAt: string;
57
+ expiresAt?: string;
58
+ /**
59
+ * The request's `payload`, exactly.
60
+ */
61
+ payload: {};
62
+ /**
63
+ * A Data Integrity proof by an `authentication` key of `issuer`.
64
+ */
65
+ proof: {};
66
+ }
67
+
68
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
69
+ export type { Ext };
70
+
71
+ /** Trust Task type URI. */
72
+ export const TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/read/0.3" as const;
73
+
74
+ /**
75
+ * The earlier version of this specification that this one declares it
76
+ * extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
77
+ * `null`. Only the direct declaration — follow the chain with
78
+ * `extendsChain` / `readForSpec`.
79
+ */
80
+ export const EXTENDS: string | null = null;
81
+
82
+ /**
83
+ * Why this version is deprecated, or `null` while it is current. A
84
+ * superseded or retired version is still supported, and is withdrawn from
85
+ * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
86
+ * Versions").
87
+ */
88
+ export const DEPRECATION: string | null = null;
89
+
90
+ /** Stable alias for this specification's request payload shape. */
91
+ export type Payload = VTAPCSVoterReadPayload;
92
+
93
+ /** Trust Task response type URI (request type URI + "#response"). */
94
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/read/0.3#response" as const;
95
+
96
+ /** Stable alias for this specification's success-response payload shape. */
97
+ export type Response = VTAPCSVoterReadResponsePayload;
98
+
99
+ /**
100
+ * This specification's payload schema, as a value.
101
+ *
102
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
103
+ * rather than only as a `.json` file because TypeScript types are erased
104
+ * at runtime: without a schema a consumer has nothing to validate, and
105
+ * every REQUIRED payload member is optional in practice. Cross-file
106
+ * `$ref`s are already inlined, so it needs no resolver.
107
+ */
108
+ export const PAYLOAD_SCHEMA = {
109
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
110
+ "$id": "https://trusttasks.org/spec/vta/pcs/voter/read/0.3",
111
+ "title": "VTA PCS — Voter Read — payload",
112
+ "description": "A voter's client asks its VTA for a vtc/elections/list or vtc/elections/show request signed as the voter's membership DID, so the client can read the community's elections as the member without holding the member's key.",
113
+ "type": "object",
114
+ "additionalProperties": false,
115
+ "required": [
116
+ "contextId",
117
+ "community",
118
+ "member",
119
+ "read",
120
+ "payload"
121
+ ],
122
+ "properties": {
123
+ "contextId": {
124
+ "type": "string",
125
+ "minLength": 1,
126
+ "maxLength": 256,
127
+ "description": "The context the voter belongs to."
128
+ },
129
+ "community": {
130
+ "type": "string",
131
+ "minLength": 1,
132
+ "maxLength": 2048,
133
+ "description": "The community's DID: the recipient of the signed request."
134
+ },
135
+ "member": {
136
+ "type": "string",
137
+ "minLength": 1,
138
+ "maxLength": 2048,
139
+ "pattern": "^did:",
140
+ "description": "The voter's membership DID at the community. MUST be a DID the engine holds an authentication key of that the caller may act as."
141
+ },
142
+ "read": {
143
+ "type": "string",
144
+ "enum": [
145
+ "list",
146
+ "show"
147
+ ],
148
+ "description": "Which read to sign: vtc/elections/list/0.3 or vtc/elections/show/0.3."
149
+ },
150
+ "payload": {
151
+ "type": "object",
152
+ "description": "The request payload of that task, validated against its own schema."
153
+ },
154
+ "ext": {
155
+ "$ref": "#/$defs/Ext"
156
+ }
157
+ },
158
+ "$defs": {
159
+ "ReadDocument": {
160
+ "title": "ReadDocument",
161
+ "description": "A complete, signed vtc/elections/list/0.3 or vtc/elections/show/0.3 request document, ready to send to the community unchanged.",
162
+ "type": "object",
163
+ "required": [
164
+ "id",
165
+ "type",
166
+ "issuer",
167
+ "recipient",
168
+ "issuedAt",
169
+ "payload",
170
+ "proof"
171
+ ],
172
+ "properties": {
173
+ "id": {
174
+ "type": "string",
175
+ "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}$"
176
+ },
177
+ "type": {
178
+ "type": "string",
179
+ "enum": [
180
+ "https://trusttasks.org/spec/vtc/elections/list/0.3",
181
+ "https://trusttasks.org/spec/vtc/elections/show/0.3"
182
+ ]
183
+ },
184
+ "issuer": {
185
+ "type": "string",
186
+ "minLength": 1,
187
+ "maxLength": 2048,
188
+ "description": "The request's `member`."
189
+ },
190
+ "recipient": {
191
+ "type": "string",
192
+ "minLength": 1,
193
+ "maxLength": 2048,
194
+ "description": "The request's `community`."
195
+ },
196
+ "issuedAt": {
197
+ "type": "string",
198
+ "format": "date-time"
199
+ },
200
+ "expiresAt": {
201
+ "type": "string",
202
+ "format": "date-time"
203
+ },
204
+ "payload": {
205
+ "type": "object",
206
+ "description": "The request's `payload`, exactly."
207
+ },
208
+ "proof": {
209
+ "type": "object",
210
+ "description": "A Data Integrity proof by an `authentication` key of `issuer`."
211
+ }
212
+ }
213
+ },
214
+ "Response": {
215
+ "$anchor": "response",
216
+ "title": "VTA PCS — Voter Read — response payload",
217
+ "description": "The signed read, to send to the community.",
218
+ "type": "object",
219
+ "additionalProperties": false,
220
+ "required": [
221
+ "document"
222
+ ],
223
+ "properties": {
224
+ "document": {
225
+ "$ref": "#/$defs/ReadDocument"
226
+ },
227
+ "ext": {
228
+ "$ref": "#/$defs/Ext"
229
+ }
230
+ }
231
+ },
232
+ "Ext": {
233
+ "title": "Ext",
234
+ "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.",
235
+ "type": "object",
236
+ "minProperties": 1,
237
+ "additionalProperties": true,
238
+ "propertyNames": {
239
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
240
+ }
241
+ }
242
+ }
243
+ } as const;
244
+
245
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
246
+ export const RESPONSE_PAYLOAD_SCHEMA = {
247
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
248
+ "$ref": "#/$defs/Response",
249
+ "$defs": {
250
+ "ReadDocument": {
251
+ "title": "ReadDocument",
252
+ "description": "A complete, signed vtc/elections/list/0.3 or vtc/elections/show/0.3 request document, ready to send to the community unchanged.",
253
+ "type": "object",
254
+ "required": [
255
+ "id",
256
+ "type",
257
+ "issuer",
258
+ "recipient",
259
+ "issuedAt",
260
+ "payload",
261
+ "proof"
262
+ ],
263
+ "properties": {
264
+ "id": {
265
+ "type": "string",
266
+ "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}$"
267
+ },
268
+ "type": {
269
+ "type": "string",
270
+ "enum": [
271
+ "https://trusttasks.org/spec/vtc/elections/list/0.3",
272
+ "https://trusttasks.org/spec/vtc/elections/show/0.3"
273
+ ]
274
+ },
275
+ "issuer": {
276
+ "type": "string",
277
+ "minLength": 1,
278
+ "maxLength": 2048,
279
+ "description": "The request's `member`."
280
+ },
281
+ "recipient": {
282
+ "type": "string",
283
+ "minLength": 1,
284
+ "maxLength": 2048,
285
+ "description": "The request's `community`."
286
+ },
287
+ "issuedAt": {
288
+ "type": "string",
289
+ "format": "date-time"
290
+ },
291
+ "expiresAt": {
292
+ "type": "string",
293
+ "format": "date-time"
294
+ },
295
+ "payload": {
296
+ "type": "object",
297
+ "description": "The request's `payload`, exactly."
298
+ },
299
+ "proof": {
300
+ "type": "object",
301
+ "description": "A Data Integrity proof by an `authentication` key of `issuer`."
302
+ }
303
+ }
304
+ },
305
+ "Response": {
306
+ "$anchor": "response",
307
+ "title": "VTA PCS — Voter Read — response payload",
308
+ "description": "The signed read, to send to the community.",
309
+ "type": "object",
310
+ "additionalProperties": false,
311
+ "required": [
312
+ "document"
313
+ ],
314
+ "properties": {
315
+ "document": {
316
+ "$ref": "#/$defs/ReadDocument"
317
+ },
318
+ "ext": {
319
+ "$ref": "#/$defs/Ext"
320
+ }
321
+ }
322
+ },
323
+ "Ext": {
324
+ "title": "Ext",
325
+ "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.",
326
+ "type": "object",
327
+ "minProperties": 1,
328
+ "additionalProperties": true,
329
+ "propertyNames": {
330
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
331
+ }
332
+ }
333
+ }
334
+ } as const;
335
+
336
+ /**
337
+ * SPEC.md §7.2 policy for the request variant, from this specification's
338
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
339
+ * per-specification and cannot be derived from the document alone, and
340
+ * item 2 needs the schema this carries.
341
+ */
342
+ export const SPEC = {
343
+ typeUri: TYPE_URI,
344
+ isBearer: false,
345
+ isProofRequired: true,
346
+ isRecipientRequired: true,
347
+ isIssuedAtRequired: true,
348
+ payloadSchema: PAYLOAD_SCHEMA,
349
+ } as const;
350
+
351
+ /**
352
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
353
+ * tracks the *issuer* party's requirement because a response swaps the
354
+ * parties (§7.3 item 5).
355
+ */
356
+ export const RESPONSE_SPEC = {
357
+ typeUri: RESPONSE_TYPE_URI,
358
+ isBearer: false,
359
+ isProofRequired: false,
360
+ isRecipientRequired: true,
361
+ isIssuedAtRequired: true,
362
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
363
+ } as const;
@@ -14,7 +14,7 @@ export type PcsValue = string;
14
14
  /**
15
15
  * A voter's client asks its VTA for the blinded request that obtains the voter's ticket for one election; the VTA derives a voter key for that election alone and keeps the blinding state.
16
16
  *
17
- * @deprecated superseded by vta/pcs/voter/register/0.2
17
+ * @deprecated superseded by vta/pcs/voter/register/0.3
18
18
  */
19
19
  export interface VTAPCSVoterRegisterPayload {
20
20
  /**
@@ -42,7 +42,7 @@ export interface VTAPCSVoterRegisterPayload {
42
42
  /**
43
43
  * Exactly the vtc/elections/tickets/issue/0.1 request payload, without its ext — and, when the request named `member`, that request as a document signed as the member.
44
44
  *
45
- * @deprecated superseded by vta/pcs/voter/register/0.2
45
+ * @deprecated superseded by vta/pcs/voter/register/0.3
46
46
  */
47
47
  export interface VTAPCSVoterRegisterResponsePayload {
48
48
  electionId: ElectionId;
@@ -121,12 +121,12 @@ export const EXTENDS: string | null = null;
121
121
  * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
122
122
  * Versions").
123
123
  */
124
- export const DEPRECATION: string | null = "superseded by vta/pcs/voter/register/0.2";
124
+ export const DEPRECATION: string | null = "superseded by vta/pcs/voter/register/0.3";
125
125
 
126
126
  /**
127
127
  * Stable alias for this specification's request payload shape.
128
128
  *
129
- * @deprecated superseded by vta/pcs/voter/register/0.2
129
+ * @deprecated superseded by vta/pcs/voter/register/0.3
130
130
  */
131
131
  export type Payload = VTAPCSVoterRegisterPayload;
132
132
 
@@ -136,7 +136,7 @@ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/regi
136
136
  /**
137
137
  * Stable alias for this specification's success-response payload shape.
138
138
  *
139
- * @deprecated superseded by vta/pcs/voter/register/0.2
139
+ * @deprecated superseded by vta/pcs/voter/register/0.3
140
140
  */
141
141
  export type Response = VTAPCSVoterRegisterResponsePayload;
142
142
 
@@ -13,6 +13,8 @@ export type PcsValue = string;
13
13
 
14
14
  /**
15
15
  * A voter's client asks its VTA for the blinded request that obtains the voter's ticket for one election; the VTA derives a voter key for that election alone and keeps the blinding state.
16
+ *
17
+ * @deprecated superseded by vta/pcs/voter/register/0.3
16
18
  */
17
19
  export interface VTAPCSVoterRegisterPayload {
18
20
  /**
@@ -39,6 +41,8 @@ export interface VTAPCSVoterRegisterPayload {
39
41
  }
40
42
  /**
41
43
  * Exactly the vtc/elections/tickets/issue/0.1 request payload, without its ext — and, when the request named `member`, that request as a document signed as the member.
44
+ *
45
+ * @deprecated superseded by vta/pcs/voter/register/0.3
42
46
  */
43
47
  export interface VTAPCSVoterRegisterResponsePayload {
44
48
  electionId: ElectionId;
@@ -117,15 +121,23 @@ export const EXTENDS: string | null = null;
117
121
  * this package in a later scheduled batch (SPEC "Superseded and Withdrawn
118
122
  * Versions").
119
123
  */
120
- export const DEPRECATION: string | null = null;
124
+ export const DEPRECATION: string | null = "superseded by vta/pcs/voter/register/0.3";
121
125
 
122
- /** Stable alias for this specification's request payload shape. */
126
+ /**
127
+ * Stable alias for this specification's request payload shape.
128
+ *
129
+ * @deprecated superseded by vta/pcs/voter/register/0.3
130
+ */
123
131
  export type Payload = VTAPCSVoterRegisterPayload;
124
132
 
125
133
  /** Trust Task response type URI (request type URI + "#response"). */
126
134
  export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/vta/pcs/voter/register/0.2#response" as const;
127
135
 
128
- /** Stable alias for this specification's success-response payload shape. */
136
+ /**
137
+ * Stable alias for this specification's success-response payload shape.
138
+ *
139
+ * @deprecated superseded by vta/pcs/voter/register/0.3
140
+ */
129
141
  export type Response = VTAPCSVoterRegisterResponsePayload;
130
142
 
131
143
  /**