@anhlp/alp-protocol 0.0.0-beta.1 → 0.10.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.
@@ -1,2082 +1,5 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$id": "https://alp.dev/schemas/methods-v1.json",
4
- "protocolVersion": 1,
5
- "errors": {
6
- "parseError": -32700,
7
- "invalidRequest": -32600,
8
- "methodNotFound": -32601,
9
- "invalidParams": -32602,
10
- "failed": 1000,
11
- "notFound": 1001,
12
- "forbidden": 1003,
13
- "conflict": 1004,
14
- "unavailable": 1005,
15
- "protocol": 1006
16
- },
17
- "capabilities": {
18
- "attach.after": "session.attach accepts `after` and answers `cursor`/`reset`; envelopes kept in a tree timeline carry `cursor`.",
19
- "prompt.receipts": "session.prompt is answered at most once per (sessionId, clientMessageId) from a durable receipt; repeats answer the first outcome or outcome_unknown.",
20
- "extension.methods": "extension.register/unregister, and the daemon sends extension.invoke requests to the owning connection.",
21
- "team": "team.list: the teams a project can use, from the daemon host's built-ins, library and project.",
22
- "task": "task.list, task.create, task.update and task.gate.resolve on a project's .alp/tasks, written by the daemon under the task lock.",
23
- "library": "library.list/get/save/delete/duplicate/rename, library.skills.set and library.models on the daemon user's library and a project's .alp overrides; secrets are redacted on read.",
24
- "settings.language": "settings.language.get/set: the language the daemon user reads, in the daemon's ALP_HOME/settings.json."
25
- },
26
- "methods": {
27
- "assignment.recall": {
28
- "x-alp": {
29
- "effect": "mutation",
30
- "scope": {
31
- "kind": "project",
32
- "param": "projectRoot",
33
- "required": false,
34
- "alternatives": [
35
- "assignmentId",
36
- "taskId"
37
- ]
38
- },
39
- "idempotent": false,
40
- "risks": [
41
- "model call"
42
- ]
43
- },
44
- "params": {
45
- "type": "object",
46
- "properties": {
47
- "assignmentId": {
48
- "type": "string"
49
- },
50
- "taskId": {
51
- "type": "string"
52
- },
53
- "projectRoot": {
54
- "type": "string"
55
- },
56
- "question": {
57
- "type": "string"
58
- }
59
- },
60
- "required": [
61
- "question"
62
- ],
63
- "additionalProperties": true
64
- },
65
- "result": {
66
- "type": "object",
67
- "properties": {
68
- "assignmentId": {
69
- "type": "string"
70
- },
71
- "agent": {
72
- "type": "string"
73
- },
74
- "taskId": {
75
- "type": "string"
76
- },
77
- "finishedAt": {
78
- "type": "string"
79
- },
80
- "answer": {
81
- "type": "string"
82
- }
83
- },
84
- "required": [
85
- "assignmentId",
86
- "agent",
87
- "finishedAt",
88
- "answer"
89
- ],
90
- "additionalProperties": true
91
- }
92
- },
93
- "board.list": {
94
- "x-alp": {
95
- "effect": "query",
96
- "scope": {
97
- "kind": "project",
98
- "param": "projectRoot",
99
- "required": true
100
- },
101
- "idempotent": true
102
- },
103
- "params": {
104
- "type": "object",
105
- "properties": {
106
- "projectRoot": {
107
- "type": "string"
108
- }
109
- },
110
- "required": [
111
- "projectRoot"
112
- ],
113
- "additionalProperties": true
114
- },
115
- "result": {
116
- "type": "object",
117
- "properties": {
118
- "pins": {
119
- "type": "array",
120
- "items": {
121
- "$ref": "#/$defs/pin"
122
- }
123
- }
124
- },
125
- "required": [
126
- "pins"
127
- ],
128
- "additionalProperties": true
129
- }
130
- },
131
- "catalog.get": {
132
- "x-alp": {
133
- "effect": "query",
134
- "scope": {
135
- "kind": "host"
136
- },
137
- "idempotent": true
138
- },
139
- "params": {
140
- "type": "object",
141
- "properties": {},
142
- "required": [],
143
- "additionalProperties": true
144
- },
145
- "result": {
146
- "type": "object",
147
- "properties": {
148
- "models": {
149
- "type": "array",
150
- "items": {
151
- "type": "object"
152
- }
153
- },
154
- "modes": {
155
- "type": "array",
156
- "items": {
157
- "type": "object"
158
- }
159
- },
160
- "thinkingOptions": {},
161
- "defaultModel": {
162
- "type": "string"
163
- }
164
- },
165
- "required": [
166
- "models",
167
- "modes",
168
- "defaultModel"
169
- ],
170
- "additionalProperties": true
171
- }
172
- },
173
- "daemon.hello": {
174
- "x-alp": {
175
- "effect": "query",
176
- "scope": {
177
- "kind": "connection"
178
- },
179
- "idempotent": true
180
- },
181
- "params": {
182
- "type": "object",
183
- "properties": {
184
- "protocolVersion": {
185
- "const": 1
186
- },
187
- "client": {
188
- "type": "object",
189
- "properties": {
190
- "name": {
191
- "type": "string"
192
- },
193
- "version": {
194
- "type": "string"
195
- }
196
- },
197
- "required": [
198
- "name",
199
- "version"
200
- ],
201
- "additionalProperties": true
202
- },
203
- "capabilities": {
204
- "type": "array",
205
- "items": {
206
- "type": "string"
207
- }
208
- }
209
- },
210
- "required": [
211
- "protocolVersion"
212
- ],
213
- "additionalProperties": true
214
- },
215
- "result": {
216
- "type": "object",
217
- "properties": {
218
- "protocolVersion": {
219
- "const": 1
220
- },
221
- "daemonVersion": {
222
- "type": "string"
223
- },
224
- "pid": {
225
- "type": "integer"
226
- },
227
- "capabilities": {
228
- "type": "array",
229
- "items": {
230
- "type": "string"
231
- }
232
- }
233
- },
234
- "required": [
235
- "protocolVersion"
236
- ],
237
- "additionalProperties": true
238
- }
239
- },
240
- "daemon.pause": {
241
- "x-alp": {
242
- "effect": "mutation",
243
- "scope": {
244
- "kind": "host"
245
- },
246
- "idempotent": true,
247
- "risks": [
248
- "admin"
249
- ]
250
- },
251
- "params": {
252
- "type": "object",
253
- "properties": {
254
- "runtime": {
255
- "enum": [
256
- "codex",
257
- "claude",
258
- "acp",
259
- "antigravity"
260
- ]
261
- },
262
- "now": {
263
- "type": "boolean"
264
- },
265
- "reason": {
266
- "type": "string"
267
- }
268
- },
269
- "required": [],
270
- "additionalProperties": true
271
- },
272
- "result": {
273
- "$ref": "#/$defs/pauseState"
274
- }
275
- },
276
- "daemon.pauses": {
277
- "x-alp": {
278
- "effect": "query",
279
- "scope": {
280
- "kind": "host"
281
- },
282
- "idempotent": true
283
- },
284
- "params": {
285
- "type": "object",
286
- "properties": {},
287
- "required": [],
288
- "additionalProperties": true
289
- },
290
- "result": {
291
- "$ref": "#/$defs/pauseState"
292
- }
293
- },
294
- "daemon.resume": {
295
- "x-alp": {
296
- "effect": "mutation",
297
- "scope": {
298
- "kind": "host"
299
- },
300
- "idempotent": true,
301
- "risks": [
302
- "admin"
303
- ]
304
- },
305
- "params": {
306
- "type": "object",
307
- "properties": {
308
- "runtime": {
309
- "enum": [
310
- "codex",
311
- "claude",
312
- "acp",
313
- "antigravity"
314
- ]
315
- }
316
- },
317
- "required": [],
318
- "additionalProperties": true
319
- },
320
- "result": {
321
- "$ref": "#/$defs/pauseState"
322
- }
323
- },
324
- "daemon.shutdown": {
325
- "x-alp": {
326
- "effect": "mutation",
327
- "scope": {
328
- "kind": "host"
329
- },
330
- "idempotent": true,
331
- "risks": [
332
- "admin"
333
- ]
334
- },
335
- "params": {
336
- "type": "object",
337
- "properties": {},
338
- "required": [],
339
- "additionalProperties": true
340
- },
341
- "result": {
342
- "type": "object",
343
- "properties": {},
344
- "required": [],
345
- "additionalProperties": true
346
- }
347
- },
348
- "daemon.status": {
349
- "x-alp": {
350
- "effect": "query",
351
- "scope": {
352
- "kind": "host"
353
- },
354
- "idempotent": true
355
- },
356
- "params": {
357
- "type": "object",
358
- "properties": {},
359
- "required": [],
360
- "additionalProperties": true
361
- },
362
- "result": {
363
- "type": "object",
364
- "properties": {
365
- "pid": {
366
- "type": "integer"
367
- },
368
- "startedAt": {
369
- "type": "string"
370
- },
371
- "version": {
372
- "type": "string"
373
- },
374
- "protocolVersion": {
375
- "type": "integer"
376
- },
377
- "sessions": {
378
- "type": "integer"
379
- },
380
- "questions": {
381
- "type": "integer"
382
- },
383
- "previousExit": {
384
- "type": "object",
385
- "properties": {
386
- "kind": {
387
- "enum": [
388
- "clean",
389
- "crash"
390
- ]
391
- },
392
- "at": {
393
- "type": "string"
394
- }
395
- },
396
- "required": [
397
- "kind"
398
- ],
399
- "additionalProperties": true
400
- },
401
- "persistence": {
402
- "type": "object"
403
- },
404
- "health": {
405
- "$ref": "#/$defs/health"
406
- }
407
- },
408
- "required": [
409
- "pid",
410
- "startedAt",
411
- "version",
412
- "protocolVersion",
413
- "sessions",
414
- "questions",
415
- "health"
416
- ],
417
- "additionalProperties": true
418
- }
419
- },
420
- "daemon.usage": {
421
- "x-alp": {
422
- "effect": "query",
423
- "scope": {
424
- "kind": "host"
425
- },
426
- "idempotent": true,
427
- "risks": [
428
- "refresh asks every provider (spawns on the daemon host)"
429
- ]
430
- },
431
- "params": {
432
- "type": "object",
433
- "properties": {
434
- "refresh": {
435
- "type": "boolean"
436
- }
437
- },
438
- "required": [],
439
- "additionalProperties": true
440
- },
441
- "result": {
442
- "type": "object",
443
- "properties": {
444
- "providers": {
445
- "type": "array",
446
- "items": {
447
- "type": "object"
448
- }
449
- }
450
- },
451
- "required": [
452
- "providers"
453
- ],
454
- "additionalProperties": true
455
- }
456
- },
457
- "extension.register": {
458
- "x-alp": {
459
- "effect": "mutation",
460
- "scope": {
461
- "kind": "connection"
462
- },
463
- "idempotent": false,
464
- "risks": [
465
- "admin"
466
- ]
467
- },
468
- "params": {
469
- "type": "object",
470
- "properties": {
471
- "method": {
472
- "type": "string"
473
- }
474
- },
475
- "required": [
476
- "method"
477
- ],
478
- "additionalProperties": true
479
- },
480
- "result": {
481
- "type": "object",
482
- "properties": {
483
- "registered": {
484
- "type": "string"
485
- }
486
- },
487
- "required": [
488
- "registered"
489
- ],
490
- "additionalProperties": true
491
- }
492
- },
493
- "extension.unregister": {
494
- "x-alp": {
495
- "effect": "mutation",
496
- "scope": {
497
- "kind": "connection"
498
- },
499
- "idempotent": false,
500
- "risks": [
501
- "admin"
502
- ]
503
- },
504
- "params": {
505
- "type": "object",
506
- "properties": {
507
- "method": {
508
- "type": "string"
509
- }
510
- },
511
- "required": [
512
- "method"
513
- ],
514
- "additionalProperties": true
515
- },
516
- "result": {
517
- "type": "object",
518
- "properties": {
519
- "unregistered": {
520
- "type": "string"
521
- }
522
- },
523
- "required": [
524
- "unregistered"
525
- ],
526
- "additionalProperties": true
527
- }
528
- },
529
- "library.delete": {
530
- "x-alp": {
531
- "effect": "mutation",
532
- "capability": "library",
533
- "scope": {
534
- "kind": "library-or-project",
535
- "param": "projectRoot",
536
- "selector": "scope"
537
- },
538
- "idempotent": false
539
- },
540
- "params": {
541
- "type": "object",
542
- "properties": {
543
- "kind": {
544
- "$ref": "#/$defs/libraryKind"
545
- },
546
- "name": {
547
- "$ref": "#/$defs/entryName"
548
- },
549
- "scope": {
550
- "$ref": "#/$defs/libraryScope"
551
- },
552
- "projectRoot": {
553
- "$ref": "#/$defs/projectRoot"
554
- },
555
- "revision": {
556
- "type": "string"
557
- }
558
- },
559
- "required": [
560
- "kind",
561
- "name",
562
- "scope"
563
- ],
564
- "additionalProperties": true
565
- },
566
- "result": {
567
- "type": "object",
568
- "properties": {
569
- "removed": {
570
- "const": true
571
- },
572
- "now": {
573
- "enum": [
574
- "builtin",
575
- "library"
576
- ]
577
- }
578
- },
579
- "required": [
580
- "removed"
581
- ],
582
- "additionalProperties": true
583
- }
584
- },
585
- "library.duplicate": {
586
- "x-alp": {
587
- "effect": "mutation",
588
- "capability": "library",
589
- "scope": {
590
- "kind": "library-or-project",
591
- "param": "projectRoot",
592
- "selector": "scope",
593
- "reads": [
594
- "builtin",
595
- "library"
596
- ]
597
- },
598
- "idempotent": false,
599
- "risks": [
600
- "exec-config when kind is mcp, hooks or providers"
601
- ]
602
- },
603
- "params": {
604
- "type": "object",
605
- "properties": {
606
- "kind": {
607
- "$ref": "#/$defs/libraryKind"
608
- },
609
- "from": {
610
- "$ref": "#/$defs/entryName"
611
- },
612
- "to": {
613
- "$ref": "#/$defs/entryName"
614
- },
615
- "scope": {
616
- "$ref": "#/$defs/libraryScope"
617
- },
618
- "projectRoot": {
619
- "$ref": "#/$defs/projectRoot"
620
- }
621
- },
622
- "required": [
623
- "kind",
624
- "from",
625
- "to",
626
- "scope"
627
- ],
628
- "additionalProperties": true
629
- },
630
- "result": {
631
- "type": "object",
632
- "properties": {
633
- "revision": {
634
- "$ref": "#/$defs/libraryRevision"
635
- }
636
- },
637
- "required": [
638
- "revision"
639
- ],
640
- "additionalProperties": true
641
- }
642
- },
643
- "library.get": {
644
- "x-alp": {
645
- "effect": "query",
646
- "capability": "library",
647
- "scope": {
648
- "kind": "project",
649
- "param": "projectRoot",
650
- "required": false,
651
- "reads": [
652
- "builtin",
653
- "library"
654
- ]
655
- },
656
- "idempotent": true,
657
- "redacts": [
658
- "mcp /server/env/*",
659
- "mcp /server/headers/*",
660
- "providers /provider/env/*"
661
- ]
662
- },
663
- "params": {
664
- "type": "object",
665
- "properties": {
666
- "kind": {
667
- "$ref": "#/$defs/libraryKind"
668
- },
669
- "name": {
670
- "$ref": "#/$defs/entryName"
671
- },
672
- "projectRoot": {
673
- "$ref": "#/$defs/projectRoot"
674
- },
675
- "scope": {
676
- "$ref": "#/$defs/libraryScope"
677
- }
678
- },
679
- "required": [
680
- "kind",
681
- "name"
682
- ],
683
- "additionalProperties": true
684
- },
685
- "result": {
686
- "type": "object",
687
- "properties": {
688
- "kind": {
689
- "$ref": "#/$defs/libraryKind"
690
- },
691
- "name": {
692
- "type": "string"
693
- },
694
- "source": {
695
- "$ref": "#/$defs/librarySource"
696
- },
697
- "overrides": {
698
- "$ref": "#/$defs/librarySource"
699
- },
700
- "content": {
701
- "type": "object"
702
- },
703
- "revision": {
704
- "$ref": "#/$defs/libraryRevision"
705
- },
706
- "usedBy": {
707
- "type": "array",
708
- "items": {
709
- "type": "string"
710
- }
711
- },
712
- "librarySkills": {
713
- "type": "array",
714
- "items": {
715
- "type": "string"
716
- }
717
- },
718
- "secrets": {
719
- "type": "array",
720
- "items": {
721
- "type": "string"
722
- }
723
- }
724
- },
725
- "required": [
726
- "kind",
727
- "name",
728
- "source",
729
- "content",
730
- "revision",
731
- "usedBy"
732
- ],
733
- "additionalProperties": true
734
- }
735
- },
736
- "library.list": {
737
- "x-alp": {
738
- "effect": "query",
739
- "capability": "library",
740
- "scope": {
741
- "kind": "project",
742
- "param": "projectRoot",
743
- "required": false,
744
- "reads": [
745
- "builtin",
746
- "library"
747
- ]
748
- },
749
- "idempotent": true
750
- },
751
- "params": {
752
- "type": "object",
753
- "properties": {
754
- "kind": {
755
- "$ref": "#/$defs/libraryKind"
756
- },
757
- "projectRoot": {
758
- "$ref": "#/$defs/projectRoot"
759
- }
760
- },
761
- "required": [
762
- "kind"
763
- ],
764
- "additionalProperties": true
765
- },
766
- "result": {
767
- "type": "object",
768
- "properties": {
769
- "projectRoot": {
770
- "type": [
771
- "string",
772
- "null"
773
- ]
774
- },
775
- "entries": {
776
- "type": "array",
777
- "items": {
778
- "$ref": "#/$defs/libraryEntryRow"
779
- }
780
- }
781
- },
782
- "required": [
783
- "projectRoot",
784
- "entries"
785
- ],
786
- "additionalProperties": true
787
- }
788
- },
789
- "library.models": {
790
- "x-alp": {
791
- "effect": "query",
792
- "capability": "library",
793
- "scope": {
794
- "kind": "host"
795
- },
796
- "idempotent": true
797
- },
798
- "params": {
799
- "type": "object",
800
- "properties": {},
801
- "required": [],
802
- "additionalProperties": true
803
- },
804
- "result": {
805
- "type": "object",
806
- "properties": {
807
- "models": {
808
- "type": "array",
809
- "items": {
810
- "type": "object",
811
- "properties": {
812
- "id": {
813
- "type": "string"
814
- },
815
- "label": {
816
- "type": "string"
817
- },
818
- "efforts": {
819
- "type": "array",
820
- "items": {
821
- "type": "string"
822
- }
823
- },
824
- "effort": {
825
- "type": "string"
826
- }
827
- },
828
- "required": [
829
- "id",
830
- "label",
831
- "efforts"
832
- ],
833
- "additionalProperties": true
834
- }
835
- }
836
- },
837
- "required": [
838
- "models"
839
- ],
840
- "additionalProperties": true
841
- }
842
- },
843
- "library.rename": {
844
- "x-alp": {
845
- "effect": "mutation",
846
- "capability": "library",
847
- "scope": {
848
- "kind": "library-or-project",
849
- "param": "projectRoot",
850
- "selector": "scope"
851
- },
852
- "idempotent": false,
853
- "risks": [
854
- "exec-config when kind is mcp, hooks or providers"
855
- ]
856
- },
857
- "params": {
858
- "type": "object",
859
- "properties": {
860
- "kind": {
861
- "$ref": "#/$defs/libraryKind"
862
- },
863
- "from": {
864
- "$ref": "#/$defs/entryName"
865
- },
866
- "to": {
867
- "$ref": "#/$defs/entryName"
868
- },
869
- "scope": {
870
- "$ref": "#/$defs/libraryScope"
871
- },
872
- "projectRoot": {
873
- "$ref": "#/$defs/projectRoot"
874
- }
875
- },
876
- "required": [
877
- "kind",
878
- "from",
879
- "to",
880
- "scope"
881
- ],
882
- "additionalProperties": true
883
- },
884
- "result": {
885
- "type": "object",
886
- "properties": {
887
- "revision": {
888
- "$ref": "#/$defs/libraryRevision"
889
- }
890
- },
891
- "required": [
892
- "revision"
893
- ],
894
- "additionalProperties": true
895
- }
896
- },
897
- "library.save": {
898
- "x-alp": {
899
- "effect": "mutation",
900
- "capability": "library",
901
- "scope": {
902
- "kind": "library-or-project",
903
- "param": "projectRoot",
904
- "selector": "scope"
905
- },
906
- "idempotent": "with revision (a repeat fails revision_conflict)",
907
- "risks": [
908
- "exec-config when kind is mcp, hooks or providers, or agents naming mcp/hooks/provider",
909
- "writes every known project's .alp/settings.json when kind is teams and sync is known-projects"
910
- ]
911
- },
912
- "params": {
913
- "type": "object",
914
- "properties": {
915
- "kind": {
916
- "$ref": "#/$defs/libraryKind"
917
- },
918
- "name": {
919
- "$ref": "#/$defs/entryName"
920
- },
921
- "scope": {
922
- "$ref": "#/$defs/libraryScope"
923
- },
924
- "projectRoot": {
925
- "$ref": "#/$defs/projectRoot"
926
- },
927
- "content": {
928
- "type": "object"
929
- },
930
- "revision": {
931
- "$ref": "#/$defs/libraryRevision"
932
- },
933
- "sync": {
934
- "enum": [
935
- "none",
936
- "known-projects"
937
- ]
938
- }
939
- },
940
- "required": [
941
- "kind",
942
- "name",
943
- "scope",
944
- "content"
945
- ],
946
- "additionalProperties": true
947
- },
948
- "result": {
949
- "type": "object",
950
- "properties": {
951
- "revision": {
952
- "$ref": "#/$defs/libraryRevision"
953
- },
954
- "syncedProjects": {
955
- "type": "integer",
956
- "minimum": 0
957
- },
958
- "syncErrors": {
959
- "type": "array",
960
- "items": {
961
- "type": "string"
962
- }
963
- }
964
- },
965
- "required": [
966
- "revision"
967
- ],
968
- "additionalProperties": true
969
- }
970
- },
971
- "library.skills.set": {
972
- "x-alp": {
973
- "effect": "mutation",
974
- "capability": "library",
975
- "scope": {
976
- "kind": "host"
977
- },
978
- "writes": [
979
- "ALP_HOME/role-skills.json"
980
- ],
981
- "idempotent": true
982
- },
983
- "params": {
984
- "type": "object",
985
- "properties": {
986
- "agent": {
987
- "$ref": "#/$defs/entryName"
988
- },
989
- "skills": {
990
- "type": "array",
991
- "items": {
992
- "$ref": "#/$defs/entryName"
993
- },
994
- "maxItems": 100
995
- }
996
- },
997
- "required": [
998
- "agent",
999
- "skills"
1000
- ],
1001
- "additionalProperties": true
1002
- },
1003
- "result": {
1004
- "type": "object",
1005
- "properties": {
1006
- "skills": {
1007
- "type": "array",
1008
- "items": {
1009
- "type": "string"
1010
- }
1011
- }
1012
- },
1013
- "required": [
1014
- "skills"
1015
- ],
1016
- "additionalProperties": true
1017
- }
1018
- },
1019
- "question.answer": {
1020
- "x-alp": {
1021
- "effect": "mutation",
1022
- "scope": {
1023
- "kind": "question",
1024
- "param": "questionId",
1025
- "prefix": true
1026
- },
1027
- "idempotent": false
1028
- },
1029
- "params": {
1030
- "type": "object",
1031
- "properties": {
1032
- "questionId": {
1033
- "type": "string"
1034
- },
1035
- "text": {
1036
- "type": "string"
1037
- },
1038
- "dismiss": {
1039
- "type": "boolean"
1040
- },
1041
- "reason": {
1042
- "type": "string"
1043
- }
1044
- },
1045
- "required": [
1046
- "questionId"
1047
- ],
1048
- "additionalProperties": true
1049
- },
1050
- "result": {
1051
- "type": "object",
1052
- "properties": {
1053
- "questionId": {
1054
- "type": "string"
1055
- }
1056
- },
1057
- "required": [
1058
- "questionId"
1059
- ],
1060
- "additionalProperties": true
1061
- }
1062
- },
1063
- "question.list": {
1064
- "x-alp": {
1065
- "effect": "query",
1066
- "scope": {
1067
- "kind": "project",
1068
- "param": "projectRoot",
1069
- "required": false
1070
- },
1071
- "idempotent": true
1072
- },
1073
- "params": {
1074
- "type": "object",
1075
- "properties": {
1076
- "projectRoot": {
1077
- "type": "string"
1078
- }
1079
- },
1080
- "required": [],
1081
- "additionalProperties": true
1082
- },
1083
- "result": {
1084
- "type": "object",
1085
- "properties": {
1086
- "questions": {
1087
- "type": "array",
1088
- "items": {
1089
- "$ref": "#/$defs/question"
1090
- }
1091
- }
1092
- },
1093
- "required": [
1094
- "questions"
1095
- ],
1096
- "additionalProperties": true
1097
- }
1098
- },
1099
- "session.archive": {
1100
- "x-alp": {
1101
- "effect": "mutation",
1102
- "scope": {
1103
- "kind": "session",
1104
- "param": "sessionId"
1105
- },
1106
- "idempotent": true
1107
- },
1108
- "params": {
1109
- "type": "object",
1110
- "properties": {
1111
- "sessionId": {
1112
- "type": "string"
1113
- },
1114
- "archived": {
1115
- "type": "boolean"
1116
- }
1117
- },
1118
- "required": [
1119
- "sessionId"
1120
- ],
1121
- "additionalProperties": true
1122
- },
1123
- "result": {
1124
- "type": "object",
1125
- "properties": {
1126
- "session": {
1127
- "$ref": "#/$defs/sessionSummary"
1128
- }
1129
- },
1130
- "required": [
1131
- "session"
1132
- ],
1133
- "additionalProperties": true
1134
- }
1135
- },
1136
- "session.attach": {
1137
- "x-alp": {
1138
- "effect": "query",
1139
- "scope": {
1140
- "kind": "session",
1141
- "param": "sessionId"
1142
- },
1143
- "idempotent": true
1144
- },
1145
- "params": {
1146
- "type": "object",
1147
- "properties": {
1148
- "sessionId": {
1149
- "type": "string"
1150
- },
1151
- "replay": {
1152
- "type": "boolean"
1153
- },
1154
- "after": {
1155
- "type": "integer",
1156
- "minimum": 0,
1157
- "maximum": 9007199254740991
1158
- }
1159
- },
1160
- "required": [
1161
- "sessionId"
1162
- ],
1163
- "additionalProperties": true
1164
- },
1165
- "result": {
1166
- "type": "object",
1167
- "properties": {
1168
- "session": {
1169
- "$ref": "#/$defs/sessionSummary"
1170
- },
1171
- "cursor": {
1172
- "type": "integer",
1173
- "minimum": 0,
1174
- "maximum": 9007199254740991
1175
- },
1176
- "reset": {
1177
- "const": true
1178
- }
1179
- },
1180
- "required": [
1181
- "session",
1182
- "cursor"
1183
- ],
1184
- "additionalProperties": true
1185
- }
1186
- },
1187
- "session.close": {
1188
- "x-alp": {
1189
- "effect": "mutation",
1190
- "scope": {
1191
- "kind": "session",
1192
- "param": "sessionId"
1193
- },
1194
- "idempotent": false
1195
- },
1196
- "params": {
1197
- "type": "object",
1198
- "properties": {
1199
- "sessionId": {
1200
- "type": "string"
1201
- }
1202
- },
1203
- "required": [
1204
- "sessionId"
1205
- ],
1206
- "additionalProperties": true
1207
- },
1208
- "result": {
1209
- "type": "object",
1210
- "properties": {},
1211
- "required": [],
1212
- "additionalProperties": true
1213
- }
1214
- },
1215
- "session.configure": {
1216
- "x-alp": {
1217
- "effect": "mutation",
1218
- "scope": {
1219
- "kind": "session",
1220
- "param": "sessionId"
1221
- },
1222
- "idempotent": true
1223
- },
1224
- "params": {
1225
- "type": "object",
1226
- "properties": {
1227
- "sessionId": {
1228
- "type": "string"
1229
- },
1230
- "mode": {
1231
- "type": "string"
1232
- }
1233
- },
1234
- "required": [
1235
- "sessionId"
1236
- ],
1237
- "additionalProperties": true
1238
- },
1239
- "result": {
1240
- "type": "object",
1241
- "properties": {
1242
- "session": {
1243
- "$ref": "#/$defs/session"
1244
- }
1245
- },
1246
- "required": [
1247
- "session"
1248
- ],
1249
- "additionalProperties": true
1250
- }
1251
- },
1252
- "session.create": {
1253
- "x-alp": {
1254
- "effect": "mutation",
1255
- "scope": {
1256
- "kind": "project",
1257
- "param": "spec.cwd"
1258
- },
1259
- "idempotent": false,
1260
- "risks": [
1261
- "exec: spec.env and stdio spec.mcpServers run on the daemon host",
1262
- "spec.workdir/writeRoot/copy*/restore/keepThread are internal"
1263
- ]
1264
- },
1265
- "params": {
1266
- "type": "object",
1267
- "properties": {
1268
- "sessionId": {
1269
- "type": "string",
1270
- "pattern": "^[A-Za-z0-9_.:-]{1,128}$"
1271
- },
1272
- "spec": {
1273
- "$ref": "#/$defs/spec"
1274
- },
1275
- "history": {
1276
- "enum": [
1277
- "skip",
1278
- "replay"
1279
- ]
1280
- },
1281
- "delegation": {
1282
- "type": "boolean"
1283
- },
1284
- "resume": {
1285
- "type": "boolean"
1286
- }
1287
- },
1288
- "required": [
1289
- "spec"
1290
- ],
1291
- "additionalProperties": true
1292
- },
1293
- "result": {
1294
- "type": "object",
1295
- "properties": {
1296
- "session": {
1297
- "$ref": "#/$defs/session"
1298
- },
1299
- "attached": {
1300
- "type": "boolean"
1301
- },
1302
- "resumed": {
1303
- "const": true
1304
- },
1305
- "durable": {
1306
- "type": "boolean"
1307
- }
1308
- },
1309
- "required": [
1310
- "session",
1311
- "attached"
1312
- ],
1313
- "additionalProperties": true
1314
- }
1315
- },
1316
- "session.get": {
1317
- "x-alp": {
1318
- "effect": "query",
1319
- "scope": {
1320
- "kind": "session",
1321
- "param": "sessionId"
1322
- },
1323
- "idempotent": true
1324
- },
1325
- "params": {
1326
- "type": "object",
1327
- "properties": {
1328
- "sessionId": {
1329
- "type": "string"
1330
- }
1331
- },
1332
- "required": [
1333
- "sessionId"
1334
- ],
1335
- "additionalProperties": true
1336
- },
1337
- "result": {
1338
- "type": "object",
1339
- "properties": {
1340
- "session": {
1341
- "$ref": "#/$defs/sessionSummary"
1342
- }
1343
- },
1344
- "required": [
1345
- "session"
1346
- ],
1347
- "additionalProperties": true
1348
- }
1349
- },
1350
- "session.interrupt": {
1351
- "x-alp": {
1352
- "effect": "mutation",
1353
- "scope": {
1354
- "kind": "session",
1355
- "param": "sessionId"
1356
- },
1357
- "idempotent": true
1358
- },
1359
- "params": {
1360
- "type": "object",
1361
- "properties": {
1362
- "sessionId": {
1363
- "type": "string"
1364
- }
1365
- },
1366
- "required": [
1367
- "sessionId"
1368
- ],
1369
- "additionalProperties": true
1370
- },
1371
- "result": {
1372
- "type": "object",
1373
- "properties": {},
1374
- "required": [],
1375
- "additionalProperties": true
1376
- }
1377
- },
1378
- "session.list": {
1379
- "x-alp": {
1380
- "effect": "query",
1381
- "scope": {
1382
- "kind": "project",
1383
- "param": "projectRoot",
1384
- "required": false
1385
- },
1386
- "idempotent": true
1387
- },
1388
- "params": {
1389
- "type": "object",
1390
- "properties": {
1391
- "projectRoot": {
1392
- "type": "string"
1393
- },
1394
- "rootsOnly": {
1395
- "type": "boolean"
1396
- },
1397
- "includeClosed": {
1398
- "type": "boolean"
1399
- },
1400
- "includeArchived": {
1401
- "type": "boolean"
1402
- }
1403
- },
1404
- "required": [],
1405
- "additionalProperties": true
1406
- },
1407
- "result": {
1408
- "type": "object",
1409
- "properties": {
1410
- "sessions": {
1411
- "type": "array",
1412
- "items": {
1413
- "$ref": "#/$defs/sessionSummary"
1414
- }
1415
- }
1416
- },
1417
- "required": [
1418
- "sessions"
1419
- ],
1420
- "additionalProperties": true
1421
- }
1422
- },
1423
- "session.log": {
1424
- "x-alp": {
1425
- "effect": "query",
1426
- "scope": {
1427
- "kind": "session",
1428
- "param": "sessionId"
1429
- },
1430
- "idempotent": true
1431
- },
1432
- "params": {
1433
- "type": "object",
1434
- "properties": {
1435
- "sessionId": {
1436
- "type": "string"
1437
- }
1438
- },
1439
- "required": [
1440
- "sessionId"
1441
- ],
1442
- "additionalProperties": true
1443
- },
1444
- "result": {
1445
- "type": "object",
1446
- "properties": {
1447
- "rootId": {
1448
- "type": "string"
1449
- },
1450
- "entries": {
1451
- "type": "array",
1452
- "items": {
1453
- "type": "object"
1454
- }
1455
- }
1456
- },
1457
- "required": [
1458
- "rootId",
1459
- "entries"
1460
- ],
1461
- "additionalProperties": true
1462
- }
1463
- },
1464
- "session.message": {
1465
- "x-alp": {
1466
- "effect": "mutation",
1467
- "scope": {
1468
- "kind": "session",
1469
- "param": "sessionId"
1470
- },
1471
- "idempotent": false
1472
- },
1473
- "params": {
1474
- "type": "object",
1475
- "properties": {
1476
- "sessionId": {
1477
- "type": "string"
1478
- },
1479
- "text": {
1480
- "type": "string"
1481
- }
1482
- },
1483
- "required": [
1484
- "sessionId",
1485
- "text"
1486
- ],
1487
- "additionalProperties": true
1488
- },
1489
- "result": {
1490
- "type": "object",
1491
- "properties": {},
1492
- "required": [],
1493
- "additionalProperties": true
1494
- }
1495
- },
1496
- "session.preview": {
1497
- "x-alp": {
1498
- "effect": "query",
1499
- "scope": {
1500
- "kind": "project",
1501
- "param": "spec.cwd"
1502
- },
1503
- "idempotent": true
1504
- },
1505
- "params": {
1506
- "type": "object",
1507
- "properties": {
1508
- "spec": {
1509
- "$ref": "#/$defs/spec"
1510
- }
1511
- },
1512
- "required": [
1513
- "spec"
1514
- ],
1515
- "additionalProperties": true
1516
- },
1517
- "result": {
1518
- "type": "object",
1519
- "properties": {
1520
- "preview": {
1521
- "$ref": "#/$defs/preview"
1522
- }
1523
- },
1524
- "required": [
1525
- "preview"
1526
- ],
1527
- "additionalProperties": true
1528
- }
1529
- },
1530
- "session.prompt": {
1531
- "x-alp": {
1532
- "effect": "mutation",
1533
- "scope": {
1534
- "kind": "session",
1535
- "param": "sessionId"
1536
- },
1537
- "idempotent": "with prompt.receipts"
1538
- },
1539
- "params": {
1540
- "type": "object",
1541
- "properties": {
1542
- "sessionId": {
1543
- "type": "string"
1544
- },
1545
- "clientMessageId": {
1546
- "type": "string"
1547
- },
1548
- "delivery": {
1549
- "enum": [
1550
- "auto",
1551
- "steer"
1552
- ]
1553
- },
1554
- "content": {
1555
- "type": "array",
1556
- "items": {
1557
- "type": "object",
1558
- "properties": {
1559
- "type": {
1560
- "type": "string"
1561
- },
1562
- "text": {
1563
- "type": "string"
1564
- }
1565
- },
1566
- "required": [
1567
- "type"
1568
- ],
1569
- "additionalProperties": true
1570
- }
1571
- }
1572
- },
1573
- "required": [
1574
- "sessionId",
1575
- "clientMessageId",
1576
- "content"
1577
- ],
1578
- "additionalProperties": true
1579
- },
1580
- "result": {
1581
- "type": "object",
1582
- "properties": {
1583
- "outcome": {
1584
- "enum": [
1585
- "accepted",
1586
- "failed"
1587
- ]
1588
- },
1589
- "error": {
1590
- "$ref": "#/$defs/alpError"
1591
- },
1592
- "duplicate": {
1593
- "type": "boolean"
1594
- },
1595
- "durable": {
1596
- "type": "boolean"
1597
- }
1598
- },
1599
- "required": [],
1600
- "additionalProperties": true
1601
- }
1602
- },
1603
- "session.release": {
1604
- "x-alp": {
1605
- "effect": "mutation",
1606
- "scope": {
1607
- "kind": "session",
1608
- "param": "sessionId"
1609
- },
1610
- "idempotent": true
1611
- },
1612
- "params": {
1613
- "type": "object",
1614
- "properties": {
1615
- "sessionId": {
1616
- "type": "string"
1617
- }
1618
- },
1619
- "required": [
1620
- "sessionId"
1621
- ],
1622
- "additionalProperties": true
1623
- },
1624
- "result": {
1625
- "type": "object",
1626
- "properties": {
1627
- "closed": {
1628
- "type": "boolean"
1629
- }
1630
- },
1631
- "required": [
1632
- "closed"
1633
- ],
1634
- "additionalProperties": true
1635
- }
1636
- },
1637
- "session.rename": {
1638
- "x-alp": {
1639
- "effect": "mutation",
1640
- "scope": {
1641
- "kind": "session",
1642
- "param": "sessionId"
1643
- },
1644
- "idempotent": true
1645
- },
1646
- "params": {
1647
- "type": "object",
1648
- "properties": {
1649
- "sessionId": {
1650
- "type": "string"
1651
- },
1652
- "title": {
1653
- "type": "string",
1654
- "minLength": 1,
1655
- "maxLength": 200,
1656
- "pattern": "\\S"
1657
- }
1658
- },
1659
- "required": [
1660
- "sessionId",
1661
- "title"
1662
- ],
1663
- "additionalProperties": true
1664
- },
1665
- "result": {
1666
- "type": "object",
1667
- "properties": {
1668
- "session": {
1669
- "$ref": "#/$defs/sessionSummary"
1670
- }
1671
- },
1672
- "required": [
1673
- "session"
1674
- ],
1675
- "additionalProperties": true
1676
- }
1677
- },
1678
- "session.status": {
1679
- "x-alp": {
1680
- "effect": "query",
1681
- "scope": {
1682
- "kind": "session",
1683
- "param": "sessionId"
1684
- },
1685
- "idempotent": true
1686
- },
1687
- "params": {
1688
- "type": "object",
1689
- "properties": {
1690
- "sessionId": {
1691
- "type": "string"
1692
- }
1693
- },
1694
- "required": [
1695
- "sessionId"
1696
- ],
1697
- "additionalProperties": true
1698
- },
1699
- "result": {
1700
- "type": "object",
1701
- "properties": {
1702
- "status": {
1703
- "$ref": "#/$defs/treeStatus"
1704
- }
1705
- },
1706
- "required": [
1707
- "status"
1708
- ],
1709
- "additionalProperties": true
1710
- }
1711
- },
1712
- "settings.language.get": {
1713
- "x-alp": {
1714
- "effect": "query",
1715
- "capability": "settings.language",
1716
- "scope": {
1717
- "kind": "host"
1718
- },
1719
- "idempotent": true
1720
- },
1721
- "params": {
1722
- "type": "object",
1723
- "properties": {},
1724
- "required": [],
1725
- "additionalProperties": true
1726
- },
1727
- "result": {
1728
- "$ref": "#/$defs/languageSetting"
1729
- }
1730
- },
1731
- "settings.language.set": {
1732
- "x-alp": {
1733
- "effect": "mutation",
1734
- "capability": "settings.language",
1735
- "scope": {
1736
- "kind": "host"
1737
- },
1738
- "writes": [
1739
- "ALP_HOME/settings.json"
1740
- ],
1741
- "idempotent": true
1742
- },
1743
- "params": {
1744
- "type": "object",
1745
- "properties": {
1746
- "language": {
1747
- "anyOf": [
1748
- {
1749
- "type": "string",
1750
- "minLength": 1,
1751
- "maxLength": 40,
1752
- "pattern": "\\S"
1753
- },
1754
- {
1755
- "type": "null"
1756
- }
1757
- ]
1758
- }
1759
- },
1760
- "required": [
1761
- "language"
1762
- ],
1763
- "additionalProperties": true
1764
- },
1765
- "result": {
1766
- "$ref": "#/$defs/languageSetting"
1767
- }
1768
- },
1769
- "task.create": {
1770
- "x-alp": {
1771
- "effect": "mutation",
1772
- "capability": "task",
1773
- "scope": {
1774
- "kind": "project",
1775
- "param": "projectRoot",
1776
- "required": true
1777
- },
1778
- "writes": [
1779
- "<projectRoot>/.alp/tasks"
1780
- ],
1781
- "idempotent": "per requestId within one alpd process (10 minutes)"
1782
- },
1783
- "params": {
1784
- "type": "object",
1785
- "properties": {
1786
- "projectRoot": {
1787
- "$ref": "#/$defs/projectRoot"
1788
- },
1789
- "title": {
1790
- "type": "string",
1791
- "minLength": 1,
1792
- "maxLength": 200,
1793
- "pattern": "\\S"
1794
- },
1795
- "priority": {
1796
- "type": "integer",
1797
- "minimum": 0,
1798
- "maximum": 4
1799
- },
1800
- "requestId": {
1801
- "type": "string",
1802
- "minLength": 1,
1803
- "maxLength": 128
1804
- }
1805
- },
1806
- "required": [
1807
- "projectRoot",
1808
- "title"
1809
- ],
1810
- "additionalProperties": true
1811
- },
1812
- "result": {
1813
- "type": "object",
1814
- "properties": {
1815
- "id": {
1816
- "$ref": "#/$defs/taskId"
1817
- },
1818
- "duplicate": {
1819
- "const": true
1820
- }
1821
- },
1822
- "required": [
1823
- "id"
1824
- ],
1825
- "additionalProperties": true
1826
- }
1827
- },
1828
- "task.gate.resolve": {
1829
- "x-alp": {
1830
- "effect": "mutation",
1831
- "capability": "task",
1832
- "scope": {
1833
- "kind": "project",
1834
- "param": "projectRoot",
1835
- "required": true
1836
- },
1837
- "writes": [
1838
- "<projectRoot>/.alp/tasks"
1839
- ],
1840
- "idempotent": false
1841
- },
1842
- "params": {
1843
- "type": "object",
1844
- "properties": {
1845
- "projectRoot": {
1846
- "$ref": "#/$defs/projectRoot"
1847
- },
1848
- "id": {
1849
- "$ref": "#/$defs/taskId"
1850
- },
1851
- "gate": {
1852
- "type": "string",
1853
- "minLength": 1,
1854
- "maxLength": 128
1855
- },
1856
- "note": {
1857
- "type": "string",
1858
- "maxLength": 2000
1859
- },
1860
- "ifRev": {
1861
- "type": "integer",
1862
- "minimum": 0
1863
- }
1864
- },
1865
- "required": [
1866
- "projectRoot",
1867
- "id",
1868
- "gate"
1869
- ],
1870
- "additionalProperties": true
1871
- },
1872
- "result": {
1873
- "type": "object",
1874
- "properties": {
1875
- "id": {
1876
- "$ref": "#/$defs/taskId"
1877
- },
1878
- "status": {
1879
- "type": "string"
1880
- },
1881
- "rev": {
1882
- "type": "integer",
1883
- "minimum": 0
1884
- }
1885
- },
1886
- "required": [
1887
- "id",
1888
- "status",
1889
- "rev"
1890
- ],
1891
- "additionalProperties": true
1892
- }
1893
- },
1894
- "task.list": {
1895
- "x-alp": {
1896
- "effect": "query",
1897
- "capability": "task",
1898
- "scope": {
1899
- "kind": "project",
1900
- "param": "projectRoot",
1901
- "required": true
1902
- },
1903
- "idempotent": true
1904
- },
1905
- "params": {
1906
- "type": "object",
1907
- "properties": {
1908
- "projectRoot": {
1909
- "$ref": "#/$defs/projectRoot"
1910
- }
1911
- },
1912
- "required": [
1913
- "projectRoot"
1914
- ],
1915
- "additionalProperties": true
1916
- },
1917
- "result": {
1918
- "type": "object",
1919
- "properties": {
1920
- "projectRoot": {
1921
- "type": "string"
1922
- },
1923
- "tasks": {
1924
- "type": "array",
1925
- "items": {
1926
- "$ref": "#/$defs/taskRow"
1927
- }
1928
- },
1929
- "unreadable": {
1930
- "type": "array",
1931
- "items": {
1932
- "type": "object",
1933
- "properties": {
1934
- "file": {
1935
- "type": "string"
1936
- },
1937
- "error": {
1938
- "type": "string"
1939
- }
1940
- },
1941
- "required": [
1942
- "file",
1943
- "error"
1944
- ],
1945
- "additionalProperties": true
1946
- }
1947
- },
1948
- "revision": {
1949
- "type": "string"
1950
- }
1951
- },
1952
- "required": [
1953
- "projectRoot",
1954
- "tasks",
1955
- "unreadable",
1956
- "revision"
1957
- ],
1958
- "additionalProperties": true
1959
- }
1960
- },
1961
- "task.update": {
1962
- "x-alp": {
1963
- "effect": "mutation",
1964
- "capability": "task",
1965
- "scope": {
1966
- "kind": "project",
1967
- "param": "projectRoot",
1968
- "required": true
1969
- },
1970
- "writes": [
1971
- "<projectRoot>/.alp/tasks"
1972
- ],
1973
- "idempotent": false
1974
- },
1975
- "params": {
1976
- "type": "object",
1977
- "properties": {
1978
- "projectRoot": {
1979
- "$ref": "#/$defs/projectRoot"
1980
- },
1981
- "id": {
1982
- "$ref": "#/$defs/taskId"
1983
- },
1984
- "action": {
1985
- "enum": [
1986
- "close",
1987
- "reopen"
1988
- ]
1989
- },
1990
- "note": {
1991
- "type": "string",
1992
- "maxLength": 2000
1993
- },
1994
- "ifRev": {
1995
- "type": "integer",
1996
- "minimum": 0
1997
- }
1998
- },
1999
- "required": [
2000
- "projectRoot",
2001
- "id",
2002
- "action"
2003
- ],
2004
- "additionalProperties": true
2005
- },
2006
- "result": {
2007
- "type": "object",
2008
- "properties": {
2009
- "id": {
2010
- "$ref": "#/$defs/taskId"
2011
- },
2012
- "status": {
2013
- "type": "string"
2014
- },
2015
- "rev": {
2016
- "type": "integer",
2017
- "minimum": 0
2018
- },
2019
- "landed": {
2020
- "type": "string"
2021
- }
2022
- },
2023
- "required": [
2024
- "id",
2025
- "status",
2026
- "rev"
2027
- ],
2028
- "additionalProperties": true
2029
- }
2030
- },
2031
- "team.list": {
2032
- "x-alp": {
2033
- "effect": "query",
2034
- "capability": "team",
2035
- "scope": {
2036
- "kind": "project",
2037
- "param": "projectRoot",
2038
- "required": false,
2039
- "reads": [
2040
- "builtin",
2041
- "library"
2042
- ]
2043
- },
2044
- "idempotent": true
2045
- },
2046
- "params": {
2047
- "type": "object",
2048
- "properties": {
2049
- "projectRoot": {
2050
- "$ref": "#/$defs/projectRoot"
2051
- }
2052
- },
2053
- "required": [],
2054
- "additionalProperties": true
2055
- },
2056
- "result": {
2057
- "type": "object",
2058
- "properties": {
2059
- "projectRoot": {
2060
- "type": [
2061
- "string",
2062
- "null"
2063
- ]
2064
- },
2065
- "teams": {
2066
- "type": "array",
2067
- "items": {
2068
- "$ref": "#/$defs/teamRow"
2069
- }
2070
- }
2071
- },
2072
- "required": [
2073
- "projectRoot",
2074
- "teams"
2075
- ],
2076
- "additionalProperties": true
2077
- }
2078
- }
2079
- },
2080
3
  "$defs": {
2081
4
  "error": {
2082
5
  "type": "object",
@@ -2345,520 +268,334 @@
2345
268
  "type": "string"
2346
269
  },
2347
270
  "agent": {
2348
- "type": "string"
2349
- },
2350
- "body": {
2351
- "type": "string"
2352
- },
2353
- "options": {
2354
- "type": "array",
2355
- "items": {
2356
- "type": "string"
2357
- }
2358
- },
2359
- "askedAt": {
2360
- "type": "string"
2361
- }
2362
- },
2363
- "required": [
2364
- "id",
2365
- "sessionId",
2366
- "rootId",
2367
- "agent",
2368
- "body",
2369
- "askedAt"
2370
- ],
2371
- "additionalProperties": true
2372
- },
2373
- "spec": {
2374
- "type": "object",
2375
- "properties": {
2376
- "cwd": {
2377
- "type": "string"
2378
- },
2379
- "agent": {
2380
- "type": "string"
2381
- },
2382
- "model": {
2383
- "type": "string"
2384
- },
2385
- "mode": {
2386
- "type": "string"
2387
- },
2388
- "thinking": {
2389
- "type": "string"
2390
- },
2391
- "persist": {
2392
- "type": "boolean"
2393
- },
2394
- "restore": {
2395
- "type": "object"
2396
- }
2397
- },
2398
- "required": [
2399
- "cwd"
2400
- ],
2401
- "additionalProperties": true
2402
- },
2403
- "item": {
2404
- "anyOf": [
2405
- {
2406
- "$ref": "#/$defs/knownItem"
2407
- },
2408
- {
2409
- "$ref": "#/$defs/unknownItem"
2410
- }
2411
- ]
2412
- },
2413
- "event": {
2414
- "anyOf": [
2415
- {
2416
- "$ref": "#/$defs/knownEvent"
2417
- },
2418
- {
2419
- "$ref": "#/$defs/unknownEvent"
2420
- }
2421
- ]
2422
- },
2423
- "envelope": {
2424
- "type": "object",
2425
- "properties": {
2426
- "sessionId": {
2427
- "type": "string"
2428
- },
2429
- "epoch": {
2430
- "type": "string"
2431
- },
2432
- "seq": {
2433
- "type": "integer",
2434
- "minimum": 0,
2435
- "maximum": 9007199254740991
2436
- },
2437
- "ts": {
2438
- "type": "string"
2439
- },
2440
- "event": {
2441
- "$ref": "#/$defs/event"
2442
- },
2443
- "cursor": {
2444
- "type": "integer",
2445
- "minimum": 1,
2446
- "maximum": 9007199254740991
2447
- }
2448
- },
2449
- "required": [
2450
- "sessionId",
2451
- "epoch",
2452
- "seq",
2453
- "ts",
2454
- "event"
2455
- ],
2456
- "additionalProperties": true
2457
- },
2458
- "request": {
2459
- "type": "object",
2460
- "properties": {
2461
- "jsonrpc": {
2462
- "const": "2.0"
2463
- },
2464
- "id": {
2465
- "anyOf": [
2466
- {
2467
- "type": "string",
2468
- "maxLength": 128
2469
- },
2470
- {
2471
- "type": "integer",
2472
- "minimum": -9007199254740991,
2473
- "maximum": 9007199254740991
2474
- }
2475
- ]
2476
- },
2477
- "method": {
2478
- "type": "string"
2479
- },
2480
- "params": {
2481
- "type": "object"
2482
- }
2483
- },
2484
- "required": [
2485
- "jsonrpc",
2486
- "method",
2487
- "id"
2488
- ],
2489
- "additionalProperties": true
2490
- },
2491
- "response": {
2492
- "oneOf": [
2493
- {
2494
- "type": "object",
2495
- "properties": {
2496
- "jsonrpc": {
2497
- "const": "2.0"
2498
- },
2499
- "id": {
2500
- "anyOf": [
2501
- {
2502
- "type": "string",
2503
- "maxLength": 128
2504
- },
2505
- {
2506
- "type": "integer",
2507
- "minimum": -9007199254740991,
2508
- "maximum": 9007199254740991
2509
- },
2510
- {
2511
- "type": "null"
2512
- }
2513
- ]
2514
- },
2515
- "result": {}
2516
- },
2517
- "required": [
2518
- "jsonrpc",
2519
- "id",
2520
- "result"
2521
- ],
2522
- "additionalProperties": true
2523
- },
2524
- {
2525
- "type": "object",
2526
- "properties": {
2527
- "jsonrpc": {
2528
- "const": "2.0"
2529
- },
2530
- "id": {
2531
- "anyOf": [
2532
- {
2533
- "type": "string",
2534
- "maxLength": 128
2535
- },
2536
- {
2537
- "type": "integer",
2538
- "minimum": -9007199254740991,
2539
- "maximum": 9007199254740991
2540
- },
2541
- {
2542
- "type": "null"
2543
- }
2544
- ]
2545
- },
2546
- "error": {
2547
- "$ref": "#/$defs/error"
2548
- }
2549
- },
2550
- "required": [
2551
- "jsonrpc",
2552
- "id",
2553
- "error"
2554
- ],
2555
- "additionalProperties": true
271
+ "type": "string"
272
+ },
273
+ "body": {
274
+ "type": "string"
275
+ },
276
+ "options": {
277
+ "type": "array",
278
+ "items": {
279
+ "type": "string"
280
+ }
281
+ },
282
+ "askedAt": {
283
+ "type": "string"
2556
284
  }
2557
- ]
285
+ },
286
+ "required": [
287
+ "id",
288
+ "sessionId",
289
+ "rootId",
290
+ "agent",
291
+ "body",
292
+ "askedAt"
293
+ ],
294
+ "additionalProperties": true
2558
295
  },
2559
- "notification": {
296
+ "spec": {
2560
297
  "type": "object",
2561
298
  "properties": {
2562
- "jsonrpc": {
2563
- "const": "2.0"
299
+ "cwd": {
300
+ "type": "string"
2564
301
  },
2565
- "method": {
2566
- "const": "event"
302
+ "agent": {
303
+ "type": "string"
2567
304
  },
2568
- "params": {
2569
- "$ref": "#/$defs/envelope"
305
+ "model": {
306
+ "type": "string"
307
+ },
308
+ "mode": {
309
+ "type": "string"
310
+ },
311
+ "thinking": {
312
+ "type": "string"
313
+ },
314
+ "persist": {
315
+ "type": "boolean"
316
+ },
317
+ "restore": {
318
+ "type": "object"
2570
319
  }
2571
320
  },
2572
321
  "required": [
2573
- "jsonrpc",
2574
- "method",
2575
- "params"
322
+ "cwd"
2576
323
  ],
2577
324
  "additionalProperties": true
2578
325
  },
2579
- "knownEvent": {
326
+ "item": {
2580
327
  "oneOf": [
2581
328
  {
2582
329
  "type": "object",
2583
330
  "properties": {
2584
- "type": {
2585
- "const": "session.opened"
2586
- },
2587
- "session": {
2588
- "$ref": "#/$defs/session"
331
+ "kind": {
332
+ "const": "user_message"
2589
333
  },
2590
- "cwd": {
334
+ "id": {
2591
335
  "type": "string"
2592
336
  },
2593
- "effective": {
2594
- "type": "object",
2595
- "properties": {
2596
- "model": {
2597
- "type": "string"
2598
- },
2599
- "thinking": {
2600
- "type": "string"
2601
- }
2602
- },
2603
- "required": [
2604
- "model",
2605
- "thinking"
2606
- ],
2607
- "additionalProperties": true
2608
- }
2609
- },
2610
- "required": [
2611
- "type",
2612
- "session",
2613
- "cwd",
2614
- "effective"
2615
- ],
2616
- "additionalProperties": true
2617
- },
2618
- {
2619
- "type": "object",
2620
- "properties": {
2621
- "type": {
2622
- "const": "session.ready"
2623
- }
2624
- },
2625
- "required": [
2626
- "type"
2627
- ],
2628
- "additionalProperties": true
2629
- },
2630
- {
2631
- "type": "object",
2632
- "properties": {
2633
- "type": {
2634
- "const": "session.updated"
2635
- },
2636
- "session": {
2637
- "$ref": "#/$defs/session"
2638
- }
2639
- },
2640
- "required": [
2641
- "type",
2642
- "session"
2643
- ],
2644
- "additionalProperties": true
2645
- },
2646
- {
2647
- "type": "object",
2648
- "properties": {
2649
- "type": {
2650
- "const": "session.closed"
2651
- }
2652
- },
2653
- "required": [
2654
- "type"
2655
- ],
2656
- "additionalProperties": true
2657
- },
2658
- {
2659
- "type": "object",
2660
- "properties": {
2661
- "type": {
2662
- "const": "session.failed"
2663
- },
2664
- "error": {
2665
- "$ref": "#/$defs/alpError"
2666
- }
2667
- },
2668
- "required": [
2669
- "type",
2670
- "error"
2671
- ],
2672
- "additionalProperties": true
2673
- },
2674
- {
2675
- "type": "object",
2676
- "properties": {
2677
- "type": {
2678
- "const": "prompt.accepted"
2679
- },
2680
- "clientMessageId": {
337
+ "text": {
2681
338
  "type": "string"
2682
339
  },
2683
- "result": {
2684
- "enum": [
2685
- "turn",
2686
- "steer"
2687
- ]
2688
- },
2689
- "turnId": {
340
+ "clientMessageId": {
2690
341
  "type": "string"
2691
342
  }
2692
343
  },
2693
344
  "required": [
2694
- "type",
2695
- "clientMessageId",
2696
- "result",
2697
- "turnId"
345
+ "kind",
346
+ "id",
347
+ "text"
2698
348
  ],
2699
349
  "additionalProperties": true
2700
350
  },
2701
351
  {
2702
352
  "type": "object",
2703
353
  "properties": {
2704
- "type": {
2705
- "const": "prompt.failed"
354
+ "kind": {
355
+ "const": "assistant_message"
2706
356
  },
2707
- "clientMessageId": {
357
+ "id": {
2708
358
  "type": "string"
2709
359
  },
2710
- "error": {
2711
- "$ref": "#/$defs/alpError"
360
+ "text": {
361
+ "type": "string"
2712
362
  }
2713
363
  },
2714
364
  "required": [
2715
- "type",
2716
- "clientMessageId",
2717
- "error"
365
+ "kind",
366
+ "id",
367
+ "text"
2718
368
  ],
2719
369
  "additionalProperties": true
2720
370
  },
2721
371
  {
2722
372
  "type": "object",
2723
373
  "properties": {
2724
- "type": {
2725
- "const": "turn.started"
374
+ "kind": {
375
+ "const": "notice"
2726
376
  },
2727
- "turnId": {
377
+ "id": {
2728
378
  "type": "string"
2729
379
  },
2730
- "origin": {
380
+ "level": {
2731
381
  "enum": [
2732
- "user",
2733
- "wake",
2734
- "assignment",
2735
- "runtime"
382
+ "info",
383
+ "warning",
384
+ "error"
2736
385
  ]
386
+ },
387
+ "text": {
388
+ "type": "string"
2737
389
  }
2738
390
  },
2739
391
  "required": [
2740
- "type",
2741
- "turnId",
2742
- "origin"
392
+ "kind",
393
+ "id",
394
+ "level",
395
+ "text"
2743
396
  ],
2744
397
  "additionalProperties": true
2745
398
  },
2746
399
  {
2747
400
  "type": "object",
2748
401
  "properties": {
2749
- "type": {
2750
- "const": "turn.ended"
402
+ "kind": {
403
+ "const": "compaction"
2751
404
  },
2752
- "turnId": {
405
+ "id": {
2753
406
  "type": "string"
2754
407
  },
2755
- "state": {
408
+ "status": {
2756
409
  "enum": [
410
+ "running",
2757
411
  "completed",
2758
- "failed",
2759
- "canceled"
412
+ "failed"
2760
413
  ]
2761
414
  },
2762
- "error": {
2763
- "$ref": "#/$defs/alpError"
2764
- }
2765
- },
2766
- "required": [
2767
- "type",
2768
- "turnId",
2769
- "state"
2770
- ],
2771
- "additionalProperties": true
2772
- },
2773
- {
2774
- "type": "object",
2775
- "properties": {
2776
- "type": {
2777
- "const": "item"
2778
- },
2779
- "item": {
2780
- "$ref": "#/$defs/item"
2781
- }
2782
- },
2783
- "required": [
2784
- "type",
2785
- "item"
2786
- ],
2787
- "additionalProperties": true
2788
- },
2789
- {
2790
- "type": "object",
2791
- "properties": {
2792
- "type": {
2793
- "const": "mail"
415
+ "trigger": {
416
+ "type": "string"
2794
417
  },
2795
- "mail": {
2796
- "$ref": "#/$defs/mail"
418
+ "preTokens": {
419
+ "type": "integer"
420
+ },
421
+ "postTokens": {
422
+ "type": "integer"
2797
423
  }
2798
424
  },
2799
425
  "required": [
2800
- "type",
2801
- "mail"
426
+ "kind",
427
+ "id",
428
+ "status"
2802
429
  ],
2803
430
  "additionalProperties": true
2804
431
  },
2805
432
  {
2806
433
  "type": "object",
2807
434
  "properties": {
2808
- "type": {
2809
- "const": "assignment"
435
+ "kind": {
436
+ "const": "todo"
2810
437
  },
2811
- "assignment": {
2812
- "$ref": "#/$defs/assignment"
438
+ "id": {
439
+ "type": "string"
440
+ },
441
+ "items": {
442
+ "type": "array",
443
+ "items": {
444
+ "type": "object",
445
+ "properties": {
446
+ "id": {
447
+ "type": "string"
448
+ },
449
+ "text": {
450
+ "type": "string"
451
+ },
452
+ "status": {
453
+ "enum": [
454
+ "pending",
455
+ "in_progress",
456
+ "completed"
457
+ ]
458
+ }
459
+ },
460
+ "required": [
461
+ "id",
462
+ "text",
463
+ "status"
464
+ ],
465
+ "additionalProperties": true
466
+ }
2813
467
  }
2814
468
  },
2815
469
  "required": [
2816
- "type",
2817
- "assignment"
470
+ "kind",
471
+ "id",
472
+ "items"
2818
473
  ],
2819
474
  "additionalProperties": true
2820
475
  },
2821
476
  {
2822
477
  "type": "object",
2823
478
  "properties": {
2824
- "type": {
2825
- "const": "question"
479
+ "kind": {
480
+ "const": "tool_call"
2826
481
  },
2827
- "question": {
2828
- "$ref": "#/$defs/question"
482
+ "id": {
483
+ "type": "string"
484
+ },
485
+ "callId": {
486
+ "type": "string"
487
+ },
488
+ "name": {
489
+ "type": "string"
490
+ },
491
+ "status": {
492
+ "enum": [
493
+ "running",
494
+ "completed",
495
+ "failed"
496
+ ]
497
+ },
498
+ "error": {
499
+ "type": "string"
500
+ },
501
+ "detail": {
502
+ "oneOf": [
503
+ {
504
+ "type": "object",
505
+ "properties": {
506
+ "type": {
507
+ "const": "shell"
508
+ },
509
+ "command": {
510
+ "type": "string"
511
+ },
512
+ "cwd": {
513
+ "type": "string"
514
+ },
515
+ "output": {
516
+ "type": "string"
517
+ },
518
+ "exitCode": {
519
+ "type": [
520
+ "integer",
521
+ "null"
522
+ ]
523
+ }
524
+ },
525
+ "required": [
526
+ "type",
527
+ "command",
528
+ "output"
529
+ ],
530
+ "additionalProperties": true
531
+ },
532
+ {
533
+ "type": "object",
534
+ "properties": {
535
+ "type": {
536
+ "const": "unknown"
537
+ },
538
+ "input": {},
539
+ "output": {}
540
+ },
541
+ "required": [
542
+ "type",
543
+ "input",
544
+ "output"
545
+ ],
546
+ "additionalProperties": true
547
+ }
548
+ ]
2829
549
  }
2830
550
  },
2831
551
  "required": [
2832
- "type",
2833
- "question"
552
+ "kind",
553
+ "id",
554
+ "callId",
555
+ "name",
556
+ "status",
557
+ "detail"
2834
558
  ],
2835
559
  "additionalProperties": true
2836
- },
560
+ }
561
+ ]
562
+ },
563
+ "event": {
564
+ "oneOf": [
2837
565
  {
2838
566
  "type": "object",
2839
567
  "properties": {
2840
568
  "type": {
2841
- "const": "question.resolved"
2842
- },
2843
- "questionId": {
2844
- "type": "string"
569
+ "const": "session.opened"
2845
570
  },
2846
- "outcome": {
2847
- "enum": [
2848
- "answered",
2849
- "dismissed",
2850
- "timeout",
2851
- "canceled"
2852
- ]
571
+ "session": {
572
+ "$ref": "#/$defs/session"
2853
573
  },
2854
- "answer": {
574
+ "cwd": {
2855
575
  "type": "string"
576
+ },
577
+ "effective": {
578
+ "type": "object",
579
+ "properties": {
580
+ "model": {
581
+ "type": "string"
582
+ },
583
+ "thinking": {
584
+ "type": "string"
585
+ }
586
+ },
587
+ "required": [
588
+ "model",
589
+ "thinking"
590
+ ],
591
+ "additionalProperties": true
2856
592
  }
2857
593
  },
2858
594
  "required": [
2859
595
  "type",
2860
- "questionId",
2861
- "outcome"
596
+ "session",
597
+ "cwd",
598
+ "effective"
2862
599
  ],
2863
600
  "additionalProperties": true
2864
601
  },
@@ -2866,15 +603,11 @@
2866
603
  "type": "object",
2867
604
  "properties": {
2868
605
  "type": {
2869
- "const": "pin"
2870
- },
2871
- "pin": {
2872
- "$ref": "#/$defs/pin"
606
+ "const": "session.ready"
2873
607
  }
2874
608
  },
2875
609
  "required": [
2876
- "type",
2877
- "pin"
610
+ "type"
2878
611
  ],
2879
612
  "additionalProperties": true
2880
613
  },
@@ -2882,1189 +615,936 @@
2882
615
  "type": "object",
2883
616
  "properties": {
2884
617
  "type": {
2885
- "const": "unpin"
2886
- },
2887
- "pinId": {
2888
- "type": "string"
618
+ "const": "session.updated"
2889
619
  },
2890
- "reason": {
2891
- "enum": [
2892
- "unpinned",
2893
- "session_ended"
2894
- ]
620
+ "session": {
621
+ "$ref": "#/$defs/session"
2895
622
  }
2896
623
  },
2897
624
  "required": [
2898
625
  "type",
2899
- "pinId",
2900
- "reason"
626
+ "session"
2901
627
  ],
2902
628
  "additionalProperties": true
2903
- }
2904
- ]
2905
- },
2906
- "unknownEvent": {
2907
- "type": "object",
2908
- "properties": {
2909
- "type": {
2910
- "type": "string",
2911
- "not": {
2912
- "enum": [
2913
- "session.opened",
2914
- "session.ready",
2915
- "session.updated",
2916
- "session.closed",
2917
- "session.failed",
2918
- "prompt.accepted",
2919
- "prompt.failed",
2920
- "turn.started",
2921
- "turn.ended",
2922
- "item",
2923
- "mail",
2924
- "assignment",
2925
- "question",
2926
- "question.resolved",
2927
- "pin",
2928
- "unpin"
2929
- ]
2930
- }
2931
- }
2932
- },
2933
- "required": [
2934
- "type"
2935
- ],
2936
- "additionalProperties": true
2937
- },
2938
- "knownItem": {
2939
- "oneOf": [
629
+ },
2940
630
  {
2941
631
  "type": "object",
2942
632
  "properties": {
2943
- "kind": {
2944
- "const": "user_message"
2945
- },
2946
- "id": {
2947
- "type": "string"
2948
- },
2949
- "text": {
2950
- "type": "string"
2951
- },
2952
- "clientMessageId": {
2953
- "type": "string"
633
+ "type": {
634
+ "const": "session.closed"
2954
635
  }
2955
636
  },
2956
637
  "required": [
2957
- "kind",
2958
- "id",
2959
- "text"
638
+ "type"
2960
639
  ],
2961
640
  "additionalProperties": true
2962
641
  },
2963
642
  {
2964
643
  "type": "object",
2965
644
  "properties": {
2966
- "kind": {
2967
- "const": "assistant_message"
2968
- },
2969
- "id": {
2970
- "type": "string"
645
+ "type": {
646
+ "const": "session.failed"
2971
647
  },
2972
- "text": {
2973
- "type": "string"
648
+ "error": {
649
+ "type": "object",
650
+ "properties": {
651
+ "message": {
652
+ "type": "string"
653
+ }
654
+ },
655
+ "required": [
656
+ "message"
657
+ ],
658
+ "additionalProperties": true
2974
659
  }
2975
660
  },
2976
661
  "required": [
2977
- "kind",
2978
- "id",
2979
- "text"
662
+ "type",
663
+ "error"
2980
664
  ],
2981
665
  "additionalProperties": true
2982
666
  },
2983
667
  {
2984
668
  "type": "object",
2985
669
  "properties": {
2986
- "kind": {
2987
- "const": "notice"
670
+ "type": {
671
+ "const": "prompt.accepted"
2988
672
  },
2989
- "id": {
673
+ "clientMessageId": {
2990
674
  "type": "string"
2991
675
  },
2992
- "level": {
676
+ "result": {
2993
677
  "enum": [
2994
- "info",
2995
- "warning",
2996
- "error"
678
+ "turn",
679
+ "steer"
2997
680
  ]
2998
681
  },
2999
- "text": {
682
+ "turnId": {
3000
683
  "type": "string"
3001
684
  }
3002
685
  },
3003
686
  "required": [
3004
- "kind",
3005
- "id",
3006
- "level",
3007
- "text"
687
+ "type",
688
+ "clientMessageId",
689
+ "result",
690
+ "turnId"
3008
691
  ],
3009
692
  "additionalProperties": true
3010
693
  },
3011
694
  {
3012
695
  "type": "object",
3013
696
  "properties": {
3014
- "kind": {
3015
- "const": "compaction"
3016
- },
3017
- "id": {
3018
- "type": "string"
3019
- },
3020
- "status": {
3021
- "enum": [
3022
- "running",
3023
- "completed",
3024
- "failed"
3025
- ]
697
+ "type": {
698
+ "const": "prompt.failed"
3026
699
  },
3027
- "trigger": {
700
+ "clientMessageId": {
3028
701
  "type": "string"
3029
702
  },
3030
- "preTokens": {
3031
- "type": "integer"
3032
- },
3033
- "postTokens": {
3034
- "type": "integer"
703
+ "error": {
704
+ "type": "object",
705
+ "properties": {
706
+ "message": {
707
+ "type": "string"
708
+ }
709
+ },
710
+ "required": [
711
+ "message"
712
+ ],
713
+ "additionalProperties": true
3035
714
  }
3036
715
  },
3037
716
  "required": [
3038
- "kind",
3039
- "id",
3040
- "status"
717
+ "type",
718
+ "clientMessageId",
719
+ "error"
3041
720
  ],
3042
721
  "additionalProperties": true
3043
722
  },
3044
723
  {
3045
724
  "type": "object",
3046
725
  "properties": {
3047
- "kind": {
3048
- "const": "todo"
726
+ "type": {
727
+ "const": "turn.started"
3049
728
  },
3050
- "id": {
729
+ "turnId": {
3051
730
  "type": "string"
3052
731
  },
3053
- "items": {
3054
- "type": "array",
3055
- "items": {
3056
- "type": "object",
3057
- "properties": {
3058
- "id": {
3059
- "type": "string"
3060
- },
3061
- "text": {
3062
- "type": "string"
3063
- },
3064
- "status": {
3065
- "enum": [
3066
- "pending",
3067
- "in_progress",
3068
- "completed"
3069
- ]
3070
- }
3071
- },
3072
- "required": [
3073
- "id",
3074
- "text",
3075
- "status"
3076
- ],
3077
- "additionalProperties": true
3078
- }
732
+ "origin": {
733
+ "enum": [
734
+ "user",
735
+ "wake",
736
+ "assignment",
737
+ "runtime"
738
+ ]
3079
739
  }
3080
740
  },
3081
741
  "required": [
3082
- "kind",
3083
- "id",
3084
- "items"
742
+ "type",
743
+ "turnId",
744
+ "origin"
3085
745
  ],
3086
746
  "additionalProperties": true
3087
747
  },
3088
748
  {
3089
749
  "type": "object",
3090
750
  "properties": {
3091
- "kind": {
3092
- "const": "tool_call"
3093
- },
3094
- "id": {
3095
- "type": "string"
3096
- },
3097
- "callId": {
3098
- "type": "string"
751
+ "type": {
752
+ "const": "turn.ended"
3099
753
  },
3100
- "name": {
754
+ "turnId": {
3101
755
  "type": "string"
3102
756
  },
3103
- "status": {
757
+ "state": {
3104
758
  "enum": [
3105
- "running",
3106
759
  "completed",
3107
- "failed"
760
+ "failed",
761
+ "canceled"
3108
762
  ]
3109
763
  },
3110
764
  "error": {
3111
- "type": "string"
3112
- },
3113
- "detail": {
3114
- "oneOf": [
3115
- {
3116
- "type": "object",
3117
- "properties": {
3118
- "type": {
3119
- "const": "shell"
3120
- },
3121
- "command": {
3122
- "type": "string"
3123
- },
3124
- "cwd": {
3125
- "type": "string"
3126
- },
3127
- "output": {
3128
- "type": "string"
3129
- },
3130
- "exitCode": {
3131
- "type": [
3132
- "integer",
3133
- "null"
3134
- ]
3135
- }
3136
- },
3137
- "required": [
3138
- "type",
3139
- "command",
3140
- "output"
3141
- ],
3142
- "additionalProperties": true
3143
- },
3144
- {
3145
- "type": "object",
3146
- "properties": {
3147
- "type": {
3148
- "const": "unknown"
3149
- },
3150
- "input": {},
3151
- "output": {}
3152
- },
3153
- "required": [
3154
- "type",
3155
- "input",
3156
- "output"
3157
- ],
3158
- "additionalProperties": true
765
+ "type": "object",
766
+ "properties": {
767
+ "message": {
768
+ "type": "string"
3159
769
  }
3160
- ]
770
+ },
771
+ "required": [
772
+ "message"
773
+ ],
774
+ "additionalProperties": true
3161
775
  }
3162
776
  },
3163
777
  "required": [
3164
- "kind",
3165
- "id",
3166
- "callId",
3167
- "name",
3168
- "status",
3169
- "detail"
778
+ "type",
779
+ "turnId",
780
+ "state"
3170
781
  ],
3171
782
  "additionalProperties": true
3172
- }
3173
- ]
3174
- },
3175
- "unknownItem": {
3176
- "type": "object",
3177
- "properties": {
3178
- "kind": {
3179
- "type": "string",
3180
- "not": {
3181
- "enum": [
3182
- "user_message",
3183
- "assistant_message",
3184
- "notice",
3185
- "compaction",
3186
- "todo",
3187
- "tool_call"
3188
- ]
3189
- }
3190
- },
3191
- "id": {
3192
- "type": "string"
3193
- }
3194
- },
3195
- "required": [
3196
- "kind",
3197
- "id"
3198
- ],
3199
- "additionalProperties": true
3200
- },
3201
- "alpError": {
3202
- "type": "object",
3203
- "properties": {
3204
- "message": {
3205
- "type": "string"
3206
- },
3207
- "code": {
3208
- "type": "string"
3209
- }
3210
- },
3211
- "required": [
3212
- "message"
3213
- ],
3214
- "additionalProperties": true
3215
- },
3216
- "sessionSummary": {
3217
- "type": "object",
3218
- "properties": {
3219
- "id": {
3220
- "type": "string"
3221
- },
3222
- "projectRoot": {
3223
- "type": "string"
3224
- },
3225
- "agent": {
3226
- "type": "string"
3227
783
  },
3228
- "runtime": {
3229
- "enum": [
3230
- "claude",
3231
- "codex",
3232
- "acp",
3233
- "antigravity"
3234
- ]
784
+ {
785
+ "type": "object",
786
+ "properties": {
787
+ "type": {
788
+ "const": "item"
789
+ },
790
+ "item": {
791
+ "$ref": "#/$defs/item"
792
+ }
793
+ },
794
+ "required": [
795
+ "type",
796
+ "item"
797
+ ],
798
+ "additionalProperties": true
3235
799
  },
3236
- "model": {
3237
- "type": "string"
800
+ {
801
+ "type": "object",
802
+ "properties": {
803
+ "type": {
804
+ "const": "mail"
805
+ },
806
+ "mail": {
807
+ "$ref": "#/$defs/mail"
808
+ }
809
+ },
810
+ "required": [
811
+ "type",
812
+ "mail"
813
+ ],
814
+ "additionalProperties": true
3238
815
  },
3239
- "mode": {
3240
- "type": "string"
816
+ {
817
+ "type": "object",
818
+ "properties": {
819
+ "type": {
820
+ "const": "assignment"
821
+ },
822
+ "assignment": {
823
+ "$ref": "#/$defs/assignment"
824
+ }
825
+ },
826
+ "required": [
827
+ "type",
828
+ "assignment"
829
+ ],
830
+ "additionalProperties": true
3241
831
  },
3242
- "thinking": {
3243
- "type": "string"
832
+ {
833
+ "type": "object",
834
+ "properties": {
835
+ "type": {
836
+ "const": "question"
837
+ },
838
+ "question": {
839
+ "$ref": "#/$defs/question"
840
+ }
841
+ },
842
+ "required": [
843
+ "type",
844
+ "question"
845
+ ],
846
+ "additionalProperties": true
3244
847
  },
3245
- "workflow": {
848
+ {
3246
849
  "type": "object",
3247
850
  "properties": {
3248
- "mode": {
851
+ "type": {
852
+ "const": "question.resolved"
853
+ },
854
+ "questionId": {
3249
855
  "type": "string"
3250
856
  },
3251
- "maxPeers": {
3252
- "type": "integer"
857
+ "outcome": {
858
+ "enum": [
859
+ "answered",
860
+ "dismissed",
861
+ "timeout",
862
+ "canceled"
863
+ ]
3253
864
  },
3254
- "supervisor": {
3255
- "type": "boolean"
865
+ "answer": {
866
+ "type": "string"
3256
867
  }
3257
868
  },
3258
869
  "required": [
3259
- "mode",
3260
- "maxPeers",
3261
- "supervisor"
870
+ "type",
871
+ "questionId",
872
+ "outcome"
3262
873
  ],
3263
874
  "additionalProperties": true
3264
875
  },
3265
- "threadId": {
3266
- "type": "string"
3267
- },
3268
- "persistent": {
3269
- "type": "boolean"
3270
- },
3271
- "busy": {
3272
- "type": "boolean"
3273
- },
3274
- "parentId": {
3275
- "type": "string"
3276
- },
3277
- "toolCallId": {
3278
- "type": "string"
3279
- },
3280
- "activeTurnId": {
3281
- "type": "string"
3282
- },
3283
- "parked": {
3284
- "type": "string"
3285
- },
3286
- "instructionsSha": {
3287
- "type": "string"
3288
- },
3289
- "teamLabel": {
3290
- "type": "string"
3291
- },
3292
- "status": {
3293
- "enum": [
3294
- "initializing",
3295
- "idle",
3296
- "running",
3297
- "error",
3298
- "closed"
3299
- ]
3300
- },
3301
- "title": {
3302
- "type": "string"
3303
- },
3304
- "archived": {
3305
- "type": "boolean"
876
+ {
877
+ "type": "object",
878
+ "properties": {
879
+ "type": {
880
+ "const": "pin"
881
+ },
882
+ "pin": {
883
+ "$ref": "#/$defs/pin"
884
+ }
885
+ },
886
+ "required": [
887
+ "type",
888
+ "pin"
889
+ ],
890
+ "additionalProperties": true
3306
891
  },
3307
- "lastError": {
892
+ {
3308
893
  "type": "object",
3309
894
  "properties": {
3310
- "code": {
3311
- "type": "string"
895
+ "type": {
896
+ "const": "unpin"
3312
897
  },
3313
- "message": {
898
+ "pinId": {
3314
899
  "type": "string"
900
+ },
901
+ "reason": {
902
+ "enum": [
903
+ "unpinned",
904
+ "session_ended"
905
+ ]
3315
906
  }
3316
907
  },
3317
908
  "required": [
3318
- "message"
909
+ "type",
910
+ "pinId",
911
+ "reason"
3319
912
  ],
3320
913
  "additionalProperties": true
3321
- },
3322
- "createdAt": {
3323
- "type": "string"
3324
- },
3325
- "updatedAt": {
3326
- "type": "string"
3327
914
  }
3328
- },
3329
- "required": [
3330
- "id",
3331
- "projectRoot",
3332
- "agent",
3333
- "runtime",
3334
- "model",
3335
- "mode",
3336
- "thinking",
3337
- "workflow",
3338
- "threadId",
3339
- "persistent",
3340
- "busy",
3341
- "status"
3342
- ],
3343
- "additionalProperties": true
915
+ ]
3344
916
  },
3345
- "pause": {
917
+ "envelope": {
3346
918
  "type": "object",
3347
919
  "properties": {
3348
- "since": {
920
+ "sessionId": {
3349
921
  "type": "string"
3350
922
  },
3351
- "by": {
923
+ "epoch": {
3352
924
  "type": "string"
3353
925
  },
3354
- "reason": {
3355
- "type": "string"
926
+ "seq": {
927
+ "type": "integer",
928
+ "minimum": 0
3356
929
  },
3357
- "resetsAt": {
930
+ "ts": {
3358
931
  "type": "string"
3359
932
  },
3360
- "checkedAt": {
3361
- "type": "string"
933
+ "event": {
934
+ "$ref": "#/$defs/event"
3362
935
  }
3363
936
  },
3364
937
  "required": [
3365
- "since",
3366
- "by",
3367
- "reason"
938
+ "sessionId",
939
+ "epoch",
940
+ "seq",
941
+ "ts",
942
+ "event"
3368
943
  ],
3369
944
  "additionalProperties": true
3370
945
  },
3371
- "pauseState": {
946
+ "request": {
3372
947
  "type": "object",
3373
948
  "properties": {
3374
- "all": {
3375
- "$ref": "#/$defs/pause"
949
+ "jsonrpc": {
950
+ "const": "2.0"
3376
951
  },
3377
- "runtimes": {
3378
- "type": "object",
3379
- "additionalProperties": {
3380
- "$ref": "#/$defs/pause"
3381
- }
952
+ "id": {
953
+ "type": [
954
+ "string",
955
+ "integer",
956
+ "null"
957
+ ]
3382
958
  },
3383
- "parked": {
3384
- "type": "array",
3385
- "items": {
3386
- "type": "object",
3387
- "properties": {
3388
- "assignmentId": {
3389
- "type": "string"
3390
- },
3391
- "agent": {
3392
- "type": "string"
3393
- },
3394
- "runtime": {
3395
- "type": "string"
3396
- },
3397
- "rootId": {
3398
- "type": "string"
3399
- },
3400
- "reason": {
3401
- "type": "string"
3402
- },
3403
- "since": {
3404
- "type": "string"
3405
- }
3406
- },
3407
- "required": [
3408
- "assignmentId",
3409
- "agent",
3410
- "runtime",
3411
- "rootId",
3412
- "reason",
3413
- "since"
3414
- ],
3415
- "additionalProperties": true
3416
- }
959
+ "method": {
960
+ "type": "string"
961
+ },
962
+ "params": {
963
+ "type": "object"
3417
964
  }
3418
965
  },
3419
966
  "required": [
3420
- "runtimes",
3421
- "parked"
967
+ "jsonrpc",
968
+ "method"
3422
969
  ],
3423
970
  "additionalProperties": true
3424
971
  },
3425
- "preview": {
3426
- "type": "object",
3427
- "properties": {
3428
- "teams": {
3429
- "type": "array",
3430
- "items": {
3431
- "type": "object",
3432
- "properties": {
3433
- "id": {
3434
- "type": "string"
3435
- },
3436
- "label": {
3437
- "type": "string"
3438
- },
3439
- "description": {
3440
- "type": "string"
3441
- }
972
+ "response": {
973
+ "oneOf": [
974
+ {
975
+ "type": "object",
976
+ "properties": {
977
+ "jsonrpc": {
978
+ "const": "2.0"
3442
979
  },
3443
- "required": [
3444
- "id",
3445
- "label"
3446
- ],
3447
- "additionalProperties": true
3448
- }
3449
- },
3450
- "team": {
3451
- "type": "string"
3452
- },
3453
- "teamLabel": {
3454
- "type": "string"
3455
- },
3456
- "agent": {
3457
- "type": "string"
3458
- },
3459
- "runtime": {
3460
- "enum": [
3461
- "claude",
3462
- "codex",
3463
- "acp",
3464
- "antigravity"
3465
- ]
980
+ "id": {
981
+ "type": [
982
+ "string",
983
+ "integer",
984
+ "null"
985
+ ]
986
+ },
987
+ "result": {}
988
+ },
989
+ "required": [
990
+ "jsonrpc",
991
+ "id",
992
+ "result"
993
+ ],
994
+ "additionalProperties": true
3466
995
  },
3467
- "model": {
3468
- "type": "string"
996
+ {
997
+ "type": "object",
998
+ "properties": {
999
+ "jsonrpc": {
1000
+ "const": "2.0"
1001
+ },
1002
+ "id": {
1003
+ "type": [
1004
+ "string",
1005
+ "integer",
1006
+ "null"
1007
+ ]
1008
+ },
1009
+ "error": {
1010
+ "$ref": "#/$defs/error"
1011
+ }
1012
+ },
1013
+ "required": [
1014
+ "jsonrpc",
1015
+ "id",
1016
+ "error"
1017
+ ],
1018
+ "additionalProperties": true
1019
+ }
1020
+ ]
1021
+ },
1022
+ "notification": {
1023
+ "type": "object",
1024
+ "properties": {
1025
+ "jsonrpc": {
1026
+ "const": "2.0"
3469
1027
  },
3470
- "mode": {
3471
- "type": "string"
1028
+ "method": {
1029
+ "const": "event"
3472
1030
  },
3473
- "thinking": {
3474
- "type": "string"
1031
+ "params": {
1032
+ "$ref": "#/$defs/envelope"
3475
1033
  }
3476
1034
  },
3477
1035
  "required": [
3478
- "teams",
3479
- "team",
3480
- "agent",
3481
- "runtime",
3482
- "model",
3483
- "mode",
3484
- "thinking"
1036
+ "jsonrpc",
1037
+ "method",
1038
+ "params"
3485
1039
  ],
3486
1040
  "additionalProperties": true
1041
+ }
1042
+ },
1043
+ "protocolVersion": 1,
1044
+ "methods": {
1045
+ "assignment.recall": {
1046
+ "params": {
1047
+ "type": "object",
1048
+ "properties": {
1049
+ "assignmentId": {
1050
+ "type": "string"
1051
+ },
1052
+ "taskId": {
1053
+ "type": "string"
1054
+ },
1055
+ "projectRoot": {
1056
+ "type": "string"
1057
+ },
1058
+ "question": {
1059
+ "type": "string"
1060
+ }
1061
+ },
1062
+ "required": [
1063
+ "question"
1064
+ ],
1065
+ "additionalProperties": true
1066
+ }
3487
1067
  },
3488
- "treeStatus": {
3489
- "type": "object",
3490
- "properties": {
3491
- "rootId": {
3492
- "type": "string"
1068
+ "board.list": {
1069
+ "params": {
1070
+ "type": "object",
1071
+ "properties": {
1072
+ "projectRoot": {
1073
+ "type": "string"
1074
+ }
3493
1075
  },
3494
- "sessions": {
3495
- "type": "array",
3496
- "items": {
1076
+ "required": [
1077
+ "projectRoot"
1078
+ ],
1079
+ "additionalProperties": true
1080
+ }
1081
+ },
1082
+ "catalog.get": {
1083
+ "params": {
1084
+ "type": "object",
1085
+ "properties": {},
1086
+ "required": [],
1087
+ "additionalProperties": true
1088
+ }
1089
+ },
1090
+ "daemon.hello": {
1091
+ "params": {
1092
+ "type": "object",
1093
+ "properties": {
1094
+ "protocolVersion": {
1095
+ "const": 1
1096
+ },
1097
+ "client": {
3497
1098
  "type": "object",
3498
1099
  "properties": {
3499
- "id": {
3500
- "type": "string"
3501
- },
3502
- "projectRoot": {
3503
- "type": "string"
3504
- },
3505
- "agent": {
3506
- "type": "string"
3507
- },
3508
- "runtime": {
3509
- "enum": [
3510
- "claude",
3511
- "codex",
3512
- "acp",
3513
- "antigravity"
3514
- ]
3515
- },
3516
- "model": {
3517
- "type": "string"
3518
- },
3519
- "mode": {
3520
- "type": "string"
3521
- },
3522
- "thinking": {
3523
- "type": "string"
3524
- },
3525
- "workflow": {
3526
- "type": "object",
3527
- "properties": {
3528
- "mode": {
3529
- "type": "string"
3530
- },
3531
- "maxPeers": {
3532
- "type": "integer"
3533
- },
3534
- "supervisor": {
3535
- "type": "boolean"
3536
- }
3537
- },
3538
- "required": [
3539
- "mode",
3540
- "maxPeers",
3541
- "supervisor"
3542
- ],
3543
- "additionalProperties": true
3544
- },
3545
- "threadId": {
3546
- "type": "string"
3547
- },
3548
- "persistent": {
3549
- "type": "boolean"
3550
- },
3551
- "busy": {
3552
- "type": "boolean"
3553
- },
3554
- "parentId": {
3555
- "type": "string"
3556
- },
3557
- "toolCallId": {
3558
- "type": "string"
3559
- },
3560
- "activeTurnId": {
3561
- "type": "string"
3562
- },
3563
- "parked": {
3564
- "type": "string"
3565
- },
3566
- "instructionsSha": {
3567
- "type": "string"
3568
- },
3569
- "teamLabel": {
1100
+ "name": {
3570
1101
  "type": "string"
3571
1102
  },
3572
- "state": {
3573
- "enum": [
3574
- "running",
3575
- "waiting",
3576
- "waiting_parent",
3577
- "waiting_user",
3578
- "idle"
3579
- ]
3580
- },
3581
- "idleMs": {
3582
- "type": "number"
3583
- },
3584
- "workdir": {
1103
+ "version": {
3585
1104
  "type": "string"
3586
- },
3587
- "unreadMail": {
3588
- "type": "integer",
3589
- "minimum": 0
3590
1105
  }
3591
1106
  },
3592
1107
  "required": [
3593
- "id",
3594
- "projectRoot",
3595
- "agent",
3596
- "runtime",
3597
- "model",
3598
- "mode",
3599
- "thinking",
3600
- "workflow",
3601
- "threadId",
3602
- "persistent",
3603
- "busy",
3604
- "state",
3605
- "idleMs",
3606
- "workdir",
3607
- "unreadMail"
1108
+ "name",
1109
+ "version"
3608
1110
  ],
3609
1111
  "additionalProperties": true
3610
1112
  }
3611
1113
  },
3612
- "assignments": {
3613
- "type": "array",
3614
- "items": {
3615
- "type": "object",
3616
- "properties": {
3617
- "id": {
3618
- "type": "string"
3619
- },
3620
- "requester": {
3621
- "type": "string"
3622
- },
3623
- "isolation": {
3624
- "enum": [
3625
- "shared",
3626
- "worktree"
3627
- ]
3628
- },
3629
- "idleMs": {
3630
- "type": "number"
3631
- }
3632
- },
3633
- "required": [
3634
- "id",
3635
- "requester",
3636
- "isolation",
3637
- "idleMs"
3638
- ],
3639
- "additionalProperties": true
1114
+ "required": [
1115
+ "protocolVersion"
1116
+ ],
1117
+ "additionalProperties": true
1118
+ }
1119
+ },
1120
+ "daemon.pause": {
1121
+ "params": {
1122
+ "type": "object",
1123
+ "properties": {
1124
+ "runtime": {
1125
+ "enum": [
1126
+ "codex",
1127
+ "claude",
1128
+ "acp",
1129
+ "antigravity"
1130
+ ]
1131
+ },
1132
+ "now": {
1133
+ "type": "boolean"
1134
+ },
1135
+ "reason": {
1136
+ "type": "string"
3640
1137
  }
3641
1138
  },
3642
- "questions": {
3643
- "type": "array",
3644
- "items": {
3645
- "$ref": "#/$defs/question"
1139
+ "required": [],
1140
+ "additionalProperties": true
1141
+ }
1142
+ },
1143
+ "daemon.pauses": {
1144
+ "params": {
1145
+ "type": "object",
1146
+ "properties": {},
1147
+ "required": [],
1148
+ "additionalProperties": true
1149
+ }
1150
+ },
1151
+ "daemon.resume": {
1152
+ "params": {
1153
+ "type": "object",
1154
+ "properties": {
1155
+ "runtime": {
1156
+ "enum": [
1157
+ "codex",
1158
+ "claude",
1159
+ "acp",
1160
+ "antigravity"
1161
+ ]
3646
1162
  }
3647
1163
  },
3648
- "worktrees": {
3649
- "type": "array",
3650
- "items": {
3651
- "type": "object",
3652
- "properties": {
3653
- "assignmentId": {
3654
- "type": "string"
3655
- },
3656
- "requester": {
3657
- "type": "string"
3658
- },
3659
- "agent": {
3660
- "type": "string"
3661
- },
3662
- "branch": {
3663
- "type": "string"
3664
- },
3665
- "files": {
3666
- "type": "array",
3667
- "items": {
3668
- "type": "string"
3669
- }
3670
- },
3671
- "stat": {
3672
- "type": "string"
3673
- }
3674
- },
3675
- "required": [
3676
- "assignmentId",
3677
- "requester",
3678
- "agent",
3679
- "branch",
3680
- "files",
3681
- "stat"
3682
- ],
3683
- "additionalProperties": true
1164
+ "required": [],
1165
+ "additionalProperties": true
1166
+ }
1167
+ },
1168
+ "daemon.shutdown": {
1169
+ "params": {
1170
+ "type": "object",
1171
+ "properties": {},
1172
+ "required": [],
1173
+ "additionalProperties": true
1174
+ }
1175
+ },
1176
+ "daemon.status": {
1177
+ "params": {
1178
+ "type": "object",
1179
+ "properties": {},
1180
+ "required": [],
1181
+ "additionalProperties": true
1182
+ }
1183
+ },
1184
+ "daemon.usage": {
1185
+ "params": {
1186
+ "type": "object",
1187
+ "properties": {
1188
+ "refresh": {
1189
+ "type": "boolean"
3684
1190
  }
3685
1191
  },
3686
- "leases": {
3687
- "type": "array",
3688
- "items": {
3689
- "type": "object",
3690
- "properties": {
3691
- "checkout": {
3692
- "type": "string"
3693
- },
3694
- "assignmentId": {
3695
- "type": "string"
3696
- },
3697
- "agent": {
3698
- "type": "string"
3699
- }
3700
- },
3701
- "required": [
3702
- "checkout",
3703
- "assignmentId",
3704
- "agent"
3705
- ],
3706
- "additionalProperties": true
1192
+ "required": [],
1193
+ "additionalProperties": true
1194
+ }
1195
+ },
1196
+ "question.answer": {
1197
+ "params": {
1198
+ "type": "object",
1199
+ "properties": {
1200
+ "questionId": {
1201
+ "type": "string"
1202
+ },
1203
+ "text": {
1204
+ "type": "string"
1205
+ },
1206
+ "dismiss": {
1207
+ "type": "boolean"
1208
+ },
1209
+ "reason": {
1210
+ "type": "string"
3707
1211
  }
3708
1212
  },
3709
- "claims": {
3710
- "type": "array",
3711
- "items": {
3712
- "$ref": "#/$defs/pin"
3713
- }
3714
- }
3715
- },
3716
- "required": [
3717
- "rootId",
3718
- "sessions",
3719
- "assignments",
3720
- "questions",
3721
- "worktrees",
3722
- "leases",
3723
- "claims"
3724
- ],
3725
- "additionalProperties": true
1213
+ "required": [
1214
+ "questionId"
1215
+ ],
1216
+ "additionalProperties": true
1217
+ }
3726
1218
  },
3727
- "health": {
3728
- "type": "object",
3729
- "properties": {
3730
- "live": {
3731
- "type": "boolean"
3732
- },
3733
- "ready": {
3734
- "type": "boolean"
3735
- },
3736
- "checks": {
3737
- "type": "array",
3738
- "items": {
3739
- "type": "object",
3740
- "properties": {
3741
- "id": {
3742
- "type": "string"
3743
- },
3744
- "ok": {
3745
- "type": "boolean"
3746
- },
3747
- "code": {
3748
- "type": "string"
3749
- },
3750
- "message": {
3751
- "type": "string"
3752
- }
3753
- },
3754
- "required": [
3755
- "id",
3756
- "ok"
3757
- ],
3758
- "additionalProperties": true
1219
+ "question.list": {
1220
+ "params": {
1221
+ "type": "object",
1222
+ "properties": {
1223
+ "projectRoot": {
1224
+ "type": "string"
3759
1225
  }
3760
- }
3761
- },
3762
- "required": [
3763
- "live",
3764
- "ready",
3765
- "checks"
3766
- ],
3767
- "additionalProperties": true
3768
- },
3769
- "projectRoot": {
3770
- "type": "string",
3771
- "minLength": 1,
3772
- "maxLength": 4096,
3773
- "description": "An absolute, normalized path on the daemon host to a directory holding .alp/. Compared as is: the daemon never walks up to a parent."
3774
- },
3775
- "taskId": {
3776
- "type": "string",
3777
- "pattern": "^t-[0-9a-f]{4,12}(?:\\.\\d+)*$"
3778
- },
3779
- "taskRow": {
3780
- "type": "object",
3781
- "properties": {
3782
- "id": {
3783
- "$ref": "#/$defs/taskId"
3784
1226
  },
3785
- "title": {
3786
- "type": "string"
1227
+ "required": [],
1228
+ "additionalProperties": true
1229
+ }
1230
+ },
1231
+ "session.archive": {
1232
+ "params": {
1233
+ "type": "object",
1234
+ "properties": {
1235
+ "sessionId": {
1236
+ "type": "string"
1237
+ },
1238
+ "archived": {
1239
+ "type": "boolean"
1240
+ }
3787
1241
  },
3788
- "type": {
3789
- "type": "string"
1242
+ "required": [
1243
+ "sessionId"
1244
+ ],
1245
+ "additionalProperties": true
1246
+ }
1247
+ },
1248
+ "session.attach": {
1249
+ "params": {
1250
+ "type": "object",
1251
+ "properties": {
1252
+ "sessionId": {
1253
+ "type": "string"
1254
+ },
1255
+ "replay": {
1256
+ "type": "boolean"
1257
+ }
3790
1258
  },
3791
- "priority": {
3792
- "type": "integer"
1259
+ "required": [
1260
+ "sessionId"
1261
+ ],
1262
+ "additionalProperties": true
1263
+ }
1264
+ },
1265
+ "session.close": {
1266
+ "params": {
1267
+ "type": "object",
1268
+ "properties": {
1269
+ "sessionId": {
1270
+ "type": "string"
1271
+ }
3793
1272
  },
3794
- "status": {
3795
- "enum": [
3796
- "open",
3797
- "in_progress",
3798
- "review",
3799
- "closed"
3800
- ]
1273
+ "required": [
1274
+ "sessionId"
1275
+ ],
1276
+ "additionalProperties": true
1277
+ }
1278
+ },
1279
+ "session.configure": {
1280
+ "params": {
1281
+ "type": "object",
1282
+ "properties": {
1283
+ "sessionId": {
1284
+ "type": "string"
1285
+ },
1286
+ "mode": {
1287
+ "type": "string"
1288
+ }
3801
1289
  },
3802
- "rev": {
3803
- "type": "integer",
3804
- "minimum": 0
1290
+ "required": [
1291
+ "sessionId",
1292
+ "mode"
1293
+ ],
1294
+ "additionalProperties": true
1295
+ }
1296
+ },
1297
+ "session.create": {
1298
+ "params": {
1299
+ "type": "object",
1300
+ "properties": {
1301
+ "sessionId": {
1302
+ "type": "string"
1303
+ },
1304
+ "spec": {
1305
+ "$ref": "#/$defs/spec"
1306
+ },
1307
+ "history": {
1308
+ "enum": [
1309
+ "skip",
1310
+ "replay"
1311
+ ]
1312
+ },
1313
+ "delegation": {
1314
+ "type": "boolean"
1315
+ },
1316
+ "resume": {
1317
+ "type": "boolean"
1318
+ }
3805
1319
  },
3806
- "parent": {
3807
- "type": "string"
1320
+ "required": [
1321
+ "spec"
1322
+ ],
1323
+ "additionalProperties": true
1324
+ }
1325
+ },
1326
+ "session.get": {
1327
+ "params": {
1328
+ "type": "object",
1329
+ "properties": {
1330
+ "sessionId": {
1331
+ "type": "string"
1332
+ }
3808
1333
  },
3809
- "assignee": {
3810
- "type": "string"
1334
+ "required": [
1335
+ "sessionId"
1336
+ ],
1337
+ "additionalProperties": true
1338
+ }
1339
+ },
1340
+ "session.interrupt": {
1341
+ "params": {
1342
+ "type": "object",
1343
+ "properties": {
1344
+ "sessionId": {
1345
+ "type": "string"
1346
+ }
3811
1347
  },
3812
- "ready": {
3813
- "type": "boolean"
1348
+ "required": [
1349
+ "sessionId"
1350
+ ],
1351
+ "additionalProperties": true
1352
+ }
1353
+ },
1354
+ "session.list": {
1355
+ "params": {
1356
+ "type": "object",
1357
+ "properties": {
1358
+ "projectRoot": {
1359
+ "type": "string"
1360
+ },
1361
+ "rootsOnly": {
1362
+ "type": "boolean"
1363
+ },
1364
+ "includeClosed": {
1365
+ "type": "boolean"
1366
+ },
1367
+ "includeArchived": {
1368
+ "type": "boolean"
1369
+ }
3814
1370
  },
3815
- "blockedBy": {
3816
- "type": "array",
3817
- "items": {
1371
+ "required": [],
1372
+ "additionalProperties": true
1373
+ }
1374
+ },
1375
+ "session.log": {
1376
+ "params": {
1377
+ "type": "object",
1378
+ "properties": {
1379
+ "sessionId": {
3818
1380
  "type": "string"
3819
1381
  }
3820
1382
  },
3821
- "waits": {
3822
- "type": "array",
3823
- "items": {
1383
+ "required": [
1384
+ "sessionId"
1385
+ ],
1386
+ "additionalProperties": true
1387
+ }
1388
+ },
1389
+ "session.message": {
1390
+ "params": {
1391
+ "type": "object",
1392
+ "properties": {
1393
+ "sessionId": {
1394
+ "type": "string"
1395
+ },
1396
+ "text": {
3824
1397
  "type": "string"
3825
1398
  }
3826
1399
  },
3827
- "approvals": {
3828
- "type": "array",
3829
- "items": {
3830
- "type": "object",
3831
- "properties": {
3832
- "gate": {
3833
- "type": "string"
3834
- },
3835
- "note": {
3836
- "type": "string"
3837
- }
3838
- },
3839
- "required": [
3840
- "gate",
3841
- "note"
3842
- ],
3843
- "additionalProperties": true
1400
+ "required": [
1401
+ "sessionId",
1402
+ "text"
1403
+ ],
1404
+ "additionalProperties": true
1405
+ }
1406
+ },
1407
+ "session.preview": {
1408
+ "params": {
1409
+ "type": "object",
1410
+ "properties": {
1411
+ "spec": {
1412
+ "$ref": "#/$defs/spec"
3844
1413
  }
3845
1414
  },
3846
- "handoff": {
3847
- "type": "object",
3848
- "properties": {
3849
- "outcome": {
3850
- "type": "string"
3851
- },
3852
- "summary": {
3853
- "type": "string"
3854
- },
3855
- "agent": {
3856
- "type": "string"
3857
- }
3858
- },
3859
- "required": [
3860
- "outcome",
3861
- "summary"
3862
- ],
3863
- "additionalProperties": true
3864
- },
3865
- "closed": {
3866
- "type": "object",
3867
- "properties": {
3868
- "reason": {
3869
- "type": "string"
3870
- },
3871
- "summary": {
3872
- "type": "string"
3873
- },
3874
- "at": {
3875
- "type": "string"
3876
- }
1415
+ "required": [
1416
+ "spec"
1417
+ ],
1418
+ "additionalProperties": true
1419
+ }
1420
+ },
1421
+ "session.prompt": {
1422
+ "params": {
1423
+ "type": "object",
1424
+ "properties": {
1425
+ "sessionId": {
1426
+ "type": "string"
3877
1427
  },
3878
- "required": [
3879
- "reason",
3880
- "at"
3881
- ],
3882
- "additionalProperties": true
3883
- },
3884
- "description": {
3885
- "type": "string"
3886
- },
3887
- "labels": {
3888
- "type": "array",
3889
- "items": {
1428
+ "clientMessageId": {
3890
1429
  "type": "string"
1430
+ },
1431
+ "delivery": {
1432
+ "enum": [
1433
+ "auto",
1434
+ "steer"
1435
+ ]
1436
+ },
1437
+ "content": {
1438
+ "type": "array",
1439
+ "items": {
1440
+ "type": "object",
1441
+ "properties": {
1442
+ "type": {
1443
+ "type": "string"
1444
+ },
1445
+ "text": {
1446
+ "type": "string"
1447
+ }
1448
+ },
1449
+ "required": [
1450
+ "type"
1451
+ ],
1452
+ "additionalProperties": true
1453
+ }
3891
1454
  }
3892
1455
  },
3893
- "paths": {
3894
- "type": "array",
3895
- "items": {
1456
+ "required": [
1457
+ "sessionId",
1458
+ "clientMessageId",
1459
+ "content"
1460
+ ],
1461
+ "additionalProperties": true
1462
+ }
1463
+ },
1464
+ "session.release": {
1465
+ "params": {
1466
+ "type": "object",
1467
+ "properties": {
1468
+ "sessionId": {
3896
1469
  "type": "string"
3897
1470
  }
3898
1471
  },
3899
- "progress": {
3900
- "type": "object",
3901
- "properties": {
3902
- "done": {
3903
- "type": "integer",
3904
- "minimum": 0
3905
- },
3906
- "total": {
3907
- "type": "integer",
3908
- "minimum": 0
3909
- }
1472
+ "required": [
1473
+ "sessionId"
1474
+ ],
1475
+ "additionalProperties": true
1476
+ }
1477
+ },
1478
+ "session.rename": {
1479
+ "params": {
1480
+ "type": "object",
1481
+ "properties": {
1482
+ "sessionId": {
1483
+ "type": "string"
3910
1484
  },
3911
- "required": [
3912
- "done",
3913
- "total"
3914
- ],
3915
- "additionalProperties": true
3916
- },
3917
- "createdAt": {
3918
- "type": "string"
1485
+ "title": {
1486
+ "type": "string",
1487
+ "minLength": 1,
1488
+ "maxLength": 200
1489
+ }
3919
1490
  },
3920
- "updatedAt": {
3921
- "type": "string"
3922
- }
3923
- },
3924
- "required": [
3925
- "id",
3926
- "title",
3927
- "type",
3928
- "priority",
3929
- "status",
3930
- "rev",
3931
- "ready",
3932
- "updatedAt"
3933
- ],
3934
- "additionalProperties": true
3935
- },
3936
- "libraryKind": {
3937
- "enum": [
3938
- "agents",
3939
- "skills",
3940
- "mcp",
3941
- "hooks",
3942
- "teams",
3943
- "providers"
3944
- ]
3945
- },
3946
- "libraryScope": {
3947
- "enum": [
3948
- "library",
3949
- "project"
3950
- ]
3951
- },
3952
- "librarySource": {
3953
- "enum": [
3954
- "builtin",
3955
- "library",
3956
- "project"
3957
- ]
3958
- },
3959
- "entryName": {
3960
- "type": "string",
3961
- "minLength": 1,
3962
- "maxLength": 128,
3963
- "pattern": "^[A-Za-z0-9_.-]+$",
3964
- "not": {
3965
- "enum": [
3966
- ".",
3967
- ".."
3968
- ]
1491
+ "required": [
1492
+ "sessionId",
1493
+ "title"
1494
+ ],
1495
+ "additionalProperties": true
3969
1496
  }
3970
1497
  },
3971
- "libraryRevision": {
3972
- "type": [
3973
- "string",
3974
- "null"
3975
- ]
3976
- },
3977
- "libraryEntryRow": {
3978
- "type": "object",
3979
- "properties": {
3980
- "name": {
3981
- "type": "string"
3982
- },
3983
- "source": {
3984
- "$ref": "#/$defs/librarySource"
3985
- },
3986
- "overrides": {
3987
- "$ref": "#/$defs/librarySource"
3988
- },
3989
- "description": {
3990
- "type": "string"
3991
- },
3992
- "usedBy": {
3993
- "type": "array",
3994
- "items": {
1498
+ "session.status": {
1499
+ "params": {
1500
+ "type": "object",
1501
+ "properties": {
1502
+ "sessionId": {
3995
1503
  "type": "string"
3996
1504
  }
3997
- }
3998
- },
3999
- "required": [
4000
- "name",
4001
- "source"
4002
- ],
4003
- "additionalProperties": true
4004
- },
4005
- "secretMarker": {
4006
- "type": "object",
4007
- "properties": {
4008
- "$secret": {
4009
- "const": "keep"
4010
- }
4011
- },
4012
- "required": [
4013
- "$secret"
4014
- ],
4015
- "additionalProperties": false,
4016
- "description": "Stands for a stored secret value: read results carry it in place of the value; a save that sends it back keeps the stored value."
4017
- },
4018
- "languageSetting": {
4019
- "type": "object",
4020
- "properties": {
4021
- "language": {
4022
- "type": [
4023
- "string",
4024
- "null"
4025
- ]
4026
- },
4027
- "applies": {
4028
- "type": "string"
4029
1505
  },
4030
- "default": {
4031
- "type": "string"
4032
- }
4033
- },
4034
- "required": [
4035
- "language",
4036
- "applies",
4037
- "default"
4038
- ],
4039
- "additionalProperties": true
1506
+ "required": [
1507
+ "sessionId"
1508
+ ],
1509
+ "additionalProperties": true
1510
+ }
4040
1511
  },
4041
- "teamRow": {
4042
- "type": "object",
4043
- "properties": {
4044
- "id": {
4045
- "type": "string"
4046
- },
4047
- "label": {
4048
- "type": "string"
4049
- },
4050
- "description": {
4051
- "type": "string"
4052
- },
4053
- "source": {
4054
- "$ref": "#/$defs/librarySource"
1512
+ "extension.register": {
1513
+ "params": {
1514
+ "type": "object",
1515
+ "properties": {
1516
+ "method": {
1517
+ "type": "string"
1518
+ }
4055
1519
  },
4056
- "overrides": {
4057
- "$ref": "#/$defs/librarySource"
1520
+ "required": [
1521
+ "method"
1522
+ ],
1523
+ "additionalProperties": true
1524
+ }
1525
+ },
1526
+ "extension.unregister": {
1527
+ "params": {
1528
+ "type": "object",
1529
+ "properties": {
1530
+ "method": {
1531
+ "type": "string"
1532
+ }
4058
1533
  },
4059
- "error": {
4060
- "type": "string"
4061
- }
4062
- },
4063
- "required": [
4064
- "id",
4065
- "source"
4066
- ],
4067
- "additionalProperties": true
1534
+ "required": [
1535
+ "method"
1536
+ ],
1537
+ "additionalProperties": true
1538
+ }
4068
1539
  }
1540
+ },
1541
+ "errors": {
1542
+ "invalidRequest": -32600,
1543
+ "methodNotFound": -32601,
1544
+ "invalidParams": -32602,
1545
+ "failed": 1000,
1546
+ "notFound": 1001,
1547
+ "conflict": 1004,
1548
+ "protocol": 1006
4069
1549
  }
4070
1550
  }