@librecode/sdk 0.1.0

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