@pixelml/sdk 0.0.0-dev-202512250746

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.
Files changed (71) hide show
  1. package/dist/client.d.ts +7 -0
  2. package/dist/client.js +25 -0
  3. package/dist/gen/client/client.gen.d.ts +2 -0
  4. package/dist/gen/client/client.gen.js +165 -0
  5. package/dist/gen/client/index.d.ts +7 -0
  6. package/dist/gen/client/index.js +5 -0
  7. package/dist/gen/client/types.gen.d.ts +127 -0
  8. package/dist/gen/client/types.gen.js +2 -0
  9. package/dist/gen/client/utils.gen.d.ts +38 -0
  10. package/dist/gen/client/utils.gen.js +226 -0
  11. package/dist/gen/client.gen.d.ts +12 -0
  12. package/dist/gen/client.gen.js +5 -0
  13. package/dist/gen/core/auth.gen.d.ts +18 -0
  14. package/dist/gen/core/auth.gen.js +14 -0
  15. package/dist/gen/core/bodySerializer.gen.d.ts +17 -0
  16. package/dist/gen/core/bodySerializer.gen.js +57 -0
  17. package/dist/gen/core/params.gen.d.ts +33 -0
  18. package/dist/gen/core/params.gen.js +89 -0
  19. package/dist/gen/core/pathSerializer.gen.d.ts +33 -0
  20. package/dist/gen/core/pathSerializer.gen.js +106 -0
  21. package/dist/gen/core/serverSentEvents.gen.d.ts +59 -0
  22. package/dist/gen/core/serverSentEvents.gen.js +117 -0
  23. package/dist/gen/core/types.gen.d.ts +78 -0
  24. package/dist/gen/core/types.gen.js +2 -0
  25. package/dist/gen/core/utils.gen.d.ts +14 -0
  26. package/dist/gen/core/utils.gen.js +69 -0
  27. package/dist/gen/sdk.gen.d.ts +403 -0
  28. package/dist/gen/sdk.gen.js +881 -0
  29. package/dist/gen/types.gen.d.ts +3368 -0
  30. package/dist/gen/types.gen.js +2 -0
  31. package/dist/index.d.ts +10 -0
  32. package/dist/index.js +16 -0
  33. package/dist/server.d.ts +23 -0
  34. package/dist/server.js +91 -0
  35. package/dist/v2/client.d.ts +7 -0
  36. package/dist/v2/client.js +25 -0
  37. package/dist/v2/gen/client/client.gen.d.ts +2 -0
  38. package/dist/v2/gen/client/client.gen.js +225 -0
  39. package/dist/v2/gen/client/index.d.ts +8 -0
  40. package/dist/v2/gen/client/index.js +6 -0
  41. package/dist/v2/gen/client/types.gen.d.ts +117 -0
  42. package/dist/v2/gen/client/types.gen.js +2 -0
  43. package/dist/v2/gen/client/utils.gen.d.ts +33 -0
  44. package/dist/v2/gen/client/utils.gen.js +226 -0
  45. package/dist/v2/gen/client.gen.d.ts +12 -0
  46. package/dist/v2/gen/client.gen.js +3 -0
  47. package/dist/v2/gen/core/auth.gen.d.ts +18 -0
  48. package/dist/v2/gen/core/auth.gen.js +14 -0
  49. package/dist/v2/gen/core/bodySerializer.gen.d.ts +25 -0
  50. package/dist/v2/gen/core/bodySerializer.gen.js +57 -0
  51. package/dist/v2/gen/core/params.gen.d.ts +43 -0
  52. package/dist/v2/gen/core/params.gen.js +102 -0
  53. package/dist/v2/gen/core/pathSerializer.gen.d.ts +33 -0
  54. package/dist/v2/gen/core/pathSerializer.gen.js +106 -0
  55. package/dist/v2/gen/core/queryKeySerializer.gen.d.ts +18 -0
  56. package/dist/v2/gen/core/queryKeySerializer.gen.js +93 -0
  57. package/dist/v2/gen/core/serverSentEvents.gen.d.ts +71 -0
  58. package/dist/v2/gen/core/serverSentEvents.gen.js +131 -0
  59. package/dist/v2/gen/core/types.gen.d.ts +78 -0
  60. package/dist/v2/gen/core/types.gen.js +2 -0
  61. package/dist/v2/gen/core/utils.gen.d.ts +19 -0
  62. package/dist/v2/gen/core/utils.gen.js +87 -0
  63. package/dist/v2/gen/sdk.gen.d.ts +902 -0
  64. package/dist/v2/gen/sdk.gen.js +1726 -0
  65. package/dist/v2/gen/types.gen.d.ts +3719 -0
  66. package/dist/v2/gen/types.gen.js +2 -0
  67. package/dist/v2/index.d.ts +10 -0
  68. package/dist/v2/index.js +16 -0
  69. package/dist/v2/server.d.ts +23 -0
  70. package/dist/v2/server.js +91 -0
  71. package/package.json +50 -0
@@ -0,0 +1,3368 @@
1
+ export type EventServerInstanceDisposed = {
2
+ type: "server.instance.disposed";
3
+ properties: {
4
+ directory: string;
5
+ };
6
+ };
7
+ export type EventInstallationUpdated = {
8
+ type: "installation.updated";
9
+ properties: {
10
+ version: string;
11
+ };
12
+ };
13
+ export type EventInstallationUpdateAvailable = {
14
+ type: "installation.update-available";
15
+ properties: {
16
+ version: string;
17
+ };
18
+ };
19
+ export type EventLspClientDiagnostics = {
20
+ type: "lsp.client.diagnostics";
21
+ properties: {
22
+ serverID: string;
23
+ path: string;
24
+ };
25
+ };
26
+ export type EventLspUpdated = {
27
+ type: "lsp.updated";
28
+ properties: {
29
+ [key: string]: unknown;
30
+ };
31
+ };
32
+ export type FileDiff = {
33
+ file: string;
34
+ before: string;
35
+ after: string;
36
+ additions: number;
37
+ deletions: number;
38
+ };
39
+ export type UserMessage = {
40
+ id: string;
41
+ sessionID: string;
42
+ role: "user";
43
+ time: {
44
+ created: number;
45
+ };
46
+ summary?: {
47
+ title?: string;
48
+ body?: string;
49
+ diffs: Array<FileDiff>;
50
+ };
51
+ agent: string;
52
+ model: {
53
+ providerID: string;
54
+ modelID: string;
55
+ };
56
+ system?: string;
57
+ tools?: {
58
+ [key: string]: boolean;
59
+ };
60
+ };
61
+ export type ProviderAuthError = {
62
+ name: "ProviderAuthError";
63
+ data: {
64
+ providerID: string;
65
+ message: string;
66
+ };
67
+ };
68
+ export type UnknownError = {
69
+ name: "UnknownError";
70
+ data: {
71
+ message: string;
72
+ };
73
+ };
74
+ export type MessageOutputLengthError = {
75
+ name: "MessageOutputLengthError";
76
+ data: {
77
+ [key: string]: unknown;
78
+ };
79
+ };
80
+ export type MessageAbortedError = {
81
+ name: "MessageAbortedError";
82
+ data: {
83
+ message: string;
84
+ };
85
+ };
86
+ export type ApiError = {
87
+ name: "APIError";
88
+ data: {
89
+ message: string;
90
+ statusCode?: number;
91
+ isRetryable: boolean;
92
+ responseHeaders?: {
93
+ [key: string]: string;
94
+ };
95
+ responseBody?: string;
96
+ };
97
+ };
98
+ export type AssistantMessage = {
99
+ id: string;
100
+ sessionID: string;
101
+ role: "assistant";
102
+ time: {
103
+ created: number;
104
+ completed?: number;
105
+ };
106
+ error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | ApiError;
107
+ parentID: string;
108
+ modelID: string;
109
+ providerID: string;
110
+ mode: string;
111
+ path: {
112
+ cwd: string;
113
+ root: string;
114
+ };
115
+ summary?: boolean;
116
+ cost: number;
117
+ tokens: {
118
+ input: number;
119
+ output: number;
120
+ reasoning: number;
121
+ cache: {
122
+ read: number;
123
+ write: number;
124
+ };
125
+ };
126
+ finish?: string;
127
+ };
128
+ export type Message = UserMessage | AssistantMessage;
129
+ export type EventMessageUpdated = {
130
+ type: "message.updated";
131
+ properties: {
132
+ info: Message;
133
+ };
134
+ };
135
+ export type EventMessageRemoved = {
136
+ type: "message.removed";
137
+ properties: {
138
+ sessionID: string;
139
+ messageID: string;
140
+ };
141
+ };
142
+ export type TextPart = {
143
+ id: string;
144
+ sessionID: string;
145
+ messageID: string;
146
+ type: "text";
147
+ text: string;
148
+ synthetic?: boolean;
149
+ ignored?: boolean;
150
+ time?: {
151
+ start: number;
152
+ end?: number;
153
+ };
154
+ metadata?: {
155
+ [key: string]: unknown;
156
+ };
157
+ };
158
+ export type ReasoningPart = {
159
+ id: string;
160
+ sessionID: string;
161
+ messageID: string;
162
+ type: "reasoning";
163
+ text: string;
164
+ metadata?: {
165
+ [key: string]: unknown;
166
+ };
167
+ time: {
168
+ start: number;
169
+ end?: number;
170
+ };
171
+ };
172
+ export type FilePartSourceText = {
173
+ value: string;
174
+ start: number;
175
+ end: number;
176
+ };
177
+ export type FileSource = {
178
+ text: FilePartSourceText;
179
+ type: "file";
180
+ path: string;
181
+ };
182
+ export type Range = {
183
+ start: {
184
+ line: number;
185
+ character: number;
186
+ };
187
+ end: {
188
+ line: number;
189
+ character: number;
190
+ };
191
+ };
192
+ export type SymbolSource = {
193
+ text: FilePartSourceText;
194
+ type: "symbol";
195
+ path: string;
196
+ range: Range;
197
+ name: string;
198
+ kind: number;
199
+ };
200
+ export type FilePartSource = FileSource | SymbolSource;
201
+ export type FilePart = {
202
+ id: string;
203
+ sessionID: string;
204
+ messageID: string;
205
+ type: "file";
206
+ mime: string;
207
+ filename?: string;
208
+ url: string;
209
+ source?: FilePartSource;
210
+ };
211
+ export type ToolStatePending = {
212
+ status: "pending";
213
+ input: {
214
+ [key: string]: unknown;
215
+ };
216
+ raw: string;
217
+ };
218
+ export type ToolStateRunning = {
219
+ status: "running";
220
+ input: {
221
+ [key: string]: unknown;
222
+ };
223
+ title?: string;
224
+ metadata?: {
225
+ [key: string]: unknown;
226
+ };
227
+ time: {
228
+ start: number;
229
+ };
230
+ };
231
+ export type ToolStateCompleted = {
232
+ status: "completed";
233
+ input: {
234
+ [key: string]: unknown;
235
+ };
236
+ output: string;
237
+ title: string;
238
+ metadata: {
239
+ [key: string]: unknown;
240
+ };
241
+ time: {
242
+ start: number;
243
+ end: number;
244
+ compacted?: number;
245
+ };
246
+ attachments?: Array<FilePart>;
247
+ };
248
+ export type ToolStateError = {
249
+ status: "error";
250
+ input: {
251
+ [key: string]: unknown;
252
+ };
253
+ error: string;
254
+ metadata?: {
255
+ [key: string]: unknown;
256
+ };
257
+ time: {
258
+ start: number;
259
+ end: number;
260
+ };
261
+ };
262
+ export type ToolState = ToolStatePending | ToolStateRunning | ToolStateCompleted | ToolStateError;
263
+ export type ToolPart = {
264
+ id: string;
265
+ sessionID: string;
266
+ messageID: string;
267
+ type: "tool";
268
+ callID: string;
269
+ tool: string;
270
+ state: ToolState;
271
+ metadata?: {
272
+ [key: string]: unknown;
273
+ };
274
+ };
275
+ export type StepStartPart = {
276
+ id: string;
277
+ sessionID: string;
278
+ messageID: string;
279
+ type: "step-start";
280
+ snapshot?: string;
281
+ };
282
+ export type StepFinishPart = {
283
+ id: string;
284
+ sessionID: string;
285
+ messageID: string;
286
+ type: "step-finish";
287
+ reason: string;
288
+ snapshot?: string;
289
+ cost: number;
290
+ tokens: {
291
+ input: number;
292
+ output: number;
293
+ reasoning: number;
294
+ cache: {
295
+ read: number;
296
+ write: number;
297
+ };
298
+ };
299
+ };
300
+ export type SnapshotPart = {
301
+ id: string;
302
+ sessionID: string;
303
+ messageID: string;
304
+ type: "snapshot";
305
+ snapshot: string;
306
+ };
307
+ export type PatchPart = {
308
+ id: string;
309
+ sessionID: string;
310
+ messageID: string;
311
+ type: "patch";
312
+ hash: string;
313
+ files: Array<string>;
314
+ };
315
+ export type AgentPart = {
316
+ id: string;
317
+ sessionID: string;
318
+ messageID: string;
319
+ type: "agent";
320
+ name: string;
321
+ source?: {
322
+ value: string;
323
+ start: number;
324
+ end: number;
325
+ };
326
+ };
327
+ export type RetryPart = {
328
+ id: string;
329
+ sessionID: string;
330
+ messageID: string;
331
+ type: "retry";
332
+ attempt: number;
333
+ error: ApiError;
334
+ time: {
335
+ created: number;
336
+ };
337
+ };
338
+ export type CompactionPart = {
339
+ id: string;
340
+ sessionID: string;
341
+ messageID: string;
342
+ type: "compaction";
343
+ auto: boolean;
344
+ };
345
+ export type Part = TextPart | {
346
+ id: string;
347
+ sessionID: string;
348
+ messageID: string;
349
+ type: "subtask";
350
+ prompt: string;
351
+ description: string;
352
+ agent: string;
353
+ } | ReasoningPart | FilePart | ToolPart | StepStartPart | StepFinishPart | SnapshotPart | PatchPart | AgentPart | RetryPart | CompactionPart;
354
+ export type EventMessagePartUpdated = {
355
+ type: "message.part.updated";
356
+ properties: {
357
+ part: Part;
358
+ delta?: string;
359
+ };
360
+ };
361
+ export type EventMessagePartRemoved = {
362
+ type: "message.part.removed";
363
+ properties: {
364
+ sessionID: string;
365
+ messageID: string;
366
+ partID: string;
367
+ };
368
+ };
369
+ export type Permission = {
370
+ id: string;
371
+ type: string;
372
+ pattern?: string | Array<string>;
373
+ sessionID: string;
374
+ messageID: string;
375
+ callID?: string;
376
+ title: string;
377
+ metadata: {
378
+ [key: string]: unknown;
379
+ };
380
+ time: {
381
+ created: number;
382
+ };
383
+ };
384
+ export type EventPermissionUpdated = {
385
+ type: "permission.updated";
386
+ properties: Permission;
387
+ };
388
+ export type EventPermissionReplied = {
389
+ type: "permission.replied";
390
+ properties: {
391
+ sessionID: string;
392
+ permissionID: string;
393
+ response: string;
394
+ };
395
+ };
396
+ export type SessionStatus = {
397
+ type: "idle";
398
+ } | {
399
+ type: "retry";
400
+ attempt: number;
401
+ message: string;
402
+ next: number;
403
+ } | {
404
+ type: "busy";
405
+ };
406
+ export type EventSessionStatus = {
407
+ type: "session.status";
408
+ properties: {
409
+ sessionID: string;
410
+ status: SessionStatus;
411
+ };
412
+ };
413
+ export type EventSessionIdle = {
414
+ type: "session.idle";
415
+ properties: {
416
+ sessionID: string;
417
+ };
418
+ };
419
+ export type EventSessionCompacted = {
420
+ type: "session.compacted";
421
+ properties: {
422
+ sessionID: string;
423
+ };
424
+ };
425
+ export type EventFileEdited = {
426
+ type: "file.edited";
427
+ properties: {
428
+ file: string;
429
+ };
430
+ };
431
+ export type Todo = {
432
+ /**
433
+ * Brief description of the task
434
+ */
435
+ content: string;
436
+ /**
437
+ * Current status of the task: pending, in_progress, completed, cancelled
438
+ */
439
+ status: string;
440
+ /**
441
+ * Priority level of the task: high, medium, low
442
+ */
443
+ priority: string;
444
+ /**
445
+ * Unique identifier for the todo item
446
+ */
447
+ id: string;
448
+ };
449
+ export type EventTodoUpdated = {
450
+ type: "todo.updated";
451
+ properties: {
452
+ sessionID: string;
453
+ todos: Array<Todo>;
454
+ };
455
+ };
456
+ export type EventCommandExecuted = {
457
+ type: "command.executed";
458
+ properties: {
459
+ name: string;
460
+ sessionID: string;
461
+ arguments: string;
462
+ messageID: string;
463
+ };
464
+ };
465
+ export type Session = {
466
+ id: string;
467
+ projectID: string;
468
+ directory: string;
469
+ parentID?: string;
470
+ summary?: {
471
+ additions: number;
472
+ deletions: number;
473
+ files: number;
474
+ diffs?: Array<FileDiff>;
475
+ };
476
+ share?: {
477
+ url: string;
478
+ };
479
+ title: string;
480
+ version: string;
481
+ time: {
482
+ created: number;
483
+ updated: number;
484
+ compacting?: number;
485
+ };
486
+ revert?: {
487
+ messageID: string;
488
+ partID?: string;
489
+ snapshot?: string;
490
+ diff?: string;
491
+ };
492
+ };
493
+ export type EventSessionCreated = {
494
+ type: "session.created";
495
+ properties: {
496
+ info: Session;
497
+ };
498
+ };
499
+ export type EventSessionUpdated = {
500
+ type: "session.updated";
501
+ properties: {
502
+ info: Session;
503
+ };
504
+ };
505
+ export type EventSessionDeleted = {
506
+ type: "session.deleted";
507
+ properties: {
508
+ info: Session;
509
+ };
510
+ };
511
+ export type EventSessionDiff = {
512
+ type: "session.diff";
513
+ properties: {
514
+ sessionID: string;
515
+ diff: Array<FileDiff>;
516
+ };
517
+ };
518
+ export type EventSessionError = {
519
+ type: "session.error";
520
+ properties: {
521
+ sessionID?: string;
522
+ error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | ApiError;
523
+ };
524
+ };
525
+ export type EventFileWatcherUpdated = {
526
+ type: "file.watcher.updated";
527
+ properties: {
528
+ file: string;
529
+ event: "add" | "change" | "unlink";
530
+ };
531
+ };
532
+ export type EventVcsBranchUpdated = {
533
+ type: "vcs.branch.updated";
534
+ properties: {
535
+ branch?: string;
536
+ };
537
+ };
538
+ export type EventTuiPromptAppend = {
539
+ type: "tui.prompt.append";
540
+ properties: {
541
+ text: string;
542
+ };
543
+ };
544
+ export type EventTuiCommandExecute = {
545
+ type: "tui.command.execute";
546
+ properties: {
547
+ command: ("session.list" | "session.new" | "session.share" | "session.interrupt" | "session.compact" | "session.page.up" | "session.page.down" | "session.half.page.up" | "session.half.page.down" | "session.first" | "session.last" | "prompt.clear" | "prompt.submit" | "agent.cycle") | string;
548
+ };
549
+ };
550
+ export type EventTuiToastShow = {
551
+ type: "tui.toast.show";
552
+ properties: {
553
+ title?: string;
554
+ message: string;
555
+ variant: "info" | "success" | "warning" | "error";
556
+ /**
557
+ * Duration in milliseconds
558
+ */
559
+ duration?: number;
560
+ };
561
+ };
562
+ export type Pty = {
563
+ id: string;
564
+ title: string;
565
+ command: string;
566
+ args: Array<string>;
567
+ cwd: string;
568
+ status: "running" | "exited";
569
+ pid: number;
570
+ };
571
+ export type EventPtyCreated = {
572
+ type: "pty.created";
573
+ properties: {
574
+ info: Pty;
575
+ };
576
+ };
577
+ export type EventPtyUpdated = {
578
+ type: "pty.updated";
579
+ properties: {
580
+ info: Pty;
581
+ };
582
+ };
583
+ export type EventPtyExited = {
584
+ type: "pty.exited";
585
+ properties: {
586
+ id: string;
587
+ exitCode: number;
588
+ };
589
+ };
590
+ export type EventPtyDeleted = {
591
+ type: "pty.deleted";
592
+ properties: {
593
+ id: string;
594
+ };
595
+ };
596
+ export type EventServerConnected = {
597
+ type: "server.connected";
598
+ properties: {
599
+ [key: string]: unknown;
600
+ };
601
+ };
602
+ export type Event = EventServerInstanceDisposed | EventInstallationUpdated | EventInstallationUpdateAvailable | EventLspClientDiagnostics | EventLspUpdated | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventPermissionUpdated | EventPermissionReplied | EventSessionStatus | EventSessionIdle | EventSessionCompacted | EventFileEdited | EventTodoUpdated | EventCommandExecuted | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventSessionDiff | EventSessionError | EventFileWatcherUpdated | EventVcsBranchUpdated | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventServerConnected;
603
+ export type GlobalEvent = {
604
+ directory: string;
605
+ payload: Event;
606
+ };
607
+ export type Project = {
608
+ id: string;
609
+ worktree: string;
610
+ vcsDir?: string;
611
+ vcs?: "git";
612
+ time: {
613
+ created: number;
614
+ initialized?: number;
615
+ };
616
+ };
617
+ export type BadRequestError = {
618
+ data: unknown;
619
+ errors: Array<{
620
+ [key: string]: unknown;
621
+ }>;
622
+ success: false;
623
+ };
624
+ export type NotFoundError = {
625
+ name: "NotFoundError";
626
+ data: {
627
+ message: string;
628
+ };
629
+ };
630
+ /**
631
+ * Custom keybind configurations
632
+ */
633
+ export type KeybindsConfig = {
634
+ /**
635
+ * Leader key for keybind combinations
636
+ */
637
+ leader?: string;
638
+ /**
639
+ * Exit the application
640
+ */
641
+ app_exit?: string;
642
+ /**
643
+ * Open external editor
644
+ */
645
+ editor_open?: string;
646
+ /**
647
+ * List available themes
648
+ */
649
+ theme_list?: string;
650
+ /**
651
+ * Toggle sidebar
652
+ */
653
+ sidebar_toggle?: string;
654
+ /**
655
+ * Toggle session scrollbar
656
+ */
657
+ scrollbar_toggle?: string;
658
+ /**
659
+ * Toggle username visibility
660
+ */
661
+ username_toggle?: string;
662
+ /**
663
+ * View status
664
+ */
665
+ status_view?: string;
666
+ /**
667
+ * Export session to editor
668
+ */
669
+ session_export?: string;
670
+ /**
671
+ * Create a new session
672
+ */
673
+ session_new?: string;
674
+ /**
675
+ * List all sessions
676
+ */
677
+ session_list?: string;
678
+ /**
679
+ * Show session timeline
680
+ */
681
+ session_timeline?: string;
682
+ /**
683
+ * Share current session
684
+ */
685
+ session_share?: string;
686
+ /**
687
+ * Unshare current session
688
+ */
689
+ session_unshare?: string;
690
+ /**
691
+ * Interrupt current session
692
+ */
693
+ session_interrupt?: string;
694
+ /**
695
+ * Compact the session
696
+ */
697
+ session_compact?: string;
698
+ /**
699
+ * Scroll messages up by one page
700
+ */
701
+ messages_page_up?: string;
702
+ /**
703
+ * Scroll messages down by one page
704
+ */
705
+ messages_page_down?: string;
706
+ /**
707
+ * Scroll messages up by half page
708
+ */
709
+ messages_half_page_up?: string;
710
+ /**
711
+ * Scroll messages down by half page
712
+ */
713
+ messages_half_page_down?: string;
714
+ /**
715
+ * Navigate to first message
716
+ */
717
+ messages_first?: string;
718
+ /**
719
+ * Navigate to last message
720
+ */
721
+ messages_last?: string;
722
+ /**
723
+ * Navigate to next message
724
+ */
725
+ messages_next?: string;
726
+ /**
727
+ * Navigate to previous message
728
+ */
729
+ messages_previous?: string;
730
+ /**
731
+ * Navigate to last user message
732
+ */
733
+ messages_last_user?: string;
734
+ /**
735
+ * Copy message
736
+ */
737
+ messages_copy?: string;
738
+ /**
739
+ * Undo message
740
+ */
741
+ messages_undo?: string;
742
+ /**
743
+ * Redo message
744
+ */
745
+ messages_redo?: string;
746
+ /**
747
+ * Toggle code block concealment in messages
748
+ */
749
+ messages_toggle_conceal?: string;
750
+ /**
751
+ * Toggle tool details visibility
752
+ */
753
+ tool_details?: string;
754
+ /**
755
+ * List available models
756
+ */
757
+ model_list?: string;
758
+ /**
759
+ * Next recently used model
760
+ */
761
+ model_cycle_recent?: string;
762
+ /**
763
+ * Previous recently used model
764
+ */
765
+ model_cycle_recent_reverse?: string;
766
+ /**
767
+ * List available commands
768
+ */
769
+ command_list?: string;
770
+ /**
771
+ * List agents
772
+ */
773
+ agent_list?: string;
774
+ /**
775
+ * Next agent
776
+ */
777
+ agent_cycle?: string;
778
+ /**
779
+ * Previous agent
780
+ */
781
+ agent_cycle_reverse?: string;
782
+ /**
783
+ * Clear input field
784
+ */
785
+ input_clear?: string;
786
+ /**
787
+ * Forward delete
788
+ */
789
+ input_forward_delete?: string;
790
+ /**
791
+ * Paste from clipboard
792
+ */
793
+ input_paste?: string;
794
+ /**
795
+ * Submit input
796
+ */
797
+ input_submit?: string;
798
+ /**
799
+ * Insert newline in input
800
+ */
801
+ input_newline?: string;
802
+ /**
803
+ * Previous history item
804
+ */
805
+ history_previous?: string;
806
+ /**
807
+ * Next history item
808
+ */
809
+ history_next?: string;
810
+ /**
811
+ * Next child session
812
+ */
813
+ session_child_cycle?: string;
814
+ /**
815
+ * Previous child session
816
+ */
817
+ session_child_cycle_reverse?: string;
818
+ /**
819
+ * Suspend terminal
820
+ */
821
+ terminal_suspend?: string;
822
+ /**
823
+ * Toggle terminal title
824
+ */
825
+ terminal_title_toggle?: string;
826
+ };
827
+ export type AgentConfig = {
828
+ model?: string;
829
+ temperature?: number;
830
+ top_p?: number;
831
+ prompt?: string;
832
+ tools?: {
833
+ [key: string]: boolean;
834
+ };
835
+ disable?: boolean;
836
+ /**
837
+ * Description of when to use the agent
838
+ */
839
+ description?: string;
840
+ mode?: "subagent" | "primary" | "all";
841
+ /**
842
+ * Hex color code for the agent (e.g., #FF5733)
843
+ */
844
+ color?: string;
845
+ /**
846
+ * Maximum number of agentic iterations before forcing text-only response
847
+ */
848
+ maxSteps?: number;
849
+ permission?: {
850
+ edit?: "ask" | "allow" | "deny";
851
+ bash?: ("ask" | "allow" | "deny") | {
852
+ [key: string]: "ask" | "allow" | "deny";
853
+ };
854
+ webfetch?: "ask" | "allow" | "deny";
855
+ doom_loop?: "ask" | "allow" | "deny";
856
+ external_directory?: "ask" | "allow" | "deny";
857
+ };
858
+ [key: string]: unknown | string | number | {
859
+ [key: string]: boolean;
860
+ } | boolean | ("subagent" | "primary" | "all") | number | {
861
+ edit?: "ask" | "allow" | "deny";
862
+ bash?: ("ask" | "allow" | "deny") | {
863
+ [key: string]: "ask" | "allow" | "deny";
864
+ };
865
+ webfetch?: "ask" | "allow" | "deny";
866
+ doom_loop?: "ask" | "allow" | "deny";
867
+ external_directory?: "ask" | "allow" | "deny";
868
+ } | undefined;
869
+ };
870
+ export type ProviderConfig = {
871
+ api?: string;
872
+ name?: string;
873
+ env?: Array<string>;
874
+ id?: string;
875
+ npm?: string;
876
+ models?: {
877
+ [key: string]: {
878
+ id?: string;
879
+ name?: string;
880
+ release_date?: string;
881
+ attachment?: boolean;
882
+ reasoning?: boolean;
883
+ temperature?: boolean;
884
+ tool_call?: boolean;
885
+ cost?: {
886
+ input: number;
887
+ output: number;
888
+ cache_read?: number;
889
+ cache_write?: number;
890
+ context_over_200k?: {
891
+ input: number;
892
+ output: number;
893
+ cache_read?: number;
894
+ cache_write?: number;
895
+ };
896
+ };
897
+ limit?: {
898
+ context: number;
899
+ output: number;
900
+ };
901
+ modalities?: {
902
+ input: Array<"text" | "audio" | "image" | "video" | "pdf">;
903
+ output: Array<"text" | "audio" | "image" | "video" | "pdf">;
904
+ };
905
+ experimental?: boolean;
906
+ status?: "alpha" | "beta" | "deprecated";
907
+ options?: {
908
+ [key: string]: unknown;
909
+ };
910
+ headers?: {
911
+ [key: string]: string;
912
+ };
913
+ provider?: {
914
+ npm: string;
915
+ };
916
+ };
917
+ };
918
+ whitelist?: Array<string>;
919
+ blacklist?: Array<string>;
920
+ options?: {
921
+ apiKey?: string;
922
+ baseURL?: string;
923
+ /**
924
+ * GitHub Enterprise URL for copilot authentication
925
+ */
926
+ enterpriseUrl?: string;
927
+ /**
928
+ * Enable promptCacheKey for this provider (default false)
929
+ */
930
+ setCacheKey?: boolean;
931
+ /**
932
+ * Timeout in milliseconds for requests to this provider. Default is 300000 (5 minutes). Set to false to disable timeout.
933
+ */
934
+ timeout?: number | false;
935
+ [key: string]: unknown | string | boolean | (number | false) | undefined;
936
+ };
937
+ };
938
+ export type McpLocalConfig = {
939
+ /**
940
+ * Type of MCP server connection
941
+ */
942
+ type: "local";
943
+ /**
944
+ * Command and arguments to run the MCP server
945
+ */
946
+ command: Array<string>;
947
+ /**
948
+ * Environment variables to set when running the MCP server
949
+ */
950
+ environment?: {
951
+ [key: string]: string;
952
+ };
953
+ /**
954
+ * Enable or disable the MCP server on startup
955
+ */
956
+ enabled?: boolean;
957
+ /**
958
+ * Timeout in ms for fetching tools from the MCP server. Defaults to 5000 (5 seconds) if not specified.
959
+ */
960
+ timeout?: number;
961
+ };
962
+ export type McpOAuthConfig = {
963
+ /**
964
+ * OAuth client ID. If not provided, dynamic client registration (RFC 7591) will be attempted.
965
+ */
966
+ clientId?: string;
967
+ /**
968
+ * OAuth client secret (if required by the authorization server)
969
+ */
970
+ clientSecret?: string;
971
+ /**
972
+ * OAuth scopes to request during authorization
973
+ */
974
+ scope?: string;
975
+ };
976
+ export type McpRemoteConfig = {
977
+ /**
978
+ * Type of MCP server connection
979
+ */
980
+ type: "remote";
981
+ /**
982
+ * URL of the remote MCP server
983
+ */
984
+ url: string;
985
+ /**
986
+ * Enable or disable the MCP server on startup
987
+ */
988
+ enabled?: boolean;
989
+ /**
990
+ * Headers to send with the request
991
+ */
992
+ headers?: {
993
+ [key: string]: string;
994
+ };
995
+ /**
996
+ * OAuth authentication configuration for the MCP server. Set to false to disable OAuth auto-detection.
997
+ */
998
+ oauth?: McpOAuthConfig | false;
999
+ /**
1000
+ * Timeout in ms for fetching tools from the MCP server. Defaults to 5000 (5 seconds) if not specified.
1001
+ */
1002
+ timeout?: number;
1003
+ };
1004
+ /**
1005
+ * @deprecated Always uses stretch layout.
1006
+ */
1007
+ export type LayoutConfig = "auto" | "stretch";
1008
+ export type Config = {
1009
+ /**
1010
+ * JSON schema reference for configuration validation
1011
+ */
1012
+ $schema?: string;
1013
+ /**
1014
+ * Theme name to use for the interface
1015
+ */
1016
+ theme?: string;
1017
+ keybinds?: KeybindsConfig;
1018
+ /**
1019
+ * TUI specific settings
1020
+ */
1021
+ tui?: {
1022
+ /**
1023
+ * TUI scroll speed
1024
+ */
1025
+ scroll_speed?: number;
1026
+ /**
1027
+ * Scroll acceleration settings
1028
+ */
1029
+ scroll_acceleration?: {
1030
+ /**
1031
+ * Enable scroll acceleration
1032
+ */
1033
+ enabled: boolean;
1034
+ };
1035
+ /**
1036
+ * Control diff rendering style: 'auto' adapts to terminal width, 'stacked' always shows single column
1037
+ */
1038
+ diff_style?: "auto" | "stacked";
1039
+ };
1040
+ /**
1041
+ * Command configuration, see https://claw.ai/docs/commands
1042
+ */
1043
+ command?: {
1044
+ [key: string]: {
1045
+ template: string;
1046
+ description?: string;
1047
+ agent?: string;
1048
+ model?: string;
1049
+ subtask?: boolean;
1050
+ };
1051
+ };
1052
+ watcher?: {
1053
+ ignore?: Array<string>;
1054
+ };
1055
+ plugin?: Array<string>;
1056
+ snapshot?: boolean;
1057
+ /**
1058
+ * Control sharing behavior:'manual' allows manual sharing via commands, 'auto' enables automatic sharing, 'disabled' disables all sharing
1059
+ */
1060
+ share?: "manual" | "auto" | "disabled";
1061
+ /**
1062
+ * @deprecated Use 'share' field instead. Share newly created sessions automatically
1063
+ */
1064
+ autoshare?: boolean;
1065
+ /**
1066
+ * Automatically update to the latest version. Set to true to auto-update, false to disable, or 'notify' to show update notifications
1067
+ */
1068
+ autoupdate?: boolean | "notify";
1069
+ /**
1070
+ * Disable providers that are loaded automatically
1071
+ */
1072
+ disabled_providers?: Array<string>;
1073
+ /**
1074
+ * When set, ONLY these providers will be enabled. All other providers will be ignored
1075
+ */
1076
+ enabled_providers?: Array<string>;
1077
+ /**
1078
+ * Model to use in the format of provider/model, eg anthropic/claude-2
1079
+ */
1080
+ model?: string;
1081
+ /**
1082
+ * Small model to use for tasks like title generation in the format of provider/model
1083
+ */
1084
+ small_model?: string;
1085
+ /**
1086
+ * Custom username to display in conversations instead of system username
1087
+ */
1088
+ username?: string;
1089
+ /**
1090
+ * @deprecated Use `agent` field instead.
1091
+ */
1092
+ mode?: {
1093
+ build?: AgentConfig;
1094
+ plan?: AgentConfig;
1095
+ [key: string]: AgentConfig | undefined;
1096
+ };
1097
+ /**
1098
+ * Agent configuration, see https://claw.ai/docs/agent
1099
+ */
1100
+ agent?: {
1101
+ plan?: AgentConfig;
1102
+ build?: AgentConfig;
1103
+ general?: AgentConfig;
1104
+ explore?: AgentConfig;
1105
+ [key: string]: AgentConfig | undefined;
1106
+ };
1107
+ /**
1108
+ * Custom provider configurations and model overrides
1109
+ */
1110
+ provider?: {
1111
+ [key: string]: ProviderConfig;
1112
+ };
1113
+ /**
1114
+ * MCP (Model Context Protocol) server configurations
1115
+ */
1116
+ mcp?: {
1117
+ [key: string]: McpLocalConfig | McpRemoteConfig;
1118
+ };
1119
+ formatter?: false | {
1120
+ [key: string]: {
1121
+ disabled?: boolean;
1122
+ command?: Array<string>;
1123
+ environment?: {
1124
+ [key: string]: string;
1125
+ };
1126
+ extensions?: Array<string>;
1127
+ };
1128
+ };
1129
+ lsp?: false | {
1130
+ [key: string]: {
1131
+ disabled: true;
1132
+ } | {
1133
+ command: Array<string>;
1134
+ extensions?: Array<string>;
1135
+ disabled?: boolean;
1136
+ env?: {
1137
+ [key: string]: string;
1138
+ };
1139
+ initialization?: {
1140
+ [key: string]: unknown;
1141
+ };
1142
+ };
1143
+ };
1144
+ /**
1145
+ * Additional instruction files or patterns to include
1146
+ */
1147
+ instructions?: Array<string>;
1148
+ layout?: LayoutConfig;
1149
+ permission?: {
1150
+ edit?: "ask" | "allow" | "deny";
1151
+ bash?: ("ask" | "allow" | "deny") | {
1152
+ [key: string]: "ask" | "allow" | "deny";
1153
+ };
1154
+ webfetch?: "ask" | "allow" | "deny";
1155
+ doom_loop?: "ask" | "allow" | "deny";
1156
+ external_directory?: "ask" | "allow" | "deny";
1157
+ };
1158
+ tools?: {
1159
+ [key: string]: boolean;
1160
+ };
1161
+ enterprise?: {
1162
+ /**
1163
+ * Enterprise URL
1164
+ */
1165
+ url?: string;
1166
+ };
1167
+ experimental?: {
1168
+ hook?: {
1169
+ file_edited?: {
1170
+ [key: string]: Array<{
1171
+ command: Array<string>;
1172
+ environment?: {
1173
+ [key: string]: string;
1174
+ };
1175
+ }>;
1176
+ };
1177
+ session_completed?: Array<{
1178
+ command: Array<string>;
1179
+ environment?: {
1180
+ [key: string]: string;
1181
+ };
1182
+ }>;
1183
+ };
1184
+ /**
1185
+ * Number of retries for chat completions on failure
1186
+ */
1187
+ chatMaxRetries?: number;
1188
+ disable_paste_summary?: boolean;
1189
+ /**
1190
+ * Enable the batch tool
1191
+ */
1192
+ batch_tool?: boolean;
1193
+ /**
1194
+ * Enable OpenTelemetry spans for AI SDK calls (using the 'experimental_telemetry' flag)
1195
+ */
1196
+ openTelemetry?: boolean;
1197
+ /**
1198
+ * Tools that should only be available to primary agents.
1199
+ */
1200
+ primary_tools?: Array<string>;
1201
+ };
1202
+ };
1203
+ export type ToolIds = Array<string>;
1204
+ export type ToolListItem = {
1205
+ id: string;
1206
+ description: string;
1207
+ parameters: unknown;
1208
+ };
1209
+ export type ToolList = Array<ToolListItem>;
1210
+ export type Path = {
1211
+ state: string;
1212
+ config: string;
1213
+ worktree: string;
1214
+ directory: string;
1215
+ };
1216
+ export type VcsInfo = {
1217
+ branch: string;
1218
+ };
1219
+ export type TextPartInput = {
1220
+ id?: string;
1221
+ type: "text";
1222
+ text: string;
1223
+ synthetic?: boolean;
1224
+ ignored?: boolean;
1225
+ time?: {
1226
+ start: number;
1227
+ end?: number;
1228
+ };
1229
+ metadata?: {
1230
+ [key: string]: unknown;
1231
+ };
1232
+ };
1233
+ export type FilePartInput = {
1234
+ id?: string;
1235
+ type: "file";
1236
+ mime: string;
1237
+ filename?: string;
1238
+ url: string;
1239
+ source?: FilePartSource;
1240
+ };
1241
+ export type AgentPartInput = {
1242
+ id?: string;
1243
+ type: "agent";
1244
+ name: string;
1245
+ source?: {
1246
+ value: string;
1247
+ start: number;
1248
+ end: number;
1249
+ };
1250
+ };
1251
+ export type SubtaskPartInput = {
1252
+ id?: string;
1253
+ type: "subtask";
1254
+ prompt: string;
1255
+ description: string;
1256
+ agent: string;
1257
+ };
1258
+ export type Command = {
1259
+ name: string;
1260
+ description?: string;
1261
+ agent?: string;
1262
+ model?: string;
1263
+ template: string;
1264
+ subtask?: boolean;
1265
+ };
1266
+ export type Model = {
1267
+ id: string;
1268
+ providerID: string;
1269
+ api: {
1270
+ id: string;
1271
+ url: string;
1272
+ npm: string;
1273
+ };
1274
+ name: string;
1275
+ capabilities: {
1276
+ temperature: boolean;
1277
+ reasoning: boolean;
1278
+ attachment: boolean;
1279
+ toolcall: boolean;
1280
+ input: {
1281
+ text: boolean;
1282
+ audio: boolean;
1283
+ image: boolean;
1284
+ video: boolean;
1285
+ pdf: boolean;
1286
+ };
1287
+ output: {
1288
+ text: boolean;
1289
+ audio: boolean;
1290
+ image: boolean;
1291
+ video: boolean;
1292
+ pdf: boolean;
1293
+ };
1294
+ };
1295
+ cost: {
1296
+ input: number;
1297
+ output: number;
1298
+ cache: {
1299
+ read: number;
1300
+ write: number;
1301
+ };
1302
+ experimentalOver200K?: {
1303
+ input: number;
1304
+ output: number;
1305
+ cache: {
1306
+ read: number;
1307
+ write: number;
1308
+ };
1309
+ };
1310
+ };
1311
+ limit: {
1312
+ context: number;
1313
+ output: number;
1314
+ };
1315
+ status: "alpha" | "beta" | "deprecated" | "active";
1316
+ options: {
1317
+ [key: string]: unknown;
1318
+ };
1319
+ headers: {
1320
+ [key: string]: string;
1321
+ };
1322
+ };
1323
+ export type Provider = {
1324
+ id: string;
1325
+ name: string;
1326
+ source: "env" | "config" | "custom" | "api";
1327
+ env: Array<string>;
1328
+ key?: string;
1329
+ options: {
1330
+ [key: string]: unknown;
1331
+ };
1332
+ models: {
1333
+ [key: string]: Model;
1334
+ };
1335
+ };
1336
+ export type ProviderAuthMethod = {
1337
+ type: "oauth" | "api";
1338
+ label: string;
1339
+ };
1340
+ export type ProviderAuthAuthorization = {
1341
+ url: string;
1342
+ method: "auto" | "code";
1343
+ instructions: string;
1344
+ };
1345
+ export type Symbol = {
1346
+ name: string;
1347
+ kind: number;
1348
+ location: {
1349
+ uri: string;
1350
+ range: Range;
1351
+ };
1352
+ };
1353
+ export type FileNode = {
1354
+ name: string;
1355
+ path: string;
1356
+ absolute: string;
1357
+ type: "file" | "directory";
1358
+ ignored: boolean;
1359
+ };
1360
+ export type FileContent = {
1361
+ type: "text";
1362
+ content: string;
1363
+ diff?: string;
1364
+ patch?: {
1365
+ oldFileName: string;
1366
+ newFileName: string;
1367
+ oldHeader?: string;
1368
+ newHeader?: string;
1369
+ hunks: Array<{
1370
+ oldStart: number;
1371
+ oldLines: number;
1372
+ newStart: number;
1373
+ newLines: number;
1374
+ lines: Array<string>;
1375
+ }>;
1376
+ index?: string;
1377
+ };
1378
+ encoding?: "base64";
1379
+ mimeType?: string;
1380
+ };
1381
+ export type File = {
1382
+ path: string;
1383
+ added: number;
1384
+ removed: number;
1385
+ status: "added" | "deleted" | "modified";
1386
+ };
1387
+ export type Agent = {
1388
+ name: string;
1389
+ description?: string;
1390
+ mode: "subagent" | "primary" | "all";
1391
+ builtIn: boolean;
1392
+ topP?: number;
1393
+ temperature?: number;
1394
+ color?: string;
1395
+ permission: {
1396
+ edit: "ask" | "allow" | "deny";
1397
+ bash: {
1398
+ [key: string]: "ask" | "allow" | "deny";
1399
+ };
1400
+ webfetch?: "ask" | "allow" | "deny";
1401
+ doom_loop?: "ask" | "allow" | "deny";
1402
+ external_directory?: "ask" | "allow" | "deny";
1403
+ };
1404
+ model?: {
1405
+ modelID: string;
1406
+ providerID: string;
1407
+ };
1408
+ prompt?: string;
1409
+ tools: {
1410
+ [key: string]: boolean;
1411
+ };
1412
+ options: {
1413
+ [key: string]: unknown;
1414
+ };
1415
+ maxSteps?: number;
1416
+ };
1417
+ export type McpStatusConnected = {
1418
+ status: "connected";
1419
+ };
1420
+ export type McpStatusDisabled = {
1421
+ status: "disabled";
1422
+ };
1423
+ export type McpStatusFailed = {
1424
+ status: "failed";
1425
+ error: string;
1426
+ };
1427
+ export type McpStatusNeedsAuth = {
1428
+ status: "needs_auth";
1429
+ };
1430
+ export type McpStatusNeedsClientRegistration = {
1431
+ status: "needs_client_registration";
1432
+ error: string;
1433
+ };
1434
+ export type McpStatus = McpStatusConnected | McpStatusDisabled | McpStatusFailed | McpStatusNeedsAuth | McpStatusNeedsClientRegistration;
1435
+ export type LspStatus = {
1436
+ id: string;
1437
+ name: string;
1438
+ root: string;
1439
+ status: "connected" | "error";
1440
+ };
1441
+ export type FormatterStatus = {
1442
+ name: string;
1443
+ extensions: Array<string>;
1444
+ enabled: boolean;
1445
+ };
1446
+ export type OAuth = {
1447
+ type: "oauth";
1448
+ refresh: string;
1449
+ access: string;
1450
+ expires: number;
1451
+ enterpriseUrl?: string;
1452
+ };
1453
+ export type ApiAuth = {
1454
+ type: "api";
1455
+ key: string;
1456
+ };
1457
+ export type WellKnownAuth = {
1458
+ type: "wellknown";
1459
+ key: string;
1460
+ token: string;
1461
+ };
1462
+ export type Auth = OAuth | ApiAuth | WellKnownAuth;
1463
+ export type GlobalEventData = {
1464
+ body?: never;
1465
+ path?: never;
1466
+ query?: never;
1467
+ url: "/global/event";
1468
+ };
1469
+ export type GlobalEventResponses = {
1470
+ /**
1471
+ * Event stream
1472
+ */
1473
+ 200: GlobalEvent;
1474
+ };
1475
+ export type GlobalEventResponse = GlobalEventResponses[keyof GlobalEventResponses];
1476
+ export type ProjectListData = {
1477
+ body?: never;
1478
+ path?: never;
1479
+ query?: {
1480
+ directory?: string;
1481
+ };
1482
+ url: "/project";
1483
+ };
1484
+ export type ProjectListResponses = {
1485
+ /**
1486
+ * List of projects
1487
+ */
1488
+ 200: Array<Project>;
1489
+ };
1490
+ export type ProjectListResponse = ProjectListResponses[keyof ProjectListResponses];
1491
+ export type ProjectCurrentData = {
1492
+ body?: never;
1493
+ path?: never;
1494
+ query?: {
1495
+ directory?: string;
1496
+ };
1497
+ url: "/project/current";
1498
+ };
1499
+ export type ProjectCurrentResponses = {
1500
+ /**
1501
+ * Current project
1502
+ */
1503
+ 200: Project;
1504
+ };
1505
+ export type ProjectCurrentResponse = ProjectCurrentResponses[keyof ProjectCurrentResponses];
1506
+ export type PtyListData = {
1507
+ body?: never;
1508
+ path?: never;
1509
+ query?: {
1510
+ directory?: string;
1511
+ };
1512
+ url: "/pty";
1513
+ };
1514
+ export type PtyListResponses = {
1515
+ /**
1516
+ * List of sessions
1517
+ */
1518
+ 200: Array<Pty>;
1519
+ };
1520
+ export type PtyListResponse = PtyListResponses[keyof PtyListResponses];
1521
+ export type PtyCreateData = {
1522
+ body?: {
1523
+ command?: string;
1524
+ args?: Array<string>;
1525
+ cwd?: string;
1526
+ title?: string;
1527
+ env?: {
1528
+ [key: string]: string;
1529
+ };
1530
+ };
1531
+ path?: never;
1532
+ query?: {
1533
+ directory?: string;
1534
+ };
1535
+ url: "/pty";
1536
+ };
1537
+ export type PtyCreateErrors = {
1538
+ /**
1539
+ * Bad request
1540
+ */
1541
+ 400: BadRequestError;
1542
+ };
1543
+ export type PtyCreateError = PtyCreateErrors[keyof PtyCreateErrors];
1544
+ export type PtyCreateResponses = {
1545
+ /**
1546
+ * Created session
1547
+ */
1548
+ 200: Pty;
1549
+ };
1550
+ export type PtyCreateResponse = PtyCreateResponses[keyof PtyCreateResponses];
1551
+ export type PtyRemoveData = {
1552
+ body?: never;
1553
+ path: {
1554
+ id: string;
1555
+ };
1556
+ query?: {
1557
+ directory?: string;
1558
+ };
1559
+ url: "/pty/{id}";
1560
+ };
1561
+ export type PtyRemoveErrors = {
1562
+ /**
1563
+ * Not found
1564
+ */
1565
+ 404: NotFoundError;
1566
+ };
1567
+ export type PtyRemoveError = PtyRemoveErrors[keyof PtyRemoveErrors];
1568
+ export type PtyRemoveResponses = {
1569
+ /**
1570
+ * Session removed
1571
+ */
1572
+ 200: boolean;
1573
+ };
1574
+ export type PtyRemoveResponse = PtyRemoveResponses[keyof PtyRemoveResponses];
1575
+ export type PtyGetData = {
1576
+ body?: never;
1577
+ path: {
1578
+ id: string;
1579
+ };
1580
+ query?: {
1581
+ directory?: string;
1582
+ };
1583
+ url: "/pty/{id}";
1584
+ };
1585
+ export type PtyGetErrors = {
1586
+ /**
1587
+ * Not found
1588
+ */
1589
+ 404: NotFoundError;
1590
+ };
1591
+ export type PtyGetError = PtyGetErrors[keyof PtyGetErrors];
1592
+ export type PtyGetResponses = {
1593
+ /**
1594
+ * Session info
1595
+ */
1596
+ 200: Pty;
1597
+ };
1598
+ export type PtyGetResponse = PtyGetResponses[keyof PtyGetResponses];
1599
+ export type PtyUpdateData = {
1600
+ body?: {
1601
+ title?: string;
1602
+ size?: {
1603
+ rows: number;
1604
+ cols: number;
1605
+ };
1606
+ };
1607
+ path: {
1608
+ id: string;
1609
+ };
1610
+ query?: {
1611
+ directory?: string;
1612
+ };
1613
+ url: "/pty/{id}";
1614
+ };
1615
+ export type PtyUpdateErrors = {
1616
+ /**
1617
+ * Bad request
1618
+ */
1619
+ 400: BadRequestError;
1620
+ };
1621
+ export type PtyUpdateError = PtyUpdateErrors[keyof PtyUpdateErrors];
1622
+ export type PtyUpdateResponses = {
1623
+ /**
1624
+ * Updated session
1625
+ */
1626
+ 200: Pty;
1627
+ };
1628
+ export type PtyUpdateResponse = PtyUpdateResponses[keyof PtyUpdateResponses];
1629
+ export type PtyConnectData = {
1630
+ body?: never;
1631
+ path: {
1632
+ id: string;
1633
+ };
1634
+ query?: {
1635
+ directory?: string;
1636
+ };
1637
+ url: "/pty/{id}/connect";
1638
+ };
1639
+ export type PtyConnectErrors = {
1640
+ /**
1641
+ * Not found
1642
+ */
1643
+ 404: NotFoundError;
1644
+ };
1645
+ export type PtyConnectError = PtyConnectErrors[keyof PtyConnectErrors];
1646
+ export type PtyConnectResponses = {
1647
+ /**
1648
+ * Connected session
1649
+ */
1650
+ 200: boolean;
1651
+ };
1652
+ export type PtyConnectResponse = PtyConnectResponses[keyof PtyConnectResponses];
1653
+ export type ConfigGetData = {
1654
+ body?: never;
1655
+ path?: never;
1656
+ query?: {
1657
+ directory?: string;
1658
+ };
1659
+ url: "/config";
1660
+ };
1661
+ export type ConfigGetResponses = {
1662
+ /**
1663
+ * Get config info
1664
+ */
1665
+ 200: Config;
1666
+ };
1667
+ export type ConfigGetResponse = ConfigGetResponses[keyof ConfigGetResponses];
1668
+ export type ConfigUpdateData = {
1669
+ body?: Config;
1670
+ path?: never;
1671
+ query?: {
1672
+ directory?: string;
1673
+ };
1674
+ url: "/config";
1675
+ };
1676
+ export type ConfigUpdateErrors = {
1677
+ /**
1678
+ * Bad request
1679
+ */
1680
+ 400: BadRequestError;
1681
+ };
1682
+ export type ConfigUpdateError = ConfigUpdateErrors[keyof ConfigUpdateErrors];
1683
+ export type ConfigUpdateResponses = {
1684
+ /**
1685
+ * Successfully updated config
1686
+ */
1687
+ 200: Config;
1688
+ };
1689
+ export type ConfigUpdateResponse = ConfigUpdateResponses[keyof ConfigUpdateResponses];
1690
+ export type ToolIdsData = {
1691
+ body?: never;
1692
+ path?: never;
1693
+ query?: {
1694
+ directory?: string;
1695
+ };
1696
+ url: "/experimental/tool/ids";
1697
+ };
1698
+ export type ToolIdsErrors = {
1699
+ /**
1700
+ * Bad request
1701
+ */
1702
+ 400: BadRequestError;
1703
+ };
1704
+ export type ToolIdsError = ToolIdsErrors[keyof ToolIdsErrors];
1705
+ export type ToolIdsResponses = {
1706
+ /**
1707
+ * Tool IDs
1708
+ */
1709
+ 200: ToolIds;
1710
+ };
1711
+ export type ToolIdsResponse = ToolIdsResponses[keyof ToolIdsResponses];
1712
+ export type ToolListData = {
1713
+ body?: never;
1714
+ path?: never;
1715
+ query: {
1716
+ directory?: string;
1717
+ provider: string;
1718
+ model: string;
1719
+ };
1720
+ url: "/experimental/tool";
1721
+ };
1722
+ export type ToolListErrors = {
1723
+ /**
1724
+ * Bad request
1725
+ */
1726
+ 400: BadRequestError;
1727
+ };
1728
+ export type ToolListError = ToolListErrors[keyof ToolListErrors];
1729
+ export type ToolListResponses = {
1730
+ /**
1731
+ * Tools
1732
+ */
1733
+ 200: ToolList;
1734
+ };
1735
+ export type ToolListResponse = ToolListResponses[keyof ToolListResponses];
1736
+ export type InstanceDisposeData = {
1737
+ body?: never;
1738
+ path?: never;
1739
+ query?: {
1740
+ directory?: string;
1741
+ };
1742
+ url: "/instance/dispose";
1743
+ };
1744
+ export type InstanceDisposeResponses = {
1745
+ /**
1746
+ * Instance disposed
1747
+ */
1748
+ 200: boolean;
1749
+ };
1750
+ export type InstanceDisposeResponse = InstanceDisposeResponses[keyof InstanceDisposeResponses];
1751
+ export type PathGetData = {
1752
+ body?: never;
1753
+ path?: never;
1754
+ query?: {
1755
+ directory?: string;
1756
+ };
1757
+ url: "/path";
1758
+ };
1759
+ export type PathGetResponses = {
1760
+ /**
1761
+ * Path
1762
+ */
1763
+ 200: Path;
1764
+ };
1765
+ export type PathGetResponse = PathGetResponses[keyof PathGetResponses];
1766
+ export type VcsGetData = {
1767
+ body?: never;
1768
+ path?: never;
1769
+ query?: {
1770
+ directory?: string;
1771
+ };
1772
+ url: "/vcs";
1773
+ };
1774
+ export type VcsGetResponses = {
1775
+ /**
1776
+ * VCS info
1777
+ */
1778
+ 200: VcsInfo;
1779
+ };
1780
+ export type VcsGetResponse = VcsGetResponses[keyof VcsGetResponses];
1781
+ export type SessionListData = {
1782
+ body?: never;
1783
+ path?: never;
1784
+ query?: {
1785
+ directory?: string;
1786
+ };
1787
+ url: "/session";
1788
+ };
1789
+ export type SessionListResponses = {
1790
+ /**
1791
+ * List of sessions
1792
+ */
1793
+ 200: Array<Session>;
1794
+ };
1795
+ export type SessionListResponse = SessionListResponses[keyof SessionListResponses];
1796
+ export type SessionCreateData = {
1797
+ body?: {
1798
+ parentID?: string;
1799
+ title?: string;
1800
+ };
1801
+ path?: never;
1802
+ query?: {
1803
+ directory?: string;
1804
+ };
1805
+ url: "/session";
1806
+ };
1807
+ export type SessionCreateErrors = {
1808
+ /**
1809
+ * Bad request
1810
+ */
1811
+ 400: BadRequestError;
1812
+ };
1813
+ export type SessionCreateError = SessionCreateErrors[keyof SessionCreateErrors];
1814
+ export type SessionCreateResponses = {
1815
+ /**
1816
+ * Successfully created session
1817
+ */
1818
+ 200: Session;
1819
+ };
1820
+ export type SessionCreateResponse = SessionCreateResponses[keyof SessionCreateResponses];
1821
+ export type SessionStatusData = {
1822
+ body?: never;
1823
+ path?: never;
1824
+ query?: {
1825
+ directory?: string;
1826
+ };
1827
+ url: "/session/status";
1828
+ };
1829
+ export type SessionStatusErrors = {
1830
+ /**
1831
+ * Bad request
1832
+ */
1833
+ 400: BadRequestError;
1834
+ };
1835
+ export type SessionStatusError = SessionStatusErrors[keyof SessionStatusErrors];
1836
+ export type SessionStatusResponses = {
1837
+ /**
1838
+ * Get session status
1839
+ */
1840
+ 200: {
1841
+ [key: string]: SessionStatus;
1842
+ };
1843
+ };
1844
+ export type SessionStatusResponse = SessionStatusResponses[keyof SessionStatusResponses];
1845
+ export type SessionDeleteData = {
1846
+ body?: never;
1847
+ path: {
1848
+ id: string;
1849
+ };
1850
+ query?: {
1851
+ directory?: string;
1852
+ };
1853
+ url: "/session/{id}";
1854
+ };
1855
+ export type SessionDeleteErrors = {
1856
+ /**
1857
+ * Bad request
1858
+ */
1859
+ 400: BadRequestError;
1860
+ /**
1861
+ * Not found
1862
+ */
1863
+ 404: NotFoundError;
1864
+ };
1865
+ export type SessionDeleteError = SessionDeleteErrors[keyof SessionDeleteErrors];
1866
+ export type SessionDeleteResponses = {
1867
+ /**
1868
+ * Successfully deleted session
1869
+ */
1870
+ 200: boolean;
1871
+ };
1872
+ export type SessionDeleteResponse = SessionDeleteResponses[keyof SessionDeleteResponses];
1873
+ export type SessionGetData = {
1874
+ body?: never;
1875
+ path: {
1876
+ id: string;
1877
+ };
1878
+ query?: {
1879
+ directory?: string;
1880
+ };
1881
+ url: "/session/{id}";
1882
+ };
1883
+ export type SessionGetErrors = {
1884
+ /**
1885
+ * Bad request
1886
+ */
1887
+ 400: BadRequestError;
1888
+ /**
1889
+ * Not found
1890
+ */
1891
+ 404: NotFoundError;
1892
+ };
1893
+ export type SessionGetError = SessionGetErrors[keyof SessionGetErrors];
1894
+ export type SessionGetResponses = {
1895
+ /**
1896
+ * Get session
1897
+ */
1898
+ 200: Session;
1899
+ };
1900
+ export type SessionGetResponse = SessionGetResponses[keyof SessionGetResponses];
1901
+ export type SessionUpdateData = {
1902
+ body?: {
1903
+ title?: string;
1904
+ };
1905
+ path: {
1906
+ id: string;
1907
+ };
1908
+ query?: {
1909
+ directory?: string;
1910
+ };
1911
+ url: "/session/{id}";
1912
+ };
1913
+ export type SessionUpdateErrors = {
1914
+ /**
1915
+ * Bad request
1916
+ */
1917
+ 400: BadRequestError;
1918
+ /**
1919
+ * Not found
1920
+ */
1921
+ 404: NotFoundError;
1922
+ };
1923
+ export type SessionUpdateError = SessionUpdateErrors[keyof SessionUpdateErrors];
1924
+ export type SessionUpdateResponses = {
1925
+ /**
1926
+ * Successfully updated session
1927
+ */
1928
+ 200: Session;
1929
+ };
1930
+ export type SessionUpdateResponse = SessionUpdateResponses[keyof SessionUpdateResponses];
1931
+ export type SessionChildrenData = {
1932
+ body?: never;
1933
+ path: {
1934
+ id: string;
1935
+ };
1936
+ query?: {
1937
+ directory?: string;
1938
+ };
1939
+ url: "/session/{id}/children";
1940
+ };
1941
+ export type SessionChildrenErrors = {
1942
+ /**
1943
+ * Bad request
1944
+ */
1945
+ 400: BadRequestError;
1946
+ /**
1947
+ * Not found
1948
+ */
1949
+ 404: NotFoundError;
1950
+ };
1951
+ export type SessionChildrenError = SessionChildrenErrors[keyof SessionChildrenErrors];
1952
+ export type SessionChildrenResponses = {
1953
+ /**
1954
+ * List of children
1955
+ */
1956
+ 200: Array<Session>;
1957
+ };
1958
+ export type SessionChildrenResponse = SessionChildrenResponses[keyof SessionChildrenResponses];
1959
+ export type SessionTodoData = {
1960
+ body?: never;
1961
+ path: {
1962
+ /**
1963
+ * Session ID
1964
+ */
1965
+ id: string;
1966
+ };
1967
+ query?: {
1968
+ directory?: string;
1969
+ };
1970
+ url: "/session/{id}/todo";
1971
+ };
1972
+ export type SessionTodoErrors = {
1973
+ /**
1974
+ * Bad request
1975
+ */
1976
+ 400: BadRequestError;
1977
+ /**
1978
+ * Not found
1979
+ */
1980
+ 404: NotFoundError;
1981
+ };
1982
+ export type SessionTodoError = SessionTodoErrors[keyof SessionTodoErrors];
1983
+ export type SessionTodoResponses = {
1984
+ /**
1985
+ * Todo list
1986
+ */
1987
+ 200: Array<Todo>;
1988
+ };
1989
+ export type SessionTodoResponse = SessionTodoResponses[keyof SessionTodoResponses];
1990
+ export type SessionInitData = {
1991
+ body?: {
1992
+ modelID: string;
1993
+ providerID: string;
1994
+ messageID: string;
1995
+ };
1996
+ path: {
1997
+ /**
1998
+ * Session ID
1999
+ */
2000
+ id: string;
2001
+ };
2002
+ query?: {
2003
+ directory?: string;
2004
+ };
2005
+ url: "/session/{id}/init";
2006
+ };
2007
+ export type SessionInitErrors = {
2008
+ /**
2009
+ * Bad request
2010
+ */
2011
+ 400: BadRequestError;
2012
+ /**
2013
+ * Not found
2014
+ */
2015
+ 404: NotFoundError;
2016
+ };
2017
+ export type SessionInitError = SessionInitErrors[keyof SessionInitErrors];
2018
+ export type SessionInitResponses = {
2019
+ /**
2020
+ * 200
2021
+ */
2022
+ 200: boolean;
2023
+ };
2024
+ export type SessionInitResponse = SessionInitResponses[keyof SessionInitResponses];
2025
+ export type SessionForkData = {
2026
+ body?: {
2027
+ messageID?: string;
2028
+ };
2029
+ path: {
2030
+ id: string;
2031
+ };
2032
+ query?: {
2033
+ directory?: string;
2034
+ };
2035
+ url: "/session/{id}/fork";
2036
+ };
2037
+ export type SessionForkResponses = {
2038
+ /**
2039
+ * 200
2040
+ */
2041
+ 200: Session;
2042
+ };
2043
+ export type SessionForkResponse = SessionForkResponses[keyof SessionForkResponses];
2044
+ export type SessionAbortData = {
2045
+ body?: never;
2046
+ path: {
2047
+ id: string;
2048
+ };
2049
+ query?: {
2050
+ directory?: string;
2051
+ };
2052
+ url: "/session/{id}/abort";
2053
+ };
2054
+ export type SessionAbortErrors = {
2055
+ /**
2056
+ * Bad request
2057
+ */
2058
+ 400: BadRequestError;
2059
+ /**
2060
+ * Not found
2061
+ */
2062
+ 404: NotFoundError;
2063
+ };
2064
+ export type SessionAbortError = SessionAbortErrors[keyof SessionAbortErrors];
2065
+ export type SessionAbortResponses = {
2066
+ /**
2067
+ * Aborted session
2068
+ */
2069
+ 200: boolean;
2070
+ };
2071
+ export type SessionAbortResponse = SessionAbortResponses[keyof SessionAbortResponses];
2072
+ export type SessionUnshareData = {
2073
+ body?: never;
2074
+ path: {
2075
+ id: string;
2076
+ };
2077
+ query?: {
2078
+ directory?: string;
2079
+ };
2080
+ url: "/session/{id}/share";
2081
+ };
2082
+ export type SessionUnshareErrors = {
2083
+ /**
2084
+ * Bad request
2085
+ */
2086
+ 400: BadRequestError;
2087
+ /**
2088
+ * Not found
2089
+ */
2090
+ 404: NotFoundError;
2091
+ };
2092
+ export type SessionUnshareError = SessionUnshareErrors[keyof SessionUnshareErrors];
2093
+ export type SessionUnshareResponses = {
2094
+ /**
2095
+ * Successfully unshared session
2096
+ */
2097
+ 200: Session;
2098
+ };
2099
+ export type SessionUnshareResponse = SessionUnshareResponses[keyof SessionUnshareResponses];
2100
+ export type SessionShareData = {
2101
+ body?: never;
2102
+ path: {
2103
+ id: string;
2104
+ };
2105
+ query?: {
2106
+ directory?: string;
2107
+ };
2108
+ url: "/session/{id}/share";
2109
+ };
2110
+ export type SessionShareErrors = {
2111
+ /**
2112
+ * Bad request
2113
+ */
2114
+ 400: BadRequestError;
2115
+ /**
2116
+ * Not found
2117
+ */
2118
+ 404: NotFoundError;
2119
+ };
2120
+ export type SessionShareError = SessionShareErrors[keyof SessionShareErrors];
2121
+ export type SessionShareResponses = {
2122
+ /**
2123
+ * Successfully shared session
2124
+ */
2125
+ 200: Session;
2126
+ };
2127
+ export type SessionShareResponse = SessionShareResponses[keyof SessionShareResponses];
2128
+ export type SessionDiffData = {
2129
+ body?: never;
2130
+ path: {
2131
+ /**
2132
+ * Session ID
2133
+ */
2134
+ id: string;
2135
+ };
2136
+ query?: {
2137
+ directory?: string;
2138
+ messageID?: string;
2139
+ };
2140
+ url: "/session/{id}/diff";
2141
+ };
2142
+ export type SessionDiffErrors = {
2143
+ /**
2144
+ * Bad request
2145
+ */
2146
+ 400: BadRequestError;
2147
+ /**
2148
+ * Not found
2149
+ */
2150
+ 404: NotFoundError;
2151
+ };
2152
+ export type SessionDiffError = SessionDiffErrors[keyof SessionDiffErrors];
2153
+ export type SessionDiffResponses = {
2154
+ /**
2155
+ * List of diffs
2156
+ */
2157
+ 200: Array<FileDiff>;
2158
+ };
2159
+ export type SessionDiffResponse = SessionDiffResponses[keyof SessionDiffResponses];
2160
+ export type SessionSummarizeData = {
2161
+ body?: {
2162
+ providerID: string;
2163
+ modelID: string;
2164
+ };
2165
+ path: {
2166
+ /**
2167
+ * Session ID
2168
+ */
2169
+ id: string;
2170
+ };
2171
+ query?: {
2172
+ directory?: string;
2173
+ };
2174
+ url: "/session/{id}/summarize";
2175
+ };
2176
+ export type SessionSummarizeErrors = {
2177
+ /**
2178
+ * Bad request
2179
+ */
2180
+ 400: BadRequestError;
2181
+ /**
2182
+ * Not found
2183
+ */
2184
+ 404: NotFoundError;
2185
+ };
2186
+ export type SessionSummarizeError = SessionSummarizeErrors[keyof SessionSummarizeErrors];
2187
+ export type SessionSummarizeResponses = {
2188
+ /**
2189
+ * Summarized session
2190
+ */
2191
+ 200: boolean;
2192
+ };
2193
+ export type SessionSummarizeResponse = SessionSummarizeResponses[keyof SessionSummarizeResponses];
2194
+ export type SessionMessagesData = {
2195
+ body?: never;
2196
+ path: {
2197
+ /**
2198
+ * Session ID
2199
+ */
2200
+ id: string;
2201
+ };
2202
+ query?: {
2203
+ directory?: string;
2204
+ limit?: number;
2205
+ };
2206
+ url: "/session/{id}/message";
2207
+ };
2208
+ export type SessionMessagesErrors = {
2209
+ /**
2210
+ * Bad request
2211
+ */
2212
+ 400: BadRequestError;
2213
+ /**
2214
+ * Not found
2215
+ */
2216
+ 404: NotFoundError;
2217
+ };
2218
+ export type SessionMessagesError = SessionMessagesErrors[keyof SessionMessagesErrors];
2219
+ export type SessionMessagesResponses = {
2220
+ /**
2221
+ * List of messages
2222
+ */
2223
+ 200: Array<{
2224
+ info: Message;
2225
+ parts: Array<Part>;
2226
+ }>;
2227
+ };
2228
+ export type SessionMessagesResponse = SessionMessagesResponses[keyof SessionMessagesResponses];
2229
+ export type SessionPromptData = {
2230
+ body?: {
2231
+ messageID?: string;
2232
+ model?: {
2233
+ providerID: string;
2234
+ modelID: string;
2235
+ };
2236
+ agent?: string;
2237
+ noReply?: boolean;
2238
+ system?: string;
2239
+ tools?: {
2240
+ [key: string]: boolean;
2241
+ };
2242
+ parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
2243
+ };
2244
+ path: {
2245
+ /**
2246
+ * Session ID
2247
+ */
2248
+ id: string;
2249
+ };
2250
+ query?: {
2251
+ directory?: string;
2252
+ };
2253
+ url: "/session/{id}/message";
2254
+ };
2255
+ export type SessionPromptErrors = {
2256
+ /**
2257
+ * Bad request
2258
+ */
2259
+ 400: BadRequestError;
2260
+ /**
2261
+ * Not found
2262
+ */
2263
+ 404: NotFoundError;
2264
+ };
2265
+ export type SessionPromptError = SessionPromptErrors[keyof SessionPromptErrors];
2266
+ export type SessionPromptResponses = {
2267
+ /**
2268
+ * Created message
2269
+ */
2270
+ 200: {
2271
+ info: AssistantMessage;
2272
+ parts: Array<Part>;
2273
+ };
2274
+ };
2275
+ export type SessionPromptResponse = SessionPromptResponses[keyof SessionPromptResponses];
2276
+ export type SessionMessageData = {
2277
+ body?: never;
2278
+ path: {
2279
+ /**
2280
+ * Session ID
2281
+ */
2282
+ id: string;
2283
+ /**
2284
+ * Message ID
2285
+ */
2286
+ messageID: string;
2287
+ };
2288
+ query?: {
2289
+ directory?: string;
2290
+ };
2291
+ url: "/session/{id}/message/{messageID}";
2292
+ };
2293
+ export type SessionMessageErrors = {
2294
+ /**
2295
+ * Bad request
2296
+ */
2297
+ 400: BadRequestError;
2298
+ /**
2299
+ * Not found
2300
+ */
2301
+ 404: NotFoundError;
2302
+ };
2303
+ export type SessionMessageError = SessionMessageErrors[keyof SessionMessageErrors];
2304
+ export type SessionMessageResponses = {
2305
+ /**
2306
+ * Message
2307
+ */
2308
+ 200: {
2309
+ info: Message;
2310
+ parts: Array<Part>;
2311
+ };
2312
+ };
2313
+ export type SessionMessageResponse = SessionMessageResponses[keyof SessionMessageResponses];
2314
+ export type SessionPromptAsyncData = {
2315
+ body?: {
2316
+ messageID?: string;
2317
+ model?: {
2318
+ providerID: string;
2319
+ modelID: string;
2320
+ };
2321
+ agent?: string;
2322
+ noReply?: boolean;
2323
+ system?: string;
2324
+ tools?: {
2325
+ [key: string]: boolean;
2326
+ };
2327
+ parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
2328
+ };
2329
+ path: {
2330
+ /**
2331
+ * Session ID
2332
+ */
2333
+ id: string;
2334
+ };
2335
+ query?: {
2336
+ directory?: string;
2337
+ };
2338
+ url: "/session/{id}/prompt_async";
2339
+ };
2340
+ export type SessionPromptAsyncErrors = {
2341
+ /**
2342
+ * Bad request
2343
+ */
2344
+ 400: BadRequestError;
2345
+ /**
2346
+ * Not found
2347
+ */
2348
+ 404: NotFoundError;
2349
+ };
2350
+ export type SessionPromptAsyncError = SessionPromptAsyncErrors[keyof SessionPromptAsyncErrors];
2351
+ export type SessionPromptAsyncResponses = {
2352
+ /**
2353
+ * Prompt accepted
2354
+ */
2355
+ 204: void;
2356
+ };
2357
+ export type SessionPromptAsyncResponse = SessionPromptAsyncResponses[keyof SessionPromptAsyncResponses];
2358
+ export type SessionCommandData = {
2359
+ body?: {
2360
+ messageID?: string;
2361
+ agent?: string;
2362
+ model?: string;
2363
+ arguments: string;
2364
+ command: string;
2365
+ };
2366
+ path: {
2367
+ /**
2368
+ * Session ID
2369
+ */
2370
+ id: string;
2371
+ };
2372
+ query?: {
2373
+ directory?: string;
2374
+ };
2375
+ url: "/session/{id}/command";
2376
+ };
2377
+ export type SessionCommandErrors = {
2378
+ /**
2379
+ * Bad request
2380
+ */
2381
+ 400: BadRequestError;
2382
+ /**
2383
+ * Not found
2384
+ */
2385
+ 404: NotFoundError;
2386
+ };
2387
+ export type SessionCommandError = SessionCommandErrors[keyof SessionCommandErrors];
2388
+ export type SessionCommandResponses = {
2389
+ /**
2390
+ * Created message
2391
+ */
2392
+ 200: {
2393
+ info: AssistantMessage;
2394
+ parts: Array<Part>;
2395
+ };
2396
+ };
2397
+ export type SessionCommandResponse = SessionCommandResponses[keyof SessionCommandResponses];
2398
+ export type SessionShellData = {
2399
+ body?: {
2400
+ agent: string;
2401
+ model?: {
2402
+ providerID: string;
2403
+ modelID: string;
2404
+ };
2405
+ command: string;
2406
+ };
2407
+ path: {
2408
+ /**
2409
+ * Session ID
2410
+ */
2411
+ id: string;
2412
+ };
2413
+ query?: {
2414
+ directory?: string;
2415
+ };
2416
+ url: "/session/{id}/shell";
2417
+ };
2418
+ export type SessionShellErrors = {
2419
+ /**
2420
+ * Bad request
2421
+ */
2422
+ 400: BadRequestError;
2423
+ /**
2424
+ * Not found
2425
+ */
2426
+ 404: NotFoundError;
2427
+ };
2428
+ export type SessionShellError = SessionShellErrors[keyof SessionShellErrors];
2429
+ export type SessionShellResponses = {
2430
+ /**
2431
+ * Created message
2432
+ */
2433
+ 200: AssistantMessage;
2434
+ };
2435
+ export type SessionShellResponse = SessionShellResponses[keyof SessionShellResponses];
2436
+ export type SessionRevertData = {
2437
+ body?: {
2438
+ messageID: string;
2439
+ partID?: string;
2440
+ };
2441
+ path: {
2442
+ id: string;
2443
+ };
2444
+ query?: {
2445
+ directory?: string;
2446
+ };
2447
+ url: "/session/{id}/revert";
2448
+ };
2449
+ export type SessionRevertErrors = {
2450
+ /**
2451
+ * Bad request
2452
+ */
2453
+ 400: BadRequestError;
2454
+ /**
2455
+ * Not found
2456
+ */
2457
+ 404: NotFoundError;
2458
+ };
2459
+ export type SessionRevertError = SessionRevertErrors[keyof SessionRevertErrors];
2460
+ export type SessionRevertResponses = {
2461
+ /**
2462
+ * Updated session
2463
+ */
2464
+ 200: Session;
2465
+ };
2466
+ export type SessionRevertResponse = SessionRevertResponses[keyof SessionRevertResponses];
2467
+ export type SessionUnrevertData = {
2468
+ body?: never;
2469
+ path: {
2470
+ id: string;
2471
+ };
2472
+ query?: {
2473
+ directory?: string;
2474
+ };
2475
+ url: "/session/{id}/unrevert";
2476
+ };
2477
+ export type SessionUnrevertErrors = {
2478
+ /**
2479
+ * Bad request
2480
+ */
2481
+ 400: BadRequestError;
2482
+ /**
2483
+ * Not found
2484
+ */
2485
+ 404: NotFoundError;
2486
+ };
2487
+ export type SessionUnrevertError = SessionUnrevertErrors[keyof SessionUnrevertErrors];
2488
+ export type SessionUnrevertResponses = {
2489
+ /**
2490
+ * Updated session
2491
+ */
2492
+ 200: Session;
2493
+ };
2494
+ export type SessionUnrevertResponse = SessionUnrevertResponses[keyof SessionUnrevertResponses];
2495
+ export type PostSessionIdPermissionsPermissionIdData = {
2496
+ body?: {
2497
+ response: "once" | "always" | "reject";
2498
+ };
2499
+ path: {
2500
+ id: string;
2501
+ permissionID: string;
2502
+ };
2503
+ query?: {
2504
+ directory?: string;
2505
+ };
2506
+ url: "/session/{id}/permissions/{permissionID}";
2507
+ };
2508
+ export type PostSessionIdPermissionsPermissionIdErrors = {
2509
+ /**
2510
+ * Bad request
2511
+ */
2512
+ 400: BadRequestError;
2513
+ /**
2514
+ * Not found
2515
+ */
2516
+ 404: NotFoundError;
2517
+ };
2518
+ export type PostSessionIdPermissionsPermissionIdError = PostSessionIdPermissionsPermissionIdErrors[keyof PostSessionIdPermissionsPermissionIdErrors];
2519
+ export type PostSessionIdPermissionsPermissionIdResponses = {
2520
+ /**
2521
+ * Permission processed successfully
2522
+ */
2523
+ 200: boolean;
2524
+ };
2525
+ export type PostSessionIdPermissionsPermissionIdResponse = PostSessionIdPermissionsPermissionIdResponses[keyof PostSessionIdPermissionsPermissionIdResponses];
2526
+ export type CommandListData = {
2527
+ body?: never;
2528
+ path?: never;
2529
+ query?: {
2530
+ directory?: string;
2531
+ };
2532
+ url: "/command";
2533
+ };
2534
+ export type CommandListResponses = {
2535
+ /**
2536
+ * List of commands
2537
+ */
2538
+ 200: Array<Command>;
2539
+ };
2540
+ export type CommandListResponse = CommandListResponses[keyof CommandListResponses];
2541
+ export type ConfigProvidersData = {
2542
+ body?: never;
2543
+ path?: never;
2544
+ query?: {
2545
+ directory?: string;
2546
+ };
2547
+ url: "/config/providers";
2548
+ };
2549
+ export type ConfigProvidersResponses = {
2550
+ /**
2551
+ * List of providers
2552
+ */
2553
+ 200: {
2554
+ providers: Array<Provider>;
2555
+ default: {
2556
+ [key: string]: string;
2557
+ };
2558
+ };
2559
+ };
2560
+ export type ConfigProvidersResponse = ConfigProvidersResponses[keyof ConfigProvidersResponses];
2561
+ export type ProviderListData = {
2562
+ body?: never;
2563
+ path?: never;
2564
+ query?: {
2565
+ directory?: string;
2566
+ };
2567
+ url: "/provider";
2568
+ };
2569
+ export type ProviderListResponses = {
2570
+ /**
2571
+ * List of providers
2572
+ */
2573
+ 200: {
2574
+ all: Array<{
2575
+ api?: string;
2576
+ name: string;
2577
+ env: Array<string>;
2578
+ id: string;
2579
+ npm?: string;
2580
+ models: {
2581
+ [key: string]: {
2582
+ id: string;
2583
+ name: string;
2584
+ release_date: string;
2585
+ attachment: boolean;
2586
+ reasoning: boolean;
2587
+ temperature: boolean;
2588
+ tool_call: boolean;
2589
+ cost?: {
2590
+ input: number;
2591
+ output: number;
2592
+ cache_read?: number;
2593
+ cache_write?: number;
2594
+ context_over_200k?: {
2595
+ input: number;
2596
+ output: number;
2597
+ cache_read?: number;
2598
+ cache_write?: number;
2599
+ };
2600
+ };
2601
+ limit: {
2602
+ context: number;
2603
+ output: number;
2604
+ };
2605
+ modalities?: {
2606
+ input: Array<"text" | "audio" | "image" | "video" | "pdf">;
2607
+ output: Array<"text" | "audio" | "image" | "video" | "pdf">;
2608
+ };
2609
+ experimental?: boolean;
2610
+ status?: "alpha" | "beta" | "deprecated";
2611
+ options: {
2612
+ [key: string]: unknown;
2613
+ };
2614
+ headers?: {
2615
+ [key: string]: string;
2616
+ };
2617
+ provider?: {
2618
+ npm: string;
2619
+ };
2620
+ };
2621
+ };
2622
+ }>;
2623
+ default: {
2624
+ [key: string]: string;
2625
+ };
2626
+ connected: Array<string>;
2627
+ };
2628
+ };
2629
+ export type ProviderListResponse = ProviderListResponses[keyof ProviderListResponses];
2630
+ export type ProviderAuthData = {
2631
+ body?: never;
2632
+ path?: never;
2633
+ query?: {
2634
+ directory?: string;
2635
+ };
2636
+ url: "/provider/auth";
2637
+ };
2638
+ export type ProviderAuthResponses = {
2639
+ /**
2640
+ * Provider auth methods
2641
+ */
2642
+ 200: {
2643
+ [key: string]: Array<ProviderAuthMethod>;
2644
+ };
2645
+ };
2646
+ export type ProviderAuthResponse = ProviderAuthResponses[keyof ProviderAuthResponses];
2647
+ export type ProviderOauthAuthorizeData = {
2648
+ body?: {
2649
+ /**
2650
+ * Auth method index
2651
+ */
2652
+ method: number;
2653
+ };
2654
+ path: {
2655
+ /**
2656
+ * Provider ID
2657
+ */
2658
+ id: string;
2659
+ };
2660
+ query?: {
2661
+ directory?: string;
2662
+ };
2663
+ url: "/provider/{id}/oauth/authorize";
2664
+ };
2665
+ export type ProviderOauthAuthorizeErrors = {
2666
+ /**
2667
+ * Bad request
2668
+ */
2669
+ 400: BadRequestError;
2670
+ };
2671
+ export type ProviderOauthAuthorizeError = ProviderOauthAuthorizeErrors[keyof ProviderOauthAuthorizeErrors];
2672
+ export type ProviderOauthAuthorizeResponses = {
2673
+ /**
2674
+ * Authorization URL and method
2675
+ */
2676
+ 200: ProviderAuthAuthorization;
2677
+ };
2678
+ export type ProviderOauthAuthorizeResponse = ProviderOauthAuthorizeResponses[keyof ProviderOauthAuthorizeResponses];
2679
+ export type ProviderOauthCallbackData = {
2680
+ body?: {
2681
+ /**
2682
+ * Auth method index
2683
+ */
2684
+ method: number;
2685
+ /**
2686
+ * OAuth authorization code
2687
+ */
2688
+ code?: string;
2689
+ };
2690
+ path: {
2691
+ /**
2692
+ * Provider ID
2693
+ */
2694
+ id: string;
2695
+ };
2696
+ query?: {
2697
+ directory?: string;
2698
+ };
2699
+ url: "/provider/{id}/oauth/callback";
2700
+ };
2701
+ export type ProviderOauthCallbackErrors = {
2702
+ /**
2703
+ * Bad request
2704
+ */
2705
+ 400: BadRequestError;
2706
+ };
2707
+ export type ProviderOauthCallbackError = ProviderOauthCallbackErrors[keyof ProviderOauthCallbackErrors];
2708
+ export type ProviderOauthCallbackResponses = {
2709
+ /**
2710
+ * OAuth callback processed successfully
2711
+ */
2712
+ 200: boolean;
2713
+ };
2714
+ export type ProviderOauthCallbackResponse = ProviderOauthCallbackResponses[keyof ProviderOauthCallbackResponses];
2715
+ export type FindTextData = {
2716
+ body?: never;
2717
+ path?: never;
2718
+ query: {
2719
+ directory?: string;
2720
+ pattern: string;
2721
+ };
2722
+ url: "/find";
2723
+ };
2724
+ export type FindTextResponses = {
2725
+ /**
2726
+ * Matches
2727
+ */
2728
+ 200: Array<{
2729
+ path: {
2730
+ text: string;
2731
+ };
2732
+ lines: {
2733
+ text: string;
2734
+ };
2735
+ line_number: number;
2736
+ absolute_offset: number;
2737
+ submatches: Array<{
2738
+ match: {
2739
+ text: string;
2740
+ };
2741
+ start: number;
2742
+ end: number;
2743
+ }>;
2744
+ }>;
2745
+ };
2746
+ export type FindTextResponse = FindTextResponses[keyof FindTextResponses];
2747
+ export type FindFilesData = {
2748
+ body?: never;
2749
+ path?: never;
2750
+ query: {
2751
+ directory?: string;
2752
+ query: string;
2753
+ dirs?: "true" | "false";
2754
+ };
2755
+ url: "/find/file";
2756
+ };
2757
+ export type FindFilesResponses = {
2758
+ /**
2759
+ * File paths
2760
+ */
2761
+ 200: Array<string>;
2762
+ };
2763
+ export type FindFilesResponse = FindFilesResponses[keyof FindFilesResponses];
2764
+ export type FindSymbolsData = {
2765
+ body?: never;
2766
+ path?: never;
2767
+ query: {
2768
+ directory?: string;
2769
+ query: string;
2770
+ };
2771
+ url: "/find/symbol";
2772
+ };
2773
+ export type FindSymbolsResponses = {
2774
+ /**
2775
+ * Symbols
2776
+ */
2777
+ 200: Array<Symbol>;
2778
+ };
2779
+ export type FindSymbolsResponse = FindSymbolsResponses[keyof FindSymbolsResponses];
2780
+ export type FileListData = {
2781
+ body?: never;
2782
+ path?: never;
2783
+ query: {
2784
+ directory?: string;
2785
+ path: string;
2786
+ };
2787
+ url: "/file";
2788
+ };
2789
+ export type FileListResponses = {
2790
+ /**
2791
+ * Files and directories
2792
+ */
2793
+ 200: Array<FileNode>;
2794
+ };
2795
+ export type FileListResponse = FileListResponses[keyof FileListResponses];
2796
+ export type FileReadData = {
2797
+ body?: never;
2798
+ path?: never;
2799
+ query: {
2800
+ directory?: string;
2801
+ path: string;
2802
+ };
2803
+ url: "/file/content";
2804
+ };
2805
+ export type FileReadResponses = {
2806
+ /**
2807
+ * File content
2808
+ */
2809
+ 200: FileContent;
2810
+ };
2811
+ export type FileReadResponse = FileReadResponses[keyof FileReadResponses];
2812
+ export type FileStatusData = {
2813
+ body?: never;
2814
+ path?: never;
2815
+ query?: {
2816
+ directory?: string;
2817
+ };
2818
+ url: "/file/status";
2819
+ };
2820
+ export type FileStatusResponses = {
2821
+ /**
2822
+ * File status
2823
+ */
2824
+ 200: Array<File>;
2825
+ };
2826
+ export type FileStatusResponse = FileStatusResponses[keyof FileStatusResponses];
2827
+ export type AppLogData = {
2828
+ body?: {
2829
+ /**
2830
+ * Service name for the log entry
2831
+ */
2832
+ service: string;
2833
+ /**
2834
+ * Log level
2835
+ */
2836
+ level: "debug" | "info" | "error" | "warn";
2837
+ /**
2838
+ * Log message
2839
+ */
2840
+ message: string;
2841
+ /**
2842
+ * Additional metadata for the log entry
2843
+ */
2844
+ extra?: {
2845
+ [key: string]: unknown;
2846
+ };
2847
+ };
2848
+ path?: never;
2849
+ query?: {
2850
+ directory?: string;
2851
+ };
2852
+ url: "/log";
2853
+ };
2854
+ export type AppLogErrors = {
2855
+ /**
2856
+ * Bad request
2857
+ */
2858
+ 400: BadRequestError;
2859
+ };
2860
+ export type AppLogError = AppLogErrors[keyof AppLogErrors];
2861
+ export type AppLogResponses = {
2862
+ /**
2863
+ * Log entry written successfully
2864
+ */
2865
+ 200: boolean;
2866
+ };
2867
+ export type AppLogResponse = AppLogResponses[keyof AppLogResponses];
2868
+ export type AppAgentsData = {
2869
+ body?: never;
2870
+ path?: never;
2871
+ query?: {
2872
+ directory?: string;
2873
+ };
2874
+ url: "/agent";
2875
+ };
2876
+ export type AppAgentsResponses = {
2877
+ /**
2878
+ * List of agents
2879
+ */
2880
+ 200: Array<Agent>;
2881
+ };
2882
+ export type AppAgentsResponse = AppAgentsResponses[keyof AppAgentsResponses];
2883
+ export type McpStatusData = {
2884
+ body?: never;
2885
+ path?: never;
2886
+ query?: {
2887
+ directory?: string;
2888
+ };
2889
+ url: "/mcp";
2890
+ };
2891
+ export type McpStatusResponses = {
2892
+ /**
2893
+ * MCP server status
2894
+ */
2895
+ 200: {
2896
+ [key: string]: McpStatus;
2897
+ };
2898
+ };
2899
+ export type McpStatusResponse = McpStatusResponses[keyof McpStatusResponses];
2900
+ export type McpAddData = {
2901
+ body?: {
2902
+ name: string;
2903
+ config: McpLocalConfig | McpRemoteConfig;
2904
+ };
2905
+ path?: never;
2906
+ query?: {
2907
+ directory?: string;
2908
+ };
2909
+ url: "/mcp";
2910
+ };
2911
+ export type McpAddErrors = {
2912
+ /**
2913
+ * Bad request
2914
+ */
2915
+ 400: BadRequestError;
2916
+ };
2917
+ export type McpAddError = McpAddErrors[keyof McpAddErrors];
2918
+ export type McpAddResponses = {
2919
+ /**
2920
+ * MCP server added successfully
2921
+ */
2922
+ 200: {
2923
+ [key: string]: McpStatus;
2924
+ };
2925
+ };
2926
+ export type McpAddResponse = McpAddResponses[keyof McpAddResponses];
2927
+ export type McpAuthRemoveData = {
2928
+ body?: never;
2929
+ path: {
2930
+ name: string;
2931
+ };
2932
+ query?: {
2933
+ directory?: string;
2934
+ };
2935
+ url: "/mcp/{name}/auth";
2936
+ };
2937
+ export type McpAuthRemoveErrors = {
2938
+ /**
2939
+ * Not found
2940
+ */
2941
+ 404: NotFoundError;
2942
+ };
2943
+ export type McpAuthRemoveError = McpAuthRemoveErrors[keyof McpAuthRemoveErrors];
2944
+ export type McpAuthRemoveResponses = {
2945
+ /**
2946
+ * OAuth credentials removed
2947
+ */
2948
+ 200: {
2949
+ success: true;
2950
+ };
2951
+ };
2952
+ export type McpAuthRemoveResponse = McpAuthRemoveResponses[keyof McpAuthRemoveResponses];
2953
+ export type McpAuthStartData = {
2954
+ body?: never;
2955
+ path: {
2956
+ name: string;
2957
+ };
2958
+ query?: {
2959
+ directory?: string;
2960
+ };
2961
+ url: "/mcp/{name}/auth";
2962
+ };
2963
+ export type McpAuthStartErrors = {
2964
+ /**
2965
+ * Bad request
2966
+ */
2967
+ 400: BadRequestError;
2968
+ /**
2969
+ * Not found
2970
+ */
2971
+ 404: NotFoundError;
2972
+ };
2973
+ export type McpAuthStartError = McpAuthStartErrors[keyof McpAuthStartErrors];
2974
+ export type McpAuthStartResponses = {
2975
+ /**
2976
+ * OAuth flow started
2977
+ */
2978
+ 200: {
2979
+ /**
2980
+ * URL to open in browser for authorization
2981
+ */
2982
+ authorizationUrl: string;
2983
+ };
2984
+ };
2985
+ export type McpAuthStartResponse = McpAuthStartResponses[keyof McpAuthStartResponses];
2986
+ export type McpAuthCallbackData = {
2987
+ body?: {
2988
+ /**
2989
+ * Authorization code from OAuth callback
2990
+ */
2991
+ code: string;
2992
+ };
2993
+ path: {
2994
+ name: string;
2995
+ };
2996
+ query?: {
2997
+ directory?: string;
2998
+ };
2999
+ url: "/mcp/{name}/auth/callback";
3000
+ };
3001
+ export type McpAuthCallbackErrors = {
3002
+ /**
3003
+ * Bad request
3004
+ */
3005
+ 400: BadRequestError;
3006
+ /**
3007
+ * Not found
3008
+ */
3009
+ 404: NotFoundError;
3010
+ };
3011
+ export type McpAuthCallbackError = McpAuthCallbackErrors[keyof McpAuthCallbackErrors];
3012
+ export type McpAuthCallbackResponses = {
3013
+ /**
3014
+ * OAuth authentication completed
3015
+ */
3016
+ 200: McpStatus;
3017
+ };
3018
+ export type McpAuthCallbackResponse = McpAuthCallbackResponses[keyof McpAuthCallbackResponses];
3019
+ export type McpAuthAuthenticateData = {
3020
+ body?: never;
3021
+ path: {
3022
+ name: string;
3023
+ };
3024
+ query?: {
3025
+ directory?: string;
3026
+ };
3027
+ url: "/mcp/{name}/auth/authenticate";
3028
+ };
3029
+ export type McpAuthAuthenticateErrors = {
3030
+ /**
3031
+ * Bad request
3032
+ */
3033
+ 400: BadRequestError;
3034
+ /**
3035
+ * Not found
3036
+ */
3037
+ 404: NotFoundError;
3038
+ };
3039
+ export type McpAuthAuthenticateError = McpAuthAuthenticateErrors[keyof McpAuthAuthenticateErrors];
3040
+ export type McpAuthAuthenticateResponses = {
3041
+ /**
3042
+ * OAuth authentication completed
3043
+ */
3044
+ 200: McpStatus;
3045
+ };
3046
+ export type McpAuthAuthenticateResponse = McpAuthAuthenticateResponses[keyof McpAuthAuthenticateResponses];
3047
+ export type McpConnectData = {
3048
+ body?: never;
3049
+ path: {
3050
+ name: string;
3051
+ };
3052
+ query?: {
3053
+ directory?: string;
3054
+ };
3055
+ url: "/mcp/{name}/connect";
3056
+ };
3057
+ export type McpConnectResponses = {
3058
+ /**
3059
+ * MCP server connected successfully
3060
+ */
3061
+ 200: boolean;
3062
+ };
3063
+ export type McpConnectResponse = McpConnectResponses[keyof McpConnectResponses];
3064
+ export type McpDisconnectData = {
3065
+ body?: never;
3066
+ path: {
3067
+ name: string;
3068
+ };
3069
+ query?: {
3070
+ directory?: string;
3071
+ };
3072
+ url: "/mcp/{name}/disconnect";
3073
+ };
3074
+ export type McpDisconnectResponses = {
3075
+ /**
3076
+ * MCP server disconnected successfully
3077
+ */
3078
+ 200: boolean;
3079
+ };
3080
+ export type McpDisconnectResponse = McpDisconnectResponses[keyof McpDisconnectResponses];
3081
+ export type LspStatusData = {
3082
+ body?: never;
3083
+ path?: never;
3084
+ query?: {
3085
+ directory?: string;
3086
+ };
3087
+ url: "/lsp";
3088
+ };
3089
+ export type LspStatusResponses = {
3090
+ /**
3091
+ * LSP server status
3092
+ */
3093
+ 200: Array<LspStatus>;
3094
+ };
3095
+ export type LspStatusResponse = LspStatusResponses[keyof LspStatusResponses];
3096
+ export type FormatterStatusData = {
3097
+ body?: never;
3098
+ path?: never;
3099
+ query?: {
3100
+ directory?: string;
3101
+ };
3102
+ url: "/formatter";
3103
+ };
3104
+ export type FormatterStatusResponses = {
3105
+ /**
3106
+ * Formatter status
3107
+ */
3108
+ 200: Array<FormatterStatus>;
3109
+ };
3110
+ export type FormatterStatusResponse = FormatterStatusResponses[keyof FormatterStatusResponses];
3111
+ export type TuiAppendPromptData = {
3112
+ body?: {
3113
+ text: string;
3114
+ };
3115
+ path?: never;
3116
+ query?: {
3117
+ directory?: string;
3118
+ };
3119
+ url: "/tui/append-prompt";
3120
+ };
3121
+ export type TuiAppendPromptErrors = {
3122
+ /**
3123
+ * Bad request
3124
+ */
3125
+ 400: BadRequestError;
3126
+ };
3127
+ export type TuiAppendPromptError = TuiAppendPromptErrors[keyof TuiAppendPromptErrors];
3128
+ export type TuiAppendPromptResponses = {
3129
+ /**
3130
+ * Prompt processed successfully
3131
+ */
3132
+ 200: boolean;
3133
+ };
3134
+ export type TuiAppendPromptResponse = TuiAppendPromptResponses[keyof TuiAppendPromptResponses];
3135
+ export type TuiOpenHelpData = {
3136
+ body?: never;
3137
+ path?: never;
3138
+ query?: {
3139
+ directory?: string;
3140
+ };
3141
+ url: "/tui/open-help";
3142
+ };
3143
+ export type TuiOpenHelpResponses = {
3144
+ /**
3145
+ * Help dialog opened successfully
3146
+ */
3147
+ 200: boolean;
3148
+ };
3149
+ export type TuiOpenHelpResponse = TuiOpenHelpResponses[keyof TuiOpenHelpResponses];
3150
+ export type TuiOpenSessionsData = {
3151
+ body?: never;
3152
+ path?: never;
3153
+ query?: {
3154
+ directory?: string;
3155
+ };
3156
+ url: "/tui/open-sessions";
3157
+ };
3158
+ export type TuiOpenSessionsResponses = {
3159
+ /**
3160
+ * Session dialog opened successfully
3161
+ */
3162
+ 200: boolean;
3163
+ };
3164
+ export type TuiOpenSessionsResponse = TuiOpenSessionsResponses[keyof TuiOpenSessionsResponses];
3165
+ export type TuiOpenThemesData = {
3166
+ body?: never;
3167
+ path?: never;
3168
+ query?: {
3169
+ directory?: string;
3170
+ };
3171
+ url: "/tui/open-themes";
3172
+ };
3173
+ export type TuiOpenThemesResponses = {
3174
+ /**
3175
+ * Theme dialog opened successfully
3176
+ */
3177
+ 200: boolean;
3178
+ };
3179
+ export type TuiOpenThemesResponse = TuiOpenThemesResponses[keyof TuiOpenThemesResponses];
3180
+ export type TuiOpenModelsData = {
3181
+ body?: never;
3182
+ path?: never;
3183
+ query?: {
3184
+ directory?: string;
3185
+ };
3186
+ url: "/tui/open-models";
3187
+ };
3188
+ export type TuiOpenModelsResponses = {
3189
+ /**
3190
+ * Model dialog opened successfully
3191
+ */
3192
+ 200: boolean;
3193
+ };
3194
+ export type TuiOpenModelsResponse = TuiOpenModelsResponses[keyof TuiOpenModelsResponses];
3195
+ export type TuiSubmitPromptData = {
3196
+ body?: never;
3197
+ path?: never;
3198
+ query?: {
3199
+ directory?: string;
3200
+ };
3201
+ url: "/tui/submit-prompt";
3202
+ };
3203
+ export type TuiSubmitPromptResponses = {
3204
+ /**
3205
+ * Prompt submitted successfully
3206
+ */
3207
+ 200: boolean;
3208
+ };
3209
+ export type TuiSubmitPromptResponse = TuiSubmitPromptResponses[keyof TuiSubmitPromptResponses];
3210
+ export type TuiClearPromptData = {
3211
+ body?: never;
3212
+ path?: never;
3213
+ query?: {
3214
+ directory?: string;
3215
+ };
3216
+ url: "/tui/clear-prompt";
3217
+ };
3218
+ export type TuiClearPromptResponses = {
3219
+ /**
3220
+ * Prompt cleared successfully
3221
+ */
3222
+ 200: boolean;
3223
+ };
3224
+ export type TuiClearPromptResponse = TuiClearPromptResponses[keyof TuiClearPromptResponses];
3225
+ export type TuiExecuteCommandData = {
3226
+ body?: {
3227
+ command: string;
3228
+ };
3229
+ path?: never;
3230
+ query?: {
3231
+ directory?: string;
3232
+ };
3233
+ url: "/tui/execute-command";
3234
+ };
3235
+ export type TuiExecuteCommandErrors = {
3236
+ /**
3237
+ * Bad request
3238
+ */
3239
+ 400: BadRequestError;
3240
+ };
3241
+ export type TuiExecuteCommandError = TuiExecuteCommandErrors[keyof TuiExecuteCommandErrors];
3242
+ export type TuiExecuteCommandResponses = {
3243
+ /**
3244
+ * Command executed successfully
3245
+ */
3246
+ 200: boolean;
3247
+ };
3248
+ export type TuiExecuteCommandResponse = TuiExecuteCommandResponses[keyof TuiExecuteCommandResponses];
3249
+ export type TuiShowToastData = {
3250
+ body?: {
3251
+ title?: string;
3252
+ message: string;
3253
+ variant: "info" | "success" | "warning" | "error";
3254
+ /**
3255
+ * Duration in milliseconds
3256
+ */
3257
+ duration?: number;
3258
+ };
3259
+ path?: never;
3260
+ query?: {
3261
+ directory?: string;
3262
+ };
3263
+ url: "/tui/show-toast";
3264
+ };
3265
+ export type TuiShowToastResponses = {
3266
+ /**
3267
+ * Toast notification shown successfully
3268
+ */
3269
+ 200: boolean;
3270
+ };
3271
+ export type TuiShowToastResponse = TuiShowToastResponses[keyof TuiShowToastResponses];
3272
+ export type TuiPublishData = {
3273
+ body?: EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow;
3274
+ path?: never;
3275
+ query?: {
3276
+ directory?: string;
3277
+ };
3278
+ url: "/tui/publish";
3279
+ };
3280
+ export type TuiPublishErrors = {
3281
+ /**
3282
+ * Bad request
3283
+ */
3284
+ 400: BadRequestError;
3285
+ };
3286
+ export type TuiPublishError = TuiPublishErrors[keyof TuiPublishErrors];
3287
+ export type TuiPublishResponses = {
3288
+ /**
3289
+ * Event published successfully
3290
+ */
3291
+ 200: boolean;
3292
+ };
3293
+ export type TuiPublishResponse = TuiPublishResponses[keyof TuiPublishResponses];
3294
+ export type TuiControlNextData = {
3295
+ body?: never;
3296
+ path?: never;
3297
+ query?: {
3298
+ directory?: string;
3299
+ };
3300
+ url: "/tui/control/next";
3301
+ };
3302
+ export type TuiControlNextResponses = {
3303
+ /**
3304
+ * Next TUI request
3305
+ */
3306
+ 200: {
3307
+ path: string;
3308
+ body: unknown;
3309
+ };
3310
+ };
3311
+ export type TuiControlNextResponse = TuiControlNextResponses[keyof TuiControlNextResponses];
3312
+ export type TuiControlResponseData = {
3313
+ body?: unknown;
3314
+ path?: never;
3315
+ query?: {
3316
+ directory?: string;
3317
+ };
3318
+ url: "/tui/control/response";
3319
+ };
3320
+ export type TuiControlResponseResponses = {
3321
+ /**
3322
+ * Response submitted successfully
3323
+ */
3324
+ 200: boolean;
3325
+ };
3326
+ export type TuiControlResponseResponse = TuiControlResponseResponses[keyof TuiControlResponseResponses];
3327
+ export type AuthSetData = {
3328
+ body?: Auth;
3329
+ path: {
3330
+ id: string;
3331
+ };
3332
+ query?: {
3333
+ directory?: string;
3334
+ };
3335
+ url: "/auth/{id}";
3336
+ };
3337
+ export type AuthSetErrors = {
3338
+ /**
3339
+ * Bad request
3340
+ */
3341
+ 400: BadRequestError;
3342
+ };
3343
+ export type AuthSetError = AuthSetErrors[keyof AuthSetErrors];
3344
+ export type AuthSetResponses = {
3345
+ /**
3346
+ * Successfully set authentication credentials
3347
+ */
3348
+ 200: boolean;
3349
+ };
3350
+ export type AuthSetResponse = AuthSetResponses[keyof AuthSetResponses];
3351
+ export type EventSubscribeData = {
3352
+ body?: never;
3353
+ path?: never;
3354
+ query?: {
3355
+ directory?: string;
3356
+ };
3357
+ url: "/event";
3358
+ };
3359
+ export type EventSubscribeResponses = {
3360
+ /**
3361
+ * Event stream
3362
+ */
3363
+ 200: Event;
3364
+ };
3365
+ export type EventSubscribeResponse = EventSubscribeResponses[keyof EventSubscribeResponses];
3366
+ export type ClientOptions = {
3367
+ baseUrl: `${string}://${string}` | (string & {});
3368
+ };