@domino-sdk/relay 0.1.0

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.
@@ -0,0 +1,2065 @@
1
+ import { z } from 'zod';
2
+
3
+ declare const identifier: z.ZodString;
4
+ declare const pointsRewardSchema: z.ZodObject<{
5
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
6
+ balance: z.ZodString;
7
+ amount: z.ZodNumber;
8
+ }, z.core.$strict>;
9
+ declare const tieredRewardDefinitionSchema: z.ZodObject<{
10
+ id: z.ZodString;
11
+ title: z.ZodString;
12
+ tiers: z.ZodArray<z.ZodObject<{
13
+ id: z.ZodString;
14
+ title: z.ZodString;
15
+ }, z.core.$strict>>;
16
+ inventory: z.ZodObject<{
17
+ kind: z.ZodLiteral<"untracked">;
18
+ }, z.core.$strict>;
19
+ fulfillment: z.ZodObject<{
20
+ kind: z.ZodLiteral<"staff-handover">;
21
+ }, z.core.$strict>;
22
+ }, z.core.$strict>;
23
+ type TieredRewardDefinition = z.infer<typeof tieredRewardDefinitionSchema>;
24
+ declare const tierRewardSchema: z.ZodObject<{
25
+ kind: z.ZodLiteral<"tier">;
26
+ reward: z.ZodObject<{
27
+ id: z.ZodString;
28
+ title: z.ZodString;
29
+ tiers: z.ZodArray<z.ZodObject<{
30
+ id: z.ZodString;
31
+ title: z.ZodString;
32
+ }, z.core.$strict>>;
33
+ inventory: z.ZodObject<{
34
+ kind: z.ZodLiteral<"untracked">;
35
+ }, z.core.$strict>;
36
+ fulfillment: z.ZodObject<{
37
+ kind: z.ZodLiteral<"staff-handover">;
38
+ }, z.core.$strict>;
39
+ }, z.core.$strict>;
40
+ tier: z.ZodString;
41
+ }, z.core.$strict>;
42
+ declare const rewardSchema: z.ZodUnion<readonly [z.ZodObject<{
43
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
44
+ balance: z.ZodString;
45
+ amount: z.ZodNumber;
46
+ }, z.core.$strict>, z.ZodObject<{
47
+ kind: z.ZodLiteral<"tier">;
48
+ reward: z.ZodObject<{
49
+ id: z.ZodString;
50
+ title: z.ZodString;
51
+ tiers: z.ZodArray<z.ZodObject<{
52
+ id: z.ZodString;
53
+ title: z.ZodString;
54
+ }, z.core.$strict>>;
55
+ inventory: z.ZodObject<{
56
+ kind: z.ZodLiteral<"untracked">;
57
+ }, z.core.$strict>;
58
+ fulfillment: z.ZodObject<{
59
+ kind: z.ZodLiteral<"staff-handover">;
60
+ }, z.core.$strict>;
61
+ }, z.core.$strict>;
62
+ tier: z.ZodString;
63
+ }, z.core.$strict>]>;
64
+ type Reward = z.infer<typeof rewardSchema>;
65
+ declare function rewardKey(reward: Reward): string;
66
+ declare const triggerSchema: z.ZodUnion<readonly [z.ZodObject<{
67
+ kind: z.ZodLiteral<"manual">;
68
+ input: z.ZodEnum<{
69
+ photo: "photo";
70
+ quiz: "quiz";
71
+ none: "none";
72
+ }>;
73
+ actor: z.ZodOptional<z.ZodEnum<{
74
+ member: "member";
75
+ staff: "staff";
76
+ }>>;
77
+ }, z.core.$strict>, z.ZodObject<{
78
+ kind: z.ZodLiteral<"automatic">;
79
+ }, z.core.$strict>]>;
80
+ declare const prerequisiteSchema: z.ZodObject<{
81
+ quest: z.ZodString;
82
+ scope: z.ZodLiteral<"ever">;
83
+ }, z.core.$strict>;
84
+ declare const photoResultSchema: z.ZodObject<{
85
+ kind: z.ZodEnum<{
86
+ pass: "pass";
87
+ fail: "fail";
88
+ unclear: "unclear";
89
+ }>;
90
+ reason: z.ZodString;
91
+ }, z.core.$strict>;
92
+ type PhotoResult = z.infer<typeof photoResultSchema>;
93
+ declare const decisionSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
94
+ kind: z.ZodLiteral<"accept">;
95
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
96
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
97
+ balance: z.ZodString;
98
+ amount: z.ZodNumber;
99
+ }, z.core.$strict>, z.ZodObject<{
100
+ kind: z.ZodLiteral<"tier">;
101
+ reward: z.ZodObject<{
102
+ id: z.ZodString;
103
+ title: z.ZodString;
104
+ tiers: z.ZodArray<z.ZodObject<{
105
+ id: z.ZodString;
106
+ title: z.ZodString;
107
+ }, z.core.$strict>>;
108
+ inventory: z.ZodObject<{
109
+ kind: z.ZodLiteral<"untracked">;
110
+ }, z.core.$strict>;
111
+ fulfillment: z.ZodObject<{
112
+ kind: z.ZodLiteral<"staff-handover">;
113
+ }, z.core.$strict>;
114
+ }, z.core.$strict>;
115
+ tier: z.ZodString;
116
+ }, z.core.$strict>]>>;
117
+ }, z.core.$strict>, z.ZodObject<{
118
+ kind: z.ZodLiteral<"reject">;
119
+ reason: z.ZodString;
120
+ }, z.core.$strict>, z.ZodObject<{
121
+ kind: z.ZodLiteral<"review">;
122
+ reason: z.ZodString;
123
+ rewards: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
124
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
125
+ balance: z.ZodString;
126
+ amount: z.ZodNumber;
127
+ }, z.core.$strict>, z.ZodObject<{
128
+ kind: z.ZodLiteral<"tier">;
129
+ reward: z.ZodObject<{
130
+ id: z.ZodString;
131
+ title: z.ZodString;
132
+ tiers: z.ZodArray<z.ZodObject<{
133
+ id: z.ZodString;
134
+ title: z.ZodString;
135
+ }, z.core.$strict>>;
136
+ inventory: z.ZodObject<{
137
+ kind: z.ZodLiteral<"untracked">;
138
+ }, z.core.$strict>;
139
+ fulfillment: z.ZodObject<{
140
+ kind: z.ZodLiteral<"staff-handover">;
141
+ }, z.core.$strict>;
142
+ }, z.core.$strict>;
143
+ tier: z.ZodString;
144
+ }, z.core.$strict>]>>>;
145
+ }, z.core.$strict>], "kind">;
146
+ type Decision = z.infer<typeof decisionSchema>;
147
+ declare const reviewModeSchema: z.ZodEnum<{
148
+ "fixture-pass": "fixture-pass";
149
+ "fixture-fail": "fixture-fail";
150
+ "fixture-unclear": "fixture-unclear";
151
+ "fixture-error": "fixture-error";
152
+ "workers-ai": "workers-ai";
153
+ }>;
154
+ declare const rewardBundleSchema: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
155
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
156
+ balance: z.ZodString;
157
+ amount: z.ZodNumber;
158
+ }, z.core.$strict>, z.ZodObject<{
159
+ kind: z.ZodLiteral<"tier">;
160
+ reward: z.ZodObject<{
161
+ id: z.ZodString;
162
+ title: z.ZodString;
163
+ tiers: z.ZodArray<z.ZodObject<{
164
+ id: z.ZodString;
165
+ title: z.ZodString;
166
+ }, z.core.$strict>>;
167
+ inventory: z.ZodObject<{
168
+ kind: z.ZodLiteral<"untracked">;
169
+ }, z.core.$strict>;
170
+ fulfillment: z.ZodObject<{
171
+ kind: z.ZodLiteral<"staff-handover">;
172
+ }, z.core.$strict>;
173
+ }, z.core.$strict>;
174
+ tier: z.ZodString;
175
+ }, z.core.$strict>]>>;
176
+ declare const mediaUrlSchema: z.ZodString;
177
+ declare const questPresentationSchema: z.ZodObject<{
178
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
179
+ id: z.ZodString;
180
+ prompt: z.ZodString;
181
+ choices: z.ZodArray<z.ZodObject<{
182
+ id: z.ZodString;
183
+ label: z.ZodString;
184
+ }, z.core.$strict>>;
185
+ }, z.core.$strict>>>;
186
+ instructions: z.ZodOptional<z.ZodString>;
187
+ video: z.ZodOptional<z.ZodObject<{
188
+ url: z.ZodString;
189
+ poster: z.ZodOptional<z.ZodString>;
190
+ captions: z.ZodOptional<z.ZodObject<{
191
+ url: z.ZodString;
192
+ language: z.ZodString;
193
+ label: z.ZodString;
194
+ }, z.core.$strict>>;
195
+ }, z.core.$strict>>;
196
+ }, z.core.$strict>;
197
+ type QuestPresentation = z.infer<typeof questPresentationSchema>;
198
+ declare const questDescriptionSchema: z.ZodObject<{
199
+ quest: z.ZodString;
200
+ runtimeVersion: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>;
201
+ title: z.ZodString;
202
+ presentation: z.ZodDefault<z.ZodObject<{
203
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
204
+ id: z.ZodString;
205
+ prompt: z.ZodString;
206
+ choices: z.ZodArray<z.ZodObject<{
207
+ id: z.ZodString;
208
+ label: z.ZodString;
209
+ }, z.core.$strict>>;
210
+ }, z.core.$strict>>>;
211
+ instructions: z.ZodOptional<z.ZodString>;
212
+ video: z.ZodOptional<z.ZodObject<{
213
+ url: z.ZodString;
214
+ poster: z.ZodOptional<z.ZodString>;
215
+ captions: z.ZodOptional<z.ZodObject<{
216
+ url: z.ZodString;
217
+ language: z.ZodString;
218
+ label: z.ZodString;
219
+ }, z.core.$strict>>;
220
+ }, z.core.$strict>>;
221
+ }, z.core.$strict>>;
222
+ fields: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
223
+ kind: z.ZodLiteral<"quiz">;
224
+ default: z.ZodArray<z.ZodObject<{
225
+ id: z.ZodString;
226
+ prompt: z.ZodString;
227
+ choices: z.ZodArray<z.ZodObject<{
228
+ id: z.ZodString;
229
+ label: z.ZodString;
230
+ }, z.core.$strict>>;
231
+ correct: z.ZodString;
232
+ }, z.core.$strict>>;
233
+ label: z.ZodString;
234
+ description: z.ZodOptional<z.ZodString>;
235
+ }, z.core.$strict>, z.ZodObject<{
236
+ kind: z.ZodLiteral<"text">;
237
+ default: z.ZodString;
238
+ minLength: z.ZodNumber;
239
+ maxLength: z.ZodNumber;
240
+ multiline: z.ZodBoolean;
241
+ label: z.ZodString;
242
+ description: z.ZodOptional<z.ZodString>;
243
+ }, z.core.$strict>, z.ZodObject<{
244
+ kind: z.ZodLiteral<"integer">;
245
+ default: z.ZodNumber;
246
+ min: z.ZodNumber;
247
+ max: z.ZodNumber;
248
+ label: z.ZodString;
249
+ description: z.ZodOptional<z.ZodString>;
250
+ }, z.core.$strict>, z.ZodObject<{
251
+ kind: z.ZodLiteral<"boolean">;
252
+ default: z.ZodBoolean;
253
+ label: z.ZodString;
254
+ description: z.ZodOptional<z.ZodString>;
255
+ }, z.core.$strict>, z.ZodObject<{
256
+ kind: z.ZodLiteral<"choice">;
257
+ default: z.ZodString;
258
+ options: z.ZodArray<z.ZodString>;
259
+ label: z.ZodString;
260
+ description: z.ZodOptional<z.ZodString>;
261
+ }, z.core.$strict>], "kind">>;
262
+ values: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
263
+ id: z.ZodString;
264
+ prompt: z.ZodString;
265
+ choices: z.ZodArray<z.ZodObject<{
266
+ id: z.ZodString;
267
+ label: z.ZodString;
268
+ }, z.core.$strict>>;
269
+ correct: z.ZodString;
270
+ }, z.core.$strict>>]>>;
271
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
272
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
273
+ balance: z.ZodString;
274
+ amount: z.ZodNumber;
275
+ }, z.core.$strict>, z.ZodObject<{
276
+ kind: z.ZodLiteral<"tier">;
277
+ reward: z.ZodObject<{
278
+ id: z.ZodString;
279
+ title: z.ZodString;
280
+ tiers: z.ZodArray<z.ZodObject<{
281
+ id: z.ZodString;
282
+ title: z.ZodString;
283
+ }, z.core.$strict>>;
284
+ inventory: z.ZodObject<{
285
+ kind: z.ZodLiteral<"untracked">;
286
+ }, z.core.$strict>;
287
+ fulfillment: z.ZodObject<{
288
+ kind: z.ZodLiteral<"staff-handover">;
289
+ }, z.core.$strict>;
290
+ }, z.core.$strict>;
291
+ tier: z.ZodString;
292
+ }, z.core.$strict>]>>;
293
+ humanReview: z.ZodBoolean;
294
+ trigger: z.ZodUnion<readonly [z.ZodObject<{
295
+ kind: z.ZodLiteral<"manual">;
296
+ input: z.ZodEnum<{
297
+ photo: "photo";
298
+ quiz: "quiz";
299
+ none: "none";
300
+ }>;
301
+ actor: z.ZodOptional<z.ZodEnum<{
302
+ member: "member";
303
+ staff: "staff";
304
+ }>>;
305
+ }, z.core.$strict>, z.ZodObject<{
306
+ kind: z.ZodLiteral<"automatic">;
307
+ }, z.core.$strict>]>;
308
+ requires: z.ZodDefault<z.ZodArray<z.ZodObject<{
309
+ quest: z.ZodString;
310
+ scope: z.ZodLiteral<"ever">;
311
+ }, z.core.$strict>>>;
312
+ completion: z.ZodObject<{
313
+ kind: z.ZodLiteral<"once">;
314
+ }, z.core.$strict>;
315
+ }, z.core.$strict>;
316
+ type QuestDescription = z.infer<typeof questDescriptionSchema>;
317
+ declare const artifactSchema: z.ZodObject<{
318
+ code: z.ZodString;
319
+ }, z.core.$strict>;
320
+ declare const releaseSchema: z.ZodObject<{
321
+ code: z.ZodString;
322
+ settings: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
323
+ id: z.ZodString;
324
+ prompt: z.ZodString;
325
+ choices: z.ZodArray<z.ZodObject<{
326
+ id: z.ZodString;
327
+ label: z.ZodString;
328
+ }, z.core.$strict>>;
329
+ correct: z.ZodString;
330
+ }, z.core.$strict>>]>>;
331
+ provider: z.ZodEnum<{
332
+ "fixture-pass": "fixture-pass";
333
+ "fixture-fail": "fixture-fail";
334
+ "fixture-unclear": "fixture-unclear";
335
+ "fixture-error": "fixture-error";
336
+ "workers-ai": "workers-ai";
337
+ }>;
338
+ expectedRelease: z.ZodOptional<z.ZodNullable<z.ZodString>>;
339
+ settingRenames: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
340
+ }, z.core.$strict>;
341
+ declare const batchReleaseSchema: z.ZodObject<{
342
+ releases: z.ZodArray<z.ZodObject<{
343
+ code: z.ZodString;
344
+ settings: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
345
+ id: z.ZodString;
346
+ prompt: z.ZodString;
347
+ choices: z.ZodArray<z.ZodObject<{
348
+ id: z.ZodString;
349
+ label: z.ZodString;
350
+ }, z.core.$strict>>;
351
+ correct: z.ZodString;
352
+ }, z.core.$strict>>]>>;
353
+ provider: z.ZodEnum<{
354
+ "fixture-pass": "fixture-pass";
355
+ "fixture-fail": "fixture-fail";
356
+ "fixture-unclear": "fixture-unclear";
357
+ "fixture-error": "fixture-error";
358
+ "workers-ai": "workers-ai";
359
+ }>;
360
+ expectedRelease: z.ZodOptional<z.ZodNullable<z.ZodString>>;
361
+ settingRenames: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
362
+ }, z.core.$strict>>;
363
+ }, z.core.$strict>;
364
+ type ReleaseInput = z.infer<typeof releaseSchema>;
365
+ declare const questSettingsInputSchema: z.ZodObject<{
366
+ quest: z.ZodString;
367
+ expectedRelease: z.ZodString;
368
+ set: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
369
+ id: z.ZodString;
370
+ prompt: z.ZodString;
371
+ choices: z.ZodArray<z.ZodObject<{
372
+ id: z.ZodString;
373
+ label: z.ZodString;
374
+ }, z.core.$strict>>;
375
+ correct: z.ZodString;
376
+ }, z.core.$strict>>]>>;
377
+ reset: z.ZodArray<z.ZodString>;
378
+ }, z.core.$strict>;
379
+ type QuestSettingsInput = z.infer<typeof questSettingsInputSchema>;
380
+ declare const publishedReleaseSchema: z.ZodUnion<readonly [z.ZodObject<{
381
+ quest: z.ZodString;
382
+ runtimeVersion: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>;
383
+ title: z.ZodString;
384
+ presentation: z.ZodDefault<z.ZodObject<{
385
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
386
+ id: z.ZodString;
387
+ prompt: z.ZodString;
388
+ choices: z.ZodArray<z.ZodObject<{
389
+ id: z.ZodString;
390
+ label: z.ZodString;
391
+ }, z.core.$strict>>;
392
+ }, z.core.$strict>>>;
393
+ instructions: z.ZodOptional<z.ZodString>;
394
+ video: z.ZodOptional<z.ZodObject<{
395
+ url: z.ZodString;
396
+ poster: z.ZodOptional<z.ZodString>;
397
+ captions: z.ZodOptional<z.ZodObject<{
398
+ url: z.ZodString;
399
+ language: z.ZodString;
400
+ label: z.ZodString;
401
+ }, z.core.$strict>>;
402
+ }, z.core.$strict>>;
403
+ }, z.core.$strict>>;
404
+ fields: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
405
+ kind: z.ZodLiteral<"quiz">;
406
+ default: z.ZodArray<z.ZodObject<{
407
+ id: z.ZodString;
408
+ prompt: z.ZodString;
409
+ choices: z.ZodArray<z.ZodObject<{
410
+ id: z.ZodString;
411
+ label: z.ZodString;
412
+ }, z.core.$strict>>;
413
+ correct: z.ZodString;
414
+ }, z.core.$strict>>;
415
+ label: z.ZodString;
416
+ description: z.ZodOptional<z.ZodString>;
417
+ }, z.core.$strict>, z.ZodObject<{
418
+ kind: z.ZodLiteral<"text">;
419
+ default: z.ZodString;
420
+ minLength: z.ZodNumber;
421
+ maxLength: z.ZodNumber;
422
+ multiline: z.ZodBoolean;
423
+ label: z.ZodString;
424
+ description: z.ZodOptional<z.ZodString>;
425
+ }, z.core.$strict>, z.ZodObject<{
426
+ kind: z.ZodLiteral<"integer">;
427
+ default: z.ZodNumber;
428
+ min: z.ZodNumber;
429
+ max: z.ZodNumber;
430
+ label: z.ZodString;
431
+ description: z.ZodOptional<z.ZodString>;
432
+ }, z.core.$strict>, z.ZodObject<{
433
+ kind: z.ZodLiteral<"boolean">;
434
+ default: z.ZodBoolean;
435
+ label: z.ZodString;
436
+ description: z.ZodOptional<z.ZodString>;
437
+ }, z.core.$strict>, z.ZodObject<{
438
+ kind: z.ZodLiteral<"choice">;
439
+ default: z.ZodString;
440
+ options: z.ZodArray<z.ZodString>;
441
+ label: z.ZodString;
442
+ description: z.ZodOptional<z.ZodString>;
443
+ }, z.core.$strict>], "kind">>;
444
+ values: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
445
+ id: z.ZodString;
446
+ prompt: z.ZodString;
447
+ choices: z.ZodArray<z.ZodObject<{
448
+ id: z.ZodString;
449
+ label: z.ZodString;
450
+ }, z.core.$strict>>;
451
+ correct: z.ZodString;
452
+ }, z.core.$strict>>]>>;
453
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
454
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
455
+ balance: z.ZodString;
456
+ amount: z.ZodNumber;
457
+ }, z.core.$strict>, z.ZodObject<{
458
+ kind: z.ZodLiteral<"tier">;
459
+ reward: z.ZodObject<{
460
+ id: z.ZodString;
461
+ title: z.ZodString;
462
+ tiers: z.ZodArray<z.ZodObject<{
463
+ id: z.ZodString;
464
+ title: z.ZodString;
465
+ }, z.core.$strict>>;
466
+ inventory: z.ZodObject<{
467
+ kind: z.ZodLiteral<"untracked">;
468
+ }, z.core.$strict>;
469
+ fulfillment: z.ZodObject<{
470
+ kind: z.ZodLiteral<"staff-handover">;
471
+ }, z.core.$strict>;
472
+ }, z.core.$strict>;
473
+ tier: z.ZodString;
474
+ }, z.core.$strict>]>>;
475
+ humanReview: z.ZodBoolean;
476
+ trigger: z.ZodUnion<readonly [z.ZodObject<{
477
+ kind: z.ZodLiteral<"manual">;
478
+ input: z.ZodEnum<{
479
+ photo: "photo";
480
+ quiz: "quiz";
481
+ none: "none";
482
+ }>;
483
+ actor: z.ZodOptional<z.ZodEnum<{
484
+ member: "member";
485
+ staff: "staff";
486
+ }>>;
487
+ }, z.core.$strict>, z.ZodObject<{
488
+ kind: z.ZodLiteral<"automatic">;
489
+ }, z.core.$strict>]>;
490
+ requires: z.ZodDefault<z.ZodArray<z.ZodObject<{
491
+ quest: z.ZodString;
492
+ scope: z.ZodLiteral<"ever">;
493
+ }, z.core.$strict>>>;
494
+ completion: z.ZodObject<{
495
+ kind: z.ZodLiteral<"once">;
496
+ }, z.core.$strict>;
497
+ code: z.ZodString;
498
+ provider: z.ZodEnum<{
499
+ "fixture-pass": "fixture-pass";
500
+ "fixture-fail": "fixture-fail";
501
+ "fixture-unclear": "fixture-unclear";
502
+ "fixture-error": "fixture-error";
503
+ "workers-ai": "workers-ai";
504
+ }>;
505
+ id: z.ZodString;
506
+ createdAt: z.ZodNumber;
507
+ legacy: z.ZodDefault<z.ZodBoolean>;
508
+ origin: z.ZodOptional<z.ZodObject<{
509
+ typeVersion: z.ZodString;
510
+ }, z.core.$strict>>;
511
+ lifecycle: z.ZodDefault<z.ZodEnum<{
512
+ active: "active";
513
+ paused: "paused";
514
+ archived: "archived";
515
+ }>>;
516
+ configuration: z.ZodOptional<z.ZodObject<{
517
+ defaults: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
518
+ id: z.ZodString;
519
+ prompt: z.ZodString;
520
+ choices: z.ZodArray<z.ZodObject<{
521
+ id: z.ZodString;
522
+ label: z.ZodString;
523
+ }, z.core.$strict>>;
524
+ correct: z.ZodString;
525
+ }, z.core.$strict>>]>>;
526
+ overrides: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
527
+ id: z.ZodString;
528
+ prompt: z.ZodString;
529
+ choices: z.ZodArray<z.ZodObject<{
530
+ id: z.ZodString;
531
+ label: z.ZodString;
532
+ }, z.core.$strict>>;
533
+ correct: z.ZodString;
534
+ }, z.core.$strict>>]>>;
535
+ preserved: z.ZodArray<z.ZodString>;
536
+ }, z.core.$strict>>;
537
+ }, z.core.$strict>, z.ZodPipe<z.ZodObject<{
538
+ quest: z.ZodString;
539
+ title: z.ZodString;
540
+ criteria: z.ZodString;
541
+ humanReview: z.ZodBoolean;
542
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
543
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
544
+ balance: z.ZodString;
545
+ amount: z.ZodNumber;
546
+ }, z.core.$strict>, z.ZodObject<{
547
+ kind: z.ZodLiteral<"tier">;
548
+ reward: z.ZodObject<{
549
+ id: z.ZodString;
550
+ title: z.ZodString;
551
+ tiers: z.ZodArray<z.ZodObject<{
552
+ id: z.ZodString;
553
+ title: z.ZodString;
554
+ }, z.core.$strict>>;
555
+ inventory: z.ZodObject<{
556
+ kind: z.ZodLiteral<"untracked">;
557
+ }, z.core.$strict>;
558
+ fulfillment: z.ZodObject<{
559
+ kind: z.ZodLiteral<"staff-handover">;
560
+ }, z.core.$strict>;
561
+ }, z.core.$strict>;
562
+ tier: z.ZodString;
563
+ }, z.core.$strict>]>>;
564
+ code: z.ZodString;
565
+ provider: z.ZodEnum<{
566
+ "fixture-pass": "fixture-pass";
567
+ "fixture-fail": "fixture-fail";
568
+ "fixture-unclear": "fixture-unclear";
569
+ "fixture-error": "fixture-error";
570
+ "workers-ai": "workers-ai";
571
+ }>;
572
+ id: z.ZodString;
573
+ createdAt: z.ZodNumber;
574
+ }, z.core.$strip>, z.ZodTransform<{
575
+ quest: string;
576
+ runtimeVersion: 1 | 2;
577
+ title: string;
578
+ presentation: {
579
+ quiz?: {
580
+ id: string;
581
+ prompt: string;
582
+ choices: {
583
+ id: string;
584
+ label: string;
585
+ }[];
586
+ }[] | undefined;
587
+ instructions?: string | undefined;
588
+ video?: {
589
+ url: string;
590
+ poster?: string | undefined;
591
+ captions?: {
592
+ url: string;
593
+ language: string;
594
+ label: string;
595
+ } | undefined;
596
+ } | undefined;
597
+ };
598
+ fields: Record<string, {
599
+ kind: "quiz";
600
+ default: {
601
+ id: string;
602
+ prompt: string;
603
+ choices: {
604
+ id: string;
605
+ label: string;
606
+ }[];
607
+ correct: string;
608
+ }[];
609
+ label: string;
610
+ description?: string | undefined;
611
+ } | {
612
+ kind: "text";
613
+ default: string;
614
+ minLength: number;
615
+ maxLength: number;
616
+ multiline: boolean;
617
+ label: string;
618
+ description?: string | undefined;
619
+ } | {
620
+ kind: "integer";
621
+ default: number;
622
+ min: number;
623
+ max: number;
624
+ label: string;
625
+ description?: string | undefined;
626
+ } | {
627
+ kind: "boolean";
628
+ default: boolean;
629
+ label: string;
630
+ description?: string | undefined;
631
+ } | {
632
+ kind: "choice";
633
+ default: string;
634
+ options: string[];
635
+ label: string;
636
+ description?: string | undefined;
637
+ }>;
638
+ values: Record<string, string | number | boolean | {
639
+ id: string;
640
+ prompt: string;
641
+ choices: {
642
+ id: string;
643
+ label: string;
644
+ }[];
645
+ correct: string;
646
+ }[]>;
647
+ rewards: ({
648
+ kind: "tier";
649
+ reward: {
650
+ id: string;
651
+ title: string;
652
+ tiers: {
653
+ id: string;
654
+ title: string;
655
+ }[];
656
+ inventory: {
657
+ kind: "untracked";
658
+ };
659
+ fulfillment: {
660
+ kind: "staff-handover";
661
+ };
662
+ };
663
+ tier: string;
664
+ } | {
665
+ kind: "points";
666
+ balance: string;
667
+ amount: number;
668
+ })[];
669
+ humanReview: boolean;
670
+ trigger: {
671
+ kind: "manual";
672
+ input: "photo" | "quiz" | "none";
673
+ actor?: "member" | "staff" | undefined;
674
+ } | {
675
+ kind: "automatic";
676
+ };
677
+ requires: {
678
+ quest: string;
679
+ scope: "ever";
680
+ }[];
681
+ completion: {
682
+ kind: "once";
683
+ };
684
+ code: string;
685
+ provider: "fixture-pass" | "fixture-fail" | "fixture-unclear" | "fixture-error" | "workers-ai";
686
+ id: string;
687
+ createdAt: number;
688
+ legacy: boolean;
689
+ lifecycle: "active" | "paused" | "archived";
690
+ origin?: {
691
+ typeVersion: string;
692
+ } | undefined;
693
+ configuration?: {
694
+ defaults: Record<string, string | number | boolean | {
695
+ id: string;
696
+ prompt: string;
697
+ choices: {
698
+ id: string;
699
+ label: string;
700
+ }[];
701
+ correct: string;
702
+ }[]>;
703
+ overrides: Record<string, string | number | boolean | {
704
+ id: string;
705
+ prompt: string;
706
+ choices: {
707
+ id: string;
708
+ label: string;
709
+ }[];
710
+ correct: string;
711
+ }[]>;
712
+ preserved: string[];
713
+ } | undefined;
714
+ }, {
715
+ quest: string;
716
+ title: string;
717
+ criteria: string;
718
+ humanReview: boolean;
719
+ rewards: ({
720
+ kind: "tier";
721
+ reward: {
722
+ id: string;
723
+ title: string;
724
+ tiers: {
725
+ id: string;
726
+ title: string;
727
+ }[];
728
+ inventory: {
729
+ kind: "untracked";
730
+ };
731
+ fulfillment: {
732
+ kind: "staff-handover";
733
+ };
734
+ };
735
+ tier: string;
736
+ } | {
737
+ kind: "points";
738
+ balance: string;
739
+ amount: number;
740
+ })[];
741
+ code: string;
742
+ provider: "fixture-pass" | "fixture-fail" | "fixture-unclear" | "fixture-error" | "workers-ai";
743
+ id: string;
744
+ createdAt: number;
745
+ }>>]>;
746
+ type PublishedRelease = z.infer<typeof publishedReleaseSchema>;
747
+ declare const templateSchema: z.ZodObject<{
748
+ code: z.ZodString;
749
+ definition: z.ZodObject<{
750
+ quest: z.ZodString;
751
+ runtimeVersion: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>;
752
+ title: z.ZodString;
753
+ presentation: z.ZodDefault<z.ZodObject<{
754
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
755
+ id: z.ZodString;
756
+ prompt: z.ZodString;
757
+ choices: z.ZodArray<z.ZodObject<{
758
+ id: z.ZodString;
759
+ label: z.ZodString;
760
+ }, z.core.$strict>>;
761
+ }, z.core.$strict>>>;
762
+ instructions: z.ZodOptional<z.ZodString>;
763
+ video: z.ZodOptional<z.ZodObject<{
764
+ url: z.ZodString;
765
+ poster: z.ZodOptional<z.ZodString>;
766
+ captions: z.ZodOptional<z.ZodObject<{
767
+ url: z.ZodString;
768
+ language: z.ZodString;
769
+ label: z.ZodString;
770
+ }, z.core.$strict>>;
771
+ }, z.core.$strict>>;
772
+ }, z.core.$strict>>;
773
+ fields: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
774
+ kind: z.ZodLiteral<"quiz">;
775
+ default: z.ZodArray<z.ZodObject<{
776
+ id: z.ZodString;
777
+ prompt: z.ZodString;
778
+ choices: z.ZodArray<z.ZodObject<{
779
+ id: z.ZodString;
780
+ label: z.ZodString;
781
+ }, z.core.$strict>>;
782
+ correct: z.ZodString;
783
+ }, z.core.$strict>>;
784
+ label: z.ZodString;
785
+ description: z.ZodOptional<z.ZodString>;
786
+ }, z.core.$strict>, z.ZodObject<{
787
+ kind: z.ZodLiteral<"text">;
788
+ default: z.ZodString;
789
+ minLength: z.ZodNumber;
790
+ maxLength: z.ZodNumber;
791
+ multiline: z.ZodBoolean;
792
+ label: z.ZodString;
793
+ description: z.ZodOptional<z.ZodString>;
794
+ }, z.core.$strict>, z.ZodObject<{
795
+ kind: z.ZodLiteral<"integer">;
796
+ default: z.ZodNumber;
797
+ min: z.ZodNumber;
798
+ max: z.ZodNumber;
799
+ label: z.ZodString;
800
+ description: z.ZodOptional<z.ZodString>;
801
+ }, z.core.$strict>, z.ZodObject<{
802
+ kind: z.ZodLiteral<"boolean">;
803
+ default: z.ZodBoolean;
804
+ label: z.ZodString;
805
+ description: z.ZodOptional<z.ZodString>;
806
+ }, z.core.$strict>, z.ZodObject<{
807
+ kind: z.ZodLiteral<"choice">;
808
+ default: z.ZodString;
809
+ options: z.ZodArray<z.ZodString>;
810
+ label: z.ZodString;
811
+ description: z.ZodOptional<z.ZodString>;
812
+ }, z.core.$strict>], "kind">>;
813
+ values: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
814
+ id: z.ZodString;
815
+ prompt: z.ZodString;
816
+ choices: z.ZodArray<z.ZodObject<{
817
+ id: z.ZodString;
818
+ label: z.ZodString;
819
+ }, z.core.$strict>>;
820
+ correct: z.ZodString;
821
+ }, z.core.$strict>>]>>;
822
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
823
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
824
+ balance: z.ZodString;
825
+ amount: z.ZodNumber;
826
+ }, z.core.$strict>, z.ZodObject<{
827
+ kind: z.ZodLiteral<"tier">;
828
+ reward: z.ZodObject<{
829
+ id: z.ZodString;
830
+ title: z.ZodString;
831
+ tiers: z.ZodArray<z.ZodObject<{
832
+ id: z.ZodString;
833
+ title: z.ZodString;
834
+ }, z.core.$strict>>;
835
+ inventory: z.ZodObject<{
836
+ kind: z.ZodLiteral<"untracked">;
837
+ }, z.core.$strict>;
838
+ fulfillment: z.ZodObject<{
839
+ kind: z.ZodLiteral<"staff-handover">;
840
+ }, z.core.$strict>;
841
+ }, z.core.$strict>;
842
+ tier: z.ZodString;
843
+ }, z.core.$strict>]>>;
844
+ humanReview: z.ZodBoolean;
845
+ trigger: z.ZodUnion<readonly [z.ZodObject<{
846
+ kind: z.ZodLiteral<"manual">;
847
+ input: z.ZodEnum<{
848
+ photo: "photo";
849
+ quiz: "quiz";
850
+ none: "none";
851
+ }>;
852
+ actor: z.ZodOptional<z.ZodEnum<{
853
+ member: "member";
854
+ staff: "staff";
855
+ }>>;
856
+ }, z.core.$strict>, z.ZodObject<{
857
+ kind: z.ZodLiteral<"automatic">;
858
+ }, z.core.$strict>]>;
859
+ requires: z.ZodDefault<z.ZodArray<z.ZodObject<{
860
+ quest: z.ZodString;
861
+ scope: z.ZodLiteral<"ever">;
862
+ }, z.core.$strict>>>;
863
+ completion: z.ZodObject<{
864
+ kind: z.ZodLiteral<"once">;
865
+ }, z.core.$strict>;
866
+ }, z.core.$strict>;
867
+ }, z.core.$strip>;
868
+ declare const quizAnswersSchema: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
869
+ [k: string]: string;
870
+ }, Record<string, string>>>;
871
+ declare const quizEvidenceSchema: z.ZodObject<{
872
+ kind: z.ZodLiteral<"quiz">;
873
+ release: z.ZodOptional<z.ZodString>;
874
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
875
+ [k: string]: string;
876
+ }, Record<string, string>>>;
877
+ }, z.core.$strict>;
878
+ type QuizEvidence = z.infer<typeof quizEvidenceSchema>;
879
+ declare const submitSchema: z.ZodObject<{
880
+ actionId: z.ZodString;
881
+ quest: z.ZodString;
882
+ member: z.ZodString;
883
+ evidence: z.ZodOptional<z.ZodString>;
884
+ input: z.ZodOptional<z.ZodObject<{
885
+ kind: z.ZodLiteral<"quiz">;
886
+ release: z.ZodOptional<z.ZodString>;
887
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
888
+ [k: string]: string;
889
+ }, Record<string, string>>>;
890
+ }, z.core.$strict>>;
891
+ release: z.ZodOptional<z.ZodString>;
892
+ faultAfterReview: z.ZodOptional<z.ZodBoolean>;
893
+ }, z.core.$strict>;
894
+ type SubmitInput = z.infer<typeof submitSchema>;
895
+ declare const attemptSchema: z.ZodObject<{
896
+ id: z.ZodString;
897
+ release: z.ZodString;
898
+ quest: z.ZodString;
899
+ member: z.ZodString;
900
+ evidence: z.ZodNullable<z.ZodString>;
901
+ input: z.ZodOptional<z.ZodObject<{
902
+ kind: z.ZodLiteral<"quiz">;
903
+ release: z.ZodOptional<z.ZodString>;
904
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
905
+ [k: string]: string;
906
+ }, Record<string, string>>>;
907
+ }, z.core.$strict>>;
908
+ status: z.ZodEnum<{
909
+ queued: "queued";
910
+ evaluating: "evaluating";
911
+ accepted: "accepted";
912
+ rejected: "rejected";
913
+ "needs-review": "needs-review";
914
+ failed: "failed";
915
+ }>;
916
+ reason: z.ZodNullable<z.ZodString>;
917
+ retries: z.ZodNumber;
918
+ generation: z.ZodNumber;
919
+ completion: z.ZodNullable<z.ZodString>;
920
+ reviewRewards: z.ZodDefault<z.ZodNullable<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
921
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
922
+ balance: z.ZodString;
923
+ amount: z.ZodNumber;
924
+ }, z.core.$strict>, z.ZodObject<{
925
+ kind: z.ZodLiteral<"tier">;
926
+ reward: z.ZodObject<{
927
+ id: z.ZodString;
928
+ title: z.ZodString;
929
+ tiers: z.ZodArray<z.ZodObject<{
930
+ id: z.ZodString;
931
+ title: z.ZodString;
932
+ }, z.core.$strict>>;
933
+ inventory: z.ZodObject<{
934
+ kind: z.ZodLiteral<"untracked">;
935
+ }, z.core.$strict>;
936
+ fulfillment: z.ZodObject<{
937
+ kind: z.ZodLiteral<"staff-handover">;
938
+ }, z.core.$strict>;
939
+ }, z.core.$strict>;
940
+ tier: z.ZodString;
941
+ }, z.core.$strict>]>>>>;
942
+ createdAt: z.ZodNumber;
943
+ }, z.core.$strip>;
944
+ type Attempt = z.infer<typeof attemptSchema>;
945
+ declare const eventSchema: z.ZodObject<{
946
+ id: z.ZodNumber;
947
+ attempt: z.ZodNullable<z.ZodString>;
948
+ kind: z.ZodString;
949
+ detail: z.ZodString;
950
+ actor: z.ZodDefault<z.ZodNullable<z.ZodString>>;
951
+ at: z.ZodNumber;
952
+ }, z.core.$strip>;
953
+ declare const pickupSelectionSchema: z.ZodObject<{
954
+ item: z.ZodString;
955
+ revision: z.ZodNumber;
956
+ }, z.core.$strict>;
957
+ declare const pickupAllocationSchema: z.ZodObject<{
958
+ item: z.ZodString;
959
+ label: z.ZodString;
960
+ }, z.core.$strict>;
961
+ declare const pickupPolicySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
962
+ kind: z.ZodLiteral<"untracked">;
963
+ }, z.core.$strict>, z.ZodObject<{
964
+ kind: z.ZodLiteral<"at-pickup">;
965
+ tiers: z.ZodArray<z.ZodObject<{
966
+ tier: z.ZodString;
967
+ variants: z.ZodArray<z.ZodObject<{
968
+ item: z.ZodString;
969
+ label: z.ZodString;
970
+ }, z.core.$strict>>;
971
+ }, z.core.$strict>>;
972
+ }, z.core.$strict>], "kind">;
973
+ declare const pickupCatalogSchema: z.ZodObject<{
974
+ reward: z.ZodObject<{
975
+ id: z.ZodString;
976
+ title: z.ZodString;
977
+ tiers: z.ZodArray<z.ZodObject<{
978
+ id: z.ZodString;
979
+ title: z.ZodString;
980
+ }, z.core.$strict>>;
981
+ inventory: z.ZodObject<{
982
+ kind: z.ZodLiteral<"untracked">;
983
+ }, z.core.$strict>;
984
+ fulfillment: z.ZodObject<{
985
+ kind: z.ZodLiteral<"staff-handover">;
986
+ }, z.core.$strict>;
987
+ }, z.core.$strict>;
988
+ revision: z.ZodNumber;
989
+ policy: z.ZodDiscriminatedUnion<[z.ZodObject<{
990
+ kind: z.ZodLiteral<"untracked">;
991
+ }, z.core.$strict>, z.ZodObject<{
992
+ kind: z.ZodLiteral<"at-pickup">;
993
+ tiers: z.ZodArray<z.ZodObject<{
994
+ tier: z.ZodString;
995
+ variants: z.ZodArray<z.ZodObject<{
996
+ item: z.ZodString;
997
+ label: z.ZodString;
998
+ }, z.core.$strict>>;
999
+ }, z.core.$strict>>;
1000
+ }, z.core.$strict>], "kind">;
1001
+ }, z.core.$strip>;
1002
+ declare const pickupAvailabilitySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1003
+ kind: z.ZodLiteral<"untracked">;
1004
+ }, z.core.$strict>, z.ZodObject<{
1005
+ kind: z.ZodLiteral<"at-pickup">;
1006
+ revision: z.ZodNumber;
1007
+ variants: z.ZodArray<z.ZodObject<{
1008
+ item: z.ZodString;
1009
+ label: z.ZodString;
1010
+ available: z.ZodNumber;
1011
+ }, z.core.$strict>>;
1012
+ }, z.core.$strict>], "kind">;
1013
+ type PickupAvailability = z.infer<typeof pickupAvailabilitySchema>;
1014
+ declare const configurePickupSchema: z.ZodObject<{
1015
+ reward: z.ZodString;
1016
+ revision: z.ZodNumber;
1017
+ actionId: z.ZodString;
1018
+ policy: z.ZodDiscriminatedUnion<[z.ZodObject<{
1019
+ kind: z.ZodLiteral<"untracked">;
1020
+ }, z.core.$strict>, z.ZodObject<{
1021
+ kind: z.ZodLiteral<"at-pickup">;
1022
+ tiers: z.ZodArray<z.ZodObject<{
1023
+ tier: z.ZodString;
1024
+ variants: z.ZodArray<z.ZodObject<{
1025
+ item: z.ZodString;
1026
+ label: z.ZodString;
1027
+ }, z.core.$strict>>;
1028
+ }, z.core.$strict>>;
1029
+ }, z.core.$strict>], "kind">;
1030
+ }, z.core.$strict>;
1031
+ declare const entitlementSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1032
+ status: z.ZodLiteral<"available">;
1033
+ id: z.ZodString;
1034
+ member: z.ZodString;
1035
+ reward: z.ZodObject<{
1036
+ id: z.ZodString;
1037
+ title: z.ZodString;
1038
+ tiers: z.ZodArray<z.ZodObject<{
1039
+ id: z.ZodString;
1040
+ title: z.ZodString;
1041
+ }, z.core.$strict>>;
1042
+ inventory: z.ZodObject<{
1043
+ kind: z.ZodLiteral<"untracked">;
1044
+ }, z.core.$strict>;
1045
+ fulfillment: z.ZodObject<{
1046
+ kind: z.ZodLiteral<"staff-handover">;
1047
+ }, z.core.$strict>;
1048
+ }, z.core.$strict>;
1049
+ earnedTier: z.ZodString;
1050
+ tier: z.ZodString;
1051
+ revision: z.ZodNumber;
1052
+ }, z.core.$strict>, z.ZodObject<{
1053
+ status: z.ZodLiteral<"handing-over">;
1054
+ handover: z.ZodString;
1055
+ startedAt: z.ZodNumber;
1056
+ allocation: z.ZodOptional<z.ZodObject<{
1057
+ item: z.ZodString;
1058
+ label: z.ZodString;
1059
+ }, z.core.$strict>>;
1060
+ id: z.ZodString;
1061
+ member: z.ZodString;
1062
+ reward: z.ZodObject<{
1063
+ id: z.ZodString;
1064
+ title: z.ZodString;
1065
+ tiers: z.ZodArray<z.ZodObject<{
1066
+ id: z.ZodString;
1067
+ title: z.ZodString;
1068
+ }, z.core.$strict>>;
1069
+ inventory: z.ZodObject<{
1070
+ kind: z.ZodLiteral<"untracked">;
1071
+ }, z.core.$strict>;
1072
+ fulfillment: z.ZodObject<{
1073
+ kind: z.ZodLiteral<"staff-handover">;
1074
+ }, z.core.$strict>;
1075
+ }, z.core.$strict>;
1076
+ earnedTier: z.ZodString;
1077
+ tier: z.ZodString;
1078
+ revision: z.ZodNumber;
1079
+ }, z.core.$strict>, z.ZodObject<{
1080
+ status: z.ZodLiteral<"collected">;
1081
+ handover: z.ZodString;
1082
+ startedAt: z.ZodNumber;
1083
+ allocation: z.ZodOptional<z.ZodObject<{
1084
+ item: z.ZodString;
1085
+ label: z.ZodString;
1086
+ }, z.core.$strict>>;
1087
+ collectedAt: z.ZodNumber;
1088
+ id: z.ZodString;
1089
+ member: z.ZodString;
1090
+ reward: z.ZodObject<{
1091
+ id: z.ZodString;
1092
+ title: z.ZodString;
1093
+ tiers: z.ZodArray<z.ZodObject<{
1094
+ id: z.ZodString;
1095
+ title: z.ZodString;
1096
+ }, z.core.$strict>>;
1097
+ inventory: z.ZodObject<{
1098
+ kind: z.ZodLiteral<"untracked">;
1099
+ }, z.core.$strict>;
1100
+ fulfillment: z.ZodObject<{
1101
+ kind: z.ZodLiteral<"staff-handover">;
1102
+ }, z.core.$strict>;
1103
+ }, z.core.$strict>;
1104
+ earnedTier: z.ZodString;
1105
+ tier: z.ZodString;
1106
+ revision: z.ZodNumber;
1107
+ }, z.core.$strict>], "status">;
1108
+ type Entitlement = z.infer<typeof entitlementSchema>;
1109
+ declare const beginHandoverSchema: z.ZodObject<{
1110
+ actionId: z.ZodString;
1111
+ revision: z.ZodNumber;
1112
+ selection: z.ZodOptional<z.ZodObject<{
1113
+ item: z.ZodString;
1114
+ revision: z.ZodNumber;
1115
+ }, z.core.$strict>>;
1116
+ }, z.core.$strict>;
1117
+ declare const confirmHandoverSchema: z.ZodObject<{
1118
+ actionId: z.ZodString;
1119
+ handover: z.ZodString;
1120
+ }, z.core.$strict>;
1121
+ declare const completionRecordSchema: z.ZodObject<{
1122
+ id: z.ZodString;
1123
+ quest: z.ZodString;
1124
+ member: z.ZodString;
1125
+ }, z.core.$strip>;
1126
+ declare const questAvailabilitySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1127
+ kind: z.ZodLiteral<"available">;
1128
+ input: z.ZodEnum<{
1129
+ photo: "photo";
1130
+ quiz: "quiz";
1131
+ none: "none";
1132
+ }>;
1133
+ }, z.core.$strict>, z.ZodObject<{
1134
+ kind: z.ZodLiteral<"completed">;
1135
+ }, z.core.$strict>, z.ZodObject<{
1136
+ kind: z.ZodLiteral<"locked">;
1137
+ missing: z.ZodArray<z.ZodObject<{
1138
+ quest: z.ZodString;
1139
+ title: z.ZodString;
1140
+ }, z.core.$strip>>;
1141
+ }, z.core.$strict>, z.ZodObject<{
1142
+ kind: z.ZodLiteral<"staff-required">;
1143
+ }, z.core.$strict>, z.ZodObject<{
1144
+ kind: z.ZodLiteral<"automatic">;
1145
+ }, z.core.$strict>, z.ZodObject<{
1146
+ kind: z.ZodLiteral<"checking">;
1147
+ attempt: z.ZodString;
1148
+ }, z.core.$strict>, z.ZodObject<{
1149
+ kind: z.ZodLiteral<"needs-review">;
1150
+ attempt: z.ZodString;
1151
+ }, z.core.$strict>, z.ZodObject<{
1152
+ kind: z.ZodLiteral<"retryable">;
1153
+ attempt: z.ZodString;
1154
+ }, z.core.$strict>], "kind">;
1155
+ type QuestAvailability = z.infer<typeof questAvailabilitySchema>;
1156
+ declare const memberProgressSchema: z.ZodObject<{
1157
+ member: z.ZodString;
1158
+ quests: z.ZodArray<z.ZodObject<{
1159
+ quest: z.ZodString;
1160
+ release: z.ZodOptional<z.ZodString>;
1161
+ title: z.ZodString;
1162
+ presentation: z.ZodDefault<z.ZodObject<{
1163
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
1164
+ id: z.ZodString;
1165
+ prompt: z.ZodString;
1166
+ choices: z.ZodArray<z.ZodObject<{
1167
+ id: z.ZodString;
1168
+ label: z.ZodString;
1169
+ }, z.core.$strict>>;
1170
+ }, z.core.$strict>>>;
1171
+ instructions: z.ZodOptional<z.ZodString>;
1172
+ video: z.ZodOptional<z.ZodObject<{
1173
+ url: z.ZodString;
1174
+ poster: z.ZodOptional<z.ZodString>;
1175
+ captions: z.ZodOptional<z.ZodObject<{
1176
+ url: z.ZodString;
1177
+ language: z.ZodString;
1178
+ label: z.ZodString;
1179
+ }, z.core.$strict>>;
1180
+ }, z.core.$strict>>;
1181
+ }, z.core.$strict>>;
1182
+ trigger: z.ZodUnion<readonly [z.ZodObject<{
1183
+ kind: z.ZodLiteral<"manual">;
1184
+ input: z.ZodEnum<{
1185
+ photo: "photo";
1186
+ quiz: "quiz";
1187
+ none: "none";
1188
+ }>;
1189
+ actor: z.ZodOptional<z.ZodEnum<{
1190
+ member: "member";
1191
+ staff: "staff";
1192
+ }>>;
1193
+ }, z.core.$strict>, z.ZodObject<{
1194
+ kind: z.ZodLiteral<"automatic">;
1195
+ }, z.core.$strict>]>;
1196
+ availability: z.ZodDiscriminatedUnion<[z.ZodObject<{
1197
+ kind: z.ZodLiteral<"available">;
1198
+ input: z.ZodEnum<{
1199
+ photo: "photo";
1200
+ quiz: "quiz";
1201
+ none: "none";
1202
+ }>;
1203
+ }, z.core.$strict>, z.ZodObject<{
1204
+ kind: z.ZodLiteral<"completed">;
1205
+ }, z.core.$strict>, z.ZodObject<{
1206
+ kind: z.ZodLiteral<"locked">;
1207
+ missing: z.ZodArray<z.ZodObject<{
1208
+ quest: z.ZodString;
1209
+ title: z.ZodString;
1210
+ }, z.core.$strip>>;
1211
+ }, z.core.$strict>, z.ZodObject<{
1212
+ kind: z.ZodLiteral<"staff-required">;
1213
+ }, z.core.$strict>, z.ZodObject<{
1214
+ kind: z.ZodLiteral<"automatic">;
1215
+ }, z.core.$strict>, z.ZodObject<{
1216
+ kind: z.ZodLiteral<"checking">;
1217
+ attempt: z.ZodString;
1218
+ }, z.core.$strict>, z.ZodObject<{
1219
+ kind: z.ZodLiteral<"needs-review">;
1220
+ attempt: z.ZodString;
1221
+ }, z.core.$strict>, z.ZodObject<{
1222
+ kind: z.ZodLiteral<"retryable">;
1223
+ attempt: z.ZodString;
1224
+ }, z.core.$strict>], "kind">;
1225
+ completed: z.ZodBoolean;
1226
+ missing: z.ZodArray<z.ZodObject<{
1227
+ quest: z.ZodString;
1228
+ title: z.ZodString;
1229
+ }, z.core.$strip>>;
1230
+ attempt: z.ZodNullable<z.ZodObject<{
1231
+ id: z.ZodString;
1232
+ release: z.ZodString;
1233
+ quest: z.ZodString;
1234
+ member: z.ZodString;
1235
+ evidence: z.ZodNullable<z.ZodString>;
1236
+ input: z.ZodOptional<z.ZodObject<{
1237
+ kind: z.ZodLiteral<"quiz">;
1238
+ release: z.ZodOptional<z.ZodString>;
1239
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
1240
+ [k: string]: string;
1241
+ }, Record<string, string>>>;
1242
+ }, z.core.$strict>>;
1243
+ status: z.ZodEnum<{
1244
+ queued: "queued";
1245
+ evaluating: "evaluating";
1246
+ accepted: "accepted";
1247
+ rejected: "rejected";
1248
+ "needs-review": "needs-review";
1249
+ failed: "failed";
1250
+ }>;
1251
+ reason: z.ZodNullable<z.ZodString>;
1252
+ retries: z.ZodNumber;
1253
+ generation: z.ZodNumber;
1254
+ completion: z.ZodNullable<z.ZodString>;
1255
+ reviewRewards: z.ZodDefault<z.ZodNullable<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1256
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
1257
+ balance: z.ZodString;
1258
+ amount: z.ZodNumber;
1259
+ }, z.core.$strict>, z.ZodObject<{
1260
+ kind: z.ZodLiteral<"tier">;
1261
+ reward: z.ZodObject<{
1262
+ id: z.ZodString;
1263
+ title: z.ZodString;
1264
+ tiers: z.ZodArray<z.ZodObject<{
1265
+ id: z.ZodString;
1266
+ title: z.ZodString;
1267
+ }, z.core.$strict>>;
1268
+ inventory: z.ZodObject<{
1269
+ kind: z.ZodLiteral<"untracked">;
1270
+ }, z.core.$strict>;
1271
+ fulfillment: z.ZodObject<{
1272
+ kind: z.ZodLiteral<"staff-handover">;
1273
+ }, z.core.$strict>;
1274
+ }, z.core.$strict>;
1275
+ tier: z.ZodString;
1276
+ }, z.core.$strict>]>>>>;
1277
+ createdAt: z.ZodNumber;
1278
+ }, z.core.$strip>>;
1279
+ }, z.core.$strip>>;
1280
+ entitlements: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
1281
+ status: z.ZodLiteral<"available">;
1282
+ id: z.ZodString;
1283
+ member: z.ZodString;
1284
+ reward: z.ZodObject<{
1285
+ id: z.ZodString;
1286
+ title: z.ZodString;
1287
+ tiers: z.ZodArray<z.ZodObject<{
1288
+ id: z.ZodString;
1289
+ title: z.ZodString;
1290
+ }, z.core.$strict>>;
1291
+ inventory: z.ZodObject<{
1292
+ kind: z.ZodLiteral<"untracked">;
1293
+ }, z.core.$strict>;
1294
+ fulfillment: z.ZodObject<{
1295
+ kind: z.ZodLiteral<"staff-handover">;
1296
+ }, z.core.$strict>;
1297
+ }, z.core.$strict>;
1298
+ earnedTier: z.ZodString;
1299
+ tier: z.ZodString;
1300
+ revision: z.ZodNumber;
1301
+ }, z.core.$strict>, z.ZodObject<{
1302
+ status: z.ZodLiteral<"handing-over">;
1303
+ handover: z.ZodString;
1304
+ startedAt: z.ZodNumber;
1305
+ allocation: z.ZodOptional<z.ZodObject<{
1306
+ item: z.ZodString;
1307
+ label: z.ZodString;
1308
+ }, z.core.$strict>>;
1309
+ id: z.ZodString;
1310
+ member: z.ZodString;
1311
+ reward: z.ZodObject<{
1312
+ id: z.ZodString;
1313
+ title: z.ZodString;
1314
+ tiers: z.ZodArray<z.ZodObject<{
1315
+ id: z.ZodString;
1316
+ title: z.ZodString;
1317
+ }, z.core.$strict>>;
1318
+ inventory: z.ZodObject<{
1319
+ kind: z.ZodLiteral<"untracked">;
1320
+ }, z.core.$strict>;
1321
+ fulfillment: z.ZodObject<{
1322
+ kind: z.ZodLiteral<"staff-handover">;
1323
+ }, z.core.$strict>;
1324
+ }, z.core.$strict>;
1325
+ earnedTier: z.ZodString;
1326
+ tier: z.ZodString;
1327
+ revision: z.ZodNumber;
1328
+ }, z.core.$strict>, z.ZodObject<{
1329
+ status: z.ZodLiteral<"collected">;
1330
+ handover: z.ZodString;
1331
+ startedAt: z.ZodNumber;
1332
+ allocation: z.ZodOptional<z.ZodObject<{
1333
+ item: z.ZodString;
1334
+ label: z.ZodString;
1335
+ }, z.core.$strict>>;
1336
+ collectedAt: z.ZodNumber;
1337
+ id: z.ZodString;
1338
+ member: z.ZodString;
1339
+ reward: z.ZodObject<{
1340
+ id: z.ZodString;
1341
+ title: z.ZodString;
1342
+ tiers: z.ZodArray<z.ZodObject<{
1343
+ id: z.ZodString;
1344
+ title: z.ZodString;
1345
+ }, z.core.$strict>>;
1346
+ inventory: z.ZodObject<{
1347
+ kind: z.ZodLiteral<"untracked">;
1348
+ }, z.core.$strict>;
1349
+ fulfillment: z.ZodObject<{
1350
+ kind: z.ZodLiteral<"staff-handover">;
1351
+ }, z.core.$strict>;
1352
+ }, z.core.$strict>;
1353
+ earnedTier: z.ZodString;
1354
+ tier: z.ZodString;
1355
+ revision: z.ZodNumber;
1356
+ }, z.core.$strict>], "status">>;
1357
+ }, z.core.$strip>;
1358
+ declare const snapshotSchema: z.ZodObject<{
1359
+ releases: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1360
+ quest: z.ZodString;
1361
+ runtimeVersion: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>;
1362
+ title: z.ZodString;
1363
+ presentation: z.ZodDefault<z.ZodObject<{
1364
+ quiz: z.ZodOptional<z.ZodArray<z.ZodObject<{
1365
+ id: z.ZodString;
1366
+ prompt: z.ZodString;
1367
+ choices: z.ZodArray<z.ZodObject<{
1368
+ id: z.ZodString;
1369
+ label: z.ZodString;
1370
+ }, z.core.$strict>>;
1371
+ }, z.core.$strict>>>;
1372
+ instructions: z.ZodOptional<z.ZodString>;
1373
+ video: z.ZodOptional<z.ZodObject<{
1374
+ url: z.ZodString;
1375
+ poster: z.ZodOptional<z.ZodString>;
1376
+ captions: z.ZodOptional<z.ZodObject<{
1377
+ url: z.ZodString;
1378
+ language: z.ZodString;
1379
+ label: z.ZodString;
1380
+ }, z.core.$strict>>;
1381
+ }, z.core.$strict>>;
1382
+ }, z.core.$strict>>;
1383
+ fields: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
1384
+ kind: z.ZodLiteral<"quiz">;
1385
+ default: z.ZodArray<z.ZodObject<{
1386
+ id: z.ZodString;
1387
+ prompt: z.ZodString;
1388
+ choices: z.ZodArray<z.ZodObject<{
1389
+ id: z.ZodString;
1390
+ label: z.ZodString;
1391
+ }, z.core.$strict>>;
1392
+ correct: z.ZodString;
1393
+ }, z.core.$strict>>;
1394
+ label: z.ZodString;
1395
+ description: z.ZodOptional<z.ZodString>;
1396
+ }, z.core.$strict>, z.ZodObject<{
1397
+ kind: z.ZodLiteral<"text">;
1398
+ default: z.ZodString;
1399
+ minLength: z.ZodNumber;
1400
+ maxLength: z.ZodNumber;
1401
+ multiline: z.ZodBoolean;
1402
+ label: z.ZodString;
1403
+ description: z.ZodOptional<z.ZodString>;
1404
+ }, z.core.$strict>, z.ZodObject<{
1405
+ kind: z.ZodLiteral<"integer">;
1406
+ default: z.ZodNumber;
1407
+ min: z.ZodNumber;
1408
+ max: z.ZodNumber;
1409
+ label: z.ZodString;
1410
+ description: z.ZodOptional<z.ZodString>;
1411
+ }, z.core.$strict>, z.ZodObject<{
1412
+ kind: z.ZodLiteral<"boolean">;
1413
+ default: z.ZodBoolean;
1414
+ label: z.ZodString;
1415
+ description: z.ZodOptional<z.ZodString>;
1416
+ }, z.core.$strict>, z.ZodObject<{
1417
+ kind: z.ZodLiteral<"choice">;
1418
+ default: z.ZodString;
1419
+ options: z.ZodArray<z.ZodString>;
1420
+ label: z.ZodString;
1421
+ description: z.ZodOptional<z.ZodString>;
1422
+ }, z.core.$strict>], "kind">>;
1423
+ values: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
1424
+ id: z.ZodString;
1425
+ prompt: z.ZodString;
1426
+ choices: z.ZodArray<z.ZodObject<{
1427
+ id: z.ZodString;
1428
+ label: z.ZodString;
1429
+ }, z.core.$strict>>;
1430
+ correct: z.ZodString;
1431
+ }, z.core.$strict>>]>>;
1432
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1433
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
1434
+ balance: z.ZodString;
1435
+ amount: z.ZodNumber;
1436
+ }, z.core.$strict>, z.ZodObject<{
1437
+ kind: z.ZodLiteral<"tier">;
1438
+ reward: z.ZodObject<{
1439
+ id: z.ZodString;
1440
+ title: z.ZodString;
1441
+ tiers: z.ZodArray<z.ZodObject<{
1442
+ id: z.ZodString;
1443
+ title: z.ZodString;
1444
+ }, z.core.$strict>>;
1445
+ inventory: z.ZodObject<{
1446
+ kind: z.ZodLiteral<"untracked">;
1447
+ }, z.core.$strict>;
1448
+ fulfillment: z.ZodObject<{
1449
+ kind: z.ZodLiteral<"staff-handover">;
1450
+ }, z.core.$strict>;
1451
+ }, z.core.$strict>;
1452
+ tier: z.ZodString;
1453
+ }, z.core.$strict>]>>;
1454
+ humanReview: z.ZodBoolean;
1455
+ trigger: z.ZodUnion<readonly [z.ZodObject<{
1456
+ kind: z.ZodLiteral<"manual">;
1457
+ input: z.ZodEnum<{
1458
+ photo: "photo";
1459
+ quiz: "quiz";
1460
+ none: "none";
1461
+ }>;
1462
+ actor: z.ZodOptional<z.ZodEnum<{
1463
+ member: "member";
1464
+ staff: "staff";
1465
+ }>>;
1466
+ }, z.core.$strict>, z.ZodObject<{
1467
+ kind: z.ZodLiteral<"automatic">;
1468
+ }, z.core.$strict>]>;
1469
+ requires: z.ZodDefault<z.ZodArray<z.ZodObject<{
1470
+ quest: z.ZodString;
1471
+ scope: z.ZodLiteral<"ever">;
1472
+ }, z.core.$strict>>>;
1473
+ completion: z.ZodObject<{
1474
+ kind: z.ZodLiteral<"once">;
1475
+ }, z.core.$strict>;
1476
+ code: z.ZodString;
1477
+ provider: z.ZodEnum<{
1478
+ "fixture-pass": "fixture-pass";
1479
+ "fixture-fail": "fixture-fail";
1480
+ "fixture-unclear": "fixture-unclear";
1481
+ "fixture-error": "fixture-error";
1482
+ "workers-ai": "workers-ai";
1483
+ }>;
1484
+ id: z.ZodString;
1485
+ createdAt: z.ZodNumber;
1486
+ legacy: z.ZodDefault<z.ZodBoolean>;
1487
+ origin: z.ZodOptional<z.ZodObject<{
1488
+ typeVersion: z.ZodString;
1489
+ }, z.core.$strict>>;
1490
+ lifecycle: z.ZodDefault<z.ZodEnum<{
1491
+ active: "active";
1492
+ paused: "paused";
1493
+ archived: "archived";
1494
+ }>>;
1495
+ configuration: z.ZodOptional<z.ZodObject<{
1496
+ defaults: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
1497
+ id: z.ZodString;
1498
+ prompt: z.ZodString;
1499
+ choices: z.ZodArray<z.ZodObject<{
1500
+ id: z.ZodString;
1501
+ label: z.ZodString;
1502
+ }, z.core.$strict>>;
1503
+ correct: z.ZodString;
1504
+ }, z.core.$strict>>]>>;
1505
+ overrides: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodObject<{
1506
+ id: z.ZodString;
1507
+ prompt: z.ZodString;
1508
+ choices: z.ZodArray<z.ZodObject<{
1509
+ id: z.ZodString;
1510
+ label: z.ZodString;
1511
+ }, z.core.$strict>>;
1512
+ correct: z.ZodString;
1513
+ }, z.core.$strict>>]>>;
1514
+ preserved: z.ZodArray<z.ZodString>;
1515
+ }, z.core.$strict>>;
1516
+ }, z.core.$strict>, z.ZodPipe<z.ZodObject<{
1517
+ quest: z.ZodString;
1518
+ title: z.ZodString;
1519
+ criteria: z.ZodString;
1520
+ humanReview: z.ZodBoolean;
1521
+ rewards: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1522
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
1523
+ balance: z.ZodString;
1524
+ amount: z.ZodNumber;
1525
+ }, z.core.$strict>, z.ZodObject<{
1526
+ kind: z.ZodLiteral<"tier">;
1527
+ reward: z.ZodObject<{
1528
+ id: z.ZodString;
1529
+ title: z.ZodString;
1530
+ tiers: z.ZodArray<z.ZodObject<{
1531
+ id: z.ZodString;
1532
+ title: z.ZodString;
1533
+ }, z.core.$strict>>;
1534
+ inventory: z.ZodObject<{
1535
+ kind: z.ZodLiteral<"untracked">;
1536
+ }, z.core.$strict>;
1537
+ fulfillment: z.ZodObject<{
1538
+ kind: z.ZodLiteral<"staff-handover">;
1539
+ }, z.core.$strict>;
1540
+ }, z.core.$strict>;
1541
+ tier: z.ZodString;
1542
+ }, z.core.$strict>]>>;
1543
+ code: z.ZodString;
1544
+ provider: z.ZodEnum<{
1545
+ "fixture-pass": "fixture-pass";
1546
+ "fixture-fail": "fixture-fail";
1547
+ "fixture-unclear": "fixture-unclear";
1548
+ "fixture-error": "fixture-error";
1549
+ "workers-ai": "workers-ai";
1550
+ }>;
1551
+ id: z.ZodString;
1552
+ createdAt: z.ZodNumber;
1553
+ }, z.core.$strip>, z.ZodTransform<{
1554
+ quest: string;
1555
+ runtimeVersion: 1 | 2;
1556
+ title: string;
1557
+ presentation: {
1558
+ quiz?: {
1559
+ id: string;
1560
+ prompt: string;
1561
+ choices: {
1562
+ id: string;
1563
+ label: string;
1564
+ }[];
1565
+ }[] | undefined;
1566
+ instructions?: string | undefined;
1567
+ video?: {
1568
+ url: string;
1569
+ poster?: string | undefined;
1570
+ captions?: {
1571
+ url: string;
1572
+ language: string;
1573
+ label: string;
1574
+ } | undefined;
1575
+ } | undefined;
1576
+ };
1577
+ fields: Record<string, {
1578
+ kind: "quiz";
1579
+ default: {
1580
+ id: string;
1581
+ prompt: string;
1582
+ choices: {
1583
+ id: string;
1584
+ label: string;
1585
+ }[];
1586
+ correct: string;
1587
+ }[];
1588
+ label: string;
1589
+ description?: string | undefined;
1590
+ } | {
1591
+ kind: "text";
1592
+ default: string;
1593
+ minLength: number;
1594
+ maxLength: number;
1595
+ multiline: boolean;
1596
+ label: string;
1597
+ description?: string | undefined;
1598
+ } | {
1599
+ kind: "integer";
1600
+ default: number;
1601
+ min: number;
1602
+ max: number;
1603
+ label: string;
1604
+ description?: string | undefined;
1605
+ } | {
1606
+ kind: "boolean";
1607
+ default: boolean;
1608
+ label: string;
1609
+ description?: string | undefined;
1610
+ } | {
1611
+ kind: "choice";
1612
+ default: string;
1613
+ options: string[];
1614
+ label: string;
1615
+ description?: string | undefined;
1616
+ }>;
1617
+ values: Record<string, string | number | boolean | {
1618
+ id: string;
1619
+ prompt: string;
1620
+ choices: {
1621
+ id: string;
1622
+ label: string;
1623
+ }[];
1624
+ correct: string;
1625
+ }[]>;
1626
+ rewards: ({
1627
+ kind: "tier";
1628
+ reward: {
1629
+ id: string;
1630
+ title: string;
1631
+ tiers: {
1632
+ id: string;
1633
+ title: string;
1634
+ }[];
1635
+ inventory: {
1636
+ kind: "untracked";
1637
+ };
1638
+ fulfillment: {
1639
+ kind: "staff-handover";
1640
+ };
1641
+ };
1642
+ tier: string;
1643
+ } | {
1644
+ kind: "points";
1645
+ balance: string;
1646
+ amount: number;
1647
+ })[];
1648
+ humanReview: boolean;
1649
+ trigger: {
1650
+ kind: "manual";
1651
+ input: "photo" | "quiz" | "none";
1652
+ actor?: "member" | "staff" | undefined;
1653
+ } | {
1654
+ kind: "automatic";
1655
+ };
1656
+ requires: {
1657
+ quest: string;
1658
+ scope: "ever";
1659
+ }[];
1660
+ completion: {
1661
+ kind: "once";
1662
+ };
1663
+ code: string;
1664
+ provider: "fixture-pass" | "fixture-fail" | "fixture-unclear" | "fixture-error" | "workers-ai";
1665
+ id: string;
1666
+ createdAt: number;
1667
+ legacy: boolean;
1668
+ lifecycle: "active" | "paused" | "archived";
1669
+ origin?: {
1670
+ typeVersion: string;
1671
+ } | undefined;
1672
+ configuration?: {
1673
+ defaults: Record<string, string | number | boolean | {
1674
+ id: string;
1675
+ prompt: string;
1676
+ choices: {
1677
+ id: string;
1678
+ label: string;
1679
+ }[];
1680
+ correct: string;
1681
+ }[]>;
1682
+ overrides: Record<string, string | number | boolean | {
1683
+ id: string;
1684
+ prompt: string;
1685
+ choices: {
1686
+ id: string;
1687
+ label: string;
1688
+ }[];
1689
+ correct: string;
1690
+ }[]>;
1691
+ preserved: string[];
1692
+ } | undefined;
1693
+ }, {
1694
+ quest: string;
1695
+ title: string;
1696
+ criteria: string;
1697
+ humanReview: boolean;
1698
+ rewards: ({
1699
+ kind: "tier";
1700
+ reward: {
1701
+ id: string;
1702
+ title: string;
1703
+ tiers: {
1704
+ id: string;
1705
+ title: string;
1706
+ }[];
1707
+ inventory: {
1708
+ kind: "untracked";
1709
+ };
1710
+ fulfillment: {
1711
+ kind: "staff-handover";
1712
+ };
1713
+ };
1714
+ tier: string;
1715
+ } | {
1716
+ kind: "points";
1717
+ balance: string;
1718
+ amount: number;
1719
+ })[];
1720
+ code: string;
1721
+ provider: "fixture-pass" | "fixture-fail" | "fixture-unclear" | "fixture-error" | "workers-ai";
1722
+ id: string;
1723
+ createdAt: number;
1724
+ }>>]>>;
1725
+ completions: z.ZodArray<z.ZodObject<{
1726
+ id: z.ZodString;
1727
+ quest: z.ZodString;
1728
+ member: z.ZodString;
1729
+ }, z.core.$strip>>;
1730
+ entitlements: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
1731
+ status: z.ZodLiteral<"available">;
1732
+ id: z.ZodString;
1733
+ member: z.ZodString;
1734
+ reward: z.ZodObject<{
1735
+ id: z.ZodString;
1736
+ title: z.ZodString;
1737
+ tiers: z.ZodArray<z.ZodObject<{
1738
+ id: z.ZodString;
1739
+ title: z.ZodString;
1740
+ }, z.core.$strict>>;
1741
+ inventory: z.ZodObject<{
1742
+ kind: z.ZodLiteral<"untracked">;
1743
+ }, z.core.$strict>;
1744
+ fulfillment: z.ZodObject<{
1745
+ kind: z.ZodLiteral<"staff-handover">;
1746
+ }, z.core.$strict>;
1747
+ }, z.core.$strict>;
1748
+ earnedTier: z.ZodString;
1749
+ tier: z.ZodString;
1750
+ revision: z.ZodNumber;
1751
+ }, z.core.$strict>, z.ZodObject<{
1752
+ status: z.ZodLiteral<"handing-over">;
1753
+ handover: z.ZodString;
1754
+ startedAt: z.ZodNumber;
1755
+ allocation: z.ZodOptional<z.ZodObject<{
1756
+ item: z.ZodString;
1757
+ label: z.ZodString;
1758
+ }, z.core.$strict>>;
1759
+ id: z.ZodString;
1760
+ member: z.ZodString;
1761
+ reward: z.ZodObject<{
1762
+ id: z.ZodString;
1763
+ title: z.ZodString;
1764
+ tiers: z.ZodArray<z.ZodObject<{
1765
+ id: z.ZodString;
1766
+ title: z.ZodString;
1767
+ }, z.core.$strict>>;
1768
+ inventory: z.ZodObject<{
1769
+ kind: z.ZodLiteral<"untracked">;
1770
+ }, z.core.$strict>;
1771
+ fulfillment: z.ZodObject<{
1772
+ kind: z.ZodLiteral<"staff-handover">;
1773
+ }, z.core.$strict>;
1774
+ }, z.core.$strict>;
1775
+ earnedTier: z.ZodString;
1776
+ tier: z.ZodString;
1777
+ revision: z.ZodNumber;
1778
+ }, z.core.$strict>, z.ZodObject<{
1779
+ status: z.ZodLiteral<"collected">;
1780
+ handover: z.ZodString;
1781
+ startedAt: z.ZodNumber;
1782
+ allocation: z.ZodOptional<z.ZodObject<{
1783
+ item: z.ZodString;
1784
+ label: z.ZodString;
1785
+ }, z.core.$strict>>;
1786
+ collectedAt: z.ZodNumber;
1787
+ id: z.ZodString;
1788
+ member: z.ZodString;
1789
+ reward: z.ZodObject<{
1790
+ id: z.ZodString;
1791
+ title: z.ZodString;
1792
+ tiers: z.ZodArray<z.ZodObject<{
1793
+ id: z.ZodString;
1794
+ title: z.ZodString;
1795
+ }, z.core.$strict>>;
1796
+ inventory: z.ZodObject<{
1797
+ kind: z.ZodLiteral<"untracked">;
1798
+ }, z.core.$strict>;
1799
+ fulfillment: z.ZodObject<{
1800
+ kind: z.ZodLiteral<"staff-handover">;
1801
+ }, z.core.$strict>;
1802
+ }, z.core.$strict>;
1803
+ earnedTier: z.ZodString;
1804
+ tier: z.ZodString;
1805
+ revision: z.ZodNumber;
1806
+ }, z.core.$strict>], "status">>;
1807
+ attempts: z.ZodArray<z.ZodObject<{
1808
+ id: z.ZodString;
1809
+ release: z.ZodString;
1810
+ quest: z.ZodString;
1811
+ member: z.ZodString;
1812
+ evidence: z.ZodNullable<z.ZodString>;
1813
+ input: z.ZodOptional<z.ZodObject<{
1814
+ kind: z.ZodLiteral<"quiz">;
1815
+ release: z.ZodOptional<z.ZodString>;
1816
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
1817
+ [k: string]: string;
1818
+ }, Record<string, string>>>;
1819
+ }, z.core.$strict>>;
1820
+ status: z.ZodEnum<{
1821
+ queued: "queued";
1822
+ evaluating: "evaluating";
1823
+ accepted: "accepted";
1824
+ rejected: "rejected";
1825
+ "needs-review": "needs-review";
1826
+ failed: "failed";
1827
+ }>;
1828
+ reason: z.ZodNullable<z.ZodString>;
1829
+ retries: z.ZodNumber;
1830
+ generation: z.ZodNumber;
1831
+ completion: z.ZodNullable<z.ZodString>;
1832
+ reviewRewards: z.ZodDefault<z.ZodNullable<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1833
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
1834
+ balance: z.ZodString;
1835
+ amount: z.ZodNumber;
1836
+ }, z.core.$strict>, z.ZodObject<{
1837
+ kind: z.ZodLiteral<"tier">;
1838
+ reward: z.ZodObject<{
1839
+ id: z.ZodString;
1840
+ title: z.ZodString;
1841
+ tiers: z.ZodArray<z.ZodObject<{
1842
+ id: z.ZodString;
1843
+ title: z.ZodString;
1844
+ }, z.core.$strict>>;
1845
+ inventory: z.ZodObject<{
1846
+ kind: z.ZodLiteral<"untracked">;
1847
+ }, z.core.$strict>;
1848
+ fulfillment: z.ZodObject<{
1849
+ kind: z.ZodLiteral<"staff-handover">;
1850
+ }, z.core.$strict>;
1851
+ }, z.core.$strict>;
1852
+ tier: z.ZodString;
1853
+ }, z.core.$strict>]>>>>;
1854
+ createdAt: z.ZodNumber;
1855
+ }, z.core.$strip>>;
1856
+ balances: z.ZodArray<z.ZodObject<{
1857
+ member: z.ZodString;
1858
+ balance: z.ZodString;
1859
+ earned: z.ZodNumber;
1860
+ held: z.ZodNumber;
1861
+ available: z.ZodNumber;
1862
+ }, z.core.$strip>>;
1863
+ events: z.ZodArray<z.ZodObject<{
1864
+ id: z.ZodNumber;
1865
+ attempt: z.ZodNullable<z.ZodString>;
1866
+ kind: z.ZodString;
1867
+ detail: z.ZodString;
1868
+ actor: z.ZodDefault<z.ZodNullable<z.ZodString>>;
1869
+ at: z.ZodNumber;
1870
+ }, z.core.$strip>>;
1871
+ }, z.core.$strip>;
1872
+ type Snapshot = z.infer<typeof snapshotSchema>;
1873
+ declare const evidenceSchema: z.ZodObject<{
1874
+ id: z.ZodString;
1875
+ member: z.ZodString;
1876
+ type: z.ZodEnum<{
1877
+ "image/jpeg": "image/jpeg";
1878
+ "image/png": "image/png";
1879
+ }>;
1880
+ size: z.ZodNumber;
1881
+ }, z.core.$strip>;
1882
+ declare const errorSchema: z.ZodObject<{
1883
+ error: z.ZodString;
1884
+ code: z.ZodOptional<z.ZodEnum<{
1885
+ "stale-quiz": "stale-quiz";
1886
+ "quest-updated": "quest-updated";
1887
+ }>>;
1888
+ missing: z.ZodOptional<z.ZodArray<z.ZodObject<{
1889
+ quest: z.ZodString;
1890
+ title: z.ZodString;
1891
+ }, z.core.$strip>>>;
1892
+ }, z.core.$strip>;
1893
+ declare const staffDecisionSchema: z.ZodObject<{
1894
+ actionId: z.ZodString;
1895
+ generation: z.ZodNumber;
1896
+ decision: z.ZodEnum<{
1897
+ accept: "accept";
1898
+ reject: "reject";
1899
+ }>;
1900
+ reason: z.ZodString;
1901
+ }, z.core.$strict>;
1902
+ declare const stockSchema: z.ZodObject<{
1903
+ item: z.ZodString;
1904
+ quantity: z.ZodNumber;
1905
+ }, z.core.$strict>;
1906
+ declare const reservationSchema: z.ZodObject<{
1907
+ actionId: z.ZodString;
1908
+ member: z.ZodString;
1909
+ item: z.ZodString;
1910
+ balance: z.ZodString;
1911
+ price: z.ZodNumber;
1912
+ }, z.core.$strict>;
1913
+ type MemberProgress = z.infer<typeof memberProgressSchema>;
1914
+ declare const reviewListSchema: z.ZodObject<{
1915
+ member: z.ZodOptional<z.ZodString>;
1916
+ quest: z.ZodOptional<z.ZodString>;
1917
+ limit: z.ZodDefault<z.ZodNumber>;
1918
+ cursor: z.ZodOptional<z.ZodString>;
1919
+ }, z.core.$strict>;
1920
+ declare const memberListSchema: z.ZodObject<{
1921
+ prefix: z.ZodOptional<z.ZodString>;
1922
+ limit: z.ZodDefault<z.ZodNumber>;
1923
+ cursor: z.ZodOptional<z.ZodString>;
1924
+ }, z.core.$strict>;
1925
+ type ReviewListOptions = z.input<typeof reviewListSchema>;
1926
+ type MemberListOptions = z.input<typeof memberListSchema>;
1927
+ declare const reviewItemSchema: z.ZodObject<{
1928
+ attempt: z.ZodObject<{
1929
+ id: z.ZodString;
1930
+ release: z.ZodString;
1931
+ quest: z.ZodString;
1932
+ member: z.ZodString;
1933
+ evidence: z.ZodNullable<z.ZodString>;
1934
+ input: z.ZodOptional<z.ZodObject<{
1935
+ kind: z.ZodLiteral<"quiz">;
1936
+ release: z.ZodOptional<z.ZodString>;
1937
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
1938
+ [k: string]: string;
1939
+ }, Record<string, string>>>;
1940
+ }, z.core.$strict>>;
1941
+ status: z.ZodEnum<{
1942
+ queued: "queued";
1943
+ evaluating: "evaluating";
1944
+ accepted: "accepted";
1945
+ rejected: "rejected";
1946
+ "needs-review": "needs-review";
1947
+ failed: "failed";
1948
+ }>;
1949
+ reason: z.ZodNullable<z.ZodString>;
1950
+ retries: z.ZodNumber;
1951
+ generation: z.ZodNumber;
1952
+ completion: z.ZodNullable<z.ZodString>;
1953
+ reviewRewards: z.ZodDefault<z.ZodNullable<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1954
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
1955
+ balance: z.ZodString;
1956
+ amount: z.ZodNumber;
1957
+ }, z.core.$strict>, z.ZodObject<{
1958
+ kind: z.ZodLiteral<"tier">;
1959
+ reward: z.ZodObject<{
1960
+ id: z.ZodString;
1961
+ title: z.ZodString;
1962
+ tiers: z.ZodArray<z.ZodObject<{
1963
+ id: z.ZodString;
1964
+ title: z.ZodString;
1965
+ }, z.core.$strict>>;
1966
+ inventory: z.ZodObject<{
1967
+ kind: z.ZodLiteral<"untracked">;
1968
+ }, z.core.$strict>;
1969
+ fulfillment: z.ZodObject<{
1970
+ kind: z.ZodLiteral<"staff-handover">;
1971
+ }, z.core.$strict>;
1972
+ }, z.core.$strict>;
1973
+ tier: z.ZodString;
1974
+ }, z.core.$strict>]>>>>;
1975
+ createdAt: z.ZodNumber;
1976
+ }, z.core.$strip>;
1977
+ title: z.ZodString;
1978
+ checks: z.ZodArray<z.ZodObject<{
1979
+ criteria: z.ZodString;
1980
+ result: z.ZodObject<{
1981
+ kind: z.ZodEnum<{
1982
+ pass: "pass";
1983
+ fail: "fail";
1984
+ unclear: "unclear";
1985
+ }>;
1986
+ reason: z.ZodString;
1987
+ }, z.core.$strict>;
1988
+ }, z.core.$strip>>;
1989
+ }, z.core.$strip>;
1990
+ declare const reviewPageSchema: z.ZodObject<{
1991
+ items: z.ZodArray<z.ZodObject<{
1992
+ attempt: z.ZodObject<{
1993
+ id: z.ZodString;
1994
+ release: z.ZodString;
1995
+ quest: z.ZodString;
1996
+ member: z.ZodString;
1997
+ evidence: z.ZodNullable<z.ZodString>;
1998
+ input: z.ZodOptional<z.ZodObject<{
1999
+ kind: z.ZodLiteral<"quiz">;
2000
+ release: z.ZodOptional<z.ZodString>;
2001
+ answers: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodString>, z.ZodTransform<{
2002
+ [k: string]: string;
2003
+ }, Record<string, string>>>;
2004
+ }, z.core.$strict>>;
2005
+ status: z.ZodEnum<{
2006
+ queued: "queued";
2007
+ evaluating: "evaluating";
2008
+ accepted: "accepted";
2009
+ rejected: "rejected";
2010
+ "needs-review": "needs-review";
2011
+ failed: "failed";
2012
+ }>;
2013
+ reason: z.ZodNullable<z.ZodString>;
2014
+ retries: z.ZodNumber;
2015
+ generation: z.ZodNumber;
2016
+ completion: z.ZodNullable<z.ZodString>;
2017
+ reviewRewards: z.ZodDefault<z.ZodNullable<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
2018
+ kind: z.ZodDefault<z.ZodLiteral<"points">>;
2019
+ balance: z.ZodString;
2020
+ amount: z.ZodNumber;
2021
+ }, z.core.$strict>, z.ZodObject<{
2022
+ kind: z.ZodLiteral<"tier">;
2023
+ reward: z.ZodObject<{
2024
+ id: z.ZodString;
2025
+ title: z.ZodString;
2026
+ tiers: z.ZodArray<z.ZodObject<{
2027
+ id: z.ZodString;
2028
+ title: z.ZodString;
2029
+ }, z.core.$strict>>;
2030
+ inventory: z.ZodObject<{
2031
+ kind: z.ZodLiteral<"untracked">;
2032
+ }, z.core.$strict>;
2033
+ fulfillment: z.ZodObject<{
2034
+ kind: z.ZodLiteral<"staff-handover">;
2035
+ }, z.core.$strict>;
2036
+ }, z.core.$strict>;
2037
+ tier: z.ZodString;
2038
+ }, z.core.$strict>]>>>>;
2039
+ createdAt: z.ZodNumber;
2040
+ }, z.core.$strip>;
2041
+ title: z.ZodString;
2042
+ checks: z.ZodArray<z.ZodObject<{
2043
+ criteria: z.ZodString;
2044
+ result: z.ZodObject<{
2045
+ kind: z.ZodEnum<{
2046
+ pass: "pass";
2047
+ fail: "fail";
2048
+ unclear: "unclear";
2049
+ }>;
2050
+ reason: z.ZodString;
2051
+ }, z.core.$strict>;
2052
+ }, z.core.$strip>>;
2053
+ }, z.core.$strip>>;
2054
+ nextCursor: z.ZodNullable<z.ZodString>;
2055
+ }, z.core.$strip>;
2056
+ declare const memberPageSchema: z.ZodObject<{
2057
+ items: z.ZodArray<z.ZodObject<{
2058
+ member: z.ZodString;
2059
+ }, z.core.$strip>>;
2060
+ nextCursor: z.ZodNullable<z.ZodString>;
2061
+ }, z.core.$strip>;
2062
+ type ReviewPage = z.infer<typeof reviewPageSchema>;
2063
+ type MemberPage = z.infer<typeof memberPageSchema>;
2064
+
2065
+ export { type Attempt, type Decision, type Entitlement, type MemberListOptions, type MemberPage, type MemberProgress, type PhotoResult, type PickupAvailability, type PublishedRelease, type QuestAvailability, type QuestDescription, type QuestPresentation, type QuestSettingsInput, type QuizEvidence, type ReleaseInput, type ReviewListOptions, type ReviewPage, type Reward, type Snapshot, type SubmitInput, type TieredRewardDefinition, artifactSchema, attemptSchema, batchReleaseSchema, beginHandoverSchema, completionRecordSchema, configurePickupSchema, confirmHandoverSchema, decisionSchema, entitlementSchema, errorSchema, eventSchema, evidenceSchema, identifier, mediaUrlSchema, memberListSchema, memberPageSchema, memberProgressSchema, photoResultSchema, pickupAllocationSchema, pickupAvailabilitySchema, pickupCatalogSchema, pickupPolicySchema, pickupSelectionSchema, pointsRewardSchema, prerequisiteSchema, publishedReleaseSchema, questAvailabilitySchema, questDescriptionSchema, questPresentationSchema, questSettingsInputSchema, quizAnswersSchema, quizEvidenceSchema, releaseSchema, reservationSchema, reviewItemSchema, reviewListSchema, reviewModeSchema, reviewPageSchema, rewardBundleSchema, rewardKey, rewardSchema, snapshotSchema, staffDecisionSchema, stockSchema, submitSchema, templateSchema, tierRewardSchema, tieredRewardDefinitionSchema, triggerSchema };