@drisp/protocol 0.6.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,1385 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://raw.githubusercontent.com/drisplabs/cli/main/packages/protocol/schema/frame.json",
4
+ "title": "frame",
5
+ "x-protocol-version": 1,
6
+ "oneOf": [
7
+ {
8
+ "type": "object",
9
+ "properties": {
10
+ "type": {
11
+ "type": "string",
12
+ "const": "job_assignment"
13
+ },
14
+ "runId": {
15
+ "type": "string"
16
+ },
17
+ "runSpec": {
18
+ "type": "object",
19
+ "properties": {
20
+ "prompt": {
21
+ "type": "string"
22
+ },
23
+ "athenaSessionId": {
24
+ "type": "string"
25
+ },
26
+ "adapterResumeSessionId": {
27
+ "type": "string"
28
+ },
29
+ "sessionId": {
30
+ "type": "string"
31
+ },
32
+ "projectDir": {
33
+ "type": "string"
34
+ },
35
+ "workflow": {
36
+ "type": "object",
37
+ "properties": {
38
+ "source": {
39
+ "type": "string"
40
+ },
41
+ "ref": {
42
+ "type": "string"
43
+ },
44
+ "version": {
45
+ "type": "string"
46
+ }
47
+ },
48
+ "additionalProperties": {}
49
+ },
50
+ "harness": {
51
+ "type": "string"
52
+ },
53
+ "env": {
54
+ "type": "object",
55
+ "propertyNames": {
56
+ "type": "string"
57
+ },
58
+ "additionalProperties": {
59
+ "type": "string"
60
+ }
61
+ },
62
+ "timeoutSec": {
63
+ "type": "number"
64
+ },
65
+ "callbackWsUrl": {
66
+ "type": "string"
67
+ },
68
+ "callbackToken": {
69
+ "type": "string"
70
+ }
71
+ },
72
+ "additionalProperties": {}
73
+ },
74
+ "runnerId": {
75
+ "type": "string"
76
+ }
77
+ },
78
+ "required": ["type", "runId"],
79
+ "additionalProperties": false
80
+ },
81
+ {
82
+ "type": "object",
83
+ "properties": {
84
+ "type": {
85
+ "type": "string",
86
+ "const": "dashboard_decision"
87
+ },
88
+ "athenaSessionId": {
89
+ "type": "string"
90
+ },
91
+ "requestId": {
92
+ "type": "string"
93
+ },
94
+ "decision": {
95
+ "type": "object",
96
+ "properties": {
97
+ "type": {
98
+ "type": "string",
99
+ "enum": ["passthrough", "block", "json"]
100
+ },
101
+ "source": {
102
+ "type": "string",
103
+ "enum": ["user", "timeout", "rule"]
104
+ },
105
+ "intent": {
106
+ "oneOf": [
107
+ {
108
+ "type": "object",
109
+ "properties": {
110
+ "kind": {
111
+ "type": "string",
112
+ "const": "permission_allow"
113
+ }
114
+ },
115
+ "required": ["kind"],
116
+ "additionalProperties": false
117
+ },
118
+ {
119
+ "type": "object",
120
+ "properties": {
121
+ "kind": {
122
+ "type": "string",
123
+ "const": "permission_deny"
124
+ },
125
+ "reason": {
126
+ "type": "string"
127
+ }
128
+ },
129
+ "required": ["kind", "reason"],
130
+ "additionalProperties": false
131
+ },
132
+ {
133
+ "type": "object",
134
+ "properties": {
135
+ "kind": {
136
+ "type": "string",
137
+ "const": "question_answer"
138
+ },
139
+ "answers": {
140
+ "type": "object",
141
+ "propertyNames": {
142
+ "type": "string"
143
+ },
144
+ "additionalProperties": {
145
+ "type": "string"
146
+ }
147
+ }
148
+ },
149
+ "required": ["kind", "answers"],
150
+ "additionalProperties": false
151
+ },
152
+ {
153
+ "type": "object",
154
+ "properties": {
155
+ "kind": {
156
+ "type": "string",
157
+ "const": "pre_tool_allow"
158
+ }
159
+ },
160
+ "required": ["kind"],
161
+ "additionalProperties": false
162
+ },
163
+ {
164
+ "type": "object",
165
+ "properties": {
166
+ "kind": {
167
+ "type": "string",
168
+ "const": "pre_tool_deny"
169
+ },
170
+ "reason": {
171
+ "type": "string"
172
+ }
173
+ },
174
+ "required": ["kind", "reason"],
175
+ "additionalProperties": false
176
+ },
177
+ {
178
+ "type": "object",
179
+ "properties": {
180
+ "kind": {
181
+ "type": "string",
182
+ "const": "stop_block"
183
+ },
184
+ "reason": {
185
+ "type": "string"
186
+ }
187
+ },
188
+ "required": ["kind", "reason"],
189
+ "additionalProperties": false
190
+ },
191
+ {
192
+ "type": "object",
193
+ "properties": {
194
+ "kind": {
195
+ "type": "string",
196
+ "const": "compact_block"
197
+ },
198
+ "reason": {
199
+ "type": "string"
200
+ }
201
+ },
202
+ "required": ["kind", "reason"],
203
+ "additionalProperties": false
204
+ }
205
+ ]
206
+ },
207
+ "reason": {
208
+ "type": "string"
209
+ },
210
+ "data": {}
211
+ },
212
+ "required": ["type", "source"],
213
+ "additionalProperties": false
214
+ }
215
+ },
216
+ "required": ["type", "athenaSessionId", "requestId", "decision"],
217
+ "additionalProperties": false
218
+ },
219
+ {
220
+ "type": "object",
221
+ "properties": {
222
+ "type": {
223
+ "type": "string",
224
+ "const": "cancel"
225
+ },
226
+ "runId": {
227
+ "type": "string"
228
+ },
229
+ "runnerId": {
230
+ "type": "string"
231
+ }
232
+ },
233
+ "required": ["type", "runId"],
234
+ "additionalProperties": false
235
+ },
236
+ {
237
+ "type": "object",
238
+ "properties": {
239
+ "type": {
240
+ "type": "string",
241
+ "const": "run_event"
242
+ },
243
+ "runId": {
244
+ "type": "string"
245
+ },
246
+ "seq": {
247
+ "type": "integer",
248
+ "minimum": 0,
249
+ "maximum": 9007199254740991
250
+ },
251
+ "ts": {
252
+ "type": "number"
253
+ },
254
+ "kind": {
255
+ "type": "string"
256
+ },
257
+ "payload": {}
258
+ },
259
+ "required": ["type", "runId", "seq", "ts", "kind"],
260
+ "additionalProperties": false
261
+ },
262
+ {
263
+ "type": "object",
264
+ "properties": {
265
+ "type": {
266
+ "type": "string",
267
+ "const": "feed_event"
268
+ },
269
+ "deliverySeq": {
270
+ "type": "integer",
271
+ "minimum": 0,
272
+ "maximum": 9007199254740991
273
+ },
274
+ "envelope": {
275
+ "type": "object",
276
+ "properties": {
277
+ "instanceId": {
278
+ "type": "string"
279
+ },
280
+ "athenaSessionId": {
281
+ "type": "string"
282
+ },
283
+ "runId": {
284
+ "type": "string"
285
+ },
286
+ "origin": {
287
+ "type": "string",
288
+ "enum": ["local", "dashboard"]
289
+ },
290
+ "eventId": {
291
+ "type": "string"
292
+ },
293
+ "feedSeq": {
294
+ "type": "integer",
295
+ "minimum": 0,
296
+ "maximum": 9007199254740991
297
+ },
298
+ "emittedAt": {
299
+ "type": "number"
300
+ },
301
+ "feedEvent": {
302
+ "type": "object",
303
+ "properties": {
304
+ "event_id": {
305
+ "type": "string"
306
+ },
307
+ "seq": {
308
+ "type": "integer",
309
+ "minimum": 0,
310
+ "maximum": 9007199254740991
311
+ },
312
+ "ts": {
313
+ "type": "number"
314
+ },
315
+ "session_id": {
316
+ "type": "string"
317
+ },
318
+ "run_id": {
319
+ "type": "string"
320
+ },
321
+ "prompt_id": {
322
+ "type": "string"
323
+ },
324
+ "effort_level": {
325
+ "type": "string"
326
+ },
327
+ "kind": {
328
+ "type": "string"
329
+ },
330
+ "level": {
331
+ "type": "string",
332
+ "enum": ["debug", "info", "warn", "error"]
333
+ },
334
+ "actor_id": {
335
+ "type": "string"
336
+ },
337
+ "cause": {
338
+ "type": "object",
339
+ "properties": {
340
+ "parent_event_id": {
341
+ "type": "string"
342
+ },
343
+ "hook_request_id": {
344
+ "type": "string"
345
+ },
346
+ "tool_use_id": {
347
+ "type": "string"
348
+ },
349
+ "transcript_path": {
350
+ "type": "string"
351
+ }
352
+ },
353
+ "additionalProperties": false
354
+ },
355
+ "title": {
356
+ "type": "string"
357
+ },
358
+ "body": {
359
+ "type": "string"
360
+ },
361
+ "ui": {
362
+ "type": "object",
363
+ "properties": {
364
+ "collapsed_default": {
365
+ "type": "boolean"
366
+ },
367
+ "pin": {
368
+ "type": "boolean"
369
+ },
370
+ "badge": {
371
+ "type": "string"
372
+ }
373
+ },
374
+ "additionalProperties": false
375
+ },
376
+ "display": {
377
+ "type": "object",
378
+ "properties": {
379
+ "title": {
380
+ "type": "string"
381
+ }
382
+ },
383
+ "additionalProperties": false
384
+ },
385
+ "data": {},
386
+ "raw": {}
387
+ },
388
+ "required": [
389
+ "event_id",
390
+ "seq",
391
+ "ts",
392
+ "session_id",
393
+ "run_id",
394
+ "kind",
395
+ "level",
396
+ "actor_id",
397
+ "title",
398
+ "data"
399
+ ],
400
+ "additionalProperties": {}
401
+ }
402
+ },
403
+ "required": [
404
+ "instanceId",
405
+ "athenaSessionId",
406
+ "runId",
407
+ "origin",
408
+ "eventId",
409
+ "feedSeq",
410
+ "emittedAt",
411
+ "feedEvent"
412
+ ],
413
+ "additionalProperties": false
414
+ }
415
+ },
416
+ "required": ["type", "deliverySeq", "envelope"],
417
+ "additionalProperties": false
418
+ },
419
+ {
420
+ "type": "object",
421
+ "properties": {
422
+ "type": {
423
+ "type": "string",
424
+ "const": "hello"
425
+ },
426
+ "protocolVersion": {
427
+ "type": "integer",
428
+ "exclusiveMinimum": 0,
429
+ "maximum": 9007199254740991
430
+ },
431
+ "role": {
432
+ "type": "string",
433
+ "enum": ["runner", "hub"]
434
+ },
435
+ "instanceId": {
436
+ "type": "string"
437
+ },
438
+ "agent": {
439
+ "type": "object",
440
+ "properties": {
441
+ "name": {
442
+ "type": "string"
443
+ },
444
+ "version": {
445
+ "type": "string"
446
+ }
447
+ },
448
+ "required": ["name"],
449
+ "additionalProperties": false
450
+ },
451
+ "capabilities": {
452
+ "type": "array",
453
+ "items": {
454
+ "type": "string"
455
+ }
456
+ },
457
+ "workflows": {
458
+ "type": "array",
459
+ "items": {
460
+ "type": "object",
461
+ "properties": {
462
+ "name": {
463
+ "type": "string",
464
+ "minLength": 1
465
+ },
466
+ "version": {
467
+ "type": "string"
468
+ },
469
+ "source": {
470
+ "oneOf": [
471
+ {
472
+ "type": "object",
473
+ "properties": {
474
+ "kind": {
475
+ "type": "string",
476
+ "const": "builtin"
477
+ }
478
+ },
479
+ "required": ["kind"],
480
+ "additionalProperties": false
481
+ },
482
+ {
483
+ "type": "object",
484
+ "properties": {
485
+ "kind": {
486
+ "type": "string",
487
+ "const": "marketplace-remote"
488
+ },
489
+ "ref": {
490
+ "type": "string"
491
+ }
492
+ },
493
+ "required": ["kind", "ref"],
494
+ "additionalProperties": false
495
+ },
496
+ {
497
+ "type": "object",
498
+ "properties": {
499
+ "kind": {
500
+ "type": "string",
501
+ "const": "marketplace-local"
502
+ },
503
+ "repoDir": {
504
+ "type": "string"
505
+ },
506
+ "workflowName": {
507
+ "type": "string"
508
+ }
509
+ },
510
+ "required": ["kind", "repoDir", "workflowName"],
511
+ "additionalProperties": false
512
+ },
513
+ {
514
+ "type": "object",
515
+ "properties": {
516
+ "kind": {
517
+ "type": "string",
518
+ "const": "filesystem"
519
+ },
520
+ "path": {
521
+ "type": "string"
522
+ }
523
+ },
524
+ "required": ["kind", "path"],
525
+ "additionalProperties": false
526
+ },
527
+ {
528
+ "type": "object",
529
+ "properties": {
530
+ "kind": {
531
+ "type": "string",
532
+ "const": "unknown"
533
+ }
534
+ },
535
+ "required": ["kind"],
536
+ "additionalProperties": false
537
+ }
538
+ ]
539
+ }
540
+ },
541
+ "required": ["name", "source"],
542
+ "additionalProperties": false
543
+ }
544
+ }
545
+ },
546
+ "required": ["type", "protocolVersion"],
547
+ "additionalProperties": false
548
+ },
549
+ {
550
+ "type": "object",
551
+ "properties": {
552
+ "type": {
553
+ "type": "string",
554
+ "const": "run.start"
555
+ },
556
+ "runId": {
557
+ "type": "string"
558
+ },
559
+ "runSpec": {
560
+ "type": "object",
561
+ "properties": {
562
+ "prompt": {
563
+ "type": "string"
564
+ },
565
+ "athenaSessionId": {
566
+ "type": "string"
567
+ },
568
+ "adapterResumeSessionId": {
569
+ "type": "string"
570
+ },
571
+ "sessionId": {
572
+ "type": "string"
573
+ },
574
+ "projectDir": {
575
+ "type": "string"
576
+ },
577
+ "workflow": {
578
+ "type": "object",
579
+ "properties": {
580
+ "source": {
581
+ "type": "string"
582
+ },
583
+ "ref": {
584
+ "type": "string"
585
+ },
586
+ "version": {
587
+ "type": "string"
588
+ }
589
+ },
590
+ "additionalProperties": {}
591
+ },
592
+ "harness": {
593
+ "type": "string"
594
+ },
595
+ "env": {
596
+ "type": "object",
597
+ "propertyNames": {
598
+ "type": "string"
599
+ },
600
+ "additionalProperties": {
601
+ "type": "string"
602
+ }
603
+ },
604
+ "timeoutSec": {
605
+ "type": "number"
606
+ },
607
+ "callbackWsUrl": {
608
+ "type": "string"
609
+ },
610
+ "callbackToken": {
611
+ "type": "string"
612
+ }
613
+ },
614
+ "additionalProperties": {}
615
+ },
616
+ "runnerId": {
617
+ "type": "string"
618
+ }
619
+ },
620
+ "required": ["type", "runId"],
621
+ "additionalProperties": false
622
+ },
623
+ {
624
+ "type": "object",
625
+ "properties": {
626
+ "type": {
627
+ "type": "string",
628
+ "const": "answer"
629
+ },
630
+ "athenaSessionId": {
631
+ "type": "string"
632
+ },
633
+ "requestId": {
634
+ "type": "string"
635
+ },
636
+ "decision": {
637
+ "type": "object",
638
+ "properties": {
639
+ "type": {
640
+ "type": "string",
641
+ "enum": ["passthrough", "block", "json"]
642
+ },
643
+ "source": {
644
+ "type": "string",
645
+ "enum": ["user", "timeout", "rule"]
646
+ },
647
+ "intent": {
648
+ "oneOf": [
649
+ {
650
+ "type": "object",
651
+ "properties": {
652
+ "kind": {
653
+ "type": "string",
654
+ "const": "permission_allow"
655
+ }
656
+ },
657
+ "required": ["kind"],
658
+ "additionalProperties": false
659
+ },
660
+ {
661
+ "type": "object",
662
+ "properties": {
663
+ "kind": {
664
+ "type": "string",
665
+ "const": "permission_deny"
666
+ },
667
+ "reason": {
668
+ "type": "string"
669
+ }
670
+ },
671
+ "required": ["kind", "reason"],
672
+ "additionalProperties": false
673
+ },
674
+ {
675
+ "type": "object",
676
+ "properties": {
677
+ "kind": {
678
+ "type": "string",
679
+ "const": "question_answer"
680
+ },
681
+ "answers": {
682
+ "type": "object",
683
+ "propertyNames": {
684
+ "type": "string"
685
+ },
686
+ "additionalProperties": {
687
+ "type": "string"
688
+ }
689
+ }
690
+ },
691
+ "required": ["kind", "answers"],
692
+ "additionalProperties": false
693
+ },
694
+ {
695
+ "type": "object",
696
+ "properties": {
697
+ "kind": {
698
+ "type": "string",
699
+ "const": "pre_tool_allow"
700
+ }
701
+ },
702
+ "required": ["kind"],
703
+ "additionalProperties": false
704
+ },
705
+ {
706
+ "type": "object",
707
+ "properties": {
708
+ "kind": {
709
+ "type": "string",
710
+ "const": "pre_tool_deny"
711
+ },
712
+ "reason": {
713
+ "type": "string"
714
+ }
715
+ },
716
+ "required": ["kind", "reason"],
717
+ "additionalProperties": false
718
+ },
719
+ {
720
+ "type": "object",
721
+ "properties": {
722
+ "kind": {
723
+ "type": "string",
724
+ "const": "stop_block"
725
+ },
726
+ "reason": {
727
+ "type": "string"
728
+ }
729
+ },
730
+ "required": ["kind", "reason"],
731
+ "additionalProperties": false
732
+ },
733
+ {
734
+ "type": "object",
735
+ "properties": {
736
+ "kind": {
737
+ "type": "string",
738
+ "const": "compact_block"
739
+ },
740
+ "reason": {
741
+ "type": "string"
742
+ }
743
+ },
744
+ "required": ["kind", "reason"],
745
+ "additionalProperties": false
746
+ }
747
+ ]
748
+ },
749
+ "reason": {
750
+ "type": "string"
751
+ },
752
+ "data": {}
753
+ },
754
+ "required": ["type", "source"],
755
+ "additionalProperties": false
756
+ }
757
+ },
758
+ "required": ["type", "athenaSessionId", "requestId", "decision"],
759
+ "additionalProperties": false
760
+ },
761
+ {
762
+ "type": "object",
763
+ "properties": {
764
+ "type": {
765
+ "type": "string",
766
+ "const": "stop"
767
+ },
768
+ "runId": {
769
+ "type": "string"
770
+ },
771
+ "runnerId": {
772
+ "type": "string"
773
+ }
774
+ },
775
+ "required": ["type", "runId"],
776
+ "additionalProperties": false
777
+ },
778
+ {
779
+ "type": "object",
780
+ "properties": {
781
+ "type": {
782
+ "type": "string",
783
+ "const": "steer"
784
+ },
785
+ "runId": {
786
+ "type": "string"
787
+ },
788
+ "athenaSessionId": {
789
+ "type": "string"
790
+ },
791
+ "text": {
792
+ "type": "string",
793
+ "minLength": 1
794
+ }
795
+ },
796
+ "required": ["type", "runId", "text"],
797
+ "additionalProperties": false
798
+ },
799
+ {
800
+ "type": "object",
801
+ "properties": {
802
+ "type": {
803
+ "type": "string",
804
+ "const": "needs_human"
805
+ },
806
+ "runId": {
807
+ "type": "string"
808
+ },
809
+ "athenaSessionId": {
810
+ "type": "string"
811
+ },
812
+ "interruption": {
813
+ "oneOf": [
814
+ {
815
+ "type": "object",
816
+ "properties": {
817
+ "message": {
818
+ "type": "string"
819
+ },
820
+ "kind": {
821
+ "type": "string",
822
+ "const": "blocked"
823
+ },
824
+ "reason": {
825
+ "type": "string"
826
+ }
827
+ },
828
+ "required": ["message", "kind"],
829
+ "additionalProperties": false
830
+ },
831
+ {
832
+ "type": "object",
833
+ "properties": {
834
+ "message": {
835
+ "type": "string"
836
+ },
837
+ "kind": {
838
+ "type": "string",
839
+ "const": "question"
840
+ },
841
+ "requestId": {
842
+ "type": "string"
843
+ },
844
+ "question": {
845
+ "type": "string"
846
+ }
847
+ },
848
+ "required": ["message", "kind"],
849
+ "additionalProperties": false
850
+ },
851
+ {
852
+ "type": "object",
853
+ "properties": {
854
+ "message": {
855
+ "type": "string"
856
+ },
857
+ "kind": {
858
+ "type": "string",
859
+ "const": "hard_failure"
860
+ },
861
+ "code": {
862
+ "type": "string",
863
+ "enum": [
864
+ "auth",
865
+ "billing",
866
+ "invalid_request",
867
+ "model_not_found",
868
+ "unclassified"
869
+ ]
870
+ }
871
+ },
872
+ "required": ["message", "kind", "code"],
873
+ "additionalProperties": false
874
+ },
875
+ {
876
+ "type": "object",
877
+ "properties": {
878
+ "message": {
879
+ "type": "string"
880
+ },
881
+ "kind": {
882
+ "type": "string",
883
+ "const": "cap_exhausted"
884
+ },
885
+ "cap": {
886
+ "type": "string",
887
+ "enum": ["retry", "nudge", "iterations", "handover", "tokens"]
888
+ },
889
+ "limit": {
890
+ "type": "integer",
891
+ "exclusiveMinimum": 0,
892
+ "maximum": 9007199254740991
893
+ },
894
+ "resource": {
895
+ "type": "object",
896
+ "properties": {
897
+ "cause": {
898
+ "type": "string",
899
+ "enum": ["tokens", "iterations", "context", "restart"]
900
+ },
901
+ "limit": {
902
+ "type": "number",
903
+ "minimum": 0
904
+ },
905
+ "used": {
906
+ "type": "number",
907
+ "minimum": 0
908
+ },
909
+ "detail": {
910
+ "type": "string"
911
+ },
912
+ "checkpointPath": {
913
+ "type": "string"
914
+ },
915
+ "fresh": {
916
+ "type": "boolean"
917
+ }
918
+ },
919
+ "required": ["cause", "limit", "used", "fresh"],
920
+ "additionalProperties": false
921
+ }
922
+ },
923
+ "required": ["message", "kind", "cap"],
924
+ "additionalProperties": false
925
+ }
926
+ ]
927
+ }
928
+ },
929
+ "required": ["type", "runId", "interruption"],
930
+ "additionalProperties": false
931
+ },
932
+ {
933
+ "type": "object",
934
+ "properties": {
935
+ "type": {
936
+ "type": "string",
937
+ "const": "workflows.changed"
938
+ },
939
+ "workflows": {
940
+ "type": "array",
941
+ "items": {
942
+ "type": "object",
943
+ "properties": {
944
+ "name": {
945
+ "type": "string",
946
+ "minLength": 1
947
+ },
948
+ "version": {
949
+ "type": "string"
950
+ },
951
+ "source": {
952
+ "oneOf": [
953
+ {
954
+ "type": "object",
955
+ "properties": {
956
+ "kind": {
957
+ "type": "string",
958
+ "const": "builtin"
959
+ }
960
+ },
961
+ "required": ["kind"],
962
+ "additionalProperties": false
963
+ },
964
+ {
965
+ "type": "object",
966
+ "properties": {
967
+ "kind": {
968
+ "type": "string",
969
+ "const": "marketplace-remote"
970
+ },
971
+ "ref": {
972
+ "type": "string"
973
+ }
974
+ },
975
+ "required": ["kind", "ref"],
976
+ "additionalProperties": false
977
+ },
978
+ {
979
+ "type": "object",
980
+ "properties": {
981
+ "kind": {
982
+ "type": "string",
983
+ "const": "marketplace-local"
984
+ },
985
+ "repoDir": {
986
+ "type": "string"
987
+ },
988
+ "workflowName": {
989
+ "type": "string"
990
+ }
991
+ },
992
+ "required": ["kind", "repoDir", "workflowName"],
993
+ "additionalProperties": false
994
+ },
995
+ {
996
+ "type": "object",
997
+ "properties": {
998
+ "kind": {
999
+ "type": "string",
1000
+ "const": "filesystem"
1001
+ },
1002
+ "path": {
1003
+ "type": "string"
1004
+ }
1005
+ },
1006
+ "required": ["kind", "path"],
1007
+ "additionalProperties": false
1008
+ },
1009
+ {
1010
+ "type": "object",
1011
+ "properties": {
1012
+ "kind": {
1013
+ "type": "string",
1014
+ "const": "unknown"
1015
+ }
1016
+ },
1017
+ "required": ["kind"],
1018
+ "additionalProperties": false
1019
+ }
1020
+ ]
1021
+ }
1022
+ },
1023
+ "required": ["name", "source"],
1024
+ "additionalProperties": false
1025
+ }
1026
+ }
1027
+ },
1028
+ "required": ["type", "workflows"],
1029
+ "additionalProperties": false
1030
+ },
1031
+ {
1032
+ "oneOf": [
1033
+ {
1034
+ "type": "object",
1035
+ "properties": {
1036
+ "type": {
1037
+ "type": "string",
1038
+ "const": "event"
1039
+ },
1040
+ "stream": {
1041
+ "type": "string",
1042
+ "const": "run"
1043
+ },
1044
+ "runId": {
1045
+ "type": "string"
1046
+ },
1047
+ "seq": {
1048
+ "type": "integer",
1049
+ "minimum": 0,
1050
+ "maximum": 9007199254740991
1051
+ },
1052
+ "ts": {
1053
+ "type": "number"
1054
+ },
1055
+ "kind": {
1056
+ "type": "string"
1057
+ },
1058
+ "payload": {}
1059
+ },
1060
+ "required": ["type", "stream", "runId", "seq", "ts", "kind"],
1061
+ "additionalProperties": false
1062
+ },
1063
+ {
1064
+ "type": "object",
1065
+ "properties": {
1066
+ "type": {
1067
+ "type": "string",
1068
+ "const": "event"
1069
+ },
1070
+ "stream": {
1071
+ "type": "string",
1072
+ "const": "feed"
1073
+ },
1074
+ "deliverySeq": {
1075
+ "type": "integer",
1076
+ "minimum": 0,
1077
+ "maximum": 9007199254740991
1078
+ },
1079
+ "envelope": {
1080
+ "type": "object",
1081
+ "properties": {
1082
+ "instanceId": {
1083
+ "type": "string"
1084
+ },
1085
+ "athenaSessionId": {
1086
+ "type": "string"
1087
+ },
1088
+ "runId": {
1089
+ "type": "string"
1090
+ },
1091
+ "origin": {
1092
+ "type": "string",
1093
+ "enum": ["local", "dashboard"]
1094
+ },
1095
+ "eventId": {
1096
+ "type": "string"
1097
+ },
1098
+ "feedSeq": {
1099
+ "type": "integer",
1100
+ "minimum": 0,
1101
+ "maximum": 9007199254740991
1102
+ },
1103
+ "emittedAt": {
1104
+ "type": "number"
1105
+ },
1106
+ "feedEvent": {
1107
+ "type": "object",
1108
+ "properties": {
1109
+ "event_id": {
1110
+ "type": "string"
1111
+ },
1112
+ "seq": {
1113
+ "type": "integer",
1114
+ "minimum": 0,
1115
+ "maximum": 9007199254740991
1116
+ },
1117
+ "ts": {
1118
+ "type": "number"
1119
+ },
1120
+ "session_id": {
1121
+ "type": "string"
1122
+ },
1123
+ "run_id": {
1124
+ "type": "string"
1125
+ },
1126
+ "prompt_id": {
1127
+ "type": "string"
1128
+ },
1129
+ "effort_level": {
1130
+ "type": "string"
1131
+ },
1132
+ "kind": {
1133
+ "type": "string"
1134
+ },
1135
+ "level": {
1136
+ "type": "string",
1137
+ "enum": ["debug", "info", "warn", "error"]
1138
+ },
1139
+ "actor_id": {
1140
+ "type": "string"
1141
+ },
1142
+ "cause": {
1143
+ "type": "object",
1144
+ "properties": {
1145
+ "parent_event_id": {
1146
+ "type": "string"
1147
+ },
1148
+ "hook_request_id": {
1149
+ "type": "string"
1150
+ },
1151
+ "tool_use_id": {
1152
+ "type": "string"
1153
+ },
1154
+ "transcript_path": {
1155
+ "type": "string"
1156
+ }
1157
+ },
1158
+ "additionalProperties": false
1159
+ },
1160
+ "title": {
1161
+ "type": "string"
1162
+ },
1163
+ "body": {
1164
+ "type": "string"
1165
+ },
1166
+ "ui": {
1167
+ "type": "object",
1168
+ "properties": {
1169
+ "collapsed_default": {
1170
+ "type": "boolean"
1171
+ },
1172
+ "pin": {
1173
+ "type": "boolean"
1174
+ },
1175
+ "badge": {
1176
+ "type": "string"
1177
+ }
1178
+ },
1179
+ "additionalProperties": false
1180
+ },
1181
+ "display": {
1182
+ "type": "object",
1183
+ "properties": {
1184
+ "title": {
1185
+ "type": "string"
1186
+ }
1187
+ },
1188
+ "additionalProperties": false
1189
+ },
1190
+ "data": {},
1191
+ "raw": {}
1192
+ },
1193
+ "required": [
1194
+ "event_id",
1195
+ "seq",
1196
+ "ts",
1197
+ "session_id",
1198
+ "run_id",
1199
+ "kind",
1200
+ "level",
1201
+ "actor_id",
1202
+ "title",
1203
+ "data"
1204
+ ],
1205
+ "additionalProperties": {}
1206
+ }
1207
+ },
1208
+ "required": [
1209
+ "instanceId",
1210
+ "athenaSessionId",
1211
+ "runId",
1212
+ "origin",
1213
+ "eventId",
1214
+ "feedSeq",
1215
+ "emittedAt",
1216
+ "feedEvent"
1217
+ ],
1218
+ "additionalProperties": false
1219
+ }
1220
+ },
1221
+ "required": ["type", "stream", "deliverySeq", "envelope"],
1222
+ "additionalProperties": false
1223
+ }
1224
+ ]
1225
+ },
1226
+ {
1227
+ "type": "object",
1228
+ "properties": {
1229
+ "type": {
1230
+ "type": "string",
1231
+ "const": "ping"
1232
+ },
1233
+ "ts": {
1234
+ "type": "number"
1235
+ }
1236
+ },
1237
+ "required": ["type", "ts"],
1238
+ "additionalProperties": false
1239
+ },
1240
+ {
1241
+ "type": "object",
1242
+ "properties": {
1243
+ "type": {
1244
+ "type": "string",
1245
+ "const": "pong"
1246
+ },
1247
+ "ts": {
1248
+ "type": "number"
1249
+ }
1250
+ },
1251
+ "required": ["type", "ts"],
1252
+ "additionalProperties": false
1253
+ },
1254
+ {
1255
+ "type": "object",
1256
+ "properties": {
1257
+ "type": {
1258
+ "type": "string",
1259
+ "const": "assignment_accepted"
1260
+ },
1261
+ "runId": {
1262
+ "type": "string"
1263
+ }
1264
+ },
1265
+ "required": ["type", "runId"],
1266
+ "additionalProperties": false
1267
+ },
1268
+ {
1269
+ "type": "object",
1270
+ "properties": {
1271
+ "type": {
1272
+ "type": "string",
1273
+ "const": "assignment_rejected"
1274
+ },
1275
+ "runId": {
1276
+ "type": "string"
1277
+ },
1278
+ "reason": {
1279
+ "type": "string",
1280
+ "enum": [
1281
+ "local_capacity",
1282
+ "duplicate",
1283
+ "malformed_assignment",
1284
+ "workspace_unresolved",
1285
+ "workspace_invalid"
1286
+ ]
1287
+ },
1288
+ "message": {
1289
+ "type": "string"
1290
+ }
1291
+ },
1292
+ "required": ["type", "runId", "reason"],
1293
+ "additionalProperties": false
1294
+ },
1295
+ {
1296
+ "type": "object",
1297
+ "properties": {
1298
+ "type": {
1299
+ "type": "string",
1300
+ "const": "decision_ack"
1301
+ },
1302
+ "athenaSessionId": {
1303
+ "type": "string"
1304
+ },
1305
+ "requestId": {
1306
+ "type": "string"
1307
+ }
1308
+ },
1309
+ "required": ["type", "athenaSessionId", "requestId"],
1310
+ "additionalProperties": false
1311
+ },
1312
+ {
1313
+ "type": "object",
1314
+ "properties": {
1315
+ "type": {
1316
+ "type": "string",
1317
+ "const": "feed_ack"
1318
+ },
1319
+ "deliverySeq": {
1320
+ "type": "integer",
1321
+ "minimum": 0,
1322
+ "maximum": 9007199254740991
1323
+ },
1324
+ "eventId": {
1325
+ "type": "string"
1326
+ }
1327
+ },
1328
+ "required": ["type"],
1329
+ "additionalProperties": false
1330
+ },
1331
+ {
1332
+ "type": "object",
1333
+ "properties": {
1334
+ "type": {
1335
+ "type": "string",
1336
+ "const": "attachments.changed"
1337
+ },
1338
+ "attachments": {
1339
+ "type": "array",
1340
+ "items": {
1341
+ "type": "object",
1342
+ "properties": {
1343
+ "runnerId": {
1344
+ "type": "string"
1345
+ },
1346
+ "name": {
1347
+ "type": "string"
1348
+ },
1349
+ "slug": {
1350
+ "type": "string"
1351
+ },
1352
+ "executionTarget": {
1353
+ "type": "string"
1354
+ },
1355
+ "remoteInstanceId": {
1356
+ "type": "string"
1357
+ }
1358
+ },
1359
+ "required": ["runnerId"],
1360
+ "additionalProperties": false
1361
+ }
1362
+ }
1363
+ },
1364
+ "required": ["type", "attachments"],
1365
+ "additionalProperties": false
1366
+ },
1367
+ {
1368
+ "type": "object",
1369
+ "properties": {
1370
+ "type": {
1371
+ "type": "string",
1372
+ "const": "error"
1373
+ },
1374
+ "code": {
1375
+ "type": "string"
1376
+ },
1377
+ "message": {
1378
+ "type": "string"
1379
+ }
1380
+ },
1381
+ "required": ["type", "code"],
1382
+ "additionalProperties": false
1383
+ }
1384
+ ]
1385
+ }