@openvtc/trust-tasks 0.28.12 → 0.28.13
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.
- package/CHANGELOG.md +9 -0
- package/dist/_shared/components.d.ts +458 -0
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/index.d.ts +42 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +42 -0
- package/dist/index.js.map +1 -1
- package/dist/vtc/boards/_shared/0.1/board.d.ts +22 -0
- package/dist/vtc/boards/_shared/0.1/board.d.ts.map +1 -0
- package/dist/vtc/boards/_shared/0.1/board.js +6 -0
- package/dist/vtc/boards/_shared/0.1/board.js.map +1 -0
- package/dist/vtc/boards/create/0.1/payload.d.ts +2402 -0
- package/dist/vtc/boards/create/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/create/0.1/payload.js +1349 -0
- package/dist/vtc/boards/create/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/ideas/decide/0.1/payload.d.ts +1781 -0
- package/dist/vtc/boards/ideas/decide/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/ideas/decide/0.1/payload.js +1028 -0
- package/dist/vtc/boards/ideas/decide/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/ideas/propose/0.1/payload.d.ts +1781 -0
- package/dist/vtc/boards/ideas/propose/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/ideas/propose/0.1/payload.js +1025 -0
- package/dist/vtc/boards/ideas/propose/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/ideas/select/0.1/payload.d.ts +1788 -0
- package/dist/vtc/boards/ideas/select/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/ideas/select/0.1/payload.js +1029 -0
- package/dist/vtc/boards/ideas/select/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/ideas/update/0.1/payload.d.ts +1781 -0
- package/dist/vtc/boards/ideas/update/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/ideas/update/0.1/payload.js +1023 -0
- package/dist/vtc/boards/ideas/update/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/ideas/withdraw/0.1/payload.d.ts +1753 -0
- package/dist/vtc/boards/ideas/withdraw/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/ideas/withdraw/0.1/payload.js +1011 -0
- package/dist/vtc/boards/ideas/withdraw/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/list/0.1/payload.d.ts +2267 -0
- package/dist/vtc/boards/list/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/list/0.1/payload.js +1326 -0
- package/dist/vtc/boards/list/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/notes/add/0.1/payload.d.ts +655 -0
- package/dist/vtc/boards/notes/add/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/notes/add/0.1/payload.js +374 -0
- package/dist/vtc/boards/notes/add/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/notes/hide/0.1/payload.d.ts +657 -0
- package/dist/vtc/boards/notes/hide/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/notes/hide/0.1/payload.js +378 -0
- package/dist/vtc/boards/notes/hide/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/notes/list/0.1/payload.d.ts +730 -0
- package/dist/vtc/boards/notes/list/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/notes/list/0.1/payload.js +406 -0
- package/dist/vtc/boards/notes/list/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/notes/withdraw/0.1/payload.d.ts +641 -0
- package/dist/vtc/boards/notes/withdraw/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/notes/withdraw/0.1/payload.js +367 -0
- package/dist/vtc/boards/notes/withdraw/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/show/0.1/payload.d.ts +3713 -0
- package/dist/vtc/boards/show/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/show/0.1/payload.js +2160 -0
- package/dist/vtc/boards/show/0.1/payload.js.map +1 -0
- package/dist/vtc/boards/update/0.1/payload.d.ts +2423 -0
- package/dist/vtc/boards/update/0.1/payload.d.ts.map +1 -0
- package/dist/vtc/boards/update/0.1/payload.js +1356 -0
- package/dist/vtc/boards/update/0.1/payload.js.map +1 -0
- package/package.json +1 -1
- package/src/_shared/components.ts +493 -0
- package/src/index.ts +42 -0
- package/src/vtc/boards/_shared/0.1/board.ts +23 -0
- package/src/vtc/boards/create/0.1/payload.ts +1517 -0
- package/src/vtc/boards/ideas/decide/0.1/payload.ts +1068 -0
- package/src/vtc/boards/ideas/propose/0.1/payload.ts +1063 -0
- package/src/vtc/boards/ideas/select/0.1/payload.ts +1070 -0
- package/src/vtc/boards/ideas/update/0.1/payload.ts +1061 -0
- package/src/vtc/boards/ideas/withdraw/0.1/payload.ts +1045 -0
- package/src/vtc/boards/list/0.1/payload.ts +1376 -0
- package/src/vtc/boards/notes/add/0.1/payload.ts +410 -0
- package/src/vtc/boards/notes/hide/0.1/payload.ts +414 -0
- package/src/vtc/boards/notes/list/0.1/payload.ts +457 -0
- package/src/vtc/boards/notes/withdraw/0.1/payload.ts +401 -0
- package/src/vtc/boards/show/0.1/payload.ts +2212 -0
- package/src/vtc/boards/update/0.1/payload.ts +1529 -0
|
@@ -0,0 +1,3713 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/vtc/boards/show/0.1/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
import type { Author, Board, BoardAudience, BoardDescription, BoardHead, BoardId, BoardStatus, BoardTitle, BoardVisibility, ChoiceQuestion, DigestMultibase, ElectionId, ElectionResult, ElectionState, ElectionTemplate, EntryId, Ext, GroupId, Idea, IdeaDecision, IdeaDescription, IdeaElection, IdeaFormat, IdeaId, IdeaOpening, IdeaState, IdeaTitle, Key_VotingV0_1 as Key, Question, QuestionOption, QuestionResult, RankingQuestion, Reason_VtcBoardsV0_1 as Reason, Revote, ScoreQuestion, SecrecyLevel, Slot_VtcBoardsV0_1 as Slot, TextQuestion, Topic_VtcBoardsV0_1 as Topic, Trustees, Window } from "../../../../_shared/components.js";
|
|
6
|
+
/**
|
|
7
|
+
* Show one board and its ideas as the caller may see them, with each accepted idea's election stage, ballot count where its board is public, and result once tallied — never who took a ticket or voted. The outer document members are owned by the framework — SPEC §6.3.
|
|
8
|
+
*/
|
|
9
|
+
export interface VTCBoardsShowPayload {
|
|
10
|
+
boardId: BoardId;
|
|
11
|
+
/**
|
|
12
|
+
* @minItems 1
|
|
13
|
+
*/
|
|
14
|
+
state?: [IdeaState, ...IdeaState[]];
|
|
15
|
+
topic?: Topic;
|
|
16
|
+
/**
|
|
17
|
+
* An opaque continuation token from a previous response's `nextCursor`, bound to the caller and the filters; a responder MUST NOT accept a cursor it did not issue.
|
|
18
|
+
*/
|
|
19
|
+
cursor?: string;
|
|
20
|
+
/**
|
|
21
|
+
* The most items to return, at most 200; the responder chooses a default (50) and MAY return fewer.
|
|
22
|
+
*/
|
|
23
|
+
limit?: number;
|
|
24
|
+
ext?: Ext;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* The success response to a vtc/boards/show/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/boards/show/0.1#response.
|
|
28
|
+
*/
|
|
29
|
+
export interface VTCBoardsShowResponsePayload {
|
|
30
|
+
board: Board;
|
|
31
|
+
ideas: Idea[];
|
|
32
|
+
/**
|
|
33
|
+
* Continuation token for the next page; pass it back as `cursor`. Absent on the last page — never `null`.
|
|
34
|
+
*/
|
|
35
|
+
nextCursor?: string;
|
|
36
|
+
ext?: Ext;
|
|
37
|
+
}
|
|
38
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
39
|
+
export type { Author, Board, BoardAudience, BoardDescription, BoardHead, BoardId, BoardStatus, BoardTitle, BoardVisibility, ChoiceQuestion, DigestMultibase, ElectionId, ElectionResult, ElectionState, ElectionTemplate, EntryId, Ext, GroupId, Idea, IdeaDecision, IdeaDescription, IdeaElection, IdeaFormat, IdeaId, IdeaOpening, IdeaState, IdeaTitle, Key, Question, QuestionOption, QuestionResult, RankingQuestion, Reason, Revote, ScoreQuestion, SecrecyLevel, Slot, TextQuestion, Topic, Trustees, Window };
|
|
40
|
+
/** Trust Task type URI. */
|
|
41
|
+
export declare const TYPE_URI: "https://trusttasks.org/spec/vtc/boards/show/0.1";
|
|
42
|
+
/**
|
|
43
|
+
* The earlier version of this specification that this one declares it
|
|
44
|
+
* extends (front matter `extends`, SPEC §5.2 "Declared extension"), or
|
|
45
|
+
* `null`. Only the direct declaration — follow the chain with
|
|
46
|
+
* `extendsChain` / `readForSpec`.
|
|
47
|
+
*/
|
|
48
|
+
export declare const EXTENDS: string | null;
|
|
49
|
+
/**
|
|
50
|
+
* Why this version is deprecated, or `null` while it is current. A
|
|
51
|
+
* superseded or retired version is still supported, and is withdrawn from
|
|
52
|
+
* this package in a later scheduled batch (SPEC "Superseded and Withdrawn
|
|
53
|
+
* Versions").
|
|
54
|
+
*/
|
|
55
|
+
export declare const DEPRECATION: string | null;
|
|
56
|
+
/** Stable alias for this specification's request payload shape. */
|
|
57
|
+
export type Payload = VTCBoardsShowPayload;
|
|
58
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
59
|
+
export declare const RESPONSE_TYPE_URI: "https://trusttasks.org/spec/vtc/boards/show/0.1#response";
|
|
60
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
61
|
+
export type Response = VTCBoardsShowResponsePayload;
|
|
62
|
+
/**
|
|
63
|
+
* This specification's payload schema, as a value.
|
|
64
|
+
*
|
|
65
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
66
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
67
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
68
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
69
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
70
|
+
*/
|
|
71
|
+
export declare const PAYLOAD_SCHEMA: {
|
|
72
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
73
|
+
readonly $id: "https://trusttasks.org/spec/vtc/boards/show/0.1";
|
|
74
|
+
readonly title: "VTC Boards — Show — payload";
|
|
75
|
+
readonly description: "Show one board and its ideas as the caller may see them, with each accepted idea's election stage, ballot count where its board is public, and result once tallied — never who took a ticket or voted. The outer document members are owned by the framework — SPEC §6.3.";
|
|
76
|
+
readonly type: "object";
|
|
77
|
+
readonly additionalProperties: false;
|
|
78
|
+
readonly required: readonly ["boardId"];
|
|
79
|
+
readonly properties: {
|
|
80
|
+
readonly boardId: {
|
|
81
|
+
readonly $ref: "#/$defs/BoardId";
|
|
82
|
+
};
|
|
83
|
+
readonly state: {
|
|
84
|
+
readonly type: "array";
|
|
85
|
+
readonly minItems: 1;
|
|
86
|
+
readonly uniqueItems: true;
|
|
87
|
+
readonly items: {
|
|
88
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
89
|
+
};
|
|
90
|
+
};
|
|
91
|
+
readonly topic: {
|
|
92
|
+
readonly $ref: "#/$defs/Topic";
|
|
93
|
+
};
|
|
94
|
+
readonly cursor: {
|
|
95
|
+
readonly type: "string";
|
|
96
|
+
readonly minLength: 1;
|
|
97
|
+
readonly maxLength: 1024;
|
|
98
|
+
readonly description: "An opaque continuation token from a previous response's `nextCursor`, bound to the caller and the filters; a responder MUST NOT accept a cursor it did not issue.";
|
|
99
|
+
};
|
|
100
|
+
readonly limit: {
|
|
101
|
+
readonly type: "integer";
|
|
102
|
+
readonly minimum: 1;
|
|
103
|
+
readonly maximum: 200;
|
|
104
|
+
readonly description: "The most items to return, at most 200; the responder chooses a default (50) and MAY return fewer.";
|
|
105
|
+
};
|
|
106
|
+
readonly ext: {
|
|
107
|
+
readonly $ref: "#/$defs/Ext";
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
readonly $defs: {
|
|
111
|
+
readonly Response: {
|
|
112
|
+
readonly $anchor: "response";
|
|
113
|
+
readonly title: "VTC Boards — Show — response payload";
|
|
114
|
+
readonly description: "The success response to a vtc/boards/show/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/boards/show/0.1#response.";
|
|
115
|
+
readonly type: "object";
|
|
116
|
+
readonly additionalProperties: false;
|
|
117
|
+
readonly required: readonly ["board", "ideas"];
|
|
118
|
+
readonly properties: {
|
|
119
|
+
readonly board: {
|
|
120
|
+
readonly $ref: "#/$defs/Board";
|
|
121
|
+
};
|
|
122
|
+
readonly ideas: {
|
|
123
|
+
readonly type: "array";
|
|
124
|
+
readonly items: {
|
|
125
|
+
readonly $ref: "#/$defs/Idea";
|
|
126
|
+
};
|
|
127
|
+
};
|
|
128
|
+
readonly nextCursor: {
|
|
129
|
+
readonly type: "string";
|
|
130
|
+
readonly maxLength: 1024;
|
|
131
|
+
readonly description: "Continuation token for the next page; pass it back as `cursor`. Absent on the last page — never `null`.";
|
|
132
|
+
};
|
|
133
|
+
readonly ext: {
|
|
134
|
+
readonly $ref: "#/$defs/Ext";
|
|
135
|
+
};
|
|
136
|
+
};
|
|
137
|
+
};
|
|
138
|
+
readonly Ext: {
|
|
139
|
+
readonly title: "Ext";
|
|
140
|
+
readonly 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.";
|
|
141
|
+
readonly type: "object";
|
|
142
|
+
readonly minProperties: 1;
|
|
143
|
+
readonly additionalProperties: true;
|
|
144
|
+
readonly propertyNames: {
|
|
145
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
146
|
+
};
|
|
147
|
+
};
|
|
148
|
+
readonly Idea: {
|
|
149
|
+
readonly title: "Idea";
|
|
150
|
+
readonly description: "An idea as one caller may see it.";
|
|
151
|
+
readonly type: "object";
|
|
152
|
+
readonly additionalProperties: false;
|
|
153
|
+
readonly required: readonly ["ideaId", "boardId", "state", "title", "description", "proposer", "proposedAt", "noteCount"];
|
|
154
|
+
readonly properties: {
|
|
155
|
+
readonly ideaId: {
|
|
156
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
157
|
+
};
|
|
158
|
+
readonly boardId: {
|
|
159
|
+
readonly $ref: "#/$defs/BoardId";
|
|
160
|
+
};
|
|
161
|
+
readonly state: {
|
|
162
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
163
|
+
};
|
|
164
|
+
readonly title: {
|
|
165
|
+
readonly $ref: "#/$defs/IdeaTitle";
|
|
166
|
+
};
|
|
167
|
+
readonly description: {
|
|
168
|
+
readonly $ref: "#/$defs/IdeaDescription";
|
|
169
|
+
};
|
|
170
|
+
readonly format: {
|
|
171
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
172
|
+
};
|
|
173
|
+
readonly topic: {
|
|
174
|
+
readonly $ref: "#/$defs/Topic";
|
|
175
|
+
};
|
|
176
|
+
readonly proposer: {
|
|
177
|
+
readonly $ref: "#/$defs/Author";
|
|
178
|
+
};
|
|
179
|
+
readonly proposedAt: {
|
|
180
|
+
readonly type: "string";
|
|
181
|
+
readonly format: "date-time";
|
|
182
|
+
};
|
|
183
|
+
readonly noteCount: {
|
|
184
|
+
readonly type: "integer";
|
|
185
|
+
readonly minimum: 0;
|
|
186
|
+
readonly description: "Notes on the idea the caller may read.";
|
|
187
|
+
};
|
|
188
|
+
readonly election: {
|
|
189
|
+
readonly $ref: "#/$defs/IdeaElection";
|
|
190
|
+
readonly description: "Present once an election was opened for the idea.";
|
|
191
|
+
};
|
|
192
|
+
readonly opening: {
|
|
193
|
+
readonly $ref: "#/$defs/IdeaOpening";
|
|
194
|
+
};
|
|
195
|
+
readonly decision: {
|
|
196
|
+
readonly $ref: "#/$defs/IdeaDecision";
|
|
197
|
+
readonly description: "Present in `declined`, `merged`, `selected` and `notSelected`.";
|
|
198
|
+
};
|
|
199
|
+
};
|
|
200
|
+
};
|
|
201
|
+
readonly IdeaDecision: {
|
|
202
|
+
readonly title: "IdeaDecision";
|
|
203
|
+
readonly description: "A facilitator's decision on an idea: declining or merging it (VTI-BRD-013), or selecting it or not (VTI-BRD-040). The deciding facilitator is not named to the audience.";
|
|
204
|
+
readonly type: "object";
|
|
205
|
+
readonly additionalProperties: false;
|
|
206
|
+
readonly required: readonly ["decidedAt"];
|
|
207
|
+
readonly properties: {
|
|
208
|
+
readonly decidedAt: {
|
|
209
|
+
readonly type: "string";
|
|
210
|
+
readonly format: "date-time";
|
|
211
|
+
};
|
|
212
|
+
readonly reason: {
|
|
213
|
+
readonly $ref: "#/$defs/Reason";
|
|
214
|
+
};
|
|
215
|
+
readonly mergedInto: {
|
|
216
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
217
|
+
readonly description: "Present exactly when the idea is `merged`.";
|
|
218
|
+
};
|
|
219
|
+
readonly slotId: {
|
|
220
|
+
readonly $ref: "#/$defs/Key";
|
|
221
|
+
readonly description: "A `selected` idea's place in the board's timetable, where it has one.";
|
|
222
|
+
};
|
|
223
|
+
readonly departsFromRule: {
|
|
224
|
+
readonly type: "boolean";
|
|
225
|
+
readonly description: "`selected` or `notSelected` only: whether the facilitator said the decision departs from the board's `selectionRule` (VTI-BRD-041); `reason` then says why.";
|
|
226
|
+
};
|
|
227
|
+
readonly ownIdea: {
|
|
228
|
+
readonly const: true;
|
|
229
|
+
readonly description: "Present when a facilitator decided their own idea because no other facilitator existed (VTI-BRD-013).";
|
|
230
|
+
};
|
|
231
|
+
};
|
|
232
|
+
};
|
|
233
|
+
readonly IdeaId: {
|
|
234
|
+
readonly title: "IdeaId";
|
|
235
|
+
readonly description: "Opaque identifier of an idea: `ida_` followed by 16 to 64 base64url characters. Random and unique within the community.";
|
|
236
|
+
readonly type: "string";
|
|
237
|
+
readonly pattern: "^ida_[A-Za-z0-9_-]{16,64}$";
|
|
238
|
+
};
|
|
239
|
+
readonly Reason: {
|
|
240
|
+
readonly title: "Reason";
|
|
241
|
+
readonly type: "string";
|
|
242
|
+
readonly minLength: 1;
|
|
243
|
+
readonly maxLength: 500;
|
|
244
|
+
readonly description: "A facilitator's stated reason, shown to the board's audience with the decision it explains. Plain text.";
|
|
245
|
+
};
|
|
246
|
+
readonly Key: {
|
|
247
|
+
readonly title: "Key";
|
|
248
|
+
readonly description: "A question or option key, unique within its manifest or question.";
|
|
249
|
+
readonly type: "string";
|
|
250
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,64}$";
|
|
251
|
+
};
|
|
252
|
+
readonly IdeaOpening: {
|
|
253
|
+
readonly title: "IdeaOpening";
|
|
254
|
+
readonly description: "Shown to facilitators only: an accepted idea whose election the ballot box has not yet registered, so the idea is still `proposed` (VTI-BRD-031). `refusal` is the ballot box's or community's refusal of the last attempt, after which the idea is no longer being opened.";
|
|
255
|
+
readonly type: "object";
|
|
256
|
+
readonly additionalProperties: false;
|
|
257
|
+
readonly required: readonly ["electionId", "startedAt"];
|
|
258
|
+
readonly properties: {
|
|
259
|
+
readonly electionId: {
|
|
260
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
261
|
+
};
|
|
262
|
+
readonly startedAt: {
|
|
263
|
+
readonly type: "string";
|
|
264
|
+
readonly format: "date-time";
|
|
265
|
+
readonly description: "When the facilitator accepted the idea.";
|
|
266
|
+
};
|
|
267
|
+
readonly refusal: {
|
|
268
|
+
readonly type: "object";
|
|
269
|
+
readonly additionalProperties: false;
|
|
270
|
+
readonly required: readonly ["code", "refusedAt"];
|
|
271
|
+
readonly properties: {
|
|
272
|
+
readonly code: {
|
|
273
|
+
readonly type: "string";
|
|
274
|
+
readonly minLength: 1;
|
|
275
|
+
readonly maxLength: 200;
|
|
276
|
+
};
|
|
277
|
+
readonly refusedAt: {
|
|
278
|
+
readonly type: "string";
|
|
279
|
+
readonly format: "date-time";
|
|
280
|
+
};
|
|
281
|
+
};
|
|
282
|
+
};
|
|
283
|
+
};
|
|
284
|
+
};
|
|
285
|
+
readonly ElectionId: {
|
|
286
|
+
readonly title: "ElectionId";
|
|
287
|
+
readonly 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.";
|
|
288
|
+
readonly type: "string";
|
|
289
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,128}$";
|
|
290
|
+
};
|
|
291
|
+
readonly IdeaElection: {
|
|
292
|
+
readonly title: "IdeaElection";
|
|
293
|
+
readonly description: "An idea's election as a board shows it (VTI-BRD-033): never who took a ticket or cast a ballot.";
|
|
294
|
+
readonly type: "object";
|
|
295
|
+
readonly additionalProperties: false;
|
|
296
|
+
readonly required: readonly ["electionId", "state"];
|
|
297
|
+
readonly properties: {
|
|
298
|
+
readonly electionId: {
|
|
299
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
300
|
+
};
|
|
301
|
+
readonly state: {
|
|
302
|
+
readonly $ref: "#/$defs/ElectionState";
|
|
303
|
+
};
|
|
304
|
+
readonly ballotsOnBoard: {
|
|
305
|
+
readonly type: "integer";
|
|
306
|
+
readonly minimum: 0;
|
|
307
|
+
readonly description: "The ballot box's latest board head's ballot count, where its board is public (VTI-VOT-052); absent otherwise. Counts ballots, not voters, where a later ballot replaces an earlier one.";
|
|
308
|
+
};
|
|
309
|
+
readonly boardHeadIssuedAt: {
|
|
310
|
+
readonly type: "string";
|
|
311
|
+
readonly format: "date-time";
|
|
312
|
+
readonly description: "When the head `ballotsOnBoard` was read from was issued.";
|
|
313
|
+
};
|
|
314
|
+
readonly result: {
|
|
315
|
+
readonly $ref: "#/$defs/ElectionResult";
|
|
316
|
+
readonly description: "Present once the election is tallied.";
|
|
317
|
+
};
|
|
318
|
+
readonly certified: {
|
|
319
|
+
readonly type: "boolean";
|
|
320
|
+
readonly description: "Present with `result`: whether the community certified it (VTI-VOT-071).";
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
};
|
|
324
|
+
readonly ElectionResult: {
|
|
325
|
+
readonly title: "ElectionResult";
|
|
326
|
+
readonly description: "An election's result, computable by anyone who can read its board from the board and the registration alone (VTI-VOT-070).";
|
|
327
|
+
readonly type: "object";
|
|
328
|
+
readonly additionalProperties: false;
|
|
329
|
+
readonly required: readonly ["electionId", "manifestDigest", "ballotsCounted", "questions", "head"];
|
|
330
|
+
readonly properties: {
|
|
331
|
+
readonly electionId: {
|
|
332
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
333
|
+
};
|
|
334
|
+
readonly manifestDigest: {
|
|
335
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
336
|
+
};
|
|
337
|
+
readonly ballotsCounted: {
|
|
338
|
+
readonly type: "integer";
|
|
339
|
+
readonly minimum: 0;
|
|
340
|
+
};
|
|
341
|
+
readonly questions: {
|
|
342
|
+
readonly type: "array";
|
|
343
|
+
readonly items: {
|
|
344
|
+
readonly $ref: "#/$defs/QuestionResult";
|
|
345
|
+
};
|
|
346
|
+
};
|
|
347
|
+
readonly head: {
|
|
348
|
+
readonly $ref: "#/$defs/BoardHead";
|
|
349
|
+
readonly description: "The head of the board as it stood at close: the result counts exactly its entries.";
|
|
350
|
+
};
|
|
351
|
+
};
|
|
352
|
+
};
|
|
353
|
+
readonly BoardHead: {
|
|
354
|
+
readonly title: "BoardHead";
|
|
355
|
+
readonly description: "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.";
|
|
356
|
+
readonly type: "object";
|
|
357
|
+
readonly additionalProperties: false;
|
|
358
|
+
readonly required: readonly ["electionId", "treeSize", "rootHash", "issuedAt"];
|
|
359
|
+
readonly properties: {
|
|
360
|
+
readonly electionId: {
|
|
361
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
362
|
+
};
|
|
363
|
+
readonly treeSize: {
|
|
364
|
+
readonly type: "integer";
|
|
365
|
+
readonly minimum: 0;
|
|
366
|
+
};
|
|
367
|
+
readonly rootHash: {
|
|
368
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
369
|
+
readonly description: "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash.";
|
|
370
|
+
};
|
|
371
|
+
readonly issuedAt: {
|
|
372
|
+
readonly type: "string";
|
|
373
|
+
readonly format: "date-time";
|
|
374
|
+
};
|
|
375
|
+
};
|
|
376
|
+
};
|
|
377
|
+
readonly DigestMultibase: {
|
|
378
|
+
readonly title: "DigestMultibase";
|
|
379
|
+
readonly description: "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.";
|
|
380
|
+
readonly type: "string";
|
|
381
|
+
readonly minLength: 16;
|
|
382
|
+
readonly pattern: "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$";
|
|
383
|
+
readonly examples: readonly ["zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"];
|
|
384
|
+
};
|
|
385
|
+
readonly QuestionResult: {
|
|
386
|
+
readonly title: "QuestionResult";
|
|
387
|
+
readonly description: "One question's totals. `choice`: selections per option. `ranking`: per option, how many ballots placed it at each position (index 0 = first). `score`: per option, the sum and the number of ballots that scored it. `text`: the answers, in board order, withheld (`withheld: true`) below the manifest's `textReleaseThreshold`. `abstained` counts ballots that left the question unanswered.";
|
|
388
|
+
readonly type: "object";
|
|
389
|
+
readonly additionalProperties: false;
|
|
390
|
+
readonly required: readonly ["question", "abstained"];
|
|
391
|
+
readonly properties: {
|
|
392
|
+
readonly question: {
|
|
393
|
+
readonly $ref: "#/$defs/Key";
|
|
394
|
+
};
|
|
395
|
+
readonly abstained: {
|
|
396
|
+
readonly type: "integer";
|
|
397
|
+
readonly minimum: 0;
|
|
398
|
+
};
|
|
399
|
+
readonly choice: {
|
|
400
|
+
readonly type: "object";
|
|
401
|
+
readonly propertyNames: {
|
|
402
|
+
readonly $ref: "#/$defs/Key";
|
|
403
|
+
};
|
|
404
|
+
readonly additionalProperties: {
|
|
405
|
+
readonly type: "integer";
|
|
406
|
+
readonly minimum: 0;
|
|
407
|
+
};
|
|
408
|
+
};
|
|
409
|
+
readonly ranking: {
|
|
410
|
+
readonly type: "object";
|
|
411
|
+
readonly propertyNames: {
|
|
412
|
+
readonly $ref: "#/$defs/Key";
|
|
413
|
+
};
|
|
414
|
+
readonly additionalProperties: {
|
|
415
|
+
readonly type: "array";
|
|
416
|
+
readonly items: {
|
|
417
|
+
readonly type: "integer";
|
|
418
|
+
readonly minimum: 0;
|
|
419
|
+
};
|
|
420
|
+
};
|
|
421
|
+
};
|
|
422
|
+
readonly score: {
|
|
423
|
+
readonly type: "object";
|
|
424
|
+
readonly propertyNames: {
|
|
425
|
+
readonly $ref: "#/$defs/Key";
|
|
426
|
+
};
|
|
427
|
+
readonly additionalProperties: {
|
|
428
|
+
readonly type: "object";
|
|
429
|
+
readonly additionalProperties: false;
|
|
430
|
+
readonly required: readonly ["sum", "count"];
|
|
431
|
+
readonly properties: {
|
|
432
|
+
readonly sum: {
|
|
433
|
+
readonly type: "integer";
|
|
434
|
+
};
|
|
435
|
+
readonly count: {
|
|
436
|
+
readonly type: "integer";
|
|
437
|
+
readonly minimum: 0;
|
|
438
|
+
};
|
|
439
|
+
};
|
|
440
|
+
};
|
|
441
|
+
};
|
|
442
|
+
readonly text: {
|
|
443
|
+
readonly type: "array";
|
|
444
|
+
readonly items: {
|
|
445
|
+
readonly type: "string";
|
|
446
|
+
readonly maxLength: 4096;
|
|
447
|
+
};
|
|
448
|
+
};
|
|
449
|
+
readonly withheld: {
|
|
450
|
+
readonly type: "boolean";
|
|
451
|
+
};
|
|
452
|
+
};
|
|
453
|
+
};
|
|
454
|
+
readonly ElectionState: {
|
|
455
|
+
readonly title: "ElectionState";
|
|
456
|
+
readonly type: "string";
|
|
457
|
+
readonly enum: readonly ["registered", "registration", "voting", "closed", "tallied", "cancelled"];
|
|
458
|
+
};
|
|
459
|
+
readonly Author: {
|
|
460
|
+
readonly title: "Author";
|
|
461
|
+
readonly description: "Who proposed an idea or wrote a note, as the board's audience sees them. `entryId` is their directory entry, which survives a rotation of their DID; `name` is their directory display name as this caller may see it, absent where the directory withholds it. A departed member is shown as `formerMember: true` with neither (VTI-BRD-060).";
|
|
462
|
+
readonly type: "object";
|
|
463
|
+
readonly additionalProperties: false;
|
|
464
|
+
readonly properties: {
|
|
465
|
+
readonly entryId: {
|
|
466
|
+
readonly $ref: "#/$defs/EntryId";
|
|
467
|
+
};
|
|
468
|
+
readonly name: {
|
|
469
|
+
readonly type: "string";
|
|
470
|
+
readonly minLength: 1;
|
|
471
|
+
readonly maxLength: 200;
|
|
472
|
+
};
|
|
473
|
+
readonly formerMember: {
|
|
474
|
+
readonly const: true;
|
|
475
|
+
};
|
|
476
|
+
readonly you: {
|
|
477
|
+
readonly const: true;
|
|
478
|
+
readonly description: "Present when the caller is the author.";
|
|
479
|
+
};
|
|
480
|
+
};
|
|
481
|
+
};
|
|
482
|
+
readonly EntryId: {
|
|
483
|
+
readonly title: "EntryId";
|
|
484
|
+
readonly description: "Opaque identifier of one directory entry: `dir_` followed by 16 to 64 base64url characters. Random, scoped to one community, and stable for the life of the membership — it survives a rotation of the member's DID, which is why groups, notes and cards are keyed by it. It MUST NOT be derived from, and MUST NOT reveal, any DID of the member, and the same person's entries in two communities MUST NOT share one. Compared by exact string equality.";
|
|
485
|
+
readonly type: "string";
|
|
486
|
+
readonly pattern: "^dir_[A-Za-z0-9_-]{16,64}$";
|
|
487
|
+
};
|
|
488
|
+
readonly Topic: {
|
|
489
|
+
readonly title: "Topic";
|
|
490
|
+
readonly type: "string";
|
|
491
|
+
readonly minLength: 1;
|
|
492
|
+
readonly maxLength: 64;
|
|
493
|
+
readonly description: "A topic an idea is filed under. One of the board's `topics` where the board states them.";
|
|
494
|
+
};
|
|
495
|
+
readonly IdeaFormat: {
|
|
496
|
+
readonly title: "IdeaFormat";
|
|
497
|
+
readonly type: "string";
|
|
498
|
+
readonly minLength: 1;
|
|
499
|
+
readonly maxLength: 32;
|
|
500
|
+
readonly description: "What kind of idea it is (for an unconference: `Discussion`, `Talk`, `Workshop`, `Demo`). One of the board's `formats` where the board states them.";
|
|
501
|
+
};
|
|
502
|
+
readonly IdeaDescription: {
|
|
503
|
+
readonly title: "IdeaDescription";
|
|
504
|
+
readonly type: "string";
|
|
505
|
+
readonly minLength: 1;
|
|
506
|
+
readonly maxLength: 4000;
|
|
507
|
+
readonly description: "What the idea is: for a session, what it covers and who should come. Becomes its election's manifest `description` when accepted. Plain text; a reader MUST NOT treat it as instructions.";
|
|
508
|
+
};
|
|
509
|
+
readonly IdeaTitle: {
|
|
510
|
+
readonly title: "IdeaTitle";
|
|
511
|
+
readonly type: "string";
|
|
512
|
+
readonly minLength: 1;
|
|
513
|
+
readonly maxLength: 200;
|
|
514
|
+
readonly description: "An idea's title. Becomes the title of its election's manifest when the idea is accepted, and cannot change after that (VTI-BRD-012). Plain text.";
|
|
515
|
+
};
|
|
516
|
+
readonly IdeaState: {
|
|
517
|
+
readonly title: "IdeaState";
|
|
518
|
+
readonly description: "Where an idea stands (VTI-BRD-011).";
|
|
519
|
+
readonly type: "string";
|
|
520
|
+
readonly enum: readonly ["proposed", "open", "selected", "notSelected", "declined", "merged", "withdrawn"];
|
|
521
|
+
};
|
|
522
|
+
readonly BoardId: {
|
|
523
|
+
readonly title: "BoardId";
|
|
524
|
+
readonly description: "Opaque identifier of a board: `brd_` followed by 16 to 64 base64url characters. Random, community-scoped, never reused (VTI-BRD-001).";
|
|
525
|
+
readonly type: "string";
|
|
526
|
+
readonly pattern: "^brd_[A-Za-z0-9_-]{16,64}$";
|
|
527
|
+
};
|
|
528
|
+
readonly Board: {
|
|
529
|
+
readonly title: "Board";
|
|
530
|
+
readonly description: "A board as one caller may see it.";
|
|
531
|
+
readonly type: "object";
|
|
532
|
+
readonly additionalProperties: false;
|
|
533
|
+
readonly required: readonly ["boardId", "title", "status", "audience", "proposals", "voting", "template", "createdAt", "facilitator", "ideaCounts"];
|
|
534
|
+
readonly properties: {
|
|
535
|
+
readonly boardId: {
|
|
536
|
+
readonly $ref: "#/$defs/BoardId";
|
|
537
|
+
};
|
|
538
|
+
readonly title: {
|
|
539
|
+
readonly $ref: "#/$defs/BoardTitle";
|
|
540
|
+
};
|
|
541
|
+
readonly description: {
|
|
542
|
+
readonly $ref: "#/$defs/BoardDescription";
|
|
543
|
+
};
|
|
544
|
+
readonly status: {
|
|
545
|
+
readonly $ref: "#/$defs/BoardStatus";
|
|
546
|
+
};
|
|
547
|
+
readonly audience: {
|
|
548
|
+
readonly $ref: "#/$defs/BoardAudience";
|
|
549
|
+
};
|
|
550
|
+
readonly proposals: {
|
|
551
|
+
readonly $ref: "#/$defs/Window";
|
|
552
|
+
readonly description: "When ideas are taken (VTI-BRD-010).";
|
|
553
|
+
};
|
|
554
|
+
readonly voting: {
|
|
555
|
+
readonly $ref: "#/$defs/Window";
|
|
556
|
+
readonly description: "When every idea's election takes ballots. Opens after `proposals` opens and closes after it closes (VTI-BRD-001).";
|
|
557
|
+
};
|
|
558
|
+
readonly topics: {
|
|
559
|
+
readonly type: "array";
|
|
560
|
+
readonly maxItems: 32;
|
|
561
|
+
readonly uniqueItems: true;
|
|
562
|
+
readonly items: {
|
|
563
|
+
readonly $ref: "#/$defs/Topic";
|
|
564
|
+
};
|
|
565
|
+
};
|
|
566
|
+
readonly formats: {
|
|
567
|
+
readonly type: "array";
|
|
568
|
+
readonly maxItems: 16;
|
|
569
|
+
readonly uniqueItems: true;
|
|
570
|
+
readonly items: {
|
|
571
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
572
|
+
};
|
|
573
|
+
};
|
|
574
|
+
readonly maxIdeasPerMember: {
|
|
575
|
+
readonly type: "integer";
|
|
576
|
+
readonly minimum: 1;
|
|
577
|
+
readonly maximum: 100;
|
|
578
|
+
readonly description: "The most ideas one member may have on the board that are not `withdrawn` or `declined`. Absent: no limit beyond the community's own.";
|
|
579
|
+
};
|
|
580
|
+
readonly selectionRule: {
|
|
581
|
+
readonly type: "string";
|
|
582
|
+
readonly minLength: 1;
|
|
583
|
+
readonly maxLength: 500;
|
|
584
|
+
readonly description: "How facilitators intend to select, in plain words (VTI-BRD-041), e.g. \"The twelve ideas the most members would attend\".";
|
|
585
|
+
};
|
|
586
|
+
readonly timetable: {
|
|
587
|
+
readonly type: "array";
|
|
588
|
+
readonly maxItems: 256;
|
|
589
|
+
readonly items: {
|
|
590
|
+
readonly $ref: "#/$defs/Slot";
|
|
591
|
+
};
|
|
592
|
+
};
|
|
593
|
+
readonly template: {
|
|
594
|
+
readonly $ref: "#/$defs/ElectionTemplate";
|
|
595
|
+
};
|
|
596
|
+
readonly createdAt: {
|
|
597
|
+
readonly type: "string";
|
|
598
|
+
readonly format: "date-time";
|
|
599
|
+
};
|
|
600
|
+
readonly facilitator: {
|
|
601
|
+
readonly type: "boolean";
|
|
602
|
+
readonly description: "Whether the caller facilitates this board.";
|
|
603
|
+
};
|
|
604
|
+
readonly ideaCounts: {
|
|
605
|
+
readonly type: "object";
|
|
606
|
+
readonly additionalProperties: false;
|
|
607
|
+
readonly description: "How many of the board's ideas are in each state the caller may see.";
|
|
608
|
+
readonly properties: {
|
|
609
|
+
readonly proposed: {
|
|
610
|
+
readonly type: "integer";
|
|
611
|
+
readonly minimum: 0;
|
|
612
|
+
};
|
|
613
|
+
readonly open: {
|
|
614
|
+
readonly type: "integer";
|
|
615
|
+
readonly minimum: 0;
|
|
616
|
+
};
|
|
617
|
+
readonly selected: {
|
|
618
|
+
readonly type: "integer";
|
|
619
|
+
readonly minimum: 0;
|
|
620
|
+
};
|
|
621
|
+
readonly notSelected: {
|
|
622
|
+
readonly type: "integer";
|
|
623
|
+
readonly minimum: 0;
|
|
624
|
+
};
|
|
625
|
+
readonly declined: {
|
|
626
|
+
readonly type: "integer";
|
|
627
|
+
readonly minimum: 0;
|
|
628
|
+
};
|
|
629
|
+
readonly merged: {
|
|
630
|
+
readonly type: "integer";
|
|
631
|
+
readonly minimum: 0;
|
|
632
|
+
};
|
|
633
|
+
readonly withdrawn: {
|
|
634
|
+
readonly type: "integer";
|
|
635
|
+
readonly minimum: 0;
|
|
636
|
+
};
|
|
637
|
+
};
|
|
638
|
+
};
|
|
639
|
+
};
|
|
640
|
+
};
|
|
641
|
+
readonly ElectionTemplate: {
|
|
642
|
+
readonly title: "ElectionTemplate";
|
|
643
|
+
readonly description: "Every member of an idea's election manifest that the board fixes (VTI-BRD-030). When a facilitator accepts an idea the community completes it: `electionId` (naming the board and the idea), `community`, `title` and `description` from the idea, `registrationOpensAt` and `votingOpensAt` from the board's voting window's `opensAt` or the acceptance, whichever is later, `votingClosesAt` from its `closesAt`, `roll` from the board's audience (rule `members`, or a credential roll naming the group), and `binding: false`. A board's template is never binding, and so has no `binding` member.";
|
|
644
|
+
readonly type: "object";
|
|
645
|
+
readonly additionalProperties: false;
|
|
646
|
+
readonly required: readonly ["questions", "secrecy", "revote", "board", "ballotBox", "allowEarlyClose", "resultsBeforeClose", "textReleaseThreshold"];
|
|
647
|
+
readonly properties: {
|
|
648
|
+
readonly questions: {
|
|
649
|
+
readonly type: "array";
|
|
650
|
+
readonly minItems: 1;
|
|
651
|
+
readonly maxItems: 16;
|
|
652
|
+
readonly items: {
|
|
653
|
+
readonly $ref: "#/$defs/Question";
|
|
654
|
+
};
|
|
655
|
+
};
|
|
656
|
+
readonly secrecy: {
|
|
657
|
+
readonly $ref: "#/$defs/SecrecyLevel";
|
|
658
|
+
};
|
|
659
|
+
readonly revote: {
|
|
660
|
+
readonly $ref: "#/$defs/Revote";
|
|
661
|
+
};
|
|
662
|
+
readonly board: {
|
|
663
|
+
readonly type: "object";
|
|
664
|
+
readonly additionalProperties: false;
|
|
665
|
+
readonly required: readonly ["visibility", "auditors"];
|
|
666
|
+
readonly description: "The ballot box's board for each idea's election, as a manifest states it (VTI-VOT-052). `public` lets a board show each idea's ballot count while voting is open (VTI-BRD-033).";
|
|
667
|
+
readonly properties: {
|
|
668
|
+
readonly visibility: {
|
|
669
|
+
readonly $ref: "#/$defs/BoardVisibility";
|
|
670
|
+
};
|
|
671
|
+
readonly auditors: {
|
|
672
|
+
readonly type: "array";
|
|
673
|
+
readonly uniqueItems: true;
|
|
674
|
+
readonly items: {
|
|
675
|
+
readonly type: "string";
|
|
676
|
+
readonly minLength: 1;
|
|
677
|
+
readonly maxLength: 2048;
|
|
678
|
+
};
|
|
679
|
+
};
|
|
680
|
+
};
|
|
681
|
+
};
|
|
682
|
+
readonly ballotBox: {
|
|
683
|
+
readonly type: "string";
|
|
684
|
+
readonly minLength: 1;
|
|
685
|
+
readonly maxLength: 2048;
|
|
686
|
+
readonly description: "The DID of the voting service every idea's election is registered with; one on the community's list (VTI-VOT-082).";
|
|
687
|
+
};
|
|
688
|
+
readonly trustees: {
|
|
689
|
+
readonly $ref: "#/$defs/Trustees";
|
|
690
|
+
};
|
|
691
|
+
readonly allowEarlyClose: {
|
|
692
|
+
readonly type: "boolean";
|
|
693
|
+
};
|
|
694
|
+
readonly resultsBeforeClose: {
|
|
695
|
+
readonly type: "boolean";
|
|
696
|
+
readonly description: "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061). A board SHOULD set it false (VTI-BRD-033).";
|
|
697
|
+
};
|
|
698
|
+
readonly textReleaseThreshold: {
|
|
699
|
+
readonly type: "integer";
|
|
700
|
+
readonly minimum: 1;
|
|
701
|
+
readonly description: "Counted ballots required before any text answer is disclosed (VTI-VOT-065); SHOULD be at least 10.";
|
|
702
|
+
};
|
|
703
|
+
};
|
|
704
|
+
};
|
|
705
|
+
readonly Trustees: {
|
|
706
|
+
readonly title: "Trustees";
|
|
707
|
+
readonly 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.";
|
|
708
|
+
readonly type: "object";
|
|
709
|
+
readonly additionalProperties: false;
|
|
710
|
+
readonly required: readonly ["dids", "threshold"];
|
|
711
|
+
readonly properties: {
|
|
712
|
+
readonly dids: {
|
|
713
|
+
readonly type: "array";
|
|
714
|
+
readonly minItems: 2;
|
|
715
|
+
readonly items: {
|
|
716
|
+
readonly type: "string";
|
|
717
|
+
readonly minLength: 1;
|
|
718
|
+
readonly maxLength: 2048;
|
|
719
|
+
};
|
|
720
|
+
readonly uniqueItems: true;
|
|
721
|
+
};
|
|
722
|
+
readonly threshold: {
|
|
723
|
+
readonly type: "integer";
|
|
724
|
+
readonly minimum: 2;
|
|
725
|
+
};
|
|
726
|
+
};
|
|
727
|
+
};
|
|
728
|
+
readonly BoardVisibility: {
|
|
729
|
+
readonly title: "BoardVisibility";
|
|
730
|
+
readonly 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).";
|
|
731
|
+
readonly type: "string";
|
|
732
|
+
readonly enum: readonly ["public", "private"];
|
|
733
|
+
};
|
|
734
|
+
readonly Revote: {
|
|
735
|
+
readonly title: "Revote";
|
|
736
|
+
readonly description: "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).";
|
|
737
|
+
readonly type: "string";
|
|
738
|
+
readonly enum: readonly ["replace", "refuse"];
|
|
739
|
+
};
|
|
740
|
+
readonly SecrecyLevel: {
|
|
741
|
+
readonly title: "SecrecyLevel";
|
|
742
|
+
readonly 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).";
|
|
743
|
+
readonly type: "string";
|
|
744
|
+
readonly enum: readonly ["open", "sealed", "talliedEncrypted"];
|
|
745
|
+
};
|
|
746
|
+
readonly Question: {
|
|
747
|
+
readonly title: "Question";
|
|
748
|
+
readonly description: "One question. Tagged union over `type`.";
|
|
749
|
+
readonly oneOf: readonly [{
|
|
750
|
+
readonly title: "ChoiceQuestion";
|
|
751
|
+
readonly description: "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.";
|
|
752
|
+
readonly type: "object";
|
|
753
|
+
readonly additionalProperties: false;
|
|
754
|
+
readonly required: readonly ["key", "type", "options", "minSelections", "maxSelections", "optional"];
|
|
755
|
+
readonly properties: {
|
|
756
|
+
readonly key: {
|
|
757
|
+
readonly $ref: "#/$defs/Key";
|
|
758
|
+
};
|
|
759
|
+
readonly type: {
|
|
760
|
+
readonly const: "choice";
|
|
761
|
+
};
|
|
762
|
+
readonly text: {
|
|
763
|
+
readonly type: "string";
|
|
764
|
+
readonly maxLength: 2048;
|
|
765
|
+
};
|
|
766
|
+
readonly options: {
|
|
767
|
+
readonly type: "array";
|
|
768
|
+
readonly minItems: 2;
|
|
769
|
+
readonly maxItems: 256;
|
|
770
|
+
readonly items: {
|
|
771
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
772
|
+
};
|
|
773
|
+
};
|
|
774
|
+
readonly minSelections: {
|
|
775
|
+
readonly type: "integer";
|
|
776
|
+
readonly minimum: 0;
|
|
777
|
+
};
|
|
778
|
+
readonly maxSelections: {
|
|
779
|
+
readonly type: "integer";
|
|
780
|
+
readonly minimum: 1;
|
|
781
|
+
};
|
|
782
|
+
readonly optional: {
|
|
783
|
+
readonly type: "boolean";
|
|
784
|
+
};
|
|
785
|
+
};
|
|
786
|
+
}, {
|
|
787
|
+
readonly title: "RankingQuestion";
|
|
788
|
+
readonly description: "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.";
|
|
789
|
+
readonly type: "object";
|
|
790
|
+
readonly additionalProperties: false;
|
|
791
|
+
readonly required: readonly ["key", "type", "options", "partial", "optional"];
|
|
792
|
+
readonly properties: {
|
|
793
|
+
readonly key: {
|
|
794
|
+
readonly $ref: "#/$defs/Key";
|
|
795
|
+
};
|
|
796
|
+
readonly type: {
|
|
797
|
+
readonly const: "ranking";
|
|
798
|
+
};
|
|
799
|
+
readonly text: {
|
|
800
|
+
readonly type: "string";
|
|
801
|
+
readonly maxLength: 2048;
|
|
802
|
+
};
|
|
803
|
+
readonly options: {
|
|
804
|
+
readonly type: "array";
|
|
805
|
+
readonly minItems: 2;
|
|
806
|
+
readonly maxItems: 64;
|
|
807
|
+
readonly items: {
|
|
808
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
809
|
+
};
|
|
810
|
+
};
|
|
811
|
+
readonly partial: {
|
|
812
|
+
readonly type: "boolean";
|
|
813
|
+
};
|
|
814
|
+
readonly optional: {
|
|
815
|
+
readonly type: "boolean";
|
|
816
|
+
};
|
|
817
|
+
};
|
|
818
|
+
}, {
|
|
819
|
+
readonly title: "ScoreQuestion";
|
|
820
|
+
readonly description: "Give each option an integer score within [min, max].";
|
|
821
|
+
readonly type: "object";
|
|
822
|
+
readonly additionalProperties: false;
|
|
823
|
+
readonly required: readonly ["key", "type", "options", "min", "max", "optional"];
|
|
824
|
+
readonly properties: {
|
|
825
|
+
readonly key: {
|
|
826
|
+
readonly $ref: "#/$defs/Key";
|
|
827
|
+
};
|
|
828
|
+
readonly type: {
|
|
829
|
+
readonly const: "score";
|
|
830
|
+
};
|
|
831
|
+
readonly text: {
|
|
832
|
+
readonly type: "string";
|
|
833
|
+
readonly maxLength: 2048;
|
|
834
|
+
};
|
|
835
|
+
readonly options: {
|
|
836
|
+
readonly type: "array";
|
|
837
|
+
readonly minItems: 1;
|
|
838
|
+
readonly maxItems: 256;
|
|
839
|
+
readonly items: {
|
|
840
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
841
|
+
};
|
|
842
|
+
};
|
|
843
|
+
readonly min: {
|
|
844
|
+
readonly type: "integer";
|
|
845
|
+
};
|
|
846
|
+
readonly max: {
|
|
847
|
+
readonly type: "integer";
|
|
848
|
+
};
|
|
849
|
+
readonly optional: {
|
|
850
|
+
readonly type: "boolean";
|
|
851
|
+
};
|
|
852
|
+
};
|
|
853
|
+
}, {
|
|
854
|
+
readonly title: "TextQuestion";
|
|
855
|
+
readonly description: "Free text of at most `maxLength` characters.";
|
|
856
|
+
readonly type: "object";
|
|
857
|
+
readonly additionalProperties: false;
|
|
858
|
+
readonly required: readonly ["key", "type", "maxLength", "optional"];
|
|
859
|
+
readonly properties: {
|
|
860
|
+
readonly key: {
|
|
861
|
+
readonly $ref: "#/$defs/Key";
|
|
862
|
+
};
|
|
863
|
+
readonly type: {
|
|
864
|
+
readonly const: "text";
|
|
865
|
+
};
|
|
866
|
+
readonly text: {
|
|
867
|
+
readonly type: "string";
|
|
868
|
+
readonly maxLength: 2048;
|
|
869
|
+
};
|
|
870
|
+
readonly maxLength: {
|
|
871
|
+
readonly type: "integer";
|
|
872
|
+
readonly minimum: 1;
|
|
873
|
+
readonly maximum: 4096;
|
|
874
|
+
};
|
|
875
|
+
readonly optional: {
|
|
876
|
+
readonly type: "boolean";
|
|
877
|
+
};
|
|
878
|
+
};
|
|
879
|
+
}];
|
|
880
|
+
};
|
|
881
|
+
readonly QuestionOption: {
|
|
882
|
+
readonly title: "QuestionOption";
|
|
883
|
+
readonly type: "object";
|
|
884
|
+
readonly additionalProperties: false;
|
|
885
|
+
readonly required: readonly ["key"];
|
|
886
|
+
readonly properties: {
|
|
887
|
+
readonly key: {
|
|
888
|
+
readonly $ref: "#/$defs/Key";
|
|
889
|
+
};
|
|
890
|
+
readonly label: {
|
|
891
|
+
readonly type: "string";
|
|
892
|
+
readonly maxLength: 512;
|
|
893
|
+
readonly description: "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014).";
|
|
894
|
+
};
|
|
895
|
+
};
|
|
896
|
+
};
|
|
897
|
+
readonly Slot: {
|
|
898
|
+
readonly title: "Slot";
|
|
899
|
+
readonly description: "One place in a board's timetable that a selected idea can be put in (VTI-BRD-040): a place (`label`, e.g. a room) and a time.";
|
|
900
|
+
readonly type: "object";
|
|
901
|
+
readonly additionalProperties: false;
|
|
902
|
+
readonly required: readonly ["slotId", "label", "startsAt", "endsAt"];
|
|
903
|
+
readonly properties: {
|
|
904
|
+
readonly slotId: {
|
|
905
|
+
readonly $ref: "#/$defs/Key";
|
|
906
|
+
};
|
|
907
|
+
readonly label: {
|
|
908
|
+
readonly type: "string";
|
|
909
|
+
readonly minLength: 1;
|
|
910
|
+
readonly maxLength: 100;
|
|
911
|
+
};
|
|
912
|
+
readonly startsAt: {
|
|
913
|
+
readonly type: "string";
|
|
914
|
+
readonly format: "date-time";
|
|
915
|
+
};
|
|
916
|
+
readonly endsAt: {
|
|
917
|
+
readonly type: "string";
|
|
918
|
+
readonly format: "date-time";
|
|
919
|
+
};
|
|
920
|
+
};
|
|
921
|
+
};
|
|
922
|
+
readonly Window: {
|
|
923
|
+
readonly title: "Window";
|
|
924
|
+
readonly description: "A period, open from `opensAt` until `closesAt`. `closesAt` is after `opensAt` (a consumer check; JSON Schema cannot compare them).";
|
|
925
|
+
readonly type: "object";
|
|
926
|
+
readonly additionalProperties: false;
|
|
927
|
+
readonly required: readonly ["opensAt", "closesAt"];
|
|
928
|
+
readonly properties: {
|
|
929
|
+
readonly opensAt: {
|
|
930
|
+
readonly type: "string";
|
|
931
|
+
readonly format: "date-time";
|
|
932
|
+
};
|
|
933
|
+
readonly closesAt: {
|
|
934
|
+
readonly type: "string";
|
|
935
|
+
readonly format: "date-time";
|
|
936
|
+
};
|
|
937
|
+
};
|
|
938
|
+
};
|
|
939
|
+
readonly BoardAudience: {
|
|
940
|
+
readonly title: "BoardAudience";
|
|
941
|
+
readonly description: "Who may see and use a board (VTI-BRD-003): every active member of the community (`members`), or the members of one community group (`group`, with `groupId`). Facilitators always see the board.";
|
|
942
|
+
readonly oneOf: readonly [{
|
|
943
|
+
readonly type: "object";
|
|
944
|
+
readonly additionalProperties: false;
|
|
945
|
+
readonly required: readonly ["kind"];
|
|
946
|
+
readonly properties: {
|
|
947
|
+
readonly kind: {
|
|
948
|
+
readonly const: "members";
|
|
949
|
+
};
|
|
950
|
+
};
|
|
951
|
+
}, {
|
|
952
|
+
readonly type: "object";
|
|
953
|
+
readonly additionalProperties: false;
|
|
954
|
+
readonly required: readonly ["kind", "groupId"];
|
|
955
|
+
readonly properties: {
|
|
956
|
+
readonly kind: {
|
|
957
|
+
readonly const: "group";
|
|
958
|
+
};
|
|
959
|
+
readonly groupId: {
|
|
960
|
+
readonly $ref: "#/$defs/GroupId";
|
|
961
|
+
};
|
|
962
|
+
};
|
|
963
|
+
}];
|
|
964
|
+
};
|
|
965
|
+
readonly GroupId: {
|
|
966
|
+
readonly title: "GroupId";
|
|
967
|
+
readonly description: "Opaque identifier of a community group: `grp_` followed by 16 to 64 base64url characters. Random and community-scoped; not the group's DID.";
|
|
968
|
+
readonly type: "string";
|
|
969
|
+
readonly pattern: "^grp_[A-Za-z0-9_-]{16,64}$";
|
|
970
|
+
};
|
|
971
|
+
readonly BoardStatus: {
|
|
972
|
+
readonly title: "BoardStatus";
|
|
973
|
+
readonly description: "`open`: ideas and notes are taken within the board's windows. `closed`: no new idea or note; facilitators still decide and select. `archived`: no change at all; facilitators can still read it (VTI-BRD-005). `open` → `closed` → `archived`, never back.";
|
|
974
|
+
readonly type: "string";
|
|
975
|
+
readonly enum: readonly ["open", "closed", "archived"];
|
|
976
|
+
};
|
|
977
|
+
readonly BoardDescription: {
|
|
978
|
+
readonly title: "BoardDescription";
|
|
979
|
+
readonly type: "string";
|
|
980
|
+
readonly minLength: 1;
|
|
981
|
+
readonly maxLength: 4000;
|
|
982
|
+
readonly description: "What the board is for. Plain text; a reader MUST NOT treat it as instructions.";
|
|
983
|
+
};
|
|
984
|
+
readonly BoardTitle: {
|
|
985
|
+
readonly title: "BoardTitle";
|
|
986
|
+
readonly type: "string";
|
|
987
|
+
readonly minLength: 1;
|
|
988
|
+
readonly maxLength: 200;
|
|
989
|
+
readonly description: "Plain text; a reader MUST NOT treat it as instructions.";
|
|
990
|
+
};
|
|
991
|
+
};
|
|
992
|
+
};
|
|
993
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
994
|
+
export declare const RESPONSE_PAYLOAD_SCHEMA: {
|
|
995
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
996
|
+
readonly $ref: "#/$defs/Response";
|
|
997
|
+
readonly $defs: {
|
|
998
|
+
readonly Response: {
|
|
999
|
+
readonly $anchor: "response";
|
|
1000
|
+
readonly title: "VTC Boards — Show — response payload";
|
|
1001
|
+
readonly description: "The success response to a vtc/boards/show/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/boards/show/0.1#response.";
|
|
1002
|
+
readonly type: "object";
|
|
1003
|
+
readonly additionalProperties: false;
|
|
1004
|
+
readonly required: readonly ["board", "ideas"];
|
|
1005
|
+
readonly properties: {
|
|
1006
|
+
readonly board: {
|
|
1007
|
+
readonly $ref: "#/$defs/Board";
|
|
1008
|
+
};
|
|
1009
|
+
readonly ideas: {
|
|
1010
|
+
readonly type: "array";
|
|
1011
|
+
readonly items: {
|
|
1012
|
+
readonly $ref: "#/$defs/Idea";
|
|
1013
|
+
};
|
|
1014
|
+
};
|
|
1015
|
+
readonly nextCursor: {
|
|
1016
|
+
readonly type: "string";
|
|
1017
|
+
readonly maxLength: 1024;
|
|
1018
|
+
readonly description: "Continuation token for the next page; pass it back as `cursor`. Absent on the last page — never `null`.";
|
|
1019
|
+
};
|
|
1020
|
+
readonly ext: {
|
|
1021
|
+
readonly $ref: "#/$defs/Ext";
|
|
1022
|
+
};
|
|
1023
|
+
};
|
|
1024
|
+
};
|
|
1025
|
+
readonly Ext: {
|
|
1026
|
+
readonly title: "Ext";
|
|
1027
|
+
readonly 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.";
|
|
1028
|
+
readonly type: "object";
|
|
1029
|
+
readonly minProperties: 1;
|
|
1030
|
+
readonly additionalProperties: true;
|
|
1031
|
+
readonly propertyNames: {
|
|
1032
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
1033
|
+
};
|
|
1034
|
+
};
|
|
1035
|
+
readonly Idea: {
|
|
1036
|
+
readonly title: "Idea";
|
|
1037
|
+
readonly description: "An idea as one caller may see it.";
|
|
1038
|
+
readonly type: "object";
|
|
1039
|
+
readonly additionalProperties: false;
|
|
1040
|
+
readonly required: readonly ["ideaId", "boardId", "state", "title", "description", "proposer", "proposedAt", "noteCount"];
|
|
1041
|
+
readonly properties: {
|
|
1042
|
+
readonly ideaId: {
|
|
1043
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
1044
|
+
};
|
|
1045
|
+
readonly boardId: {
|
|
1046
|
+
readonly $ref: "#/$defs/BoardId";
|
|
1047
|
+
};
|
|
1048
|
+
readonly state: {
|
|
1049
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
1050
|
+
};
|
|
1051
|
+
readonly title: {
|
|
1052
|
+
readonly $ref: "#/$defs/IdeaTitle";
|
|
1053
|
+
};
|
|
1054
|
+
readonly description: {
|
|
1055
|
+
readonly $ref: "#/$defs/IdeaDescription";
|
|
1056
|
+
};
|
|
1057
|
+
readonly format: {
|
|
1058
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
1059
|
+
};
|
|
1060
|
+
readonly topic: {
|
|
1061
|
+
readonly $ref: "#/$defs/Topic";
|
|
1062
|
+
};
|
|
1063
|
+
readonly proposer: {
|
|
1064
|
+
readonly $ref: "#/$defs/Author";
|
|
1065
|
+
};
|
|
1066
|
+
readonly proposedAt: {
|
|
1067
|
+
readonly type: "string";
|
|
1068
|
+
readonly format: "date-time";
|
|
1069
|
+
};
|
|
1070
|
+
readonly noteCount: {
|
|
1071
|
+
readonly type: "integer";
|
|
1072
|
+
readonly minimum: 0;
|
|
1073
|
+
readonly description: "Notes on the idea the caller may read.";
|
|
1074
|
+
};
|
|
1075
|
+
readonly election: {
|
|
1076
|
+
readonly $ref: "#/$defs/IdeaElection";
|
|
1077
|
+
readonly description: "Present once an election was opened for the idea.";
|
|
1078
|
+
};
|
|
1079
|
+
readonly opening: {
|
|
1080
|
+
readonly $ref: "#/$defs/IdeaOpening";
|
|
1081
|
+
};
|
|
1082
|
+
readonly decision: {
|
|
1083
|
+
readonly $ref: "#/$defs/IdeaDecision";
|
|
1084
|
+
readonly description: "Present in `declined`, `merged`, `selected` and `notSelected`.";
|
|
1085
|
+
};
|
|
1086
|
+
};
|
|
1087
|
+
};
|
|
1088
|
+
readonly IdeaDecision: {
|
|
1089
|
+
readonly title: "IdeaDecision";
|
|
1090
|
+
readonly description: "A facilitator's decision on an idea: declining or merging it (VTI-BRD-013), or selecting it or not (VTI-BRD-040). The deciding facilitator is not named to the audience.";
|
|
1091
|
+
readonly type: "object";
|
|
1092
|
+
readonly additionalProperties: false;
|
|
1093
|
+
readonly required: readonly ["decidedAt"];
|
|
1094
|
+
readonly properties: {
|
|
1095
|
+
readonly decidedAt: {
|
|
1096
|
+
readonly type: "string";
|
|
1097
|
+
readonly format: "date-time";
|
|
1098
|
+
};
|
|
1099
|
+
readonly reason: {
|
|
1100
|
+
readonly $ref: "#/$defs/Reason";
|
|
1101
|
+
};
|
|
1102
|
+
readonly mergedInto: {
|
|
1103
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
1104
|
+
readonly description: "Present exactly when the idea is `merged`.";
|
|
1105
|
+
};
|
|
1106
|
+
readonly slotId: {
|
|
1107
|
+
readonly $ref: "#/$defs/Key";
|
|
1108
|
+
readonly description: "A `selected` idea's place in the board's timetable, where it has one.";
|
|
1109
|
+
};
|
|
1110
|
+
readonly departsFromRule: {
|
|
1111
|
+
readonly type: "boolean";
|
|
1112
|
+
readonly description: "`selected` or `notSelected` only: whether the facilitator said the decision departs from the board's `selectionRule` (VTI-BRD-041); `reason` then says why.";
|
|
1113
|
+
};
|
|
1114
|
+
readonly ownIdea: {
|
|
1115
|
+
readonly const: true;
|
|
1116
|
+
readonly description: "Present when a facilitator decided their own idea because no other facilitator existed (VTI-BRD-013).";
|
|
1117
|
+
};
|
|
1118
|
+
};
|
|
1119
|
+
};
|
|
1120
|
+
readonly IdeaId: {
|
|
1121
|
+
readonly title: "IdeaId";
|
|
1122
|
+
readonly description: "Opaque identifier of an idea: `ida_` followed by 16 to 64 base64url characters. Random and unique within the community.";
|
|
1123
|
+
readonly type: "string";
|
|
1124
|
+
readonly pattern: "^ida_[A-Za-z0-9_-]{16,64}$";
|
|
1125
|
+
};
|
|
1126
|
+
readonly Reason: {
|
|
1127
|
+
readonly title: "Reason";
|
|
1128
|
+
readonly type: "string";
|
|
1129
|
+
readonly minLength: 1;
|
|
1130
|
+
readonly maxLength: 500;
|
|
1131
|
+
readonly description: "A facilitator's stated reason, shown to the board's audience with the decision it explains. Plain text.";
|
|
1132
|
+
};
|
|
1133
|
+
readonly Key: {
|
|
1134
|
+
readonly title: "Key";
|
|
1135
|
+
readonly description: "A question or option key, unique within its manifest or question.";
|
|
1136
|
+
readonly type: "string";
|
|
1137
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,64}$";
|
|
1138
|
+
};
|
|
1139
|
+
readonly IdeaOpening: {
|
|
1140
|
+
readonly title: "IdeaOpening";
|
|
1141
|
+
readonly description: "Shown to facilitators only: an accepted idea whose election the ballot box has not yet registered, so the idea is still `proposed` (VTI-BRD-031). `refusal` is the ballot box's or community's refusal of the last attempt, after which the idea is no longer being opened.";
|
|
1142
|
+
readonly type: "object";
|
|
1143
|
+
readonly additionalProperties: false;
|
|
1144
|
+
readonly required: readonly ["electionId", "startedAt"];
|
|
1145
|
+
readonly properties: {
|
|
1146
|
+
readonly electionId: {
|
|
1147
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
1148
|
+
};
|
|
1149
|
+
readonly startedAt: {
|
|
1150
|
+
readonly type: "string";
|
|
1151
|
+
readonly format: "date-time";
|
|
1152
|
+
readonly description: "When the facilitator accepted the idea.";
|
|
1153
|
+
};
|
|
1154
|
+
readonly refusal: {
|
|
1155
|
+
readonly type: "object";
|
|
1156
|
+
readonly additionalProperties: false;
|
|
1157
|
+
readonly required: readonly ["code", "refusedAt"];
|
|
1158
|
+
readonly properties: {
|
|
1159
|
+
readonly code: {
|
|
1160
|
+
readonly type: "string";
|
|
1161
|
+
readonly minLength: 1;
|
|
1162
|
+
readonly maxLength: 200;
|
|
1163
|
+
};
|
|
1164
|
+
readonly refusedAt: {
|
|
1165
|
+
readonly type: "string";
|
|
1166
|
+
readonly format: "date-time";
|
|
1167
|
+
};
|
|
1168
|
+
};
|
|
1169
|
+
};
|
|
1170
|
+
};
|
|
1171
|
+
};
|
|
1172
|
+
readonly ElectionId: {
|
|
1173
|
+
readonly title: "ElectionId";
|
|
1174
|
+
readonly 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.";
|
|
1175
|
+
readonly type: "string";
|
|
1176
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,128}$";
|
|
1177
|
+
};
|
|
1178
|
+
readonly IdeaElection: {
|
|
1179
|
+
readonly title: "IdeaElection";
|
|
1180
|
+
readonly description: "An idea's election as a board shows it (VTI-BRD-033): never who took a ticket or cast a ballot.";
|
|
1181
|
+
readonly type: "object";
|
|
1182
|
+
readonly additionalProperties: false;
|
|
1183
|
+
readonly required: readonly ["electionId", "state"];
|
|
1184
|
+
readonly properties: {
|
|
1185
|
+
readonly electionId: {
|
|
1186
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
1187
|
+
};
|
|
1188
|
+
readonly state: {
|
|
1189
|
+
readonly $ref: "#/$defs/ElectionState";
|
|
1190
|
+
};
|
|
1191
|
+
readonly ballotsOnBoard: {
|
|
1192
|
+
readonly type: "integer";
|
|
1193
|
+
readonly minimum: 0;
|
|
1194
|
+
readonly description: "The ballot box's latest board head's ballot count, where its board is public (VTI-VOT-052); absent otherwise. Counts ballots, not voters, where a later ballot replaces an earlier one.";
|
|
1195
|
+
};
|
|
1196
|
+
readonly boardHeadIssuedAt: {
|
|
1197
|
+
readonly type: "string";
|
|
1198
|
+
readonly format: "date-time";
|
|
1199
|
+
readonly description: "When the head `ballotsOnBoard` was read from was issued.";
|
|
1200
|
+
};
|
|
1201
|
+
readonly result: {
|
|
1202
|
+
readonly $ref: "#/$defs/ElectionResult";
|
|
1203
|
+
readonly description: "Present once the election is tallied.";
|
|
1204
|
+
};
|
|
1205
|
+
readonly certified: {
|
|
1206
|
+
readonly type: "boolean";
|
|
1207
|
+
readonly description: "Present with `result`: whether the community certified it (VTI-VOT-071).";
|
|
1208
|
+
};
|
|
1209
|
+
};
|
|
1210
|
+
};
|
|
1211
|
+
readonly ElectionResult: {
|
|
1212
|
+
readonly title: "ElectionResult";
|
|
1213
|
+
readonly description: "An election's result, computable by anyone who can read its board from the board and the registration alone (VTI-VOT-070).";
|
|
1214
|
+
readonly type: "object";
|
|
1215
|
+
readonly additionalProperties: false;
|
|
1216
|
+
readonly required: readonly ["electionId", "manifestDigest", "ballotsCounted", "questions", "head"];
|
|
1217
|
+
readonly properties: {
|
|
1218
|
+
readonly electionId: {
|
|
1219
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
1220
|
+
};
|
|
1221
|
+
readonly manifestDigest: {
|
|
1222
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
1223
|
+
};
|
|
1224
|
+
readonly ballotsCounted: {
|
|
1225
|
+
readonly type: "integer";
|
|
1226
|
+
readonly minimum: 0;
|
|
1227
|
+
};
|
|
1228
|
+
readonly questions: {
|
|
1229
|
+
readonly type: "array";
|
|
1230
|
+
readonly items: {
|
|
1231
|
+
readonly $ref: "#/$defs/QuestionResult";
|
|
1232
|
+
};
|
|
1233
|
+
};
|
|
1234
|
+
readonly head: {
|
|
1235
|
+
readonly $ref: "#/$defs/BoardHead";
|
|
1236
|
+
readonly description: "The head of the board as it stood at close: the result counts exactly its entries.";
|
|
1237
|
+
};
|
|
1238
|
+
};
|
|
1239
|
+
};
|
|
1240
|
+
readonly BoardHead: {
|
|
1241
|
+
readonly title: "BoardHead";
|
|
1242
|
+
readonly description: "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.";
|
|
1243
|
+
readonly type: "object";
|
|
1244
|
+
readonly additionalProperties: false;
|
|
1245
|
+
readonly required: readonly ["electionId", "treeSize", "rootHash", "issuedAt"];
|
|
1246
|
+
readonly properties: {
|
|
1247
|
+
readonly electionId: {
|
|
1248
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
1249
|
+
};
|
|
1250
|
+
readonly treeSize: {
|
|
1251
|
+
readonly type: "integer";
|
|
1252
|
+
readonly minimum: 0;
|
|
1253
|
+
};
|
|
1254
|
+
readonly rootHash: {
|
|
1255
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
1256
|
+
readonly description: "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash.";
|
|
1257
|
+
};
|
|
1258
|
+
readonly issuedAt: {
|
|
1259
|
+
readonly type: "string";
|
|
1260
|
+
readonly format: "date-time";
|
|
1261
|
+
};
|
|
1262
|
+
};
|
|
1263
|
+
};
|
|
1264
|
+
readonly DigestMultibase: {
|
|
1265
|
+
readonly title: "DigestMultibase";
|
|
1266
|
+
readonly description: "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.";
|
|
1267
|
+
readonly type: "string";
|
|
1268
|
+
readonly minLength: 16;
|
|
1269
|
+
readonly pattern: "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$";
|
|
1270
|
+
readonly examples: readonly ["zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"];
|
|
1271
|
+
};
|
|
1272
|
+
readonly QuestionResult: {
|
|
1273
|
+
readonly title: "QuestionResult";
|
|
1274
|
+
readonly description: "One question's totals. `choice`: selections per option. `ranking`: per option, how many ballots placed it at each position (index 0 = first). `score`: per option, the sum and the number of ballots that scored it. `text`: the answers, in board order, withheld (`withheld: true`) below the manifest's `textReleaseThreshold`. `abstained` counts ballots that left the question unanswered.";
|
|
1275
|
+
readonly type: "object";
|
|
1276
|
+
readonly additionalProperties: false;
|
|
1277
|
+
readonly required: readonly ["question", "abstained"];
|
|
1278
|
+
readonly properties: {
|
|
1279
|
+
readonly question: {
|
|
1280
|
+
readonly $ref: "#/$defs/Key";
|
|
1281
|
+
};
|
|
1282
|
+
readonly abstained: {
|
|
1283
|
+
readonly type: "integer";
|
|
1284
|
+
readonly minimum: 0;
|
|
1285
|
+
};
|
|
1286
|
+
readonly choice: {
|
|
1287
|
+
readonly type: "object";
|
|
1288
|
+
readonly propertyNames: {
|
|
1289
|
+
readonly $ref: "#/$defs/Key";
|
|
1290
|
+
};
|
|
1291
|
+
readonly additionalProperties: {
|
|
1292
|
+
readonly type: "integer";
|
|
1293
|
+
readonly minimum: 0;
|
|
1294
|
+
};
|
|
1295
|
+
};
|
|
1296
|
+
readonly ranking: {
|
|
1297
|
+
readonly type: "object";
|
|
1298
|
+
readonly propertyNames: {
|
|
1299
|
+
readonly $ref: "#/$defs/Key";
|
|
1300
|
+
};
|
|
1301
|
+
readonly additionalProperties: {
|
|
1302
|
+
readonly type: "array";
|
|
1303
|
+
readonly items: {
|
|
1304
|
+
readonly type: "integer";
|
|
1305
|
+
readonly minimum: 0;
|
|
1306
|
+
};
|
|
1307
|
+
};
|
|
1308
|
+
};
|
|
1309
|
+
readonly score: {
|
|
1310
|
+
readonly type: "object";
|
|
1311
|
+
readonly propertyNames: {
|
|
1312
|
+
readonly $ref: "#/$defs/Key";
|
|
1313
|
+
};
|
|
1314
|
+
readonly additionalProperties: {
|
|
1315
|
+
readonly type: "object";
|
|
1316
|
+
readonly additionalProperties: false;
|
|
1317
|
+
readonly required: readonly ["sum", "count"];
|
|
1318
|
+
readonly properties: {
|
|
1319
|
+
readonly sum: {
|
|
1320
|
+
readonly type: "integer";
|
|
1321
|
+
};
|
|
1322
|
+
readonly count: {
|
|
1323
|
+
readonly type: "integer";
|
|
1324
|
+
readonly minimum: 0;
|
|
1325
|
+
};
|
|
1326
|
+
};
|
|
1327
|
+
};
|
|
1328
|
+
};
|
|
1329
|
+
readonly text: {
|
|
1330
|
+
readonly type: "array";
|
|
1331
|
+
readonly items: {
|
|
1332
|
+
readonly type: "string";
|
|
1333
|
+
readonly maxLength: 4096;
|
|
1334
|
+
};
|
|
1335
|
+
};
|
|
1336
|
+
readonly withheld: {
|
|
1337
|
+
readonly type: "boolean";
|
|
1338
|
+
};
|
|
1339
|
+
};
|
|
1340
|
+
};
|
|
1341
|
+
readonly ElectionState: {
|
|
1342
|
+
readonly title: "ElectionState";
|
|
1343
|
+
readonly type: "string";
|
|
1344
|
+
readonly enum: readonly ["registered", "registration", "voting", "closed", "tallied", "cancelled"];
|
|
1345
|
+
};
|
|
1346
|
+
readonly Author: {
|
|
1347
|
+
readonly title: "Author";
|
|
1348
|
+
readonly description: "Who proposed an idea or wrote a note, as the board's audience sees them. `entryId` is their directory entry, which survives a rotation of their DID; `name` is their directory display name as this caller may see it, absent where the directory withholds it. A departed member is shown as `formerMember: true` with neither (VTI-BRD-060).";
|
|
1349
|
+
readonly type: "object";
|
|
1350
|
+
readonly additionalProperties: false;
|
|
1351
|
+
readonly properties: {
|
|
1352
|
+
readonly entryId: {
|
|
1353
|
+
readonly $ref: "#/$defs/EntryId";
|
|
1354
|
+
};
|
|
1355
|
+
readonly name: {
|
|
1356
|
+
readonly type: "string";
|
|
1357
|
+
readonly minLength: 1;
|
|
1358
|
+
readonly maxLength: 200;
|
|
1359
|
+
};
|
|
1360
|
+
readonly formerMember: {
|
|
1361
|
+
readonly const: true;
|
|
1362
|
+
};
|
|
1363
|
+
readonly you: {
|
|
1364
|
+
readonly const: true;
|
|
1365
|
+
readonly description: "Present when the caller is the author.";
|
|
1366
|
+
};
|
|
1367
|
+
};
|
|
1368
|
+
};
|
|
1369
|
+
readonly EntryId: {
|
|
1370
|
+
readonly title: "EntryId";
|
|
1371
|
+
readonly description: "Opaque identifier of one directory entry: `dir_` followed by 16 to 64 base64url characters. Random, scoped to one community, and stable for the life of the membership — it survives a rotation of the member's DID, which is why groups, notes and cards are keyed by it. It MUST NOT be derived from, and MUST NOT reveal, any DID of the member, and the same person's entries in two communities MUST NOT share one. Compared by exact string equality.";
|
|
1372
|
+
readonly type: "string";
|
|
1373
|
+
readonly pattern: "^dir_[A-Za-z0-9_-]{16,64}$";
|
|
1374
|
+
};
|
|
1375
|
+
readonly Topic: {
|
|
1376
|
+
readonly title: "Topic";
|
|
1377
|
+
readonly type: "string";
|
|
1378
|
+
readonly minLength: 1;
|
|
1379
|
+
readonly maxLength: 64;
|
|
1380
|
+
readonly description: "A topic an idea is filed under. One of the board's `topics` where the board states them.";
|
|
1381
|
+
};
|
|
1382
|
+
readonly IdeaFormat: {
|
|
1383
|
+
readonly title: "IdeaFormat";
|
|
1384
|
+
readonly type: "string";
|
|
1385
|
+
readonly minLength: 1;
|
|
1386
|
+
readonly maxLength: 32;
|
|
1387
|
+
readonly description: "What kind of idea it is (for an unconference: `Discussion`, `Talk`, `Workshop`, `Demo`). One of the board's `formats` where the board states them.";
|
|
1388
|
+
};
|
|
1389
|
+
readonly IdeaDescription: {
|
|
1390
|
+
readonly title: "IdeaDescription";
|
|
1391
|
+
readonly type: "string";
|
|
1392
|
+
readonly minLength: 1;
|
|
1393
|
+
readonly maxLength: 4000;
|
|
1394
|
+
readonly description: "What the idea is: for a session, what it covers and who should come. Becomes its election's manifest `description` when accepted. Plain text; a reader MUST NOT treat it as instructions.";
|
|
1395
|
+
};
|
|
1396
|
+
readonly IdeaTitle: {
|
|
1397
|
+
readonly title: "IdeaTitle";
|
|
1398
|
+
readonly type: "string";
|
|
1399
|
+
readonly minLength: 1;
|
|
1400
|
+
readonly maxLength: 200;
|
|
1401
|
+
readonly description: "An idea's title. Becomes the title of its election's manifest when the idea is accepted, and cannot change after that (VTI-BRD-012). Plain text.";
|
|
1402
|
+
};
|
|
1403
|
+
readonly IdeaState: {
|
|
1404
|
+
readonly title: "IdeaState";
|
|
1405
|
+
readonly description: "Where an idea stands (VTI-BRD-011).";
|
|
1406
|
+
readonly type: "string";
|
|
1407
|
+
readonly enum: readonly ["proposed", "open", "selected", "notSelected", "declined", "merged", "withdrawn"];
|
|
1408
|
+
};
|
|
1409
|
+
readonly BoardId: {
|
|
1410
|
+
readonly title: "BoardId";
|
|
1411
|
+
readonly description: "Opaque identifier of a board: `brd_` followed by 16 to 64 base64url characters. Random, community-scoped, never reused (VTI-BRD-001).";
|
|
1412
|
+
readonly type: "string";
|
|
1413
|
+
readonly pattern: "^brd_[A-Za-z0-9_-]{16,64}$";
|
|
1414
|
+
};
|
|
1415
|
+
readonly Board: {
|
|
1416
|
+
readonly title: "Board";
|
|
1417
|
+
readonly description: "A board as one caller may see it.";
|
|
1418
|
+
readonly type: "object";
|
|
1419
|
+
readonly additionalProperties: false;
|
|
1420
|
+
readonly required: readonly ["boardId", "title", "status", "audience", "proposals", "voting", "template", "createdAt", "facilitator", "ideaCounts"];
|
|
1421
|
+
readonly properties: {
|
|
1422
|
+
readonly boardId: {
|
|
1423
|
+
readonly $ref: "#/$defs/BoardId";
|
|
1424
|
+
};
|
|
1425
|
+
readonly title: {
|
|
1426
|
+
readonly $ref: "#/$defs/BoardTitle";
|
|
1427
|
+
};
|
|
1428
|
+
readonly description: {
|
|
1429
|
+
readonly $ref: "#/$defs/BoardDescription";
|
|
1430
|
+
};
|
|
1431
|
+
readonly status: {
|
|
1432
|
+
readonly $ref: "#/$defs/BoardStatus";
|
|
1433
|
+
};
|
|
1434
|
+
readonly audience: {
|
|
1435
|
+
readonly $ref: "#/$defs/BoardAudience";
|
|
1436
|
+
};
|
|
1437
|
+
readonly proposals: {
|
|
1438
|
+
readonly $ref: "#/$defs/Window";
|
|
1439
|
+
readonly description: "When ideas are taken (VTI-BRD-010).";
|
|
1440
|
+
};
|
|
1441
|
+
readonly voting: {
|
|
1442
|
+
readonly $ref: "#/$defs/Window";
|
|
1443
|
+
readonly description: "When every idea's election takes ballots. Opens after `proposals` opens and closes after it closes (VTI-BRD-001).";
|
|
1444
|
+
};
|
|
1445
|
+
readonly topics: {
|
|
1446
|
+
readonly type: "array";
|
|
1447
|
+
readonly maxItems: 32;
|
|
1448
|
+
readonly uniqueItems: true;
|
|
1449
|
+
readonly items: {
|
|
1450
|
+
readonly $ref: "#/$defs/Topic";
|
|
1451
|
+
};
|
|
1452
|
+
};
|
|
1453
|
+
readonly formats: {
|
|
1454
|
+
readonly type: "array";
|
|
1455
|
+
readonly maxItems: 16;
|
|
1456
|
+
readonly uniqueItems: true;
|
|
1457
|
+
readonly items: {
|
|
1458
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
1459
|
+
};
|
|
1460
|
+
};
|
|
1461
|
+
readonly maxIdeasPerMember: {
|
|
1462
|
+
readonly type: "integer";
|
|
1463
|
+
readonly minimum: 1;
|
|
1464
|
+
readonly maximum: 100;
|
|
1465
|
+
readonly description: "The most ideas one member may have on the board that are not `withdrawn` or `declined`. Absent: no limit beyond the community's own.";
|
|
1466
|
+
};
|
|
1467
|
+
readonly selectionRule: {
|
|
1468
|
+
readonly type: "string";
|
|
1469
|
+
readonly minLength: 1;
|
|
1470
|
+
readonly maxLength: 500;
|
|
1471
|
+
readonly description: "How facilitators intend to select, in plain words (VTI-BRD-041), e.g. \"The twelve ideas the most members would attend\".";
|
|
1472
|
+
};
|
|
1473
|
+
readonly timetable: {
|
|
1474
|
+
readonly type: "array";
|
|
1475
|
+
readonly maxItems: 256;
|
|
1476
|
+
readonly items: {
|
|
1477
|
+
readonly $ref: "#/$defs/Slot";
|
|
1478
|
+
};
|
|
1479
|
+
};
|
|
1480
|
+
readonly template: {
|
|
1481
|
+
readonly $ref: "#/$defs/ElectionTemplate";
|
|
1482
|
+
};
|
|
1483
|
+
readonly createdAt: {
|
|
1484
|
+
readonly type: "string";
|
|
1485
|
+
readonly format: "date-time";
|
|
1486
|
+
};
|
|
1487
|
+
readonly facilitator: {
|
|
1488
|
+
readonly type: "boolean";
|
|
1489
|
+
readonly description: "Whether the caller facilitates this board.";
|
|
1490
|
+
};
|
|
1491
|
+
readonly ideaCounts: {
|
|
1492
|
+
readonly type: "object";
|
|
1493
|
+
readonly additionalProperties: false;
|
|
1494
|
+
readonly description: "How many of the board's ideas are in each state the caller may see.";
|
|
1495
|
+
readonly properties: {
|
|
1496
|
+
readonly proposed: {
|
|
1497
|
+
readonly type: "integer";
|
|
1498
|
+
readonly minimum: 0;
|
|
1499
|
+
};
|
|
1500
|
+
readonly open: {
|
|
1501
|
+
readonly type: "integer";
|
|
1502
|
+
readonly minimum: 0;
|
|
1503
|
+
};
|
|
1504
|
+
readonly selected: {
|
|
1505
|
+
readonly type: "integer";
|
|
1506
|
+
readonly minimum: 0;
|
|
1507
|
+
};
|
|
1508
|
+
readonly notSelected: {
|
|
1509
|
+
readonly type: "integer";
|
|
1510
|
+
readonly minimum: 0;
|
|
1511
|
+
};
|
|
1512
|
+
readonly declined: {
|
|
1513
|
+
readonly type: "integer";
|
|
1514
|
+
readonly minimum: 0;
|
|
1515
|
+
};
|
|
1516
|
+
readonly merged: {
|
|
1517
|
+
readonly type: "integer";
|
|
1518
|
+
readonly minimum: 0;
|
|
1519
|
+
};
|
|
1520
|
+
readonly withdrawn: {
|
|
1521
|
+
readonly type: "integer";
|
|
1522
|
+
readonly minimum: 0;
|
|
1523
|
+
};
|
|
1524
|
+
};
|
|
1525
|
+
};
|
|
1526
|
+
};
|
|
1527
|
+
};
|
|
1528
|
+
readonly ElectionTemplate: {
|
|
1529
|
+
readonly title: "ElectionTemplate";
|
|
1530
|
+
readonly description: "Every member of an idea's election manifest that the board fixes (VTI-BRD-030). When a facilitator accepts an idea the community completes it: `electionId` (naming the board and the idea), `community`, `title` and `description` from the idea, `registrationOpensAt` and `votingOpensAt` from the board's voting window's `opensAt` or the acceptance, whichever is later, `votingClosesAt` from its `closesAt`, `roll` from the board's audience (rule `members`, or a credential roll naming the group), and `binding: false`. A board's template is never binding, and so has no `binding` member.";
|
|
1531
|
+
readonly type: "object";
|
|
1532
|
+
readonly additionalProperties: false;
|
|
1533
|
+
readonly required: readonly ["questions", "secrecy", "revote", "board", "ballotBox", "allowEarlyClose", "resultsBeforeClose", "textReleaseThreshold"];
|
|
1534
|
+
readonly properties: {
|
|
1535
|
+
readonly questions: {
|
|
1536
|
+
readonly type: "array";
|
|
1537
|
+
readonly minItems: 1;
|
|
1538
|
+
readonly maxItems: 16;
|
|
1539
|
+
readonly items: {
|
|
1540
|
+
readonly $ref: "#/$defs/Question";
|
|
1541
|
+
};
|
|
1542
|
+
};
|
|
1543
|
+
readonly secrecy: {
|
|
1544
|
+
readonly $ref: "#/$defs/SecrecyLevel";
|
|
1545
|
+
};
|
|
1546
|
+
readonly revote: {
|
|
1547
|
+
readonly $ref: "#/$defs/Revote";
|
|
1548
|
+
};
|
|
1549
|
+
readonly board: {
|
|
1550
|
+
readonly type: "object";
|
|
1551
|
+
readonly additionalProperties: false;
|
|
1552
|
+
readonly required: readonly ["visibility", "auditors"];
|
|
1553
|
+
readonly description: "The ballot box's board for each idea's election, as a manifest states it (VTI-VOT-052). `public` lets a board show each idea's ballot count while voting is open (VTI-BRD-033).";
|
|
1554
|
+
readonly properties: {
|
|
1555
|
+
readonly visibility: {
|
|
1556
|
+
readonly $ref: "#/$defs/BoardVisibility";
|
|
1557
|
+
};
|
|
1558
|
+
readonly auditors: {
|
|
1559
|
+
readonly type: "array";
|
|
1560
|
+
readonly uniqueItems: true;
|
|
1561
|
+
readonly items: {
|
|
1562
|
+
readonly type: "string";
|
|
1563
|
+
readonly minLength: 1;
|
|
1564
|
+
readonly maxLength: 2048;
|
|
1565
|
+
};
|
|
1566
|
+
};
|
|
1567
|
+
};
|
|
1568
|
+
};
|
|
1569
|
+
readonly ballotBox: {
|
|
1570
|
+
readonly type: "string";
|
|
1571
|
+
readonly minLength: 1;
|
|
1572
|
+
readonly maxLength: 2048;
|
|
1573
|
+
readonly description: "The DID of the voting service every idea's election is registered with; one on the community's list (VTI-VOT-082).";
|
|
1574
|
+
};
|
|
1575
|
+
readonly trustees: {
|
|
1576
|
+
readonly $ref: "#/$defs/Trustees";
|
|
1577
|
+
};
|
|
1578
|
+
readonly allowEarlyClose: {
|
|
1579
|
+
readonly type: "boolean";
|
|
1580
|
+
};
|
|
1581
|
+
readonly resultsBeforeClose: {
|
|
1582
|
+
readonly type: "boolean";
|
|
1583
|
+
readonly description: "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061). A board SHOULD set it false (VTI-BRD-033).";
|
|
1584
|
+
};
|
|
1585
|
+
readonly textReleaseThreshold: {
|
|
1586
|
+
readonly type: "integer";
|
|
1587
|
+
readonly minimum: 1;
|
|
1588
|
+
readonly description: "Counted ballots required before any text answer is disclosed (VTI-VOT-065); SHOULD be at least 10.";
|
|
1589
|
+
};
|
|
1590
|
+
};
|
|
1591
|
+
};
|
|
1592
|
+
readonly Trustees: {
|
|
1593
|
+
readonly title: "Trustees";
|
|
1594
|
+
readonly 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.";
|
|
1595
|
+
readonly type: "object";
|
|
1596
|
+
readonly additionalProperties: false;
|
|
1597
|
+
readonly required: readonly ["dids", "threshold"];
|
|
1598
|
+
readonly properties: {
|
|
1599
|
+
readonly dids: {
|
|
1600
|
+
readonly type: "array";
|
|
1601
|
+
readonly minItems: 2;
|
|
1602
|
+
readonly items: {
|
|
1603
|
+
readonly type: "string";
|
|
1604
|
+
readonly minLength: 1;
|
|
1605
|
+
readonly maxLength: 2048;
|
|
1606
|
+
};
|
|
1607
|
+
readonly uniqueItems: true;
|
|
1608
|
+
};
|
|
1609
|
+
readonly threshold: {
|
|
1610
|
+
readonly type: "integer";
|
|
1611
|
+
readonly minimum: 2;
|
|
1612
|
+
};
|
|
1613
|
+
};
|
|
1614
|
+
};
|
|
1615
|
+
readonly BoardVisibility: {
|
|
1616
|
+
readonly title: "BoardVisibility";
|
|
1617
|
+
readonly 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).";
|
|
1618
|
+
readonly type: "string";
|
|
1619
|
+
readonly enum: readonly ["public", "private"];
|
|
1620
|
+
};
|
|
1621
|
+
readonly Revote: {
|
|
1622
|
+
readonly title: "Revote";
|
|
1623
|
+
readonly description: "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).";
|
|
1624
|
+
readonly type: "string";
|
|
1625
|
+
readonly enum: readonly ["replace", "refuse"];
|
|
1626
|
+
};
|
|
1627
|
+
readonly SecrecyLevel: {
|
|
1628
|
+
readonly title: "SecrecyLevel";
|
|
1629
|
+
readonly 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).";
|
|
1630
|
+
readonly type: "string";
|
|
1631
|
+
readonly enum: readonly ["open", "sealed", "talliedEncrypted"];
|
|
1632
|
+
};
|
|
1633
|
+
readonly Question: {
|
|
1634
|
+
readonly title: "Question";
|
|
1635
|
+
readonly description: "One question. Tagged union over `type`.";
|
|
1636
|
+
readonly oneOf: readonly [{
|
|
1637
|
+
readonly title: "ChoiceQuestion";
|
|
1638
|
+
readonly description: "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.";
|
|
1639
|
+
readonly type: "object";
|
|
1640
|
+
readonly additionalProperties: false;
|
|
1641
|
+
readonly required: readonly ["key", "type", "options", "minSelections", "maxSelections", "optional"];
|
|
1642
|
+
readonly properties: {
|
|
1643
|
+
readonly key: {
|
|
1644
|
+
readonly $ref: "#/$defs/Key";
|
|
1645
|
+
};
|
|
1646
|
+
readonly type: {
|
|
1647
|
+
readonly const: "choice";
|
|
1648
|
+
};
|
|
1649
|
+
readonly text: {
|
|
1650
|
+
readonly type: "string";
|
|
1651
|
+
readonly maxLength: 2048;
|
|
1652
|
+
};
|
|
1653
|
+
readonly options: {
|
|
1654
|
+
readonly type: "array";
|
|
1655
|
+
readonly minItems: 2;
|
|
1656
|
+
readonly maxItems: 256;
|
|
1657
|
+
readonly items: {
|
|
1658
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
1659
|
+
};
|
|
1660
|
+
};
|
|
1661
|
+
readonly minSelections: {
|
|
1662
|
+
readonly type: "integer";
|
|
1663
|
+
readonly minimum: 0;
|
|
1664
|
+
};
|
|
1665
|
+
readonly maxSelections: {
|
|
1666
|
+
readonly type: "integer";
|
|
1667
|
+
readonly minimum: 1;
|
|
1668
|
+
};
|
|
1669
|
+
readonly optional: {
|
|
1670
|
+
readonly type: "boolean";
|
|
1671
|
+
};
|
|
1672
|
+
};
|
|
1673
|
+
}, {
|
|
1674
|
+
readonly title: "RankingQuestion";
|
|
1675
|
+
readonly description: "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.";
|
|
1676
|
+
readonly type: "object";
|
|
1677
|
+
readonly additionalProperties: false;
|
|
1678
|
+
readonly required: readonly ["key", "type", "options", "partial", "optional"];
|
|
1679
|
+
readonly properties: {
|
|
1680
|
+
readonly key: {
|
|
1681
|
+
readonly $ref: "#/$defs/Key";
|
|
1682
|
+
};
|
|
1683
|
+
readonly type: {
|
|
1684
|
+
readonly const: "ranking";
|
|
1685
|
+
};
|
|
1686
|
+
readonly text: {
|
|
1687
|
+
readonly type: "string";
|
|
1688
|
+
readonly maxLength: 2048;
|
|
1689
|
+
};
|
|
1690
|
+
readonly options: {
|
|
1691
|
+
readonly type: "array";
|
|
1692
|
+
readonly minItems: 2;
|
|
1693
|
+
readonly maxItems: 64;
|
|
1694
|
+
readonly items: {
|
|
1695
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
1696
|
+
};
|
|
1697
|
+
};
|
|
1698
|
+
readonly partial: {
|
|
1699
|
+
readonly type: "boolean";
|
|
1700
|
+
};
|
|
1701
|
+
readonly optional: {
|
|
1702
|
+
readonly type: "boolean";
|
|
1703
|
+
};
|
|
1704
|
+
};
|
|
1705
|
+
}, {
|
|
1706
|
+
readonly title: "ScoreQuestion";
|
|
1707
|
+
readonly description: "Give each option an integer score within [min, max].";
|
|
1708
|
+
readonly type: "object";
|
|
1709
|
+
readonly additionalProperties: false;
|
|
1710
|
+
readonly required: readonly ["key", "type", "options", "min", "max", "optional"];
|
|
1711
|
+
readonly properties: {
|
|
1712
|
+
readonly key: {
|
|
1713
|
+
readonly $ref: "#/$defs/Key";
|
|
1714
|
+
};
|
|
1715
|
+
readonly type: {
|
|
1716
|
+
readonly const: "score";
|
|
1717
|
+
};
|
|
1718
|
+
readonly text: {
|
|
1719
|
+
readonly type: "string";
|
|
1720
|
+
readonly maxLength: 2048;
|
|
1721
|
+
};
|
|
1722
|
+
readonly options: {
|
|
1723
|
+
readonly type: "array";
|
|
1724
|
+
readonly minItems: 1;
|
|
1725
|
+
readonly maxItems: 256;
|
|
1726
|
+
readonly items: {
|
|
1727
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
1728
|
+
};
|
|
1729
|
+
};
|
|
1730
|
+
readonly min: {
|
|
1731
|
+
readonly type: "integer";
|
|
1732
|
+
};
|
|
1733
|
+
readonly max: {
|
|
1734
|
+
readonly type: "integer";
|
|
1735
|
+
};
|
|
1736
|
+
readonly optional: {
|
|
1737
|
+
readonly type: "boolean";
|
|
1738
|
+
};
|
|
1739
|
+
};
|
|
1740
|
+
}, {
|
|
1741
|
+
readonly title: "TextQuestion";
|
|
1742
|
+
readonly description: "Free text of at most `maxLength` characters.";
|
|
1743
|
+
readonly type: "object";
|
|
1744
|
+
readonly additionalProperties: false;
|
|
1745
|
+
readonly required: readonly ["key", "type", "maxLength", "optional"];
|
|
1746
|
+
readonly properties: {
|
|
1747
|
+
readonly key: {
|
|
1748
|
+
readonly $ref: "#/$defs/Key";
|
|
1749
|
+
};
|
|
1750
|
+
readonly type: {
|
|
1751
|
+
readonly const: "text";
|
|
1752
|
+
};
|
|
1753
|
+
readonly text: {
|
|
1754
|
+
readonly type: "string";
|
|
1755
|
+
readonly maxLength: 2048;
|
|
1756
|
+
};
|
|
1757
|
+
readonly maxLength: {
|
|
1758
|
+
readonly type: "integer";
|
|
1759
|
+
readonly minimum: 1;
|
|
1760
|
+
readonly maximum: 4096;
|
|
1761
|
+
};
|
|
1762
|
+
readonly optional: {
|
|
1763
|
+
readonly type: "boolean";
|
|
1764
|
+
};
|
|
1765
|
+
};
|
|
1766
|
+
}];
|
|
1767
|
+
};
|
|
1768
|
+
readonly QuestionOption: {
|
|
1769
|
+
readonly title: "QuestionOption";
|
|
1770
|
+
readonly type: "object";
|
|
1771
|
+
readonly additionalProperties: false;
|
|
1772
|
+
readonly required: readonly ["key"];
|
|
1773
|
+
readonly properties: {
|
|
1774
|
+
readonly key: {
|
|
1775
|
+
readonly $ref: "#/$defs/Key";
|
|
1776
|
+
};
|
|
1777
|
+
readonly label: {
|
|
1778
|
+
readonly type: "string";
|
|
1779
|
+
readonly maxLength: 512;
|
|
1780
|
+
readonly description: "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014).";
|
|
1781
|
+
};
|
|
1782
|
+
};
|
|
1783
|
+
};
|
|
1784
|
+
readonly Slot: {
|
|
1785
|
+
readonly title: "Slot";
|
|
1786
|
+
readonly description: "One place in a board's timetable that a selected idea can be put in (VTI-BRD-040): a place (`label`, e.g. a room) and a time.";
|
|
1787
|
+
readonly type: "object";
|
|
1788
|
+
readonly additionalProperties: false;
|
|
1789
|
+
readonly required: readonly ["slotId", "label", "startsAt", "endsAt"];
|
|
1790
|
+
readonly properties: {
|
|
1791
|
+
readonly slotId: {
|
|
1792
|
+
readonly $ref: "#/$defs/Key";
|
|
1793
|
+
};
|
|
1794
|
+
readonly label: {
|
|
1795
|
+
readonly type: "string";
|
|
1796
|
+
readonly minLength: 1;
|
|
1797
|
+
readonly maxLength: 100;
|
|
1798
|
+
};
|
|
1799
|
+
readonly startsAt: {
|
|
1800
|
+
readonly type: "string";
|
|
1801
|
+
readonly format: "date-time";
|
|
1802
|
+
};
|
|
1803
|
+
readonly endsAt: {
|
|
1804
|
+
readonly type: "string";
|
|
1805
|
+
readonly format: "date-time";
|
|
1806
|
+
};
|
|
1807
|
+
};
|
|
1808
|
+
};
|
|
1809
|
+
readonly Window: {
|
|
1810
|
+
readonly title: "Window";
|
|
1811
|
+
readonly description: "A period, open from `opensAt` until `closesAt`. `closesAt` is after `opensAt` (a consumer check; JSON Schema cannot compare them).";
|
|
1812
|
+
readonly type: "object";
|
|
1813
|
+
readonly additionalProperties: false;
|
|
1814
|
+
readonly required: readonly ["opensAt", "closesAt"];
|
|
1815
|
+
readonly properties: {
|
|
1816
|
+
readonly opensAt: {
|
|
1817
|
+
readonly type: "string";
|
|
1818
|
+
readonly format: "date-time";
|
|
1819
|
+
};
|
|
1820
|
+
readonly closesAt: {
|
|
1821
|
+
readonly type: "string";
|
|
1822
|
+
readonly format: "date-time";
|
|
1823
|
+
};
|
|
1824
|
+
};
|
|
1825
|
+
};
|
|
1826
|
+
readonly BoardAudience: {
|
|
1827
|
+
readonly title: "BoardAudience";
|
|
1828
|
+
readonly description: "Who may see and use a board (VTI-BRD-003): every active member of the community (`members`), or the members of one community group (`group`, with `groupId`). Facilitators always see the board.";
|
|
1829
|
+
readonly oneOf: readonly [{
|
|
1830
|
+
readonly type: "object";
|
|
1831
|
+
readonly additionalProperties: false;
|
|
1832
|
+
readonly required: readonly ["kind"];
|
|
1833
|
+
readonly properties: {
|
|
1834
|
+
readonly kind: {
|
|
1835
|
+
readonly const: "members";
|
|
1836
|
+
};
|
|
1837
|
+
};
|
|
1838
|
+
}, {
|
|
1839
|
+
readonly type: "object";
|
|
1840
|
+
readonly additionalProperties: false;
|
|
1841
|
+
readonly required: readonly ["kind", "groupId"];
|
|
1842
|
+
readonly properties: {
|
|
1843
|
+
readonly kind: {
|
|
1844
|
+
readonly const: "group";
|
|
1845
|
+
};
|
|
1846
|
+
readonly groupId: {
|
|
1847
|
+
readonly $ref: "#/$defs/GroupId";
|
|
1848
|
+
};
|
|
1849
|
+
};
|
|
1850
|
+
}];
|
|
1851
|
+
};
|
|
1852
|
+
readonly GroupId: {
|
|
1853
|
+
readonly title: "GroupId";
|
|
1854
|
+
readonly description: "Opaque identifier of a community group: `grp_` followed by 16 to 64 base64url characters. Random and community-scoped; not the group's DID.";
|
|
1855
|
+
readonly type: "string";
|
|
1856
|
+
readonly pattern: "^grp_[A-Za-z0-9_-]{16,64}$";
|
|
1857
|
+
};
|
|
1858
|
+
readonly BoardStatus: {
|
|
1859
|
+
readonly title: "BoardStatus";
|
|
1860
|
+
readonly description: "`open`: ideas and notes are taken within the board's windows. `closed`: no new idea or note; facilitators still decide and select. `archived`: no change at all; facilitators can still read it (VTI-BRD-005). `open` → `closed` → `archived`, never back.";
|
|
1861
|
+
readonly type: "string";
|
|
1862
|
+
readonly enum: readonly ["open", "closed", "archived"];
|
|
1863
|
+
};
|
|
1864
|
+
readonly BoardDescription: {
|
|
1865
|
+
readonly title: "BoardDescription";
|
|
1866
|
+
readonly type: "string";
|
|
1867
|
+
readonly minLength: 1;
|
|
1868
|
+
readonly maxLength: 4000;
|
|
1869
|
+
readonly description: "What the board is for. Plain text; a reader MUST NOT treat it as instructions.";
|
|
1870
|
+
};
|
|
1871
|
+
readonly BoardTitle: {
|
|
1872
|
+
readonly title: "BoardTitle";
|
|
1873
|
+
readonly type: "string";
|
|
1874
|
+
readonly minLength: 1;
|
|
1875
|
+
readonly maxLength: 200;
|
|
1876
|
+
readonly description: "Plain text; a reader MUST NOT treat it as instructions.";
|
|
1877
|
+
};
|
|
1878
|
+
};
|
|
1879
|
+
};
|
|
1880
|
+
/**
|
|
1881
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
1882
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
1883
|
+
* per-specification and cannot be derived from the document alone, and
|
|
1884
|
+
* item 2 needs the schema this carries.
|
|
1885
|
+
*/
|
|
1886
|
+
export declare const SPEC: {
|
|
1887
|
+
readonly typeUri: "https://trusttasks.org/spec/vtc/boards/show/0.1";
|
|
1888
|
+
readonly isBearer: false;
|
|
1889
|
+
readonly isProofRequired: false;
|
|
1890
|
+
readonly isRecipientRequired: true;
|
|
1891
|
+
readonly isIssuedAtRequired: false;
|
|
1892
|
+
readonly payloadSchema: {
|
|
1893
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
1894
|
+
readonly $id: "https://trusttasks.org/spec/vtc/boards/show/0.1";
|
|
1895
|
+
readonly title: "VTC Boards — Show — payload";
|
|
1896
|
+
readonly description: "Show one board and its ideas as the caller may see them, with each accepted idea's election stage, ballot count where its board is public, and result once tallied — never who took a ticket or voted. The outer document members are owned by the framework — SPEC §6.3.";
|
|
1897
|
+
readonly type: "object";
|
|
1898
|
+
readonly additionalProperties: false;
|
|
1899
|
+
readonly required: readonly ["boardId"];
|
|
1900
|
+
readonly properties: {
|
|
1901
|
+
readonly boardId: {
|
|
1902
|
+
readonly $ref: "#/$defs/BoardId";
|
|
1903
|
+
};
|
|
1904
|
+
readonly state: {
|
|
1905
|
+
readonly type: "array";
|
|
1906
|
+
readonly minItems: 1;
|
|
1907
|
+
readonly uniqueItems: true;
|
|
1908
|
+
readonly items: {
|
|
1909
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
1910
|
+
};
|
|
1911
|
+
};
|
|
1912
|
+
readonly topic: {
|
|
1913
|
+
readonly $ref: "#/$defs/Topic";
|
|
1914
|
+
};
|
|
1915
|
+
readonly cursor: {
|
|
1916
|
+
readonly type: "string";
|
|
1917
|
+
readonly minLength: 1;
|
|
1918
|
+
readonly maxLength: 1024;
|
|
1919
|
+
readonly description: "An opaque continuation token from a previous response's `nextCursor`, bound to the caller and the filters; a responder MUST NOT accept a cursor it did not issue.";
|
|
1920
|
+
};
|
|
1921
|
+
readonly limit: {
|
|
1922
|
+
readonly type: "integer";
|
|
1923
|
+
readonly minimum: 1;
|
|
1924
|
+
readonly maximum: 200;
|
|
1925
|
+
readonly description: "The most items to return, at most 200; the responder chooses a default (50) and MAY return fewer.";
|
|
1926
|
+
};
|
|
1927
|
+
readonly ext: {
|
|
1928
|
+
readonly $ref: "#/$defs/Ext";
|
|
1929
|
+
};
|
|
1930
|
+
};
|
|
1931
|
+
readonly $defs: {
|
|
1932
|
+
readonly Response: {
|
|
1933
|
+
readonly $anchor: "response";
|
|
1934
|
+
readonly title: "VTC Boards — Show — response payload";
|
|
1935
|
+
readonly description: "The success response to a vtc/boards/show/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/boards/show/0.1#response.";
|
|
1936
|
+
readonly type: "object";
|
|
1937
|
+
readonly additionalProperties: false;
|
|
1938
|
+
readonly required: readonly ["board", "ideas"];
|
|
1939
|
+
readonly properties: {
|
|
1940
|
+
readonly board: {
|
|
1941
|
+
readonly $ref: "#/$defs/Board";
|
|
1942
|
+
};
|
|
1943
|
+
readonly ideas: {
|
|
1944
|
+
readonly type: "array";
|
|
1945
|
+
readonly items: {
|
|
1946
|
+
readonly $ref: "#/$defs/Idea";
|
|
1947
|
+
};
|
|
1948
|
+
};
|
|
1949
|
+
readonly nextCursor: {
|
|
1950
|
+
readonly type: "string";
|
|
1951
|
+
readonly maxLength: 1024;
|
|
1952
|
+
readonly description: "Continuation token for the next page; pass it back as `cursor`. Absent on the last page — never `null`.";
|
|
1953
|
+
};
|
|
1954
|
+
readonly ext: {
|
|
1955
|
+
readonly $ref: "#/$defs/Ext";
|
|
1956
|
+
};
|
|
1957
|
+
};
|
|
1958
|
+
};
|
|
1959
|
+
readonly Ext: {
|
|
1960
|
+
readonly title: "Ext";
|
|
1961
|
+
readonly 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.";
|
|
1962
|
+
readonly type: "object";
|
|
1963
|
+
readonly minProperties: 1;
|
|
1964
|
+
readonly additionalProperties: true;
|
|
1965
|
+
readonly propertyNames: {
|
|
1966
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
1967
|
+
};
|
|
1968
|
+
};
|
|
1969
|
+
readonly Idea: {
|
|
1970
|
+
readonly title: "Idea";
|
|
1971
|
+
readonly description: "An idea as one caller may see it.";
|
|
1972
|
+
readonly type: "object";
|
|
1973
|
+
readonly additionalProperties: false;
|
|
1974
|
+
readonly required: readonly ["ideaId", "boardId", "state", "title", "description", "proposer", "proposedAt", "noteCount"];
|
|
1975
|
+
readonly properties: {
|
|
1976
|
+
readonly ideaId: {
|
|
1977
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
1978
|
+
};
|
|
1979
|
+
readonly boardId: {
|
|
1980
|
+
readonly $ref: "#/$defs/BoardId";
|
|
1981
|
+
};
|
|
1982
|
+
readonly state: {
|
|
1983
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
1984
|
+
};
|
|
1985
|
+
readonly title: {
|
|
1986
|
+
readonly $ref: "#/$defs/IdeaTitle";
|
|
1987
|
+
};
|
|
1988
|
+
readonly description: {
|
|
1989
|
+
readonly $ref: "#/$defs/IdeaDescription";
|
|
1990
|
+
};
|
|
1991
|
+
readonly format: {
|
|
1992
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
1993
|
+
};
|
|
1994
|
+
readonly topic: {
|
|
1995
|
+
readonly $ref: "#/$defs/Topic";
|
|
1996
|
+
};
|
|
1997
|
+
readonly proposer: {
|
|
1998
|
+
readonly $ref: "#/$defs/Author";
|
|
1999
|
+
};
|
|
2000
|
+
readonly proposedAt: {
|
|
2001
|
+
readonly type: "string";
|
|
2002
|
+
readonly format: "date-time";
|
|
2003
|
+
};
|
|
2004
|
+
readonly noteCount: {
|
|
2005
|
+
readonly type: "integer";
|
|
2006
|
+
readonly minimum: 0;
|
|
2007
|
+
readonly description: "Notes on the idea the caller may read.";
|
|
2008
|
+
};
|
|
2009
|
+
readonly election: {
|
|
2010
|
+
readonly $ref: "#/$defs/IdeaElection";
|
|
2011
|
+
readonly description: "Present once an election was opened for the idea.";
|
|
2012
|
+
};
|
|
2013
|
+
readonly opening: {
|
|
2014
|
+
readonly $ref: "#/$defs/IdeaOpening";
|
|
2015
|
+
};
|
|
2016
|
+
readonly decision: {
|
|
2017
|
+
readonly $ref: "#/$defs/IdeaDecision";
|
|
2018
|
+
readonly description: "Present in `declined`, `merged`, `selected` and `notSelected`.";
|
|
2019
|
+
};
|
|
2020
|
+
};
|
|
2021
|
+
};
|
|
2022
|
+
readonly IdeaDecision: {
|
|
2023
|
+
readonly title: "IdeaDecision";
|
|
2024
|
+
readonly description: "A facilitator's decision on an idea: declining or merging it (VTI-BRD-013), or selecting it or not (VTI-BRD-040). The deciding facilitator is not named to the audience.";
|
|
2025
|
+
readonly type: "object";
|
|
2026
|
+
readonly additionalProperties: false;
|
|
2027
|
+
readonly required: readonly ["decidedAt"];
|
|
2028
|
+
readonly properties: {
|
|
2029
|
+
readonly decidedAt: {
|
|
2030
|
+
readonly type: "string";
|
|
2031
|
+
readonly format: "date-time";
|
|
2032
|
+
};
|
|
2033
|
+
readonly reason: {
|
|
2034
|
+
readonly $ref: "#/$defs/Reason";
|
|
2035
|
+
};
|
|
2036
|
+
readonly mergedInto: {
|
|
2037
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
2038
|
+
readonly description: "Present exactly when the idea is `merged`.";
|
|
2039
|
+
};
|
|
2040
|
+
readonly slotId: {
|
|
2041
|
+
readonly $ref: "#/$defs/Key";
|
|
2042
|
+
readonly description: "A `selected` idea's place in the board's timetable, where it has one.";
|
|
2043
|
+
};
|
|
2044
|
+
readonly departsFromRule: {
|
|
2045
|
+
readonly type: "boolean";
|
|
2046
|
+
readonly description: "`selected` or `notSelected` only: whether the facilitator said the decision departs from the board's `selectionRule` (VTI-BRD-041); `reason` then says why.";
|
|
2047
|
+
};
|
|
2048
|
+
readonly ownIdea: {
|
|
2049
|
+
readonly const: true;
|
|
2050
|
+
readonly description: "Present when a facilitator decided their own idea because no other facilitator existed (VTI-BRD-013).";
|
|
2051
|
+
};
|
|
2052
|
+
};
|
|
2053
|
+
};
|
|
2054
|
+
readonly IdeaId: {
|
|
2055
|
+
readonly title: "IdeaId";
|
|
2056
|
+
readonly description: "Opaque identifier of an idea: `ida_` followed by 16 to 64 base64url characters. Random and unique within the community.";
|
|
2057
|
+
readonly type: "string";
|
|
2058
|
+
readonly pattern: "^ida_[A-Za-z0-9_-]{16,64}$";
|
|
2059
|
+
};
|
|
2060
|
+
readonly Reason: {
|
|
2061
|
+
readonly title: "Reason";
|
|
2062
|
+
readonly type: "string";
|
|
2063
|
+
readonly minLength: 1;
|
|
2064
|
+
readonly maxLength: 500;
|
|
2065
|
+
readonly description: "A facilitator's stated reason, shown to the board's audience with the decision it explains. Plain text.";
|
|
2066
|
+
};
|
|
2067
|
+
readonly Key: {
|
|
2068
|
+
readonly title: "Key";
|
|
2069
|
+
readonly description: "A question or option key, unique within its manifest or question.";
|
|
2070
|
+
readonly type: "string";
|
|
2071
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,64}$";
|
|
2072
|
+
};
|
|
2073
|
+
readonly IdeaOpening: {
|
|
2074
|
+
readonly title: "IdeaOpening";
|
|
2075
|
+
readonly description: "Shown to facilitators only: an accepted idea whose election the ballot box has not yet registered, so the idea is still `proposed` (VTI-BRD-031). `refusal` is the ballot box's or community's refusal of the last attempt, after which the idea is no longer being opened.";
|
|
2076
|
+
readonly type: "object";
|
|
2077
|
+
readonly additionalProperties: false;
|
|
2078
|
+
readonly required: readonly ["electionId", "startedAt"];
|
|
2079
|
+
readonly properties: {
|
|
2080
|
+
readonly electionId: {
|
|
2081
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
2082
|
+
};
|
|
2083
|
+
readonly startedAt: {
|
|
2084
|
+
readonly type: "string";
|
|
2085
|
+
readonly format: "date-time";
|
|
2086
|
+
readonly description: "When the facilitator accepted the idea.";
|
|
2087
|
+
};
|
|
2088
|
+
readonly refusal: {
|
|
2089
|
+
readonly type: "object";
|
|
2090
|
+
readonly additionalProperties: false;
|
|
2091
|
+
readonly required: readonly ["code", "refusedAt"];
|
|
2092
|
+
readonly properties: {
|
|
2093
|
+
readonly code: {
|
|
2094
|
+
readonly type: "string";
|
|
2095
|
+
readonly minLength: 1;
|
|
2096
|
+
readonly maxLength: 200;
|
|
2097
|
+
};
|
|
2098
|
+
readonly refusedAt: {
|
|
2099
|
+
readonly type: "string";
|
|
2100
|
+
readonly format: "date-time";
|
|
2101
|
+
};
|
|
2102
|
+
};
|
|
2103
|
+
};
|
|
2104
|
+
};
|
|
2105
|
+
};
|
|
2106
|
+
readonly ElectionId: {
|
|
2107
|
+
readonly title: "ElectionId";
|
|
2108
|
+
readonly 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.";
|
|
2109
|
+
readonly type: "string";
|
|
2110
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,128}$";
|
|
2111
|
+
};
|
|
2112
|
+
readonly IdeaElection: {
|
|
2113
|
+
readonly title: "IdeaElection";
|
|
2114
|
+
readonly description: "An idea's election as a board shows it (VTI-BRD-033): never who took a ticket or cast a ballot.";
|
|
2115
|
+
readonly type: "object";
|
|
2116
|
+
readonly additionalProperties: false;
|
|
2117
|
+
readonly required: readonly ["electionId", "state"];
|
|
2118
|
+
readonly properties: {
|
|
2119
|
+
readonly electionId: {
|
|
2120
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
2121
|
+
};
|
|
2122
|
+
readonly state: {
|
|
2123
|
+
readonly $ref: "#/$defs/ElectionState";
|
|
2124
|
+
};
|
|
2125
|
+
readonly ballotsOnBoard: {
|
|
2126
|
+
readonly type: "integer";
|
|
2127
|
+
readonly minimum: 0;
|
|
2128
|
+
readonly description: "The ballot box's latest board head's ballot count, where its board is public (VTI-VOT-052); absent otherwise. Counts ballots, not voters, where a later ballot replaces an earlier one.";
|
|
2129
|
+
};
|
|
2130
|
+
readonly boardHeadIssuedAt: {
|
|
2131
|
+
readonly type: "string";
|
|
2132
|
+
readonly format: "date-time";
|
|
2133
|
+
readonly description: "When the head `ballotsOnBoard` was read from was issued.";
|
|
2134
|
+
};
|
|
2135
|
+
readonly result: {
|
|
2136
|
+
readonly $ref: "#/$defs/ElectionResult";
|
|
2137
|
+
readonly description: "Present once the election is tallied.";
|
|
2138
|
+
};
|
|
2139
|
+
readonly certified: {
|
|
2140
|
+
readonly type: "boolean";
|
|
2141
|
+
readonly description: "Present with `result`: whether the community certified it (VTI-VOT-071).";
|
|
2142
|
+
};
|
|
2143
|
+
};
|
|
2144
|
+
};
|
|
2145
|
+
readonly ElectionResult: {
|
|
2146
|
+
readonly title: "ElectionResult";
|
|
2147
|
+
readonly description: "An election's result, computable by anyone who can read its board from the board and the registration alone (VTI-VOT-070).";
|
|
2148
|
+
readonly type: "object";
|
|
2149
|
+
readonly additionalProperties: false;
|
|
2150
|
+
readonly required: readonly ["electionId", "manifestDigest", "ballotsCounted", "questions", "head"];
|
|
2151
|
+
readonly properties: {
|
|
2152
|
+
readonly electionId: {
|
|
2153
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
2154
|
+
};
|
|
2155
|
+
readonly manifestDigest: {
|
|
2156
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
2157
|
+
};
|
|
2158
|
+
readonly ballotsCounted: {
|
|
2159
|
+
readonly type: "integer";
|
|
2160
|
+
readonly minimum: 0;
|
|
2161
|
+
};
|
|
2162
|
+
readonly questions: {
|
|
2163
|
+
readonly type: "array";
|
|
2164
|
+
readonly items: {
|
|
2165
|
+
readonly $ref: "#/$defs/QuestionResult";
|
|
2166
|
+
};
|
|
2167
|
+
};
|
|
2168
|
+
readonly head: {
|
|
2169
|
+
readonly $ref: "#/$defs/BoardHead";
|
|
2170
|
+
readonly description: "The head of the board as it stood at close: the result counts exactly its entries.";
|
|
2171
|
+
};
|
|
2172
|
+
};
|
|
2173
|
+
};
|
|
2174
|
+
readonly BoardHead: {
|
|
2175
|
+
readonly title: "BoardHead";
|
|
2176
|
+
readonly description: "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.";
|
|
2177
|
+
readonly type: "object";
|
|
2178
|
+
readonly additionalProperties: false;
|
|
2179
|
+
readonly required: readonly ["electionId", "treeSize", "rootHash", "issuedAt"];
|
|
2180
|
+
readonly properties: {
|
|
2181
|
+
readonly electionId: {
|
|
2182
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
2183
|
+
};
|
|
2184
|
+
readonly treeSize: {
|
|
2185
|
+
readonly type: "integer";
|
|
2186
|
+
readonly minimum: 0;
|
|
2187
|
+
};
|
|
2188
|
+
readonly rootHash: {
|
|
2189
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
2190
|
+
readonly description: "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash.";
|
|
2191
|
+
};
|
|
2192
|
+
readonly issuedAt: {
|
|
2193
|
+
readonly type: "string";
|
|
2194
|
+
readonly format: "date-time";
|
|
2195
|
+
};
|
|
2196
|
+
};
|
|
2197
|
+
};
|
|
2198
|
+
readonly DigestMultibase: {
|
|
2199
|
+
readonly title: "DigestMultibase";
|
|
2200
|
+
readonly description: "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.";
|
|
2201
|
+
readonly type: "string";
|
|
2202
|
+
readonly minLength: 16;
|
|
2203
|
+
readonly pattern: "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$";
|
|
2204
|
+
readonly examples: readonly ["zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"];
|
|
2205
|
+
};
|
|
2206
|
+
readonly QuestionResult: {
|
|
2207
|
+
readonly title: "QuestionResult";
|
|
2208
|
+
readonly description: "One question's totals. `choice`: selections per option. `ranking`: per option, how many ballots placed it at each position (index 0 = first). `score`: per option, the sum and the number of ballots that scored it. `text`: the answers, in board order, withheld (`withheld: true`) below the manifest's `textReleaseThreshold`. `abstained` counts ballots that left the question unanswered.";
|
|
2209
|
+
readonly type: "object";
|
|
2210
|
+
readonly additionalProperties: false;
|
|
2211
|
+
readonly required: readonly ["question", "abstained"];
|
|
2212
|
+
readonly properties: {
|
|
2213
|
+
readonly question: {
|
|
2214
|
+
readonly $ref: "#/$defs/Key";
|
|
2215
|
+
};
|
|
2216
|
+
readonly abstained: {
|
|
2217
|
+
readonly type: "integer";
|
|
2218
|
+
readonly minimum: 0;
|
|
2219
|
+
};
|
|
2220
|
+
readonly choice: {
|
|
2221
|
+
readonly type: "object";
|
|
2222
|
+
readonly propertyNames: {
|
|
2223
|
+
readonly $ref: "#/$defs/Key";
|
|
2224
|
+
};
|
|
2225
|
+
readonly additionalProperties: {
|
|
2226
|
+
readonly type: "integer";
|
|
2227
|
+
readonly minimum: 0;
|
|
2228
|
+
};
|
|
2229
|
+
};
|
|
2230
|
+
readonly ranking: {
|
|
2231
|
+
readonly type: "object";
|
|
2232
|
+
readonly propertyNames: {
|
|
2233
|
+
readonly $ref: "#/$defs/Key";
|
|
2234
|
+
};
|
|
2235
|
+
readonly additionalProperties: {
|
|
2236
|
+
readonly type: "array";
|
|
2237
|
+
readonly items: {
|
|
2238
|
+
readonly type: "integer";
|
|
2239
|
+
readonly minimum: 0;
|
|
2240
|
+
};
|
|
2241
|
+
};
|
|
2242
|
+
};
|
|
2243
|
+
readonly score: {
|
|
2244
|
+
readonly type: "object";
|
|
2245
|
+
readonly propertyNames: {
|
|
2246
|
+
readonly $ref: "#/$defs/Key";
|
|
2247
|
+
};
|
|
2248
|
+
readonly additionalProperties: {
|
|
2249
|
+
readonly type: "object";
|
|
2250
|
+
readonly additionalProperties: false;
|
|
2251
|
+
readonly required: readonly ["sum", "count"];
|
|
2252
|
+
readonly properties: {
|
|
2253
|
+
readonly sum: {
|
|
2254
|
+
readonly type: "integer";
|
|
2255
|
+
};
|
|
2256
|
+
readonly count: {
|
|
2257
|
+
readonly type: "integer";
|
|
2258
|
+
readonly minimum: 0;
|
|
2259
|
+
};
|
|
2260
|
+
};
|
|
2261
|
+
};
|
|
2262
|
+
};
|
|
2263
|
+
readonly text: {
|
|
2264
|
+
readonly type: "array";
|
|
2265
|
+
readonly items: {
|
|
2266
|
+
readonly type: "string";
|
|
2267
|
+
readonly maxLength: 4096;
|
|
2268
|
+
};
|
|
2269
|
+
};
|
|
2270
|
+
readonly withheld: {
|
|
2271
|
+
readonly type: "boolean";
|
|
2272
|
+
};
|
|
2273
|
+
};
|
|
2274
|
+
};
|
|
2275
|
+
readonly ElectionState: {
|
|
2276
|
+
readonly title: "ElectionState";
|
|
2277
|
+
readonly type: "string";
|
|
2278
|
+
readonly enum: readonly ["registered", "registration", "voting", "closed", "tallied", "cancelled"];
|
|
2279
|
+
};
|
|
2280
|
+
readonly Author: {
|
|
2281
|
+
readonly title: "Author";
|
|
2282
|
+
readonly description: "Who proposed an idea or wrote a note, as the board's audience sees them. `entryId` is their directory entry, which survives a rotation of their DID; `name` is their directory display name as this caller may see it, absent where the directory withholds it. A departed member is shown as `formerMember: true` with neither (VTI-BRD-060).";
|
|
2283
|
+
readonly type: "object";
|
|
2284
|
+
readonly additionalProperties: false;
|
|
2285
|
+
readonly properties: {
|
|
2286
|
+
readonly entryId: {
|
|
2287
|
+
readonly $ref: "#/$defs/EntryId";
|
|
2288
|
+
};
|
|
2289
|
+
readonly name: {
|
|
2290
|
+
readonly type: "string";
|
|
2291
|
+
readonly minLength: 1;
|
|
2292
|
+
readonly maxLength: 200;
|
|
2293
|
+
};
|
|
2294
|
+
readonly formerMember: {
|
|
2295
|
+
readonly const: true;
|
|
2296
|
+
};
|
|
2297
|
+
readonly you: {
|
|
2298
|
+
readonly const: true;
|
|
2299
|
+
readonly description: "Present when the caller is the author.";
|
|
2300
|
+
};
|
|
2301
|
+
};
|
|
2302
|
+
};
|
|
2303
|
+
readonly EntryId: {
|
|
2304
|
+
readonly title: "EntryId";
|
|
2305
|
+
readonly description: "Opaque identifier of one directory entry: `dir_` followed by 16 to 64 base64url characters. Random, scoped to one community, and stable for the life of the membership — it survives a rotation of the member's DID, which is why groups, notes and cards are keyed by it. It MUST NOT be derived from, and MUST NOT reveal, any DID of the member, and the same person's entries in two communities MUST NOT share one. Compared by exact string equality.";
|
|
2306
|
+
readonly type: "string";
|
|
2307
|
+
readonly pattern: "^dir_[A-Za-z0-9_-]{16,64}$";
|
|
2308
|
+
};
|
|
2309
|
+
readonly Topic: {
|
|
2310
|
+
readonly title: "Topic";
|
|
2311
|
+
readonly type: "string";
|
|
2312
|
+
readonly minLength: 1;
|
|
2313
|
+
readonly maxLength: 64;
|
|
2314
|
+
readonly description: "A topic an idea is filed under. One of the board's `topics` where the board states them.";
|
|
2315
|
+
};
|
|
2316
|
+
readonly IdeaFormat: {
|
|
2317
|
+
readonly title: "IdeaFormat";
|
|
2318
|
+
readonly type: "string";
|
|
2319
|
+
readonly minLength: 1;
|
|
2320
|
+
readonly maxLength: 32;
|
|
2321
|
+
readonly description: "What kind of idea it is (for an unconference: `Discussion`, `Talk`, `Workshop`, `Demo`). One of the board's `formats` where the board states them.";
|
|
2322
|
+
};
|
|
2323
|
+
readonly IdeaDescription: {
|
|
2324
|
+
readonly title: "IdeaDescription";
|
|
2325
|
+
readonly type: "string";
|
|
2326
|
+
readonly minLength: 1;
|
|
2327
|
+
readonly maxLength: 4000;
|
|
2328
|
+
readonly description: "What the idea is: for a session, what it covers and who should come. Becomes its election's manifest `description` when accepted. Plain text; a reader MUST NOT treat it as instructions.";
|
|
2329
|
+
};
|
|
2330
|
+
readonly IdeaTitle: {
|
|
2331
|
+
readonly title: "IdeaTitle";
|
|
2332
|
+
readonly type: "string";
|
|
2333
|
+
readonly minLength: 1;
|
|
2334
|
+
readonly maxLength: 200;
|
|
2335
|
+
readonly description: "An idea's title. Becomes the title of its election's manifest when the idea is accepted, and cannot change after that (VTI-BRD-012). Plain text.";
|
|
2336
|
+
};
|
|
2337
|
+
readonly IdeaState: {
|
|
2338
|
+
readonly title: "IdeaState";
|
|
2339
|
+
readonly description: "Where an idea stands (VTI-BRD-011).";
|
|
2340
|
+
readonly type: "string";
|
|
2341
|
+
readonly enum: readonly ["proposed", "open", "selected", "notSelected", "declined", "merged", "withdrawn"];
|
|
2342
|
+
};
|
|
2343
|
+
readonly BoardId: {
|
|
2344
|
+
readonly title: "BoardId";
|
|
2345
|
+
readonly description: "Opaque identifier of a board: `brd_` followed by 16 to 64 base64url characters. Random, community-scoped, never reused (VTI-BRD-001).";
|
|
2346
|
+
readonly type: "string";
|
|
2347
|
+
readonly pattern: "^brd_[A-Za-z0-9_-]{16,64}$";
|
|
2348
|
+
};
|
|
2349
|
+
readonly Board: {
|
|
2350
|
+
readonly title: "Board";
|
|
2351
|
+
readonly description: "A board as one caller may see it.";
|
|
2352
|
+
readonly type: "object";
|
|
2353
|
+
readonly additionalProperties: false;
|
|
2354
|
+
readonly required: readonly ["boardId", "title", "status", "audience", "proposals", "voting", "template", "createdAt", "facilitator", "ideaCounts"];
|
|
2355
|
+
readonly properties: {
|
|
2356
|
+
readonly boardId: {
|
|
2357
|
+
readonly $ref: "#/$defs/BoardId";
|
|
2358
|
+
};
|
|
2359
|
+
readonly title: {
|
|
2360
|
+
readonly $ref: "#/$defs/BoardTitle";
|
|
2361
|
+
};
|
|
2362
|
+
readonly description: {
|
|
2363
|
+
readonly $ref: "#/$defs/BoardDescription";
|
|
2364
|
+
};
|
|
2365
|
+
readonly status: {
|
|
2366
|
+
readonly $ref: "#/$defs/BoardStatus";
|
|
2367
|
+
};
|
|
2368
|
+
readonly audience: {
|
|
2369
|
+
readonly $ref: "#/$defs/BoardAudience";
|
|
2370
|
+
};
|
|
2371
|
+
readonly proposals: {
|
|
2372
|
+
readonly $ref: "#/$defs/Window";
|
|
2373
|
+
readonly description: "When ideas are taken (VTI-BRD-010).";
|
|
2374
|
+
};
|
|
2375
|
+
readonly voting: {
|
|
2376
|
+
readonly $ref: "#/$defs/Window";
|
|
2377
|
+
readonly description: "When every idea's election takes ballots. Opens after `proposals` opens and closes after it closes (VTI-BRD-001).";
|
|
2378
|
+
};
|
|
2379
|
+
readonly topics: {
|
|
2380
|
+
readonly type: "array";
|
|
2381
|
+
readonly maxItems: 32;
|
|
2382
|
+
readonly uniqueItems: true;
|
|
2383
|
+
readonly items: {
|
|
2384
|
+
readonly $ref: "#/$defs/Topic";
|
|
2385
|
+
};
|
|
2386
|
+
};
|
|
2387
|
+
readonly formats: {
|
|
2388
|
+
readonly type: "array";
|
|
2389
|
+
readonly maxItems: 16;
|
|
2390
|
+
readonly uniqueItems: true;
|
|
2391
|
+
readonly items: {
|
|
2392
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
2393
|
+
};
|
|
2394
|
+
};
|
|
2395
|
+
readonly maxIdeasPerMember: {
|
|
2396
|
+
readonly type: "integer";
|
|
2397
|
+
readonly minimum: 1;
|
|
2398
|
+
readonly maximum: 100;
|
|
2399
|
+
readonly description: "The most ideas one member may have on the board that are not `withdrawn` or `declined`. Absent: no limit beyond the community's own.";
|
|
2400
|
+
};
|
|
2401
|
+
readonly selectionRule: {
|
|
2402
|
+
readonly type: "string";
|
|
2403
|
+
readonly minLength: 1;
|
|
2404
|
+
readonly maxLength: 500;
|
|
2405
|
+
readonly description: "How facilitators intend to select, in plain words (VTI-BRD-041), e.g. \"The twelve ideas the most members would attend\".";
|
|
2406
|
+
};
|
|
2407
|
+
readonly timetable: {
|
|
2408
|
+
readonly type: "array";
|
|
2409
|
+
readonly maxItems: 256;
|
|
2410
|
+
readonly items: {
|
|
2411
|
+
readonly $ref: "#/$defs/Slot";
|
|
2412
|
+
};
|
|
2413
|
+
};
|
|
2414
|
+
readonly template: {
|
|
2415
|
+
readonly $ref: "#/$defs/ElectionTemplate";
|
|
2416
|
+
};
|
|
2417
|
+
readonly createdAt: {
|
|
2418
|
+
readonly type: "string";
|
|
2419
|
+
readonly format: "date-time";
|
|
2420
|
+
};
|
|
2421
|
+
readonly facilitator: {
|
|
2422
|
+
readonly type: "boolean";
|
|
2423
|
+
readonly description: "Whether the caller facilitates this board.";
|
|
2424
|
+
};
|
|
2425
|
+
readonly ideaCounts: {
|
|
2426
|
+
readonly type: "object";
|
|
2427
|
+
readonly additionalProperties: false;
|
|
2428
|
+
readonly description: "How many of the board's ideas are in each state the caller may see.";
|
|
2429
|
+
readonly properties: {
|
|
2430
|
+
readonly proposed: {
|
|
2431
|
+
readonly type: "integer";
|
|
2432
|
+
readonly minimum: 0;
|
|
2433
|
+
};
|
|
2434
|
+
readonly open: {
|
|
2435
|
+
readonly type: "integer";
|
|
2436
|
+
readonly minimum: 0;
|
|
2437
|
+
};
|
|
2438
|
+
readonly selected: {
|
|
2439
|
+
readonly type: "integer";
|
|
2440
|
+
readonly minimum: 0;
|
|
2441
|
+
};
|
|
2442
|
+
readonly notSelected: {
|
|
2443
|
+
readonly type: "integer";
|
|
2444
|
+
readonly minimum: 0;
|
|
2445
|
+
};
|
|
2446
|
+
readonly declined: {
|
|
2447
|
+
readonly type: "integer";
|
|
2448
|
+
readonly minimum: 0;
|
|
2449
|
+
};
|
|
2450
|
+
readonly merged: {
|
|
2451
|
+
readonly type: "integer";
|
|
2452
|
+
readonly minimum: 0;
|
|
2453
|
+
};
|
|
2454
|
+
readonly withdrawn: {
|
|
2455
|
+
readonly type: "integer";
|
|
2456
|
+
readonly minimum: 0;
|
|
2457
|
+
};
|
|
2458
|
+
};
|
|
2459
|
+
};
|
|
2460
|
+
};
|
|
2461
|
+
};
|
|
2462
|
+
readonly ElectionTemplate: {
|
|
2463
|
+
readonly title: "ElectionTemplate";
|
|
2464
|
+
readonly description: "Every member of an idea's election manifest that the board fixes (VTI-BRD-030). When a facilitator accepts an idea the community completes it: `electionId` (naming the board and the idea), `community`, `title` and `description` from the idea, `registrationOpensAt` and `votingOpensAt` from the board's voting window's `opensAt` or the acceptance, whichever is later, `votingClosesAt` from its `closesAt`, `roll` from the board's audience (rule `members`, or a credential roll naming the group), and `binding: false`. A board's template is never binding, and so has no `binding` member.";
|
|
2465
|
+
readonly type: "object";
|
|
2466
|
+
readonly additionalProperties: false;
|
|
2467
|
+
readonly required: readonly ["questions", "secrecy", "revote", "board", "ballotBox", "allowEarlyClose", "resultsBeforeClose", "textReleaseThreshold"];
|
|
2468
|
+
readonly properties: {
|
|
2469
|
+
readonly questions: {
|
|
2470
|
+
readonly type: "array";
|
|
2471
|
+
readonly minItems: 1;
|
|
2472
|
+
readonly maxItems: 16;
|
|
2473
|
+
readonly items: {
|
|
2474
|
+
readonly $ref: "#/$defs/Question";
|
|
2475
|
+
};
|
|
2476
|
+
};
|
|
2477
|
+
readonly secrecy: {
|
|
2478
|
+
readonly $ref: "#/$defs/SecrecyLevel";
|
|
2479
|
+
};
|
|
2480
|
+
readonly revote: {
|
|
2481
|
+
readonly $ref: "#/$defs/Revote";
|
|
2482
|
+
};
|
|
2483
|
+
readonly board: {
|
|
2484
|
+
readonly type: "object";
|
|
2485
|
+
readonly additionalProperties: false;
|
|
2486
|
+
readonly required: readonly ["visibility", "auditors"];
|
|
2487
|
+
readonly description: "The ballot box's board for each idea's election, as a manifest states it (VTI-VOT-052). `public` lets a board show each idea's ballot count while voting is open (VTI-BRD-033).";
|
|
2488
|
+
readonly properties: {
|
|
2489
|
+
readonly visibility: {
|
|
2490
|
+
readonly $ref: "#/$defs/BoardVisibility";
|
|
2491
|
+
};
|
|
2492
|
+
readonly auditors: {
|
|
2493
|
+
readonly type: "array";
|
|
2494
|
+
readonly uniqueItems: true;
|
|
2495
|
+
readonly items: {
|
|
2496
|
+
readonly type: "string";
|
|
2497
|
+
readonly minLength: 1;
|
|
2498
|
+
readonly maxLength: 2048;
|
|
2499
|
+
};
|
|
2500
|
+
};
|
|
2501
|
+
};
|
|
2502
|
+
};
|
|
2503
|
+
readonly ballotBox: {
|
|
2504
|
+
readonly type: "string";
|
|
2505
|
+
readonly minLength: 1;
|
|
2506
|
+
readonly maxLength: 2048;
|
|
2507
|
+
readonly description: "The DID of the voting service every idea's election is registered with; one on the community's list (VTI-VOT-082).";
|
|
2508
|
+
};
|
|
2509
|
+
readonly trustees: {
|
|
2510
|
+
readonly $ref: "#/$defs/Trustees";
|
|
2511
|
+
};
|
|
2512
|
+
readonly allowEarlyClose: {
|
|
2513
|
+
readonly type: "boolean";
|
|
2514
|
+
};
|
|
2515
|
+
readonly resultsBeforeClose: {
|
|
2516
|
+
readonly type: "boolean";
|
|
2517
|
+
readonly description: "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061). A board SHOULD set it false (VTI-BRD-033).";
|
|
2518
|
+
};
|
|
2519
|
+
readonly textReleaseThreshold: {
|
|
2520
|
+
readonly type: "integer";
|
|
2521
|
+
readonly minimum: 1;
|
|
2522
|
+
readonly description: "Counted ballots required before any text answer is disclosed (VTI-VOT-065); SHOULD be at least 10.";
|
|
2523
|
+
};
|
|
2524
|
+
};
|
|
2525
|
+
};
|
|
2526
|
+
readonly Trustees: {
|
|
2527
|
+
readonly title: "Trustees";
|
|
2528
|
+
readonly 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.";
|
|
2529
|
+
readonly type: "object";
|
|
2530
|
+
readonly additionalProperties: false;
|
|
2531
|
+
readonly required: readonly ["dids", "threshold"];
|
|
2532
|
+
readonly properties: {
|
|
2533
|
+
readonly dids: {
|
|
2534
|
+
readonly type: "array";
|
|
2535
|
+
readonly minItems: 2;
|
|
2536
|
+
readonly items: {
|
|
2537
|
+
readonly type: "string";
|
|
2538
|
+
readonly minLength: 1;
|
|
2539
|
+
readonly maxLength: 2048;
|
|
2540
|
+
};
|
|
2541
|
+
readonly uniqueItems: true;
|
|
2542
|
+
};
|
|
2543
|
+
readonly threshold: {
|
|
2544
|
+
readonly type: "integer";
|
|
2545
|
+
readonly minimum: 2;
|
|
2546
|
+
};
|
|
2547
|
+
};
|
|
2548
|
+
};
|
|
2549
|
+
readonly BoardVisibility: {
|
|
2550
|
+
readonly title: "BoardVisibility";
|
|
2551
|
+
readonly 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).";
|
|
2552
|
+
readonly type: "string";
|
|
2553
|
+
readonly enum: readonly ["public", "private"];
|
|
2554
|
+
};
|
|
2555
|
+
readonly Revote: {
|
|
2556
|
+
readonly title: "Revote";
|
|
2557
|
+
readonly description: "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).";
|
|
2558
|
+
readonly type: "string";
|
|
2559
|
+
readonly enum: readonly ["replace", "refuse"];
|
|
2560
|
+
};
|
|
2561
|
+
readonly SecrecyLevel: {
|
|
2562
|
+
readonly title: "SecrecyLevel";
|
|
2563
|
+
readonly 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).";
|
|
2564
|
+
readonly type: "string";
|
|
2565
|
+
readonly enum: readonly ["open", "sealed", "talliedEncrypted"];
|
|
2566
|
+
};
|
|
2567
|
+
readonly Question: {
|
|
2568
|
+
readonly title: "Question";
|
|
2569
|
+
readonly description: "One question. Tagged union over `type`.";
|
|
2570
|
+
readonly oneOf: readonly [{
|
|
2571
|
+
readonly title: "ChoiceQuestion";
|
|
2572
|
+
readonly description: "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.";
|
|
2573
|
+
readonly type: "object";
|
|
2574
|
+
readonly additionalProperties: false;
|
|
2575
|
+
readonly required: readonly ["key", "type", "options", "minSelections", "maxSelections", "optional"];
|
|
2576
|
+
readonly properties: {
|
|
2577
|
+
readonly key: {
|
|
2578
|
+
readonly $ref: "#/$defs/Key";
|
|
2579
|
+
};
|
|
2580
|
+
readonly type: {
|
|
2581
|
+
readonly const: "choice";
|
|
2582
|
+
};
|
|
2583
|
+
readonly text: {
|
|
2584
|
+
readonly type: "string";
|
|
2585
|
+
readonly maxLength: 2048;
|
|
2586
|
+
};
|
|
2587
|
+
readonly options: {
|
|
2588
|
+
readonly type: "array";
|
|
2589
|
+
readonly minItems: 2;
|
|
2590
|
+
readonly maxItems: 256;
|
|
2591
|
+
readonly items: {
|
|
2592
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
2593
|
+
};
|
|
2594
|
+
};
|
|
2595
|
+
readonly minSelections: {
|
|
2596
|
+
readonly type: "integer";
|
|
2597
|
+
readonly minimum: 0;
|
|
2598
|
+
};
|
|
2599
|
+
readonly maxSelections: {
|
|
2600
|
+
readonly type: "integer";
|
|
2601
|
+
readonly minimum: 1;
|
|
2602
|
+
};
|
|
2603
|
+
readonly optional: {
|
|
2604
|
+
readonly type: "boolean";
|
|
2605
|
+
};
|
|
2606
|
+
};
|
|
2607
|
+
}, {
|
|
2608
|
+
readonly title: "RankingQuestion";
|
|
2609
|
+
readonly description: "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.";
|
|
2610
|
+
readonly type: "object";
|
|
2611
|
+
readonly additionalProperties: false;
|
|
2612
|
+
readonly required: readonly ["key", "type", "options", "partial", "optional"];
|
|
2613
|
+
readonly properties: {
|
|
2614
|
+
readonly key: {
|
|
2615
|
+
readonly $ref: "#/$defs/Key";
|
|
2616
|
+
};
|
|
2617
|
+
readonly type: {
|
|
2618
|
+
readonly const: "ranking";
|
|
2619
|
+
};
|
|
2620
|
+
readonly text: {
|
|
2621
|
+
readonly type: "string";
|
|
2622
|
+
readonly maxLength: 2048;
|
|
2623
|
+
};
|
|
2624
|
+
readonly options: {
|
|
2625
|
+
readonly type: "array";
|
|
2626
|
+
readonly minItems: 2;
|
|
2627
|
+
readonly maxItems: 64;
|
|
2628
|
+
readonly items: {
|
|
2629
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
2630
|
+
};
|
|
2631
|
+
};
|
|
2632
|
+
readonly partial: {
|
|
2633
|
+
readonly type: "boolean";
|
|
2634
|
+
};
|
|
2635
|
+
readonly optional: {
|
|
2636
|
+
readonly type: "boolean";
|
|
2637
|
+
};
|
|
2638
|
+
};
|
|
2639
|
+
}, {
|
|
2640
|
+
readonly title: "ScoreQuestion";
|
|
2641
|
+
readonly description: "Give each option an integer score within [min, max].";
|
|
2642
|
+
readonly type: "object";
|
|
2643
|
+
readonly additionalProperties: false;
|
|
2644
|
+
readonly required: readonly ["key", "type", "options", "min", "max", "optional"];
|
|
2645
|
+
readonly properties: {
|
|
2646
|
+
readonly key: {
|
|
2647
|
+
readonly $ref: "#/$defs/Key";
|
|
2648
|
+
};
|
|
2649
|
+
readonly type: {
|
|
2650
|
+
readonly const: "score";
|
|
2651
|
+
};
|
|
2652
|
+
readonly text: {
|
|
2653
|
+
readonly type: "string";
|
|
2654
|
+
readonly maxLength: 2048;
|
|
2655
|
+
};
|
|
2656
|
+
readonly options: {
|
|
2657
|
+
readonly type: "array";
|
|
2658
|
+
readonly minItems: 1;
|
|
2659
|
+
readonly maxItems: 256;
|
|
2660
|
+
readonly items: {
|
|
2661
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
2662
|
+
};
|
|
2663
|
+
};
|
|
2664
|
+
readonly min: {
|
|
2665
|
+
readonly type: "integer";
|
|
2666
|
+
};
|
|
2667
|
+
readonly max: {
|
|
2668
|
+
readonly type: "integer";
|
|
2669
|
+
};
|
|
2670
|
+
readonly optional: {
|
|
2671
|
+
readonly type: "boolean";
|
|
2672
|
+
};
|
|
2673
|
+
};
|
|
2674
|
+
}, {
|
|
2675
|
+
readonly title: "TextQuestion";
|
|
2676
|
+
readonly description: "Free text of at most `maxLength` characters.";
|
|
2677
|
+
readonly type: "object";
|
|
2678
|
+
readonly additionalProperties: false;
|
|
2679
|
+
readonly required: readonly ["key", "type", "maxLength", "optional"];
|
|
2680
|
+
readonly properties: {
|
|
2681
|
+
readonly key: {
|
|
2682
|
+
readonly $ref: "#/$defs/Key";
|
|
2683
|
+
};
|
|
2684
|
+
readonly type: {
|
|
2685
|
+
readonly const: "text";
|
|
2686
|
+
};
|
|
2687
|
+
readonly text: {
|
|
2688
|
+
readonly type: "string";
|
|
2689
|
+
readonly maxLength: 2048;
|
|
2690
|
+
};
|
|
2691
|
+
readonly maxLength: {
|
|
2692
|
+
readonly type: "integer";
|
|
2693
|
+
readonly minimum: 1;
|
|
2694
|
+
readonly maximum: 4096;
|
|
2695
|
+
};
|
|
2696
|
+
readonly optional: {
|
|
2697
|
+
readonly type: "boolean";
|
|
2698
|
+
};
|
|
2699
|
+
};
|
|
2700
|
+
}];
|
|
2701
|
+
};
|
|
2702
|
+
readonly QuestionOption: {
|
|
2703
|
+
readonly title: "QuestionOption";
|
|
2704
|
+
readonly type: "object";
|
|
2705
|
+
readonly additionalProperties: false;
|
|
2706
|
+
readonly required: readonly ["key"];
|
|
2707
|
+
readonly properties: {
|
|
2708
|
+
readonly key: {
|
|
2709
|
+
readonly $ref: "#/$defs/Key";
|
|
2710
|
+
};
|
|
2711
|
+
readonly label: {
|
|
2712
|
+
readonly type: "string";
|
|
2713
|
+
readonly maxLength: 512;
|
|
2714
|
+
readonly description: "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014).";
|
|
2715
|
+
};
|
|
2716
|
+
};
|
|
2717
|
+
};
|
|
2718
|
+
readonly Slot: {
|
|
2719
|
+
readonly title: "Slot";
|
|
2720
|
+
readonly description: "One place in a board's timetable that a selected idea can be put in (VTI-BRD-040): a place (`label`, e.g. a room) and a time.";
|
|
2721
|
+
readonly type: "object";
|
|
2722
|
+
readonly additionalProperties: false;
|
|
2723
|
+
readonly required: readonly ["slotId", "label", "startsAt", "endsAt"];
|
|
2724
|
+
readonly properties: {
|
|
2725
|
+
readonly slotId: {
|
|
2726
|
+
readonly $ref: "#/$defs/Key";
|
|
2727
|
+
};
|
|
2728
|
+
readonly label: {
|
|
2729
|
+
readonly type: "string";
|
|
2730
|
+
readonly minLength: 1;
|
|
2731
|
+
readonly maxLength: 100;
|
|
2732
|
+
};
|
|
2733
|
+
readonly startsAt: {
|
|
2734
|
+
readonly type: "string";
|
|
2735
|
+
readonly format: "date-time";
|
|
2736
|
+
};
|
|
2737
|
+
readonly endsAt: {
|
|
2738
|
+
readonly type: "string";
|
|
2739
|
+
readonly format: "date-time";
|
|
2740
|
+
};
|
|
2741
|
+
};
|
|
2742
|
+
};
|
|
2743
|
+
readonly Window: {
|
|
2744
|
+
readonly title: "Window";
|
|
2745
|
+
readonly description: "A period, open from `opensAt` until `closesAt`. `closesAt` is after `opensAt` (a consumer check; JSON Schema cannot compare them).";
|
|
2746
|
+
readonly type: "object";
|
|
2747
|
+
readonly additionalProperties: false;
|
|
2748
|
+
readonly required: readonly ["opensAt", "closesAt"];
|
|
2749
|
+
readonly properties: {
|
|
2750
|
+
readonly opensAt: {
|
|
2751
|
+
readonly type: "string";
|
|
2752
|
+
readonly format: "date-time";
|
|
2753
|
+
};
|
|
2754
|
+
readonly closesAt: {
|
|
2755
|
+
readonly type: "string";
|
|
2756
|
+
readonly format: "date-time";
|
|
2757
|
+
};
|
|
2758
|
+
};
|
|
2759
|
+
};
|
|
2760
|
+
readonly BoardAudience: {
|
|
2761
|
+
readonly title: "BoardAudience";
|
|
2762
|
+
readonly description: "Who may see and use a board (VTI-BRD-003): every active member of the community (`members`), or the members of one community group (`group`, with `groupId`). Facilitators always see the board.";
|
|
2763
|
+
readonly oneOf: readonly [{
|
|
2764
|
+
readonly type: "object";
|
|
2765
|
+
readonly additionalProperties: false;
|
|
2766
|
+
readonly required: readonly ["kind"];
|
|
2767
|
+
readonly properties: {
|
|
2768
|
+
readonly kind: {
|
|
2769
|
+
readonly const: "members";
|
|
2770
|
+
};
|
|
2771
|
+
};
|
|
2772
|
+
}, {
|
|
2773
|
+
readonly type: "object";
|
|
2774
|
+
readonly additionalProperties: false;
|
|
2775
|
+
readonly required: readonly ["kind", "groupId"];
|
|
2776
|
+
readonly properties: {
|
|
2777
|
+
readonly kind: {
|
|
2778
|
+
readonly const: "group";
|
|
2779
|
+
};
|
|
2780
|
+
readonly groupId: {
|
|
2781
|
+
readonly $ref: "#/$defs/GroupId";
|
|
2782
|
+
};
|
|
2783
|
+
};
|
|
2784
|
+
}];
|
|
2785
|
+
};
|
|
2786
|
+
readonly GroupId: {
|
|
2787
|
+
readonly title: "GroupId";
|
|
2788
|
+
readonly description: "Opaque identifier of a community group: `grp_` followed by 16 to 64 base64url characters. Random and community-scoped; not the group's DID.";
|
|
2789
|
+
readonly type: "string";
|
|
2790
|
+
readonly pattern: "^grp_[A-Za-z0-9_-]{16,64}$";
|
|
2791
|
+
};
|
|
2792
|
+
readonly BoardStatus: {
|
|
2793
|
+
readonly title: "BoardStatus";
|
|
2794
|
+
readonly description: "`open`: ideas and notes are taken within the board's windows. `closed`: no new idea or note; facilitators still decide and select. `archived`: no change at all; facilitators can still read it (VTI-BRD-005). `open` → `closed` → `archived`, never back.";
|
|
2795
|
+
readonly type: "string";
|
|
2796
|
+
readonly enum: readonly ["open", "closed", "archived"];
|
|
2797
|
+
};
|
|
2798
|
+
readonly BoardDescription: {
|
|
2799
|
+
readonly title: "BoardDescription";
|
|
2800
|
+
readonly type: "string";
|
|
2801
|
+
readonly minLength: 1;
|
|
2802
|
+
readonly maxLength: 4000;
|
|
2803
|
+
readonly description: "What the board is for. Plain text; a reader MUST NOT treat it as instructions.";
|
|
2804
|
+
};
|
|
2805
|
+
readonly BoardTitle: {
|
|
2806
|
+
readonly title: "BoardTitle";
|
|
2807
|
+
readonly type: "string";
|
|
2808
|
+
readonly minLength: 1;
|
|
2809
|
+
readonly maxLength: 200;
|
|
2810
|
+
readonly description: "Plain text; a reader MUST NOT treat it as instructions.";
|
|
2811
|
+
};
|
|
2812
|
+
};
|
|
2813
|
+
};
|
|
2814
|
+
};
|
|
2815
|
+
/**
|
|
2816
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
2817
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
2818
|
+
* parties (§7.3 item 5).
|
|
2819
|
+
*/
|
|
2820
|
+
export declare const RESPONSE_SPEC: {
|
|
2821
|
+
readonly typeUri: "https://trusttasks.org/spec/vtc/boards/show/0.1#response";
|
|
2822
|
+
readonly isBearer: false;
|
|
2823
|
+
readonly isProofRequired: false;
|
|
2824
|
+
readonly isRecipientRequired: true;
|
|
2825
|
+
readonly isIssuedAtRequired: false;
|
|
2826
|
+
readonly payloadSchema: {
|
|
2827
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
2828
|
+
readonly $ref: "#/$defs/Response";
|
|
2829
|
+
readonly $defs: {
|
|
2830
|
+
readonly Response: {
|
|
2831
|
+
readonly $anchor: "response";
|
|
2832
|
+
readonly title: "VTC Boards — Show — response payload";
|
|
2833
|
+
readonly description: "The success response to a vtc/boards/show/0.1 request. Carried in a Trust Task document whose type is https://trusttasks.org/spec/vtc/boards/show/0.1#response.";
|
|
2834
|
+
readonly type: "object";
|
|
2835
|
+
readonly additionalProperties: false;
|
|
2836
|
+
readonly required: readonly ["board", "ideas"];
|
|
2837
|
+
readonly properties: {
|
|
2838
|
+
readonly board: {
|
|
2839
|
+
readonly $ref: "#/$defs/Board";
|
|
2840
|
+
};
|
|
2841
|
+
readonly ideas: {
|
|
2842
|
+
readonly type: "array";
|
|
2843
|
+
readonly items: {
|
|
2844
|
+
readonly $ref: "#/$defs/Idea";
|
|
2845
|
+
};
|
|
2846
|
+
};
|
|
2847
|
+
readonly nextCursor: {
|
|
2848
|
+
readonly type: "string";
|
|
2849
|
+
readonly maxLength: 1024;
|
|
2850
|
+
readonly description: "Continuation token for the next page; pass it back as `cursor`. Absent on the last page — never `null`.";
|
|
2851
|
+
};
|
|
2852
|
+
readonly ext: {
|
|
2853
|
+
readonly $ref: "#/$defs/Ext";
|
|
2854
|
+
};
|
|
2855
|
+
};
|
|
2856
|
+
};
|
|
2857
|
+
readonly Ext: {
|
|
2858
|
+
readonly title: "Ext";
|
|
2859
|
+
readonly 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.";
|
|
2860
|
+
readonly type: "object";
|
|
2861
|
+
readonly minProperties: 1;
|
|
2862
|
+
readonly additionalProperties: true;
|
|
2863
|
+
readonly propertyNames: {
|
|
2864
|
+
readonly pattern: "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$";
|
|
2865
|
+
};
|
|
2866
|
+
};
|
|
2867
|
+
readonly Idea: {
|
|
2868
|
+
readonly title: "Idea";
|
|
2869
|
+
readonly description: "An idea as one caller may see it.";
|
|
2870
|
+
readonly type: "object";
|
|
2871
|
+
readonly additionalProperties: false;
|
|
2872
|
+
readonly required: readonly ["ideaId", "boardId", "state", "title", "description", "proposer", "proposedAt", "noteCount"];
|
|
2873
|
+
readonly properties: {
|
|
2874
|
+
readonly ideaId: {
|
|
2875
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
2876
|
+
};
|
|
2877
|
+
readonly boardId: {
|
|
2878
|
+
readonly $ref: "#/$defs/BoardId";
|
|
2879
|
+
};
|
|
2880
|
+
readonly state: {
|
|
2881
|
+
readonly $ref: "#/$defs/IdeaState";
|
|
2882
|
+
};
|
|
2883
|
+
readonly title: {
|
|
2884
|
+
readonly $ref: "#/$defs/IdeaTitle";
|
|
2885
|
+
};
|
|
2886
|
+
readonly description: {
|
|
2887
|
+
readonly $ref: "#/$defs/IdeaDescription";
|
|
2888
|
+
};
|
|
2889
|
+
readonly format: {
|
|
2890
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
2891
|
+
};
|
|
2892
|
+
readonly topic: {
|
|
2893
|
+
readonly $ref: "#/$defs/Topic";
|
|
2894
|
+
};
|
|
2895
|
+
readonly proposer: {
|
|
2896
|
+
readonly $ref: "#/$defs/Author";
|
|
2897
|
+
};
|
|
2898
|
+
readonly proposedAt: {
|
|
2899
|
+
readonly type: "string";
|
|
2900
|
+
readonly format: "date-time";
|
|
2901
|
+
};
|
|
2902
|
+
readonly noteCount: {
|
|
2903
|
+
readonly type: "integer";
|
|
2904
|
+
readonly minimum: 0;
|
|
2905
|
+
readonly description: "Notes on the idea the caller may read.";
|
|
2906
|
+
};
|
|
2907
|
+
readonly election: {
|
|
2908
|
+
readonly $ref: "#/$defs/IdeaElection";
|
|
2909
|
+
readonly description: "Present once an election was opened for the idea.";
|
|
2910
|
+
};
|
|
2911
|
+
readonly opening: {
|
|
2912
|
+
readonly $ref: "#/$defs/IdeaOpening";
|
|
2913
|
+
};
|
|
2914
|
+
readonly decision: {
|
|
2915
|
+
readonly $ref: "#/$defs/IdeaDecision";
|
|
2916
|
+
readonly description: "Present in `declined`, `merged`, `selected` and `notSelected`.";
|
|
2917
|
+
};
|
|
2918
|
+
};
|
|
2919
|
+
};
|
|
2920
|
+
readonly IdeaDecision: {
|
|
2921
|
+
readonly title: "IdeaDecision";
|
|
2922
|
+
readonly description: "A facilitator's decision on an idea: declining or merging it (VTI-BRD-013), or selecting it or not (VTI-BRD-040). The deciding facilitator is not named to the audience.";
|
|
2923
|
+
readonly type: "object";
|
|
2924
|
+
readonly additionalProperties: false;
|
|
2925
|
+
readonly required: readonly ["decidedAt"];
|
|
2926
|
+
readonly properties: {
|
|
2927
|
+
readonly decidedAt: {
|
|
2928
|
+
readonly type: "string";
|
|
2929
|
+
readonly format: "date-time";
|
|
2930
|
+
};
|
|
2931
|
+
readonly reason: {
|
|
2932
|
+
readonly $ref: "#/$defs/Reason";
|
|
2933
|
+
};
|
|
2934
|
+
readonly mergedInto: {
|
|
2935
|
+
readonly $ref: "#/$defs/IdeaId";
|
|
2936
|
+
readonly description: "Present exactly when the idea is `merged`.";
|
|
2937
|
+
};
|
|
2938
|
+
readonly slotId: {
|
|
2939
|
+
readonly $ref: "#/$defs/Key";
|
|
2940
|
+
readonly description: "A `selected` idea's place in the board's timetable, where it has one.";
|
|
2941
|
+
};
|
|
2942
|
+
readonly departsFromRule: {
|
|
2943
|
+
readonly type: "boolean";
|
|
2944
|
+
readonly description: "`selected` or `notSelected` only: whether the facilitator said the decision departs from the board's `selectionRule` (VTI-BRD-041); `reason` then says why.";
|
|
2945
|
+
};
|
|
2946
|
+
readonly ownIdea: {
|
|
2947
|
+
readonly const: true;
|
|
2948
|
+
readonly description: "Present when a facilitator decided their own idea because no other facilitator existed (VTI-BRD-013).";
|
|
2949
|
+
};
|
|
2950
|
+
};
|
|
2951
|
+
};
|
|
2952
|
+
readonly IdeaId: {
|
|
2953
|
+
readonly title: "IdeaId";
|
|
2954
|
+
readonly description: "Opaque identifier of an idea: `ida_` followed by 16 to 64 base64url characters. Random and unique within the community.";
|
|
2955
|
+
readonly type: "string";
|
|
2956
|
+
readonly pattern: "^ida_[A-Za-z0-9_-]{16,64}$";
|
|
2957
|
+
};
|
|
2958
|
+
readonly Reason: {
|
|
2959
|
+
readonly title: "Reason";
|
|
2960
|
+
readonly type: "string";
|
|
2961
|
+
readonly minLength: 1;
|
|
2962
|
+
readonly maxLength: 500;
|
|
2963
|
+
readonly description: "A facilitator's stated reason, shown to the board's audience with the decision it explains. Plain text.";
|
|
2964
|
+
};
|
|
2965
|
+
readonly Key: {
|
|
2966
|
+
readonly title: "Key";
|
|
2967
|
+
readonly description: "A question or option key, unique within its manifest or question.";
|
|
2968
|
+
readonly type: "string";
|
|
2969
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,64}$";
|
|
2970
|
+
};
|
|
2971
|
+
readonly IdeaOpening: {
|
|
2972
|
+
readonly title: "IdeaOpening";
|
|
2973
|
+
readonly description: "Shown to facilitators only: an accepted idea whose election the ballot box has not yet registered, so the idea is still `proposed` (VTI-BRD-031). `refusal` is the ballot box's or community's refusal of the last attempt, after which the idea is no longer being opened.";
|
|
2974
|
+
readonly type: "object";
|
|
2975
|
+
readonly additionalProperties: false;
|
|
2976
|
+
readonly required: readonly ["electionId", "startedAt"];
|
|
2977
|
+
readonly properties: {
|
|
2978
|
+
readonly electionId: {
|
|
2979
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
2980
|
+
};
|
|
2981
|
+
readonly startedAt: {
|
|
2982
|
+
readonly type: "string";
|
|
2983
|
+
readonly format: "date-time";
|
|
2984
|
+
readonly description: "When the facilitator accepted the idea.";
|
|
2985
|
+
};
|
|
2986
|
+
readonly refusal: {
|
|
2987
|
+
readonly type: "object";
|
|
2988
|
+
readonly additionalProperties: false;
|
|
2989
|
+
readonly required: readonly ["code", "refusedAt"];
|
|
2990
|
+
readonly properties: {
|
|
2991
|
+
readonly code: {
|
|
2992
|
+
readonly type: "string";
|
|
2993
|
+
readonly minLength: 1;
|
|
2994
|
+
readonly maxLength: 200;
|
|
2995
|
+
};
|
|
2996
|
+
readonly refusedAt: {
|
|
2997
|
+
readonly type: "string";
|
|
2998
|
+
readonly format: "date-time";
|
|
2999
|
+
};
|
|
3000
|
+
};
|
|
3001
|
+
};
|
|
3002
|
+
};
|
|
3003
|
+
};
|
|
3004
|
+
readonly ElectionId: {
|
|
3005
|
+
readonly title: "ElectionId";
|
|
3006
|
+
readonly 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.";
|
|
3007
|
+
readonly type: "string";
|
|
3008
|
+
readonly pattern: "^[A-Za-z0-9._-]{1,128}$";
|
|
3009
|
+
};
|
|
3010
|
+
readonly IdeaElection: {
|
|
3011
|
+
readonly title: "IdeaElection";
|
|
3012
|
+
readonly description: "An idea's election as a board shows it (VTI-BRD-033): never who took a ticket or cast a ballot.";
|
|
3013
|
+
readonly type: "object";
|
|
3014
|
+
readonly additionalProperties: false;
|
|
3015
|
+
readonly required: readonly ["electionId", "state"];
|
|
3016
|
+
readonly properties: {
|
|
3017
|
+
readonly electionId: {
|
|
3018
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
3019
|
+
};
|
|
3020
|
+
readonly state: {
|
|
3021
|
+
readonly $ref: "#/$defs/ElectionState";
|
|
3022
|
+
};
|
|
3023
|
+
readonly ballotsOnBoard: {
|
|
3024
|
+
readonly type: "integer";
|
|
3025
|
+
readonly minimum: 0;
|
|
3026
|
+
readonly description: "The ballot box's latest board head's ballot count, where its board is public (VTI-VOT-052); absent otherwise. Counts ballots, not voters, where a later ballot replaces an earlier one.";
|
|
3027
|
+
};
|
|
3028
|
+
readonly boardHeadIssuedAt: {
|
|
3029
|
+
readonly type: "string";
|
|
3030
|
+
readonly format: "date-time";
|
|
3031
|
+
readonly description: "When the head `ballotsOnBoard` was read from was issued.";
|
|
3032
|
+
};
|
|
3033
|
+
readonly result: {
|
|
3034
|
+
readonly $ref: "#/$defs/ElectionResult";
|
|
3035
|
+
readonly description: "Present once the election is tallied.";
|
|
3036
|
+
};
|
|
3037
|
+
readonly certified: {
|
|
3038
|
+
readonly type: "boolean";
|
|
3039
|
+
readonly description: "Present with `result`: whether the community certified it (VTI-VOT-071).";
|
|
3040
|
+
};
|
|
3041
|
+
};
|
|
3042
|
+
};
|
|
3043
|
+
readonly ElectionResult: {
|
|
3044
|
+
readonly title: "ElectionResult";
|
|
3045
|
+
readonly description: "An election's result, computable by anyone who can read its board from the board and the registration alone (VTI-VOT-070).";
|
|
3046
|
+
readonly type: "object";
|
|
3047
|
+
readonly additionalProperties: false;
|
|
3048
|
+
readonly required: readonly ["electionId", "manifestDigest", "ballotsCounted", "questions", "head"];
|
|
3049
|
+
readonly properties: {
|
|
3050
|
+
readonly electionId: {
|
|
3051
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
3052
|
+
};
|
|
3053
|
+
readonly manifestDigest: {
|
|
3054
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
3055
|
+
};
|
|
3056
|
+
readonly ballotsCounted: {
|
|
3057
|
+
readonly type: "integer";
|
|
3058
|
+
readonly minimum: 0;
|
|
3059
|
+
};
|
|
3060
|
+
readonly questions: {
|
|
3061
|
+
readonly type: "array";
|
|
3062
|
+
readonly items: {
|
|
3063
|
+
readonly $ref: "#/$defs/QuestionResult";
|
|
3064
|
+
};
|
|
3065
|
+
};
|
|
3066
|
+
readonly head: {
|
|
3067
|
+
readonly $ref: "#/$defs/BoardHead";
|
|
3068
|
+
readonly description: "The head of the board as it stood at close: the result counts exactly its entries.";
|
|
3069
|
+
};
|
|
3070
|
+
};
|
|
3071
|
+
};
|
|
3072
|
+
readonly BoardHead: {
|
|
3073
|
+
readonly title: "BoardHead";
|
|
3074
|
+
readonly description: "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.";
|
|
3075
|
+
readonly type: "object";
|
|
3076
|
+
readonly additionalProperties: false;
|
|
3077
|
+
readonly required: readonly ["electionId", "treeSize", "rootHash", "issuedAt"];
|
|
3078
|
+
readonly properties: {
|
|
3079
|
+
readonly electionId: {
|
|
3080
|
+
readonly $ref: "#/$defs/ElectionId";
|
|
3081
|
+
};
|
|
3082
|
+
readonly treeSize: {
|
|
3083
|
+
readonly type: "integer";
|
|
3084
|
+
readonly minimum: 0;
|
|
3085
|
+
};
|
|
3086
|
+
readonly rootHash: {
|
|
3087
|
+
readonly $ref: "#/$defs/DigestMultibase";
|
|
3088
|
+
readonly description: "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash.";
|
|
3089
|
+
};
|
|
3090
|
+
readonly issuedAt: {
|
|
3091
|
+
readonly type: "string";
|
|
3092
|
+
readonly format: "date-time";
|
|
3093
|
+
};
|
|
3094
|
+
};
|
|
3095
|
+
};
|
|
3096
|
+
readonly DigestMultibase: {
|
|
3097
|
+
readonly title: "DigestMultibase";
|
|
3098
|
+
readonly description: "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.";
|
|
3099
|
+
readonly type: "string";
|
|
3100
|
+
readonly minLength: 16;
|
|
3101
|
+
readonly pattern: "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$";
|
|
3102
|
+
readonly examples: readonly ["zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"];
|
|
3103
|
+
};
|
|
3104
|
+
readonly QuestionResult: {
|
|
3105
|
+
readonly title: "QuestionResult";
|
|
3106
|
+
readonly description: "One question's totals. `choice`: selections per option. `ranking`: per option, how many ballots placed it at each position (index 0 = first). `score`: per option, the sum and the number of ballots that scored it. `text`: the answers, in board order, withheld (`withheld: true`) below the manifest's `textReleaseThreshold`. `abstained` counts ballots that left the question unanswered.";
|
|
3107
|
+
readonly type: "object";
|
|
3108
|
+
readonly additionalProperties: false;
|
|
3109
|
+
readonly required: readonly ["question", "abstained"];
|
|
3110
|
+
readonly properties: {
|
|
3111
|
+
readonly question: {
|
|
3112
|
+
readonly $ref: "#/$defs/Key";
|
|
3113
|
+
};
|
|
3114
|
+
readonly abstained: {
|
|
3115
|
+
readonly type: "integer";
|
|
3116
|
+
readonly minimum: 0;
|
|
3117
|
+
};
|
|
3118
|
+
readonly choice: {
|
|
3119
|
+
readonly type: "object";
|
|
3120
|
+
readonly propertyNames: {
|
|
3121
|
+
readonly $ref: "#/$defs/Key";
|
|
3122
|
+
};
|
|
3123
|
+
readonly additionalProperties: {
|
|
3124
|
+
readonly type: "integer";
|
|
3125
|
+
readonly minimum: 0;
|
|
3126
|
+
};
|
|
3127
|
+
};
|
|
3128
|
+
readonly ranking: {
|
|
3129
|
+
readonly type: "object";
|
|
3130
|
+
readonly propertyNames: {
|
|
3131
|
+
readonly $ref: "#/$defs/Key";
|
|
3132
|
+
};
|
|
3133
|
+
readonly additionalProperties: {
|
|
3134
|
+
readonly type: "array";
|
|
3135
|
+
readonly items: {
|
|
3136
|
+
readonly type: "integer";
|
|
3137
|
+
readonly minimum: 0;
|
|
3138
|
+
};
|
|
3139
|
+
};
|
|
3140
|
+
};
|
|
3141
|
+
readonly score: {
|
|
3142
|
+
readonly type: "object";
|
|
3143
|
+
readonly propertyNames: {
|
|
3144
|
+
readonly $ref: "#/$defs/Key";
|
|
3145
|
+
};
|
|
3146
|
+
readonly additionalProperties: {
|
|
3147
|
+
readonly type: "object";
|
|
3148
|
+
readonly additionalProperties: false;
|
|
3149
|
+
readonly required: readonly ["sum", "count"];
|
|
3150
|
+
readonly properties: {
|
|
3151
|
+
readonly sum: {
|
|
3152
|
+
readonly type: "integer";
|
|
3153
|
+
};
|
|
3154
|
+
readonly count: {
|
|
3155
|
+
readonly type: "integer";
|
|
3156
|
+
readonly minimum: 0;
|
|
3157
|
+
};
|
|
3158
|
+
};
|
|
3159
|
+
};
|
|
3160
|
+
};
|
|
3161
|
+
readonly text: {
|
|
3162
|
+
readonly type: "array";
|
|
3163
|
+
readonly items: {
|
|
3164
|
+
readonly type: "string";
|
|
3165
|
+
readonly maxLength: 4096;
|
|
3166
|
+
};
|
|
3167
|
+
};
|
|
3168
|
+
readonly withheld: {
|
|
3169
|
+
readonly type: "boolean";
|
|
3170
|
+
};
|
|
3171
|
+
};
|
|
3172
|
+
};
|
|
3173
|
+
readonly ElectionState: {
|
|
3174
|
+
readonly title: "ElectionState";
|
|
3175
|
+
readonly type: "string";
|
|
3176
|
+
readonly enum: readonly ["registered", "registration", "voting", "closed", "tallied", "cancelled"];
|
|
3177
|
+
};
|
|
3178
|
+
readonly Author: {
|
|
3179
|
+
readonly title: "Author";
|
|
3180
|
+
readonly description: "Who proposed an idea or wrote a note, as the board's audience sees them. `entryId` is their directory entry, which survives a rotation of their DID; `name` is their directory display name as this caller may see it, absent where the directory withholds it. A departed member is shown as `formerMember: true` with neither (VTI-BRD-060).";
|
|
3181
|
+
readonly type: "object";
|
|
3182
|
+
readonly additionalProperties: false;
|
|
3183
|
+
readonly properties: {
|
|
3184
|
+
readonly entryId: {
|
|
3185
|
+
readonly $ref: "#/$defs/EntryId";
|
|
3186
|
+
};
|
|
3187
|
+
readonly name: {
|
|
3188
|
+
readonly type: "string";
|
|
3189
|
+
readonly minLength: 1;
|
|
3190
|
+
readonly maxLength: 200;
|
|
3191
|
+
};
|
|
3192
|
+
readonly formerMember: {
|
|
3193
|
+
readonly const: true;
|
|
3194
|
+
};
|
|
3195
|
+
readonly you: {
|
|
3196
|
+
readonly const: true;
|
|
3197
|
+
readonly description: "Present when the caller is the author.";
|
|
3198
|
+
};
|
|
3199
|
+
};
|
|
3200
|
+
};
|
|
3201
|
+
readonly EntryId: {
|
|
3202
|
+
readonly title: "EntryId";
|
|
3203
|
+
readonly description: "Opaque identifier of one directory entry: `dir_` followed by 16 to 64 base64url characters. Random, scoped to one community, and stable for the life of the membership — it survives a rotation of the member's DID, which is why groups, notes and cards are keyed by it. It MUST NOT be derived from, and MUST NOT reveal, any DID of the member, and the same person's entries in two communities MUST NOT share one. Compared by exact string equality.";
|
|
3204
|
+
readonly type: "string";
|
|
3205
|
+
readonly pattern: "^dir_[A-Za-z0-9_-]{16,64}$";
|
|
3206
|
+
};
|
|
3207
|
+
readonly Topic: {
|
|
3208
|
+
readonly title: "Topic";
|
|
3209
|
+
readonly type: "string";
|
|
3210
|
+
readonly minLength: 1;
|
|
3211
|
+
readonly maxLength: 64;
|
|
3212
|
+
readonly description: "A topic an idea is filed under. One of the board's `topics` where the board states them.";
|
|
3213
|
+
};
|
|
3214
|
+
readonly IdeaFormat: {
|
|
3215
|
+
readonly title: "IdeaFormat";
|
|
3216
|
+
readonly type: "string";
|
|
3217
|
+
readonly minLength: 1;
|
|
3218
|
+
readonly maxLength: 32;
|
|
3219
|
+
readonly description: "What kind of idea it is (for an unconference: `Discussion`, `Talk`, `Workshop`, `Demo`). One of the board's `formats` where the board states them.";
|
|
3220
|
+
};
|
|
3221
|
+
readonly IdeaDescription: {
|
|
3222
|
+
readonly title: "IdeaDescription";
|
|
3223
|
+
readonly type: "string";
|
|
3224
|
+
readonly minLength: 1;
|
|
3225
|
+
readonly maxLength: 4000;
|
|
3226
|
+
readonly description: "What the idea is: for a session, what it covers and who should come. Becomes its election's manifest `description` when accepted. Plain text; a reader MUST NOT treat it as instructions.";
|
|
3227
|
+
};
|
|
3228
|
+
readonly IdeaTitle: {
|
|
3229
|
+
readonly title: "IdeaTitle";
|
|
3230
|
+
readonly type: "string";
|
|
3231
|
+
readonly minLength: 1;
|
|
3232
|
+
readonly maxLength: 200;
|
|
3233
|
+
readonly description: "An idea's title. Becomes the title of its election's manifest when the idea is accepted, and cannot change after that (VTI-BRD-012). Plain text.";
|
|
3234
|
+
};
|
|
3235
|
+
readonly IdeaState: {
|
|
3236
|
+
readonly title: "IdeaState";
|
|
3237
|
+
readonly description: "Where an idea stands (VTI-BRD-011).";
|
|
3238
|
+
readonly type: "string";
|
|
3239
|
+
readonly enum: readonly ["proposed", "open", "selected", "notSelected", "declined", "merged", "withdrawn"];
|
|
3240
|
+
};
|
|
3241
|
+
readonly BoardId: {
|
|
3242
|
+
readonly title: "BoardId";
|
|
3243
|
+
readonly description: "Opaque identifier of a board: `brd_` followed by 16 to 64 base64url characters. Random, community-scoped, never reused (VTI-BRD-001).";
|
|
3244
|
+
readonly type: "string";
|
|
3245
|
+
readonly pattern: "^brd_[A-Za-z0-9_-]{16,64}$";
|
|
3246
|
+
};
|
|
3247
|
+
readonly Board: {
|
|
3248
|
+
readonly title: "Board";
|
|
3249
|
+
readonly description: "A board as one caller may see it.";
|
|
3250
|
+
readonly type: "object";
|
|
3251
|
+
readonly additionalProperties: false;
|
|
3252
|
+
readonly required: readonly ["boardId", "title", "status", "audience", "proposals", "voting", "template", "createdAt", "facilitator", "ideaCounts"];
|
|
3253
|
+
readonly properties: {
|
|
3254
|
+
readonly boardId: {
|
|
3255
|
+
readonly $ref: "#/$defs/BoardId";
|
|
3256
|
+
};
|
|
3257
|
+
readonly title: {
|
|
3258
|
+
readonly $ref: "#/$defs/BoardTitle";
|
|
3259
|
+
};
|
|
3260
|
+
readonly description: {
|
|
3261
|
+
readonly $ref: "#/$defs/BoardDescription";
|
|
3262
|
+
};
|
|
3263
|
+
readonly status: {
|
|
3264
|
+
readonly $ref: "#/$defs/BoardStatus";
|
|
3265
|
+
};
|
|
3266
|
+
readonly audience: {
|
|
3267
|
+
readonly $ref: "#/$defs/BoardAudience";
|
|
3268
|
+
};
|
|
3269
|
+
readonly proposals: {
|
|
3270
|
+
readonly $ref: "#/$defs/Window";
|
|
3271
|
+
readonly description: "When ideas are taken (VTI-BRD-010).";
|
|
3272
|
+
};
|
|
3273
|
+
readonly voting: {
|
|
3274
|
+
readonly $ref: "#/$defs/Window";
|
|
3275
|
+
readonly description: "When every idea's election takes ballots. Opens after `proposals` opens and closes after it closes (VTI-BRD-001).";
|
|
3276
|
+
};
|
|
3277
|
+
readonly topics: {
|
|
3278
|
+
readonly type: "array";
|
|
3279
|
+
readonly maxItems: 32;
|
|
3280
|
+
readonly uniqueItems: true;
|
|
3281
|
+
readonly items: {
|
|
3282
|
+
readonly $ref: "#/$defs/Topic";
|
|
3283
|
+
};
|
|
3284
|
+
};
|
|
3285
|
+
readonly formats: {
|
|
3286
|
+
readonly type: "array";
|
|
3287
|
+
readonly maxItems: 16;
|
|
3288
|
+
readonly uniqueItems: true;
|
|
3289
|
+
readonly items: {
|
|
3290
|
+
readonly $ref: "#/$defs/IdeaFormat";
|
|
3291
|
+
};
|
|
3292
|
+
};
|
|
3293
|
+
readonly maxIdeasPerMember: {
|
|
3294
|
+
readonly type: "integer";
|
|
3295
|
+
readonly minimum: 1;
|
|
3296
|
+
readonly maximum: 100;
|
|
3297
|
+
readonly description: "The most ideas one member may have on the board that are not `withdrawn` or `declined`. Absent: no limit beyond the community's own.";
|
|
3298
|
+
};
|
|
3299
|
+
readonly selectionRule: {
|
|
3300
|
+
readonly type: "string";
|
|
3301
|
+
readonly minLength: 1;
|
|
3302
|
+
readonly maxLength: 500;
|
|
3303
|
+
readonly description: "How facilitators intend to select, in plain words (VTI-BRD-041), e.g. \"The twelve ideas the most members would attend\".";
|
|
3304
|
+
};
|
|
3305
|
+
readonly timetable: {
|
|
3306
|
+
readonly type: "array";
|
|
3307
|
+
readonly maxItems: 256;
|
|
3308
|
+
readonly items: {
|
|
3309
|
+
readonly $ref: "#/$defs/Slot";
|
|
3310
|
+
};
|
|
3311
|
+
};
|
|
3312
|
+
readonly template: {
|
|
3313
|
+
readonly $ref: "#/$defs/ElectionTemplate";
|
|
3314
|
+
};
|
|
3315
|
+
readonly createdAt: {
|
|
3316
|
+
readonly type: "string";
|
|
3317
|
+
readonly format: "date-time";
|
|
3318
|
+
};
|
|
3319
|
+
readonly facilitator: {
|
|
3320
|
+
readonly type: "boolean";
|
|
3321
|
+
readonly description: "Whether the caller facilitates this board.";
|
|
3322
|
+
};
|
|
3323
|
+
readonly ideaCounts: {
|
|
3324
|
+
readonly type: "object";
|
|
3325
|
+
readonly additionalProperties: false;
|
|
3326
|
+
readonly description: "How many of the board's ideas are in each state the caller may see.";
|
|
3327
|
+
readonly properties: {
|
|
3328
|
+
readonly proposed: {
|
|
3329
|
+
readonly type: "integer";
|
|
3330
|
+
readonly minimum: 0;
|
|
3331
|
+
};
|
|
3332
|
+
readonly open: {
|
|
3333
|
+
readonly type: "integer";
|
|
3334
|
+
readonly minimum: 0;
|
|
3335
|
+
};
|
|
3336
|
+
readonly selected: {
|
|
3337
|
+
readonly type: "integer";
|
|
3338
|
+
readonly minimum: 0;
|
|
3339
|
+
};
|
|
3340
|
+
readonly notSelected: {
|
|
3341
|
+
readonly type: "integer";
|
|
3342
|
+
readonly minimum: 0;
|
|
3343
|
+
};
|
|
3344
|
+
readonly declined: {
|
|
3345
|
+
readonly type: "integer";
|
|
3346
|
+
readonly minimum: 0;
|
|
3347
|
+
};
|
|
3348
|
+
readonly merged: {
|
|
3349
|
+
readonly type: "integer";
|
|
3350
|
+
readonly minimum: 0;
|
|
3351
|
+
};
|
|
3352
|
+
readonly withdrawn: {
|
|
3353
|
+
readonly type: "integer";
|
|
3354
|
+
readonly minimum: 0;
|
|
3355
|
+
};
|
|
3356
|
+
};
|
|
3357
|
+
};
|
|
3358
|
+
};
|
|
3359
|
+
};
|
|
3360
|
+
readonly ElectionTemplate: {
|
|
3361
|
+
readonly title: "ElectionTemplate";
|
|
3362
|
+
readonly description: "Every member of an idea's election manifest that the board fixes (VTI-BRD-030). When a facilitator accepts an idea the community completes it: `electionId` (naming the board and the idea), `community`, `title` and `description` from the idea, `registrationOpensAt` and `votingOpensAt` from the board's voting window's `opensAt` or the acceptance, whichever is later, `votingClosesAt` from its `closesAt`, `roll` from the board's audience (rule `members`, or a credential roll naming the group), and `binding: false`. A board's template is never binding, and so has no `binding` member.";
|
|
3363
|
+
readonly type: "object";
|
|
3364
|
+
readonly additionalProperties: false;
|
|
3365
|
+
readonly required: readonly ["questions", "secrecy", "revote", "board", "ballotBox", "allowEarlyClose", "resultsBeforeClose", "textReleaseThreshold"];
|
|
3366
|
+
readonly properties: {
|
|
3367
|
+
readonly questions: {
|
|
3368
|
+
readonly type: "array";
|
|
3369
|
+
readonly minItems: 1;
|
|
3370
|
+
readonly maxItems: 16;
|
|
3371
|
+
readonly items: {
|
|
3372
|
+
readonly $ref: "#/$defs/Question";
|
|
3373
|
+
};
|
|
3374
|
+
};
|
|
3375
|
+
readonly secrecy: {
|
|
3376
|
+
readonly $ref: "#/$defs/SecrecyLevel";
|
|
3377
|
+
};
|
|
3378
|
+
readonly revote: {
|
|
3379
|
+
readonly $ref: "#/$defs/Revote";
|
|
3380
|
+
};
|
|
3381
|
+
readonly board: {
|
|
3382
|
+
readonly type: "object";
|
|
3383
|
+
readonly additionalProperties: false;
|
|
3384
|
+
readonly required: readonly ["visibility", "auditors"];
|
|
3385
|
+
readonly description: "The ballot box's board for each idea's election, as a manifest states it (VTI-VOT-052). `public` lets a board show each idea's ballot count while voting is open (VTI-BRD-033).";
|
|
3386
|
+
readonly properties: {
|
|
3387
|
+
readonly visibility: {
|
|
3388
|
+
readonly $ref: "#/$defs/BoardVisibility";
|
|
3389
|
+
};
|
|
3390
|
+
readonly auditors: {
|
|
3391
|
+
readonly type: "array";
|
|
3392
|
+
readonly uniqueItems: true;
|
|
3393
|
+
readonly items: {
|
|
3394
|
+
readonly type: "string";
|
|
3395
|
+
readonly minLength: 1;
|
|
3396
|
+
readonly maxLength: 2048;
|
|
3397
|
+
};
|
|
3398
|
+
};
|
|
3399
|
+
};
|
|
3400
|
+
};
|
|
3401
|
+
readonly ballotBox: {
|
|
3402
|
+
readonly type: "string";
|
|
3403
|
+
readonly minLength: 1;
|
|
3404
|
+
readonly maxLength: 2048;
|
|
3405
|
+
readonly description: "The DID of the voting service every idea's election is registered with; one on the community's list (VTI-VOT-082).";
|
|
3406
|
+
};
|
|
3407
|
+
readonly trustees: {
|
|
3408
|
+
readonly $ref: "#/$defs/Trustees";
|
|
3409
|
+
};
|
|
3410
|
+
readonly allowEarlyClose: {
|
|
3411
|
+
readonly type: "boolean";
|
|
3412
|
+
};
|
|
3413
|
+
readonly resultsBeforeClose: {
|
|
3414
|
+
readonly type: "boolean";
|
|
3415
|
+
readonly description: "Open elections only: whether running totals may be read while voting is open (VTI-VOT-061). A board SHOULD set it false (VTI-BRD-033).";
|
|
3416
|
+
};
|
|
3417
|
+
readonly textReleaseThreshold: {
|
|
3418
|
+
readonly type: "integer";
|
|
3419
|
+
readonly minimum: 1;
|
|
3420
|
+
readonly description: "Counted ballots required before any text answer is disclosed (VTI-VOT-065); SHOULD be at least 10.";
|
|
3421
|
+
};
|
|
3422
|
+
};
|
|
3423
|
+
};
|
|
3424
|
+
readonly Trustees: {
|
|
3425
|
+
readonly title: "Trustees";
|
|
3426
|
+
readonly 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.";
|
|
3427
|
+
readonly type: "object";
|
|
3428
|
+
readonly additionalProperties: false;
|
|
3429
|
+
readonly required: readonly ["dids", "threshold"];
|
|
3430
|
+
readonly properties: {
|
|
3431
|
+
readonly dids: {
|
|
3432
|
+
readonly type: "array";
|
|
3433
|
+
readonly minItems: 2;
|
|
3434
|
+
readonly items: {
|
|
3435
|
+
readonly type: "string";
|
|
3436
|
+
readonly minLength: 1;
|
|
3437
|
+
readonly maxLength: 2048;
|
|
3438
|
+
};
|
|
3439
|
+
readonly uniqueItems: true;
|
|
3440
|
+
};
|
|
3441
|
+
readonly threshold: {
|
|
3442
|
+
readonly type: "integer";
|
|
3443
|
+
readonly minimum: 2;
|
|
3444
|
+
};
|
|
3445
|
+
};
|
|
3446
|
+
};
|
|
3447
|
+
readonly BoardVisibility: {
|
|
3448
|
+
readonly title: "BoardVisibility";
|
|
3449
|
+
readonly 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).";
|
|
3450
|
+
readonly type: "string";
|
|
3451
|
+
readonly enum: readonly ["public", "private"];
|
|
3452
|
+
};
|
|
3453
|
+
readonly Revote: {
|
|
3454
|
+
readonly title: "Revote";
|
|
3455
|
+
readonly description: "What a later, different ballot under one ticket does: `replace` the earlier one, or be refused (`refuse`) (VTI-VOT-041).";
|
|
3456
|
+
readonly type: "string";
|
|
3457
|
+
readonly enum: readonly ["replace", "refuse"];
|
|
3458
|
+
};
|
|
3459
|
+
readonly SecrecyLevel: {
|
|
3460
|
+
readonly title: "SecrecyLevel";
|
|
3461
|
+
readonly 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).";
|
|
3462
|
+
readonly type: "string";
|
|
3463
|
+
readonly enum: readonly ["open", "sealed", "talliedEncrypted"];
|
|
3464
|
+
};
|
|
3465
|
+
readonly Question: {
|
|
3466
|
+
readonly title: "Question";
|
|
3467
|
+
readonly description: "One question. Tagged union over `type`.";
|
|
3468
|
+
readonly oneOf: readonly [{
|
|
3469
|
+
readonly title: "ChoiceQuestion";
|
|
3470
|
+
readonly description: "Select between `minSelections` and `maxSelections` of `options`. A yes/no/abstain motion is a choice of exactly one of three.";
|
|
3471
|
+
readonly type: "object";
|
|
3472
|
+
readonly additionalProperties: false;
|
|
3473
|
+
readonly required: readonly ["key", "type", "options", "minSelections", "maxSelections", "optional"];
|
|
3474
|
+
readonly properties: {
|
|
3475
|
+
readonly key: {
|
|
3476
|
+
readonly $ref: "#/$defs/Key";
|
|
3477
|
+
};
|
|
3478
|
+
readonly type: {
|
|
3479
|
+
readonly const: "choice";
|
|
3480
|
+
};
|
|
3481
|
+
readonly text: {
|
|
3482
|
+
readonly type: "string";
|
|
3483
|
+
readonly maxLength: 2048;
|
|
3484
|
+
};
|
|
3485
|
+
readonly options: {
|
|
3486
|
+
readonly type: "array";
|
|
3487
|
+
readonly minItems: 2;
|
|
3488
|
+
readonly maxItems: 256;
|
|
3489
|
+
readonly items: {
|
|
3490
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
3491
|
+
};
|
|
3492
|
+
};
|
|
3493
|
+
readonly minSelections: {
|
|
3494
|
+
readonly type: "integer";
|
|
3495
|
+
readonly minimum: 0;
|
|
3496
|
+
};
|
|
3497
|
+
readonly maxSelections: {
|
|
3498
|
+
readonly type: "integer";
|
|
3499
|
+
readonly minimum: 1;
|
|
3500
|
+
};
|
|
3501
|
+
readonly optional: {
|
|
3502
|
+
readonly type: "boolean";
|
|
3503
|
+
};
|
|
3504
|
+
};
|
|
3505
|
+
}, {
|
|
3506
|
+
readonly title: "RankingQuestion";
|
|
3507
|
+
readonly description: "Order `options`; a ballot ranks every option or, when `partial` is true, a prefix of them.";
|
|
3508
|
+
readonly type: "object";
|
|
3509
|
+
readonly additionalProperties: false;
|
|
3510
|
+
readonly required: readonly ["key", "type", "options", "partial", "optional"];
|
|
3511
|
+
readonly properties: {
|
|
3512
|
+
readonly key: {
|
|
3513
|
+
readonly $ref: "#/$defs/Key";
|
|
3514
|
+
};
|
|
3515
|
+
readonly type: {
|
|
3516
|
+
readonly const: "ranking";
|
|
3517
|
+
};
|
|
3518
|
+
readonly text: {
|
|
3519
|
+
readonly type: "string";
|
|
3520
|
+
readonly maxLength: 2048;
|
|
3521
|
+
};
|
|
3522
|
+
readonly options: {
|
|
3523
|
+
readonly type: "array";
|
|
3524
|
+
readonly minItems: 2;
|
|
3525
|
+
readonly maxItems: 64;
|
|
3526
|
+
readonly items: {
|
|
3527
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
3528
|
+
};
|
|
3529
|
+
};
|
|
3530
|
+
readonly partial: {
|
|
3531
|
+
readonly type: "boolean";
|
|
3532
|
+
};
|
|
3533
|
+
readonly optional: {
|
|
3534
|
+
readonly type: "boolean";
|
|
3535
|
+
};
|
|
3536
|
+
};
|
|
3537
|
+
}, {
|
|
3538
|
+
readonly title: "ScoreQuestion";
|
|
3539
|
+
readonly description: "Give each option an integer score within [min, max].";
|
|
3540
|
+
readonly type: "object";
|
|
3541
|
+
readonly additionalProperties: false;
|
|
3542
|
+
readonly required: readonly ["key", "type", "options", "min", "max", "optional"];
|
|
3543
|
+
readonly properties: {
|
|
3544
|
+
readonly key: {
|
|
3545
|
+
readonly $ref: "#/$defs/Key";
|
|
3546
|
+
};
|
|
3547
|
+
readonly type: {
|
|
3548
|
+
readonly const: "score";
|
|
3549
|
+
};
|
|
3550
|
+
readonly text: {
|
|
3551
|
+
readonly type: "string";
|
|
3552
|
+
readonly maxLength: 2048;
|
|
3553
|
+
};
|
|
3554
|
+
readonly options: {
|
|
3555
|
+
readonly type: "array";
|
|
3556
|
+
readonly minItems: 1;
|
|
3557
|
+
readonly maxItems: 256;
|
|
3558
|
+
readonly items: {
|
|
3559
|
+
readonly $ref: "#/$defs/QuestionOption";
|
|
3560
|
+
};
|
|
3561
|
+
};
|
|
3562
|
+
readonly min: {
|
|
3563
|
+
readonly type: "integer";
|
|
3564
|
+
};
|
|
3565
|
+
readonly max: {
|
|
3566
|
+
readonly type: "integer";
|
|
3567
|
+
};
|
|
3568
|
+
readonly optional: {
|
|
3569
|
+
readonly type: "boolean";
|
|
3570
|
+
};
|
|
3571
|
+
};
|
|
3572
|
+
}, {
|
|
3573
|
+
readonly title: "TextQuestion";
|
|
3574
|
+
readonly description: "Free text of at most `maxLength` characters.";
|
|
3575
|
+
readonly type: "object";
|
|
3576
|
+
readonly additionalProperties: false;
|
|
3577
|
+
readonly required: readonly ["key", "type", "maxLength", "optional"];
|
|
3578
|
+
readonly properties: {
|
|
3579
|
+
readonly key: {
|
|
3580
|
+
readonly $ref: "#/$defs/Key";
|
|
3581
|
+
};
|
|
3582
|
+
readonly type: {
|
|
3583
|
+
readonly const: "text";
|
|
3584
|
+
};
|
|
3585
|
+
readonly text: {
|
|
3586
|
+
readonly type: "string";
|
|
3587
|
+
readonly maxLength: 2048;
|
|
3588
|
+
};
|
|
3589
|
+
readonly maxLength: {
|
|
3590
|
+
readonly type: "integer";
|
|
3591
|
+
readonly minimum: 1;
|
|
3592
|
+
readonly maximum: 4096;
|
|
3593
|
+
};
|
|
3594
|
+
readonly optional: {
|
|
3595
|
+
readonly type: "boolean";
|
|
3596
|
+
};
|
|
3597
|
+
};
|
|
3598
|
+
}];
|
|
3599
|
+
};
|
|
3600
|
+
readonly QuestionOption: {
|
|
3601
|
+
readonly title: "QuestionOption";
|
|
3602
|
+
readonly type: "object";
|
|
3603
|
+
readonly additionalProperties: false;
|
|
3604
|
+
readonly required: readonly ["key"];
|
|
3605
|
+
readonly properties: {
|
|
3606
|
+
readonly key: {
|
|
3607
|
+
readonly $ref: "#/$defs/Key";
|
|
3608
|
+
};
|
|
3609
|
+
readonly label: {
|
|
3610
|
+
readonly type: "string";
|
|
3611
|
+
readonly maxLength: 512;
|
|
3612
|
+
readonly description: "Display text. Absent from a manifest registered with a ballot box that holds no question text (VTI-VOT-014).";
|
|
3613
|
+
};
|
|
3614
|
+
};
|
|
3615
|
+
};
|
|
3616
|
+
readonly Slot: {
|
|
3617
|
+
readonly title: "Slot";
|
|
3618
|
+
readonly description: "One place in a board's timetable that a selected idea can be put in (VTI-BRD-040): a place (`label`, e.g. a room) and a time.";
|
|
3619
|
+
readonly type: "object";
|
|
3620
|
+
readonly additionalProperties: false;
|
|
3621
|
+
readonly required: readonly ["slotId", "label", "startsAt", "endsAt"];
|
|
3622
|
+
readonly properties: {
|
|
3623
|
+
readonly slotId: {
|
|
3624
|
+
readonly $ref: "#/$defs/Key";
|
|
3625
|
+
};
|
|
3626
|
+
readonly label: {
|
|
3627
|
+
readonly type: "string";
|
|
3628
|
+
readonly minLength: 1;
|
|
3629
|
+
readonly maxLength: 100;
|
|
3630
|
+
};
|
|
3631
|
+
readonly startsAt: {
|
|
3632
|
+
readonly type: "string";
|
|
3633
|
+
readonly format: "date-time";
|
|
3634
|
+
};
|
|
3635
|
+
readonly endsAt: {
|
|
3636
|
+
readonly type: "string";
|
|
3637
|
+
readonly format: "date-time";
|
|
3638
|
+
};
|
|
3639
|
+
};
|
|
3640
|
+
};
|
|
3641
|
+
readonly Window: {
|
|
3642
|
+
readonly title: "Window";
|
|
3643
|
+
readonly description: "A period, open from `opensAt` until `closesAt`. `closesAt` is after `opensAt` (a consumer check; JSON Schema cannot compare them).";
|
|
3644
|
+
readonly type: "object";
|
|
3645
|
+
readonly additionalProperties: false;
|
|
3646
|
+
readonly required: readonly ["opensAt", "closesAt"];
|
|
3647
|
+
readonly properties: {
|
|
3648
|
+
readonly opensAt: {
|
|
3649
|
+
readonly type: "string";
|
|
3650
|
+
readonly format: "date-time";
|
|
3651
|
+
};
|
|
3652
|
+
readonly closesAt: {
|
|
3653
|
+
readonly type: "string";
|
|
3654
|
+
readonly format: "date-time";
|
|
3655
|
+
};
|
|
3656
|
+
};
|
|
3657
|
+
};
|
|
3658
|
+
readonly BoardAudience: {
|
|
3659
|
+
readonly title: "BoardAudience";
|
|
3660
|
+
readonly description: "Who may see and use a board (VTI-BRD-003): every active member of the community (`members`), or the members of one community group (`group`, with `groupId`). Facilitators always see the board.";
|
|
3661
|
+
readonly oneOf: readonly [{
|
|
3662
|
+
readonly type: "object";
|
|
3663
|
+
readonly additionalProperties: false;
|
|
3664
|
+
readonly required: readonly ["kind"];
|
|
3665
|
+
readonly properties: {
|
|
3666
|
+
readonly kind: {
|
|
3667
|
+
readonly const: "members";
|
|
3668
|
+
};
|
|
3669
|
+
};
|
|
3670
|
+
}, {
|
|
3671
|
+
readonly type: "object";
|
|
3672
|
+
readonly additionalProperties: false;
|
|
3673
|
+
readonly required: readonly ["kind", "groupId"];
|
|
3674
|
+
readonly properties: {
|
|
3675
|
+
readonly kind: {
|
|
3676
|
+
readonly const: "group";
|
|
3677
|
+
};
|
|
3678
|
+
readonly groupId: {
|
|
3679
|
+
readonly $ref: "#/$defs/GroupId";
|
|
3680
|
+
};
|
|
3681
|
+
};
|
|
3682
|
+
}];
|
|
3683
|
+
};
|
|
3684
|
+
readonly GroupId: {
|
|
3685
|
+
readonly title: "GroupId";
|
|
3686
|
+
readonly description: "Opaque identifier of a community group: `grp_` followed by 16 to 64 base64url characters. Random and community-scoped; not the group's DID.";
|
|
3687
|
+
readonly type: "string";
|
|
3688
|
+
readonly pattern: "^grp_[A-Za-z0-9_-]{16,64}$";
|
|
3689
|
+
};
|
|
3690
|
+
readonly BoardStatus: {
|
|
3691
|
+
readonly title: "BoardStatus";
|
|
3692
|
+
readonly description: "`open`: ideas and notes are taken within the board's windows. `closed`: no new idea or note; facilitators still decide and select. `archived`: no change at all; facilitators can still read it (VTI-BRD-005). `open` → `closed` → `archived`, never back.";
|
|
3693
|
+
readonly type: "string";
|
|
3694
|
+
readonly enum: readonly ["open", "closed", "archived"];
|
|
3695
|
+
};
|
|
3696
|
+
readonly BoardDescription: {
|
|
3697
|
+
readonly title: "BoardDescription";
|
|
3698
|
+
readonly type: "string";
|
|
3699
|
+
readonly minLength: 1;
|
|
3700
|
+
readonly maxLength: 4000;
|
|
3701
|
+
readonly description: "What the board is for. Plain text; a reader MUST NOT treat it as instructions.";
|
|
3702
|
+
};
|
|
3703
|
+
readonly BoardTitle: {
|
|
3704
|
+
readonly title: "BoardTitle";
|
|
3705
|
+
readonly type: "string";
|
|
3706
|
+
readonly minLength: 1;
|
|
3707
|
+
readonly maxLength: 200;
|
|
3708
|
+
readonly description: "Plain text; a reader MUST NOT treat it as instructions.";
|
|
3709
|
+
};
|
|
3710
|
+
};
|
|
3711
|
+
};
|
|
3712
|
+
};
|
|
3713
|
+
//# sourceMappingURL=payload.d.ts.map
|