optio-contracts 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,864 @@
1
+ import { z } from 'zod';
2
+ export declare const optioEngineContract: import("@clamator/protocol").Contract<"optio-engine", {
3
+ launch: import("@clamator/protocol").MethodDef<z.ZodObject<{
4
+ processId: z.ZodString;
5
+ resume: z.ZodOptional<z.ZodBoolean>;
6
+ }, "strip", z.ZodTypeAny, {
7
+ processId: string;
8
+ resume?: boolean | undefined;
9
+ }, {
10
+ processId: string;
11
+ resume?: boolean | undefined;
12
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
13
+ ok: z.ZodLiteral<true>;
14
+ process: z.ZodObject<{
15
+ _id: z.ZodString;
16
+ processId: z.ZodString;
17
+ name: z.ZodString;
18
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
19
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
20
+ parentId: z.ZodOptional<z.ZodString>;
21
+ rootId: z.ZodString;
22
+ depth: z.ZodNumber;
23
+ order: z.ZodNumber;
24
+ cancellable: z.ZodBoolean;
25
+ special: z.ZodOptional<z.ZodBoolean>;
26
+ warning: z.ZodOptional<z.ZodString>;
27
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
28
+ status: z.ZodObject<{
29
+ state: z.ZodEnum<["idle", "scheduled", "running", "done", "failed", "cancel_requested", "cancelling", "cancelled"]>;
30
+ error: z.ZodOptional<z.ZodString>;
31
+ runningSince: z.ZodOptional<z.ZodDate>;
32
+ doneAt: z.ZodOptional<z.ZodDate>;
33
+ duration: z.ZodOptional<z.ZodNumber>;
34
+ failedAt: z.ZodOptional<z.ZodDate>;
35
+ stoppedAt: z.ZodOptional<z.ZodDate>;
36
+ }, "strip", z.ZodTypeAny, {
37
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
38
+ error?: string | undefined;
39
+ runningSince?: Date | undefined;
40
+ doneAt?: Date | undefined;
41
+ duration?: number | undefined;
42
+ failedAt?: Date | undefined;
43
+ stoppedAt?: Date | undefined;
44
+ }, {
45
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
46
+ error?: string | undefined;
47
+ runningSince?: Date | undefined;
48
+ doneAt?: Date | undefined;
49
+ duration?: number | undefined;
50
+ failedAt?: Date | undefined;
51
+ stoppedAt?: Date | undefined;
52
+ }>;
53
+ progress: z.ZodObject<{
54
+ percent: z.ZodNullable<z.ZodNumber>;
55
+ message: z.ZodOptional<z.ZodString>;
56
+ }, "strip", z.ZodTypeAny, {
57
+ percent: number | null;
58
+ message?: string | undefined;
59
+ }, {
60
+ percent: number | null;
61
+ message?: string | undefined;
62
+ }>;
63
+ log: z.ZodArray<z.ZodObject<{
64
+ timestamp: z.ZodDate;
65
+ level: z.ZodEnum<["event", "info", "debug", "warning", "error"]>;
66
+ message: z.ZodString;
67
+ data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
68
+ }, "strip", z.ZodTypeAny, {
69
+ message: string;
70
+ timestamp: Date;
71
+ level: "error" | "event" | "info" | "debug" | "warning";
72
+ data?: Record<string, unknown> | undefined;
73
+ }, {
74
+ message: string;
75
+ timestamp: Date;
76
+ level: "error" | "event" | "info" | "debug" | "warning";
77
+ data?: Record<string, unknown> | undefined;
78
+ }>, "many">;
79
+ uiWidget: z.ZodOptional<z.ZodNullable<z.ZodString>>;
80
+ widgetData: z.ZodOptional<z.ZodUnknown>;
81
+ supportsResume: z.ZodOptional<z.ZodBoolean>;
82
+ hasSavedState: z.ZodOptional<z.ZodBoolean>;
83
+ createdAt: z.ZodDate;
84
+ }, "strip", z.ZodTypeAny, {
85
+ status: {
86
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
87
+ error?: string | undefined;
88
+ runningSince?: Date | undefined;
89
+ doneAt?: Date | undefined;
90
+ duration?: number | undefined;
91
+ failedAt?: Date | undefined;
92
+ stoppedAt?: Date | undefined;
93
+ };
94
+ _id: string;
95
+ processId: string;
96
+ name: string;
97
+ rootId: string;
98
+ depth: number;
99
+ order: number;
100
+ cancellable: boolean;
101
+ progress: {
102
+ percent: number | null;
103
+ message?: string | undefined;
104
+ };
105
+ log: {
106
+ message: string;
107
+ timestamp: Date;
108
+ level: "error" | "event" | "info" | "debug" | "warning";
109
+ data?: Record<string, unknown> | undefined;
110
+ }[];
111
+ createdAt: Date;
112
+ params?: Record<string, unknown> | undefined;
113
+ warning?: string | undefined;
114
+ metadata?: Record<string, unknown> | undefined;
115
+ parentId?: string | undefined;
116
+ special?: boolean | undefined;
117
+ description?: string | null | undefined;
118
+ uiWidget?: string | null | undefined;
119
+ widgetData?: unknown;
120
+ supportsResume?: boolean | undefined;
121
+ hasSavedState?: boolean | undefined;
122
+ }, {
123
+ status: {
124
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
125
+ error?: string | undefined;
126
+ runningSince?: Date | undefined;
127
+ doneAt?: Date | undefined;
128
+ duration?: number | undefined;
129
+ failedAt?: Date | undefined;
130
+ stoppedAt?: Date | undefined;
131
+ };
132
+ _id: string;
133
+ processId: string;
134
+ name: string;
135
+ rootId: string;
136
+ depth: number;
137
+ order: number;
138
+ cancellable: boolean;
139
+ progress: {
140
+ percent: number | null;
141
+ message?: string | undefined;
142
+ };
143
+ log: {
144
+ message: string;
145
+ timestamp: Date;
146
+ level: "error" | "event" | "info" | "debug" | "warning";
147
+ data?: Record<string, unknown> | undefined;
148
+ }[];
149
+ createdAt: Date;
150
+ params?: Record<string, unknown> | undefined;
151
+ warning?: string | undefined;
152
+ metadata?: Record<string, unknown> | undefined;
153
+ parentId?: string | undefined;
154
+ special?: boolean | undefined;
155
+ description?: string | null | undefined;
156
+ uiWidget?: string | null | undefined;
157
+ widgetData?: unknown;
158
+ supportsResume?: boolean | undefined;
159
+ hasSavedState?: boolean | undefined;
160
+ }>;
161
+ }, "strip", z.ZodTypeAny, {
162
+ ok: true;
163
+ process: {
164
+ status: {
165
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
166
+ error?: string | undefined;
167
+ runningSince?: Date | undefined;
168
+ doneAt?: Date | undefined;
169
+ duration?: number | undefined;
170
+ failedAt?: Date | undefined;
171
+ stoppedAt?: Date | undefined;
172
+ };
173
+ _id: string;
174
+ processId: string;
175
+ name: string;
176
+ rootId: string;
177
+ depth: number;
178
+ order: number;
179
+ cancellable: boolean;
180
+ progress: {
181
+ percent: number | null;
182
+ message?: string | undefined;
183
+ };
184
+ log: {
185
+ message: string;
186
+ timestamp: Date;
187
+ level: "error" | "event" | "info" | "debug" | "warning";
188
+ data?: Record<string, unknown> | undefined;
189
+ }[];
190
+ createdAt: Date;
191
+ params?: Record<string, unknown> | undefined;
192
+ warning?: string | undefined;
193
+ metadata?: Record<string, unknown> | undefined;
194
+ parentId?: string | undefined;
195
+ special?: boolean | undefined;
196
+ description?: string | null | undefined;
197
+ uiWidget?: string | null | undefined;
198
+ widgetData?: unknown;
199
+ supportsResume?: boolean | undefined;
200
+ hasSavedState?: boolean | undefined;
201
+ };
202
+ }, {
203
+ ok: true;
204
+ process: {
205
+ status: {
206
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
207
+ error?: string | undefined;
208
+ runningSince?: Date | undefined;
209
+ doneAt?: Date | undefined;
210
+ duration?: number | undefined;
211
+ failedAt?: Date | undefined;
212
+ stoppedAt?: Date | undefined;
213
+ };
214
+ _id: string;
215
+ processId: string;
216
+ name: string;
217
+ rootId: string;
218
+ depth: number;
219
+ order: number;
220
+ cancellable: boolean;
221
+ progress: {
222
+ percent: number | null;
223
+ message?: string | undefined;
224
+ };
225
+ log: {
226
+ message: string;
227
+ timestamp: Date;
228
+ level: "error" | "event" | "info" | "debug" | "warning";
229
+ data?: Record<string, unknown> | undefined;
230
+ }[];
231
+ createdAt: Date;
232
+ params?: Record<string, unknown> | undefined;
233
+ warning?: string | undefined;
234
+ metadata?: Record<string, unknown> | undefined;
235
+ parentId?: string | undefined;
236
+ special?: boolean | undefined;
237
+ description?: string | null | undefined;
238
+ uiWidget?: string | null | undefined;
239
+ widgetData?: unknown;
240
+ supportsResume?: boolean | undefined;
241
+ hasSavedState?: boolean | undefined;
242
+ };
243
+ }>, z.ZodObject<{
244
+ ok: z.ZodLiteral<false>;
245
+ reason: z.ZodEnum<["not-found", "not-launchable", "no-resume-support", "launch-blocked"]>;
246
+ }, "strip", z.ZodTypeAny, {
247
+ reason: "not-found" | "not-launchable" | "no-resume-support" | "launch-blocked";
248
+ ok: false;
249
+ }, {
250
+ reason: "not-found" | "not-launchable" | "no-resume-support" | "launch-blocked";
251
+ ok: false;
252
+ }>]>>;
253
+ cancel: import("@clamator/protocol").MethodDef<z.ZodObject<{
254
+ processId: z.ZodString;
255
+ }, "strip", z.ZodTypeAny, {
256
+ processId: string;
257
+ }, {
258
+ processId: string;
259
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
260
+ ok: z.ZodLiteral<true>;
261
+ process: z.ZodObject<{
262
+ _id: z.ZodString;
263
+ processId: z.ZodString;
264
+ name: z.ZodString;
265
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
266
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
267
+ parentId: z.ZodOptional<z.ZodString>;
268
+ rootId: z.ZodString;
269
+ depth: z.ZodNumber;
270
+ order: z.ZodNumber;
271
+ cancellable: z.ZodBoolean;
272
+ special: z.ZodOptional<z.ZodBoolean>;
273
+ warning: z.ZodOptional<z.ZodString>;
274
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
275
+ status: z.ZodObject<{
276
+ state: z.ZodEnum<["idle", "scheduled", "running", "done", "failed", "cancel_requested", "cancelling", "cancelled"]>;
277
+ error: z.ZodOptional<z.ZodString>;
278
+ runningSince: z.ZodOptional<z.ZodDate>;
279
+ doneAt: z.ZodOptional<z.ZodDate>;
280
+ duration: z.ZodOptional<z.ZodNumber>;
281
+ failedAt: z.ZodOptional<z.ZodDate>;
282
+ stoppedAt: z.ZodOptional<z.ZodDate>;
283
+ }, "strip", z.ZodTypeAny, {
284
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
285
+ error?: string | undefined;
286
+ runningSince?: Date | undefined;
287
+ doneAt?: Date | undefined;
288
+ duration?: number | undefined;
289
+ failedAt?: Date | undefined;
290
+ stoppedAt?: Date | undefined;
291
+ }, {
292
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
293
+ error?: string | undefined;
294
+ runningSince?: Date | undefined;
295
+ doneAt?: Date | undefined;
296
+ duration?: number | undefined;
297
+ failedAt?: Date | undefined;
298
+ stoppedAt?: Date | undefined;
299
+ }>;
300
+ progress: z.ZodObject<{
301
+ percent: z.ZodNullable<z.ZodNumber>;
302
+ message: z.ZodOptional<z.ZodString>;
303
+ }, "strip", z.ZodTypeAny, {
304
+ percent: number | null;
305
+ message?: string | undefined;
306
+ }, {
307
+ percent: number | null;
308
+ message?: string | undefined;
309
+ }>;
310
+ log: z.ZodArray<z.ZodObject<{
311
+ timestamp: z.ZodDate;
312
+ level: z.ZodEnum<["event", "info", "debug", "warning", "error"]>;
313
+ message: z.ZodString;
314
+ data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
315
+ }, "strip", z.ZodTypeAny, {
316
+ message: string;
317
+ timestamp: Date;
318
+ level: "error" | "event" | "info" | "debug" | "warning";
319
+ data?: Record<string, unknown> | undefined;
320
+ }, {
321
+ message: string;
322
+ timestamp: Date;
323
+ level: "error" | "event" | "info" | "debug" | "warning";
324
+ data?: Record<string, unknown> | undefined;
325
+ }>, "many">;
326
+ uiWidget: z.ZodOptional<z.ZodNullable<z.ZodString>>;
327
+ widgetData: z.ZodOptional<z.ZodUnknown>;
328
+ supportsResume: z.ZodOptional<z.ZodBoolean>;
329
+ hasSavedState: z.ZodOptional<z.ZodBoolean>;
330
+ createdAt: z.ZodDate;
331
+ }, "strip", z.ZodTypeAny, {
332
+ status: {
333
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
334
+ error?: string | undefined;
335
+ runningSince?: Date | undefined;
336
+ doneAt?: Date | undefined;
337
+ duration?: number | undefined;
338
+ failedAt?: Date | undefined;
339
+ stoppedAt?: Date | undefined;
340
+ };
341
+ _id: string;
342
+ processId: string;
343
+ name: string;
344
+ rootId: string;
345
+ depth: number;
346
+ order: number;
347
+ cancellable: boolean;
348
+ progress: {
349
+ percent: number | null;
350
+ message?: string | undefined;
351
+ };
352
+ log: {
353
+ message: string;
354
+ timestamp: Date;
355
+ level: "error" | "event" | "info" | "debug" | "warning";
356
+ data?: Record<string, unknown> | undefined;
357
+ }[];
358
+ createdAt: Date;
359
+ params?: Record<string, unknown> | undefined;
360
+ warning?: string | undefined;
361
+ metadata?: Record<string, unknown> | undefined;
362
+ parentId?: string | undefined;
363
+ special?: boolean | undefined;
364
+ description?: string | null | undefined;
365
+ uiWidget?: string | null | undefined;
366
+ widgetData?: unknown;
367
+ supportsResume?: boolean | undefined;
368
+ hasSavedState?: boolean | undefined;
369
+ }, {
370
+ status: {
371
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
372
+ error?: string | undefined;
373
+ runningSince?: Date | undefined;
374
+ doneAt?: Date | undefined;
375
+ duration?: number | undefined;
376
+ failedAt?: Date | undefined;
377
+ stoppedAt?: Date | undefined;
378
+ };
379
+ _id: string;
380
+ processId: string;
381
+ name: string;
382
+ rootId: string;
383
+ depth: number;
384
+ order: number;
385
+ cancellable: boolean;
386
+ progress: {
387
+ percent: number | null;
388
+ message?: string | undefined;
389
+ };
390
+ log: {
391
+ message: string;
392
+ timestamp: Date;
393
+ level: "error" | "event" | "info" | "debug" | "warning";
394
+ data?: Record<string, unknown> | undefined;
395
+ }[];
396
+ createdAt: Date;
397
+ params?: Record<string, unknown> | undefined;
398
+ warning?: string | undefined;
399
+ metadata?: Record<string, unknown> | undefined;
400
+ parentId?: string | undefined;
401
+ special?: boolean | undefined;
402
+ description?: string | null | undefined;
403
+ uiWidget?: string | null | undefined;
404
+ widgetData?: unknown;
405
+ supportsResume?: boolean | undefined;
406
+ hasSavedState?: boolean | undefined;
407
+ }>;
408
+ }, "strip", z.ZodTypeAny, {
409
+ ok: true;
410
+ process: {
411
+ status: {
412
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
413
+ error?: string | undefined;
414
+ runningSince?: Date | undefined;
415
+ doneAt?: Date | undefined;
416
+ duration?: number | undefined;
417
+ failedAt?: Date | undefined;
418
+ stoppedAt?: Date | undefined;
419
+ };
420
+ _id: string;
421
+ processId: string;
422
+ name: string;
423
+ rootId: string;
424
+ depth: number;
425
+ order: number;
426
+ cancellable: boolean;
427
+ progress: {
428
+ percent: number | null;
429
+ message?: string | undefined;
430
+ };
431
+ log: {
432
+ message: string;
433
+ timestamp: Date;
434
+ level: "error" | "event" | "info" | "debug" | "warning";
435
+ data?: Record<string, unknown> | undefined;
436
+ }[];
437
+ createdAt: Date;
438
+ params?: Record<string, unknown> | undefined;
439
+ warning?: string | undefined;
440
+ metadata?: Record<string, unknown> | undefined;
441
+ parentId?: string | undefined;
442
+ special?: boolean | undefined;
443
+ description?: string | null | undefined;
444
+ uiWidget?: string | null | undefined;
445
+ widgetData?: unknown;
446
+ supportsResume?: boolean | undefined;
447
+ hasSavedState?: boolean | undefined;
448
+ };
449
+ }, {
450
+ ok: true;
451
+ process: {
452
+ status: {
453
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
454
+ error?: string | undefined;
455
+ runningSince?: Date | undefined;
456
+ doneAt?: Date | undefined;
457
+ duration?: number | undefined;
458
+ failedAt?: Date | undefined;
459
+ stoppedAt?: Date | undefined;
460
+ };
461
+ _id: string;
462
+ processId: string;
463
+ name: string;
464
+ rootId: string;
465
+ depth: number;
466
+ order: number;
467
+ cancellable: boolean;
468
+ progress: {
469
+ percent: number | null;
470
+ message?: string | undefined;
471
+ };
472
+ log: {
473
+ message: string;
474
+ timestamp: Date;
475
+ level: "error" | "event" | "info" | "debug" | "warning";
476
+ data?: Record<string, unknown> | undefined;
477
+ }[];
478
+ createdAt: Date;
479
+ params?: Record<string, unknown> | undefined;
480
+ warning?: string | undefined;
481
+ metadata?: Record<string, unknown> | undefined;
482
+ parentId?: string | undefined;
483
+ special?: boolean | undefined;
484
+ description?: string | null | undefined;
485
+ uiWidget?: string | null | undefined;
486
+ widgetData?: unknown;
487
+ supportsResume?: boolean | undefined;
488
+ hasSavedState?: boolean | undefined;
489
+ };
490
+ }>, z.ZodObject<{
491
+ ok: z.ZodLiteral<false>;
492
+ reason: z.ZodEnum<["not-found", "not-cancellable"]>;
493
+ }, "strip", z.ZodTypeAny, {
494
+ reason: "not-found" | "not-cancellable";
495
+ ok: false;
496
+ }, {
497
+ reason: "not-found" | "not-cancellable";
498
+ ok: false;
499
+ }>]>>;
500
+ dismiss: import("@clamator/protocol").MethodDef<z.ZodObject<{
501
+ processId: z.ZodString;
502
+ }, "strip", z.ZodTypeAny, {
503
+ processId: string;
504
+ }, {
505
+ processId: string;
506
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
507
+ ok: z.ZodLiteral<true>;
508
+ process: z.ZodObject<{
509
+ _id: z.ZodString;
510
+ processId: z.ZodString;
511
+ name: z.ZodString;
512
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
513
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
514
+ parentId: z.ZodOptional<z.ZodString>;
515
+ rootId: z.ZodString;
516
+ depth: z.ZodNumber;
517
+ order: z.ZodNumber;
518
+ cancellable: z.ZodBoolean;
519
+ special: z.ZodOptional<z.ZodBoolean>;
520
+ warning: z.ZodOptional<z.ZodString>;
521
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
522
+ status: z.ZodObject<{
523
+ state: z.ZodEnum<["idle", "scheduled", "running", "done", "failed", "cancel_requested", "cancelling", "cancelled"]>;
524
+ error: z.ZodOptional<z.ZodString>;
525
+ runningSince: z.ZodOptional<z.ZodDate>;
526
+ doneAt: z.ZodOptional<z.ZodDate>;
527
+ duration: z.ZodOptional<z.ZodNumber>;
528
+ failedAt: z.ZodOptional<z.ZodDate>;
529
+ stoppedAt: z.ZodOptional<z.ZodDate>;
530
+ }, "strip", z.ZodTypeAny, {
531
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
532
+ error?: string | undefined;
533
+ runningSince?: Date | undefined;
534
+ doneAt?: Date | undefined;
535
+ duration?: number | undefined;
536
+ failedAt?: Date | undefined;
537
+ stoppedAt?: Date | undefined;
538
+ }, {
539
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
540
+ error?: string | undefined;
541
+ runningSince?: Date | undefined;
542
+ doneAt?: Date | undefined;
543
+ duration?: number | undefined;
544
+ failedAt?: Date | undefined;
545
+ stoppedAt?: Date | undefined;
546
+ }>;
547
+ progress: z.ZodObject<{
548
+ percent: z.ZodNullable<z.ZodNumber>;
549
+ message: z.ZodOptional<z.ZodString>;
550
+ }, "strip", z.ZodTypeAny, {
551
+ percent: number | null;
552
+ message?: string | undefined;
553
+ }, {
554
+ percent: number | null;
555
+ message?: string | undefined;
556
+ }>;
557
+ log: z.ZodArray<z.ZodObject<{
558
+ timestamp: z.ZodDate;
559
+ level: z.ZodEnum<["event", "info", "debug", "warning", "error"]>;
560
+ message: z.ZodString;
561
+ data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
562
+ }, "strip", z.ZodTypeAny, {
563
+ message: string;
564
+ timestamp: Date;
565
+ level: "error" | "event" | "info" | "debug" | "warning";
566
+ data?: Record<string, unknown> | undefined;
567
+ }, {
568
+ message: string;
569
+ timestamp: Date;
570
+ level: "error" | "event" | "info" | "debug" | "warning";
571
+ data?: Record<string, unknown> | undefined;
572
+ }>, "many">;
573
+ uiWidget: z.ZodOptional<z.ZodNullable<z.ZodString>>;
574
+ widgetData: z.ZodOptional<z.ZodUnknown>;
575
+ supportsResume: z.ZodOptional<z.ZodBoolean>;
576
+ hasSavedState: z.ZodOptional<z.ZodBoolean>;
577
+ createdAt: z.ZodDate;
578
+ }, "strip", z.ZodTypeAny, {
579
+ status: {
580
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
581
+ error?: string | undefined;
582
+ runningSince?: Date | undefined;
583
+ doneAt?: Date | undefined;
584
+ duration?: number | undefined;
585
+ failedAt?: Date | undefined;
586
+ stoppedAt?: Date | undefined;
587
+ };
588
+ _id: string;
589
+ processId: string;
590
+ name: string;
591
+ rootId: string;
592
+ depth: number;
593
+ order: number;
594
+ cancellable: boolean;
595
+ progress: {
596
+ percent: number | null;
597
+ message?: string | undefined;
598
+ };
599
+ log: {
600
+ message: string;
601
+ timestamp: Date;
602
+ level: "error" | "event" | "info" | "debug" | "warning";
603
+ data?: Record<string, unknown> | undefined;
604
+ }[];
605
+ createdAt: Date;
606
+ params?: Record<string, unknown> | undefined;
607
+ warning?: string | undefined;
608
+ metadata?: Record<string, unknown> | undefined;
609
+ parentId?: string | undefined;
610
+ special?: boolean | undefined;
611
+ description?: string | null | undefined;
612
+ uiWidget?: string | null | undefined;
613
+ widgetData?: unknown;
614
+ supportsResume?: boolean | undefined;
615
+ hasSavedState?: boolean | undefined;
616
+ }, {
617
+ status: {
618
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
619
+ error?: string | undefined;
620
+ runningSince?: Date | undefined;
621
+ doneAt?: Date | undefined;
622
+ duration?: number | undefined;
623
+ failedAt?: Date | undefined;
624
+ stoppedAt?: Date | undefined;
625
+ };
626
+ _id: string;
627
+ processId: string;
628
+ name: string;
629
+ rootId: string;
630
+ depth: number;
631
+ order: number;
632
+ cancellable: boolean;
633
+ progress: {
634
+ percent: number | null;
635
+ message?: string | undefined;
636
+ };
637
+ log: {
638
+ message: string;
639
+ timestamp: Date;
640
+ level: "error" | "event" | "info" | "debug" | "warning";
641
+ data?: Record<string, unknown> | undefined;
642
+ }[];
643
+ createdAt: Date;
644
+ params?: Record<string, unknown> | undefined;
645
+ warning?: string | undefined;
646
+ metadata?: Record<string, unknown> | undefined;
647
+ parentId?: string | undefined;
648
+ special?: boolean | undefined;
649
+ description?: string | null | undefined;
650
+ uiWidget?: string | null | undefined;
651
+ widgetData?: unknown;
652
+ supportsResume?: boolean | undefined;
653
+ hasSavedState?: boolean | undefined;
654
+ }>;
655
+ }, "strip", z.ZodTypeAny, {
656
+ ok: true;
657
+ process: {
658
+ status: {
659
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
660
+ error?: string | undefined;
661
+ runningSince?: Date | undefined;
662
+ doneAt?: Date | undefined;
663
+ duration?: number | undefined;
664
+ failedAt?: Date | undefined;
665
+ stoppedAt?: Date | undefined;
666
+ };
667
+ _id: string;
668
+ processId: string;
669
+ name: string;
670
+ rootId: string;
671
+ depth: number;
672
+ order: number;
673
+ cancellable: boolean;
674
+ progress: {
675
+ percent: number | null;
676
+ message?: string | undefined;
677
+ };
678
+ log: {
679
+ message: string;
680
+ timestamp: Date;
681
+ level: "error" | "event" | "info" | "debug" | "warning";
682
+ data?: Record<string, unknown> | undefined;
683
+ }[];
684
+ createdAt: Date;
685
+ params?: Record<string, unknown> | undefined;
686
+ warning?: string | undefined;
687
+ metadata?: Record<string, unknown> | undefined;
688
+ parentId?: string | undefined;
689
+ special?: boolean | undefined;
690
+ description?: string | null | undefined;
691
+ uiWidget?: string | null | undefined;
692
+ widgetData?: unknown;
693
+ supportsResume?: boolean | undefined;
694
+ hasSavedState?: boolean | undefined;
695
+ };
696
+ }, {
697
+ ok: true;
698
+ process: {
699
+ status: {
700
+ state: "idle" | "scheduled" | "running" | "done" | "failed" | "cancel_requested" | "cancelling" | "cancelled";
701
+ error?: string | undefined;
702
+ runningSince?: Date | undefined;
703
+ doneAt?: Date | undefined;
704
+ duration?: number | undefined;
705
+ failedAt?: Date | undefined;
706
+ stoppedAt?: Date | undefined;
707
+ };
708
+ _id: string;
709
+ processId: string;
710
+ name: string;
711
+ rootId: string;
712
+ depth: number;
713
+ order: number;
714
+ cancellable: boolean;
715
+ progress: {
716
+ percent: number | null;
717
+ message?: string | undefined;
718
+ };
719
+ log: {
720
+ message: string;
721
+ timestamp: Date;
722
+ level: "error" | "event" | "info" | "debug" | "warning";
723
+ data?: Record<string, unknown> | undefined;
724
+ }[];
725
+ createdAt: Date;
726
+ params?: Record<string, unknown> | undefined;
727
+ warning?: string | undefined;
728
+ metadata?: Record<string, unknown> | undefined;
729
+ parentId?: string | undefined;
730
+ special?: boolean | undefined;
731
+ description?: string | null | undefined;
732
+ uiWidget?: string | null | undefined;
733
+ widgetData?: unknown;
734
+ supportsResume?: boolean | undefined;
735
+ hasSavedState?: boolean | undefined;
736
+ };
737
+ }>, z.ZodObject<{
738
+ ok: z.ZodLiteral<false>;
739
+ reason: z.ZodEnum<["not-found", "not-dismissable"]>;
740
+ }, "strip", z.ZodTypeAny, {
741
+ reason: "not-found" | "not-dismissable";
742
+ ok: false;
743
+ }, {
744
+ reason: "not-found" | "not-dismissable";
745
+ ok: false;
746
+ }>]>>;
747
+ groupCancel: import("@clamator/protocol").MethodDef<z.ZodObject<{
748
+ metadataFilter: z.ZodRecord<z.ZodString, z.ZodUnknown>;
749
+ blockNewLaunches: z.ZodOptional<z.ZodBoolean>;
750
+ persist: z.ZodOptional<z.ZodBoolean>;
751
+ reason: z.ZodOptional<z.ZodString>;
752
+ }, "strip", z.ZodTypeAny, {
753
+ metadataFilter: Record<string, unknown>;
754
+ reason?: string | undefined;
755
+ blockNewLaunches?: boolean | undefined;
756
+ persist?: boolean | undefined;
757
+ }, {
758
+ metadataFilter: Record<string, unknown>;
759
+ reason?: string | undefined;
760
+ blockNewLaunches?: boolean | undefined;
761
+ persist?: boolean | undefined;
762
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
763
+ ok: z.ZodLiteral<true>;
764
+ cancelledCount: z.ZodNumber;
765
+ }, "strip", z.ZodTypeAny, {
766
+ ok: true;
767
+ cancelledCount: number;
768
+ }, {
769
+ ok: true;
770
+ cancelledCount: number;
771
+ }>, z.ZodObject<{
772
+ ok: z.ZodLiteral<false>;
773
+ reason: z.ZodEnum<["invalid-persist-without-block"]>;
774
+ }, "strip", z.ZodTypeAny, {
775
+ reason: "invalid-persist-without-block";
776
+ ok: false;
777
+ }, {
778
+ reason: "invalid-persist-without-block";
779
+ ok: false;
780
+ }>]>>;
781
+ groupCancelAndWait: import("@clamator/protocol").MethodDef<z.ZodObject<{
782
+ metadataFilter: z.ZodRecord<z.ZodString, z.ZodUnknown>;
783
+ blockNewLaunches: z.ZodOptional<z.ZodBoolean>;
784
+ persist: z.ZodOptional<z.ZodBoolean>;
785
+ reason: z.ZodOptional<z.ZodString>;
786
+ }, "strip", z.ZodTypeAny, {
787
+ metadataFilter: Record<string, unknown>;
788
+ reason?: string | undefined;
789
+ blockNewLaunches?: boolean | undefined;
790
+ persist?: boolean | undefined;
791
+ }, {
792
+ metadataFilter: Record<string, unknown>;
793
+ reason?: string | undefined;
794
+ blockNewLaunches?: boolean | undefined;
795
+ persist?: boolean | undefined;
796
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
797
+ ok: z.ZodLiteral<true>;
798
+ cancelledCount: z.ZodNumber;
799
+ }, "strip", z.ZodTypeAny, {
800
+ ok: true;
801
+ cancelledCount: number;
802
+ }, {
803
+ ok: true;
804
+ cancelledCount: number;
805
+ }>, z.ZodObject<{
806
+ ok: z.ZodLiteral<false>;
807
+ reason: z.ZodEnum<["invalid-persist-without-block"]>;
808
+ }, "strip", z.ZodTypeAny, {
809
+ reason: "invalid-persist-without-block";
810
+ ok: false;
811
+ }, {
812
+ reason: "invalid-persist-without-block";
813
+ ok: false;
814
+ }>]>>;
815
+ blockLaunches: import("@clamator/protocol").MethodDef<z.ZodObject<{
816
+ launchFilter: z.ZodRecord<z.ZodString, z.ZodUnknown>;
817
+ reason: z.ZodOptional<z.ZodString>;
818
+ }, "strip", z.ZodTypeAny, {
819
+ launchFilter: Record<string, unknown>;
820
+ reason?: string | undefined;
821
+ }, {
822
+ launchFilter: Record<string, unknown>;
823
+ reason?: string | undefined;
824
+ }>, z.ZodDiscriminatedUnion<"ok", [z.ZodObject<{
825
+ ok: z.ZodLiteral<true>;
826
+ }, "strip", z.ZodTypeAny, {
827
+ ok: true;
828
+ }, {
829
+ ok: true;
830
+ }>, z.ZodObject<{
831
+ ok: z.ZodLiteral<false>;
832
+ reason: z.ZodEnum<["invalid-filter"]>;
833
+ }, "strip", z.ZodTypeAny, {
834
+ reason: "invalid-filter";
835
+ ok: false;
836
+ }, {
837
+ reason: "invalid-filter";
838
+ ok: false;
839
+ }>]>>;
840
+ unblockLaunches: import("@clamator/protocol").MethodDef<z.ZodObject<{
841
+ launchFilter: z.ZodRecord<z.ZodString, z.ZodUnknown>;
842
+ }, "strip", z.ZodTypeAny, {
843
+ launchFilter: Record<string, unknown>;
844
+ }, {
845
+ launchFilter: Record<string, unknown>;
846
+ }>, z.ZodObject<{
847
+ removed: z.ZodNumber;
848
+ }, "strip", z.ZodTypeAny, {
849
+ removed: number;
850
+ }, {
851
+ removed: number;
852
+ }>>;
853
+ resync: import("@clamator/protocol").NotificationDef<z.ZodObject<{
854
+ clean: z.ZodOptional<z.ZodBoolean>;
855
+ metadataFilter: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
856
+ }, "strip", z.ZodTypeAny, {
857
+ metadataFilter?: Record<string, unknown> | undefined;
858
+ clean?: boolean | undefined;
859
+ }, {
860
+ metadataFilter?: Record<string, unknown> | undefined;
861
+ clean?: boolean | undefined;
862
+ }>>;
863
+ }>;
864
+ //# sourceMappingURL=optio-engine-to-api.d.ts.map