@ofoundation/opencode-sdk 0.0.0-dev-202603011725

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 +3380 -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 +7 -0
  38. package/dist/v2/client.js +27 -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 +1168 -0
  66. package/dist/v2/gen/sdk.gen.js +2266 -0
  67. package/dist/v2/gen/types.gen.d.ts +4178 -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 +73 -0
@@ -0,0 +1,2266 @@
1
+ // This file is auto-generated by @hey-api/openapi-ts
2
+ import { client } from "./client.gen.js";
3
+ import { buildClientParams } from "./client/index.js";
4
+ class HeyApiClient {
5
+ client;
6
+ constructor(args) {
7
+ this.client = args?.client ?? client;
8
+ }
9
+ }
10
+ class HeyApiRegistry {
11
+ defaultKey = "default";
12
+ instances = new Map();
13
+ get(key) {
14
+ const instance = this.instances.get(key ?? this.defaultKey);
15
+ if (!instance) {
16
+ throw new Error(`No SDK client found. Create one with "new OpencodeClient()" to fix this error.`);
17
+ }
18
+ return instance;
19
+ }
20
+ set(value, key) {
21
+ this.instances.set(key ?? this.defaultKey, value);
22
+ }
23
+ }
24
+ export class Config extends HeyApiClient {
25
+ /**
26
+ * Get global configuration
27
+ *
28
+ * Retrieve the current global OpenCode configuration settings and preferences.
29
+ */
30
+ get(options) {
31
+ return (options?.client ?? this.client).get({
32
+ url: "/global/config",
33
+ ...options,
34
+ });
35
+ }
36
+ /**
37
+ * Update global configuration
38
+ *
39
+ * Update global OpenCode configuration settings and preferences.
40
+ */
41
+ update(parameters, options) {
42
+ const params = buildClientParams([parameters], [{ args: [{ key: "config", map: "body" }] }]);
43
+ return (options?.client ?? this.client).patch({
44
+ url: "/global/config",
45
+ ...options,
46
+ ...params,
47
+ headers: {
48
+ "Content-Type": "application/json",
49
+ ...options?.headers,
50
+ ...params.headers,
51
+ },
52
+ });
53
+ }
54
+ }
55
+ export class Global extends HeyApiClient {
56
+ /**
57
+ * Get health
58
+ *
59
+ * Get health information about the OpenCode server.
60
+ */
61
+ health(options) {
62
+ return (options?.client ?? this.client).get({
63
+ url: "/global/health",
64
+ ...options,
65
+ });
66
+ }
67
+ /**
68
+ * Get global events
69
+ *
70
+ * Subscribe to global events from the OpenCode system using server-sent events.
71
+ */
72
+ event(options) {
73
+ return (options?.client ?? this.client).sse.get({
74
+ url: "/global/event",
75
+ ...options,
76
+ });
77
+ }
78
+ /**
79
+ * Dispose instance
80
+ *
81
+ * Clean up and dispose all OpenCode instances, releasing all resources.
82
+ */
83
+ dispose(options) {
84
+ return (options?.client ?? this.client).post({
85
+ url: "/global/dispose",
86
+ ...options,
87
+ });
88
+ }
89
+ _config;
90
+ get config() {
91
+ return (this._config ??= new Config({ client: this.client }));
92
+ }
93
+ }
94
+ export class Auth extends HeyApiClient {
95
+ /**
96
+ * Remove auth credentials
97
+ *
98
+ * Remove authentication credentials
99
+ */
100
+ remove(parameters, options) {
101
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "providerID" }] }]);
102
+ return (options?.client ?? this.client).delete({
103
+ url: "/auth/{providerID}",
104
+ ...options,
105
+ ...params,
106
+ });
107
+ }
108
+ /**
109
+ * Set auth credentials
110
+ *
111
+ * Set authentication credentials
112
+ */
113
+ set(parameters, options) {
114
+ const params = buildClientParams([parameters], [
115
+ {
116
+ args: [
117
+ { in: "path", key: "providerID" },
118
+ { key: "auth", map: "body" },
119
+ ],
120
+ },
121
+ ]);
122
+ return (options?.client ?? this.client).put({
123
+ url: "/auth/{providerID}",
124
+ ...options,
125
+ ...params,
126
+ headers: {
127
+ "Content-Type": "application/json",
128
+ ...options?.headers,
129
+ ...params.headers,
130
+ },
131
+ });
132
+ }
133
+ }
134
+ export class Project extends HeyApiClient {
135
+ /**
136
+ * List all projects
137
+ *
138
+ * Get a list of projects that have been opened with OpenCode.
139
+ */
140
+ list(parameters, options) {
141
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
142
+ return (options?.client ?? this.client).get({
143
+ url: "/project",
144
+ ...options,
145
+ ...params,
146
+ });
147
+ }
148
+ /**
149
+ * Get current project
150
+ *
151
+ * Retrieve the currently active project that OpenCode is working with.
152
+ */
153
+ current(parameters, options) {
154
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
155
+ return (options?.client ?? this.client).get({
156
+ url: "/project/current",
157
+ ...options,
158
+ ...params,
159
+ });
160
+ }
161
+ /**
162
+ * Update project
163
+ *
164
+ * Update project properties such as name, icon, and commands.
165
+ */
166
+ update(parameters, options) {
167
+ const params = buildClientParams([parameters], [
168
+ {
169
+ args: [
170
+ { in: "path", key: "projectID" },
171
+ { in: "query", key: "directory" },
172
+ { in: "body", key: "name" },
173
+ { in: "body", key: "icon" },
174
+ { in: "body", key: "commands" },
175
+ ],
176
+ },
177
+ ]);
178
+ return (options?.client ?? this.client).patch({
179
+ url: "/project/{projectID}",
180
+ ...options,
181
+ ...params,
182
+ headers: {
183
+ "Content-Type": "application/json",
184
+ ...options?.headers,
185
+ ...params.headers,
186
+ },
187
+ });
188
+ }
189
+ }
190
+ export class Pty extends HeyApiClient {
191
+ /**
192
+ * List PTY sessions
193
+ *
194
+ * Get a list of all active pseudo-terminal (PTY) sessions managed by OpenCode.
195
+ */
196
+ list(parameters, options) {
197
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
198
+ return (options?.client ?? this.client).get({
199
+ url: "/pty",
200
+ ...options,
201
+ ...params,
202
+ });
203
+ }
204
+ /**
205
+ * Create PTY session
206
+ *
207
+ * Create a new pseudo-terminal (PTY) session for running shell commands and processes.
208
+ */
209
+ create(parameters, options) {
210
+ const params = buildClientParams([parameters], [
211
+ {
212
+ args: [
213
+ { in: "query", key: "directory" },
214
+ { in: "body", key: "command" },
215
+ { in: "body", key: "args" },
216
+ { in: "body", key: "cwd" },
217
+ { in: "body", key: "title" },
218
+ { in: "body", key: "env" },
219
+ ],
220
+ },
221
+ ]);
222
+ return (options?.client ?? this.client).post({
223
+ url: "/pty",
224
+ ...options,
225
+ ...params,
226
+ headers: {
227
+ "Content-Type": "application/json",
228
+ ...options?.headers,
229
+ ...params.headers,
230
+ },
231
+ });
232
+ }
233
+ /**
234
+ * Remove PTY session
235
+ *
236
+ * Remove and terminate a specific pseudo-terminal (PTY) session.
237
+ */
238
+ remove(parameters, options) {
239
+ const params = buildClientParams([parameters], [
240
+ {
241
+ args: [
242
+ { in: "path", key: "ptyID" },
243
+ { in: "query", key: "directory" },
244
+ ],
245
+ },
246
+ ]);
247
+ return (options?.client ?? this.client).delete({
248
+ url: "/pty/{ptyID}",
249
+ ...options,
250
+ ...params,
251
+ });
252
+ }
253
+ /**
254
+ * Get PTY session
255
+ *
256
+ * Retrieve detailed information about a specific pseudo-terminal (PTY) session.
257
+ */
258
+ get(parameters, options) {
259
+ const params = buildClientParams([parameters], [
260
+ {
261
+ args: [
262
+ { in: "path", key: "ptyID" },
263
+ { in: "query", key: "directory" },
264
+ ],
265
+ },
266
+ ]);
267
+ return (options?.client ?? this.client).get({
268
+ url: "/pty/{ptyID}",
269
+ ...options,
270
+ ...params,
271
+ });
272
+ }
273
+ /**
274
+ * Update PTY session
275
+ *
276
+ * Update properties of an existing pseudo-terminal (PTY) session.
277
+ */
278
+ update(parameters, options) {
279
+ const params = buildClientParams([parameters], [
280
+ {
281
+ args: [
282
+ { in: "path", key: "ptyID" },
283
+ { in: "query", key: "directory" },
284
+ { in: "body", key: "title" },
285
+ { in: "body", key: "size" },
286
+ ],
287
+ },
288
+ ]);
289
+ return (options?.client ?? this.client).put({
290
+ url: "/pty/{ptyID}",
291
+ ...options,
292
+ ...params,
293
+ headers: {
294
+ "Content-Type": "application/json",
295
+ ...options?.headers,
296
+ ...params.headers,
297
+ },
298
+ });
299
+ }
300
+ /**
301
+ * Connect to PTY session
302
+ *
303
+ * Establish a WebSocket connection to interact with a pseudo-terminal (PTY) session in real-time.
304
+ */
305
+ connect(parameters, options) {
306
+ const params = buildClientParams([parameters], [
307
+ {
308
+ args: [
309
+ { in: "path", key: "ptyID" },
310
+ { in: "query", key: "directory" },
311
+ ],
312
+ },
313
+ ]);
314
+ return (options?.client ?? this.client).get({
315
+ url: "/pty/{ptyID}/connect",
316
+ ...options,
317
+ ...params,
318
+ });
319
+ }
320
+ }
321
+ export class Config2 extends HeyApiClient {
322
+ /**
323
+ * Get configuration
324
+ *
325
+ * Retrieve the current OpenCode configuration settings and preferences.
326
+ */
327
+ get(parameters, options) {
328
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
329
+ return (options?.client ?? this.client).get({
330
+ url: "/config",
331
+ ...options,
332
+ ...params,
333
+ });
334
+ }
335
+ /**
336
+ * Update configuration
337
+ *
338
+ * Update OpenCode configuration settings and preferences.
339
+ */
340
+ update(parameters, options) {
341
+ const params = buildClientParams([parameters], [
342
+ {
343
+ args: [
344
+ { in: "query", key: "directory" },
345
+ { key: "config", map: "body" },
346
+ ],
347
+ },
348
+ ]);
349
+ return (options?.client ?? this.client).patch({
350
+ url: "/config",
351
+ ...options,
352
+ ...params,
353
+ headers: {
354
+ "Content-Type": "application/json",
355
+ ...options?.headers,
356
+ ...params.headers,
357
+ },
358
+ });
359
+ }
360
+ /**
361
+ * List config providers
362
+ *
363
+ * Get a list of all configured AI providers and their default models.
364
+ */
365
+ providers(parameters, options) {
366
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
367
+ return (options?.client ?? this.client).get({
368
+ url: "/config/providers",
369
+ ...options,
370
+ ...params,
371
+ });
372
+ }
373
+ }
374
+ export class Tool extends HeyApiClient {
375
+ /**
376
+ * List tool IDs
377
+ *
378
+ * Get a list of all available tool IDs, including both built-in tools and dynamically registered tools.
379
+ */
380
+ ids(parameters, options) {
381
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
382
+ return (options?.client ?? this.client).get({
383
+ url: "/experimental/tool/ids",
384
+ ...options,
385
+ ...params,
386
+ });
387
+ }
388
+ /**
389
+ * List tools
390
+ *
391
+ * Get a list of available tools with their JSON schema parameters for a specific provider and model combination.
392
+ */
393
+ list(parameters, options) {
394
+ const params = buildClientParams([parameters], [
395
+ {
396
+ args: [
397
+ { in: "query", key: "directory" },
398
+ { in: "query", key: "provider" },
399
+ { in: "query", key: "model" },
400
+ ],
401
+ },
402
+ ]);
403
+ return (options?.client ?? this.client).get({
404
+ url: "/experimental/tool",
405
+ ...options,
406
+ ...params,
407
+ });
408
+ }
409
+ }
410
+ export class Worktree extends HeyApiClient {
411
+ /**
412
+ * Remove worktree
413
+ *
414
+ * Remove a git worktree and delete its branch.
415
+ */
416
+ remove(parameters, options) {
417
+ const params = buildClientParams([parameters], [
418
+ {
419
+ args: [
420
+ { in: "query", key: "directory" },
421
+ { key: "worktreeRemoveInput", map: "body" },
422
+ ],
423
+ },
424
+ ]);
425
+ return (options?.client ?? this.client).delete({
426
+ url: "/experimental/worktree",
427
+ ...options,
428
+ ...params,
429
+ headers: {
430
+ "Content-Type": "application/json",
431
+ ...options?.headers,
432
+ ...params.headers,
433
+ },
434
+ });
435
+ }
436
+ /**
437
+ * List worktrees
438
+ *
439
+ * List all sandbox worktrees for the current project.
440
+ */
441
+ list(parameters, options) {
442
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
443
+ return (options?.client ?? this.client).get({
444
+ url: "/experimental/worktree",
445
+ ...options,
446
+ ...params,
447
+ });
448
+ }
449
+ /**
450
+ * Create worktree
451
+ *
452
+ * Create a new git worktree for the current project and run any configured startup scripts.
453
+ */
454
+ create(parameters, options) {
455
+ const params = buildClientParams([parameters], [
456
+ {
457
+ args: [
458
+ { in: "query", key: "directory" },
459
+ { key: "worktreeCreateInput", map: "body" },
460
+ ],
461
+ },
462
+ ]);
463
+ return (options?.client ?? this.client).post({
464
+ url: "/experimental/worktree",
465
+ ...options,
466
+ ...params,
467
+ headers: {
468
+ "Content-Type": "application/json",
469
+ ...options?.headers,
470
+ ...params.headers,
471
+ },
472
+ });
473
+ }
474
+ /**
475
+ * Reset worktree
476
+ *
477
+ * Reset a worktree branch to the primary default branch.
478
+ */
479
+ reset(parameters, options) {
480
+ const params = buildClientParams([parameters], [
481
+ {
482
+ args: [
483
+ { in: "query", key: "directory" },
484
+ { key: "worktreeResetInput", map: "body" },
485
+ ],
486
+ },
487
+ ]);
488
+ return (options?.client ?? this.client).post({
489
+ url: "/experimental/worktree/reset",
490
+ ...options,
491
+ ...params,
492
+ headers: {
493
+ "Content-Type": "application/json",
494
+ ...options?.headers,
495
+ ...params.headers,
496
+ },
497
+ });
498
+ }
499
+ }
500
+ export class Workspace extends HeyApiClient {
501
+ /**
502
+ * Remove workspace
503
+ *
504
+ * Remove an existing workspace.
505
+ */
506
+ remove(parameters, options) {
507
+ const params = buildClientParams([parameters], [
508
+ {
509
+ args: [
510
+ { in: "path", key: "id" },
511
+ { in: "query", key: "directory" },
512
+ ],
513
+ },
514
+ ]);
515
+ return (options?.client ?? this.client).delete({
516
+ url: "/experimental/workspace/{id}",
517
+ ...options,
518
+ ...params,
519
+ });
520
+ }
521
+ /**
522
+ * Create workspace
523
+ *
524
+ * Create a workspace for the current project.
525
+ */
526
+ create(parameters, options) {
527
+ const params = buildClientParams([parameters], [
528
+ {
529
+ args: [
530
+ { in: "path", key: "id" },
531
+ { in: "query", key: "directory" },
532
+ { in: "body", key: "branch" },
533
+ { in: "body", key: "config" },
534
+ ],
535
+ },
536
+ ]);
537
+ return (options?.client ?? this.client).post({
538
+ url: "/experimental/workspace/{id}",
539
+ ...options,
540
+ ...params,
541
+ headers: {
542
+ "Content-Type": "application/json",
543
+ ...options?.headers,
544
+ ...params.headers,
545
+ },
546
+ });
547
+ }
548
+ /**
549
+ * List workspaces
550
+ *
551
+ * List all workspaces.
552
+ */
553
+ list(parameters, options) {
554
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
555
+ return (options?.client ?? this.client).get({
556
+ url: "/experimental/workspace",
557
+ ...options,
558
+ ...params,
559
+ });
560
+ }
561
+ }
562
+ export class Session extends HeyApiClient {
563
+ /**
564
+ * List sessions
565
+ *
566
+ * Get a list of all OpenCode sessions across projects, sorted by most recently updated. Archived sessions are excluded by default.
567
+ */
568
+ list(parameters, options) {
569
+ const params = buildClientParams([parameters], [
570
+ {
571
+ args: [
572
+ { in: "query", key: "directory" },
573
+ { in: "query", key: "roots" },
574
+ { in: "query", key: "start" },
575
+ { in: "query", key: "cursor" },
576
+ { in: "query", key: "search" },
577
+ { in: "query", key: "limit" },
578
+ { in: "query", key: "archived" },
579
+ ],
580
+ },
581
+ ]);
582
+ return (options?.client ?? this.client).get({
583
+ url: "/experimental/session",
584
+ ...options,
585
+ ...params,
586
+ });
587
+ }
588
+ }
589
+ export class Resource extends HeyApiClient {
590
+ /**
591
+ * Get MCP resources
592
+ *
593
+ * Get all available MCP resources from connected servers. Optionally filter by name.
594
+ */
595
+ list(parameters, options) {
596
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
597
+ return (options?.client ?? this.client).get({
598
+ url: "/experimental/resource",
599
+ ...options,
600
+ ...params,
601
+ });
602
+ }
603
+ }
604
+ export class Experimental extends HeyApiClient {
605
+ _workspace;
606
+ get workspace() {
607
+ return (this._workspace ??= new Workspace({ client: this.client }));
608
+ }
609
+ _session;
610
+ get session() {
611
+ return (this._session ??= new Session({ client: this.client }));
612
+ }
613
+ _resource;
614
+ get resource() {
615
+ return (this._resource ??= new Resource({ client: this.client }));
616
+ }
617
+ }
618
+ export class Session2 extends HeyApiClient {
619
+ /**
620
+ * List sessions
621
+ *
622
+ * Get a list of all OpenCode sessions, sorted by most recently updated.
623
+ */
624
+ list(parameters, options) {
625
+ const params = buildClientParams([parameters], [
626
+ {
627
+ args: [
628
+ { in: "query", key: "directory" },
629
+ { in: "query", key: "roots" },
630
+ { in: "query", key: "start" },
631
+ { in: "query", key: "search" },
632
+ { in: "query", key: "limit" },
633
+ ],
634
+ },
635
+ ]);
636
+ return (options?.client ?? this.client).get({
637
+ url: "/session",
638
+ ...options,
639
+ ...params,
640
+ });
641
+ }
642
+ /**
643
+ * Create session
644
+ *
645
+ * Create a new OpenCode session for interacting with AI assistants and managing conversations.
646
+ */
647
+ create(parameters, options) {
648
+ const params = buildClientParams([parameters], [
649
+ {
650
+ args: [
651
+ { in: "query", key: "directory" },
652
+ { in: "body", key: "parentID" },
653
+ { in: "body", key: "title" },
654
+ { in: "body", key: "permission" },
655
+ ],
656
+ },
657
+ ]);
658
+ return (options?.client ?? this.client).post({
659
+ url: "/session",
660
+ ...options,
661
+ ...params,
662
+ headers: {
663
+ "Content-Type": "application/json",
664
+ ...options?.headers,
665
+ ...params.headers,
666
+ },
667
+ });
668
+ }
669
+ /**
670
+ * Get session status
671
+ *
672
+ * Retrieve the current status of all sessions, including active, idle, and completed states.
673
+ */
674
+ status(parameters, options) {
675
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
676
+ return (options?.client ?? this.client).get({
677
+ url: "/session/status",
678
+ ...options,
679
+ ...params,
680
+ });
681
+ }
682
+ /**
683
+ * Delete session
684
+ *
685
+ * Delete a session and permanently remove all associated data, including messages and history.
686
+ */
687
+ delete(parameters, options) {
688
+ const params = buildClientParams([parameters], [
689
+ {
690
+ args: [
691
+ { in: "path", key: "sessionID" },
692
+ { in: "query", key: "directory" },
693
+ ],
694
+ },
695
+ ]);
696
+ return (options?.client ?? this.client).delete({
697
+ url: "/session/{sessionID}",
698
+ ...options,
699
+ ...params,
700
+ });
701
+ }
702
+ /**
703
+ * Get session
704
+ *
705
+ * Retrieve detailed information about a specific OpenCode session.
706
+ */
707
+ get(parameters, options) {
708
+ const params = buildClientParams([parameters], [
709
+ {
710
+ args: [
711
+ { in: "path", key: "sessionID" },
712
+ { in: "query", key: "directory" },
713
+ ],
714
+ },
715
+ ]);
716
+ return (options?.client ?? this.client).get({
717
+ url: "/session/{sessionID}",
718
+ ...options,
719
+ ...params,
720
+ });
721
+ }
722
+ /**
723
+ * Update session
724
+ *
725
+ * Update properties of an existing session, such as title or other metadata.
726
+ */
727
+ update(parameters, options) {
728
+ const params = buildClientParams([parameters], [
729
+ {
730
+ args: [
731
+ { in: "path", key: "sessionID" },
732
+ { in: "query", key: "directory" },
733
+ { in: "body", key: "title" },
734
+ { in: "body", key: "time" },
735
+ ],
736
+ },
737
+ ]);
738
+ return (options?.client ?? this.client).patch({
739
+ url: "/session/{sessionID}",
740
+ ...options,
741
+ ...params,
742
+ headers: {
743
+ "Content-Type": "application/json",
744
+ ...options?.headers,
745
+ ...params.headers,
746
+ },
747
+ });
748
+ }
749
+ /**
750
+ * Get session children
751
+ *
752
+ * Retrieve all child sessions that were forked from the specified parent session.
753
+ */
754
+ children(parameters, options) {
755
+ const params = buildClientParams([parameters], [
756
+ {
757
+ args: [
758
+ { in: "path", key: "sessionID" },
759
+ { in: "query", key: "directory" },
760
+ ],
761
+ },
762
+ ]);
763
+ return (options?.client ?? this.client).get({
764
+ url: "/session/{sessionID}/children",
765
+ ...options,
766
+ ...params,
767
+ });
768
+ }
769
+ /**
770
+ * Get session todos
771
+ *
772
+ * Retrieve the todo list associated with a specific session, showing tasks and action items.
773
+ */
774
+ todo(parameters, options) {
775
+ const params = buildClientParams([parameters], [
776
+ {
777
+ args: [
778
+ { in: "path", key: "sessionID" },
779
+ { in: "query", key: "directory" },
780
+ ],
781
+ },
782
+ ]);
783
+ return (options?.client ?? this.client).get({
784
+ url: "/session/{sessionID}/todo",
785
+ ...options,
786
+ ...params,
787
+ });
788
+ }
789
+ /**
790
+ * Initialize session
791
+ *
792
+ * Analyze the current application and create an AGENTS.md file with project-specific agent configurations.
793
+ */
794
+ init(parameters, options) {
795
+ const params = buildClientParams([parameters], [
796
+ {
797
+ args: [
798
+ { in: "path", key: "sessionID" },
799
+ { in: "query", key: "directory" },
800
+ { in: "body", key: "modelID" },
801
+ { in: "body", key: "providerID" },
802
+ { in: "body", key: "messageID" },
803
+ ],
804
+ },
805
+ ]);
806
+ return (options?.client ?? this.client).post({
807
+ url: "/session/{sessionID}/init",
808
+ ...options,
809
+ ...params,
810
+ headers: {
811
+ "Content-Type": "application/json",
812
+ ...options?.headers,
813
+ ...params.headers,
814
+ },
815
+ });
816
+ }
817
+ /**
818
+ * Fork session
819
+ *
820
+ * Create a new session by forking an existing session at a specific message point.
821
+ */
822
+ fork(parameters, options) {
823
+ const params = buildClientParams([parameters], [
824
+ {
825
+ args: [
826
+ { in: "path", key: "sessionID" },
827
+ { in: "query", key: "directory" },
828
+ { in: "body", key: "messageID" },
829
+ ],
830
+ },
831
+ ]);
832
+ return (options?.client ?? this.client).post({
833
+ url: "/session/{sessionID}/fork",
834
+ ...options,
835
+ ...params,
836
+ headers: {
837
+ "Content-Type": "application/json",
838
+ ...options?.headers,
839
+ ...params.headers,
840
+ },
841
+ });
842
+ }
843
+ /**
844
+ * Abort session
845
+ *
846
+ * Abort an active session and stop any ongoing AI processing or command execution.
847
+ */
848
+ abort(parameters, options) {
849
+ const params = buildClientParams([parameters], [
850
+ {
851
+ args: [
852
+ { in: "path", key: "sessionID" },
853
+ { in: "query", key: "directory" },
854
+ ],
855
+ },
856
+ ]);
857
+ return (options?.client ?? this.client).post({
858
+ url: "/session/{sessionID}/abort",
859
+ ...options,
860
+ ...params,
861
+ });
862
+ }
863
+ /**
864
+ * Unshare session
865
+ *
866
+ * Remove the shareable link for a session, making it private again.
867
+ */
868
+ unshare(parameters, options) {
869
+ const params = buildClientParams([parameters], [
870
+ {
871
+ args: [
872
+ { in: "path", key: "sessionID" },
873
+ { in: "query", key: "directory" },
874
+ ],
875
+ },
876
+ ]);
877
+ return (options?.client ?? this.client).delete({
878
+ url: "/session/{sessionID}/share",
879
+ ...options,
880
+ ...params,
881
+ });
882
+ }
883
+ /**
884
+ * Share session
885
+ *
886
+ * Create a shareable link for a session, allowing others to view the conversation.
887
+ */
888
+ share(parameters, options) {
889
+ const params = buildClientParams([parameters], [
890
+ {
891
+ args: [
892
+ { in: "path", key: "sessionID" },
893
+ { in: "query", key: "directory" },
894
+ ],
895
+ },
896
+ ]);
897
+ return (options?.client ?? this.client).post({
898
+ url: "/session/{sessionID}/share",
899
+ ...options,
900
+ ...params,
901
+ });
902
+ }
903
+ /**
904
+ * Get message diff
905
+ *
906
+ * Get the file changes (diff) that resulted from a specific user message in the session.
907
+ */
908
+ diff(parameters, options) {
909
+ const params = buildClientParams([parameters], [
910
+ {
911
+ args: [
912
+ { in: "path", key: "sessionID" },
913
+ { in: "query", key: "directory" },
914
+ { in: "query", key: "messageID" },
915
+ ],
916
+ },
917
+ ]);
918
+ return (options?.client ?? this.client).get({
919
+ url: "/session/{sessionID}/diff",
920
+ ...options,
921
+ ...params,
922
+ });
923
+ }
924
+ /**
925
+ * Summarize session
926
+ *
927
+ * Generate a concise summary of the session using AI compaction to preserve key information.
928
+ */
929
+ summarize(parameters, options) {
930
+ const params = buildClientParams([parameters], [
931
+ {
932
+ args: [
933
+ { in: "path", key: "sessionID" },
934
+ { in: "query", key: "directory" },
935
+ { in: "body", key: "providerID" },
936
+ { in: "body", key: "modelID" },
937
+ { in: "body", key: "auto" },
938
+ ],
939
+ },
940
+ ]);
941
+ return (options?.client ?? this.client).post({
942
+ url: "/session/{sessionID}/summarize",
943
+ ...options,
944
+ ...params,
945
+ headers: {
946
+ "Content-Type": "application/json",
947
+ ...options?.headers,
948
+ ...params.headers,
949
+ },
950
+ });
951
+ }
952
+ /**
953
+ * Get session messages
954
+ *
955
+ * Retrieve all messages in a session, including user prompts and AI responses.
956
+ */
957
+ messages(parameters, options) {
958
+ const params = buildClientParams([parameters], [
959
+ {
960
+ args: [
961
+ { in: "path", key: "sessionID" },
962
+ { in: "query", key: "directory" },
963
+ { in: "query", key: "limit" },
964
+ ],
965
+ },
966
+ ]);
967
+ return (options?.client ?? this.client).get({
968
+ url: "/session/{sessionID}/message",
969
+ ...options,
970
+ ...params,
971
+ });
972
+ }
973
+ /**
974
+ * Send message
975
+ *
976
+ * Create and send a new message to a session, streaming the AI response.
977
+ */
978
+ prompt(parameters, options) {
979
+ const params = buildClientParams([parameters], [
980
+ {
981
+ args: [
982
+ { in: "path", key: "sessionID" },
983
+ { in: "query", key: "directory" },
984
+ { in: "body", key: "messageID" },
985
+ { in: "body", key: "model" },
986
+ { in: "body", key: "agent" },
987
+ { in: "body", key: "noReply" },
988
+ { in: "body", key: "tools" },
989
+ { in: "body", key: "format" },
990
+ { in: "body", key: "system" },
991
+ { in: "body", key: "variant" },
992
+ { in: "body", key: "parts" },
993
+ ],
994
+ },
995
+ ]);
996
+ return (options?.client ?? this.client).post({
997
+ url: "/session/{sessionID}/message",
998
+ ...options,
999
+ ...params,
1000
+ headers: {
1001
+ "Content-Type": "application/json",
1002
+ ...options?.headers,
1003
+ ...params.headers,
1004
+ },
1005
+ });
1006
+ }
1007
+ /**
1008
+ * Delete message
1009
+ *
1010
+ * Permanently delete a specific message (and all of its parts) from a session. This does not revert any file changes that may have been made while processing the message.
1011
+ */
1012
+ deleteMessage(parameters, options) {
1013
+ const params = buildClientParams([parameters], [
1014
+ {
1015
+ args: [
1016
+ { in: "path", key: "sessionID" },
1017
+ { in: "path", key: "messageID" },
1018
+ { in: "query", key: "directory" },
1019
+ ],
1020
+ },
1021
+ ]);
1022
+ return (options?.client ?? this.client).delete({
1023
+ url: "/session/{sessionID}/message/{messageID}",
1024
+ ...options,
1025
+ ...params,
1026
+ });
1027
+ }
1028
+ /**
1029
+ * Get message
1030
+ *
1031
+ * Retrieve a specific message from a session by its message ID.
1032
+ */
1033
+ message(parameters, options) {
1034
+ const params = buildClientParams([parameters], [
1035
+ {
1036
+ args: [
1037
+ { in: "path", key: "sessionID" },
1038
+ { in: "path", key: "messageID" },
1039
+ { in: "query", key: "directory" },
1040
+ ],
1041
+ },
1042
+ ]);
1043
+ return (options?.client ?? this.client).get({
1044
+ url: "/session/{sessionID}/message/{messageID}",
1045
+ ...options,
1046
+ ...params,
1047
+ });
1048
+ }
1049
+ /**
1050
+ * Send async message
1051
+ *
1052
+ * Create and send a new message to a session asynchronously, starting the session if needed and returning immediately.
1053
+ */
1054
+ promptAsync(parameters, options) {
1055
+ const params = buildClientParams([parameters], [
1056
+ {
1057
+ args: [
1058
+ { in: "path", key: "sessionID" },
1059
+ { in: "query", key: "directory" },
1060
+ { in: "body", key: "messageID" },
1061
+ { in: "body", key: "model" },
1062
+ { in: "body", key: "agent" },
1063
+ { in: "body", key: "noReply" },
1064
+ { in: "body", key: "tools" },
1065
+ { in: "body", key: "format" },
1066
+ { in: "body", key: "system" },
1067
+ { in: "body", key: "variant" },
1068
+ { in: "body", key: "parts" },
1069
+ ],
1070
+ },
1071
+ ]);
1072
+ return (options?.client ?? this.client).post({
1073
+ url: "/session/{sessionID}/prompt_async",
1074
+ ...options,
1075
+ ...params,
1076
+ headers: {
1077
+ "Content-Type": "application/json",
1078
+ ...options?.headers,
1079
+ ...params.headers,
1080
+ },
1081
+ });
1082
+ }
1083
+ /**
1084
+ * Send command
1085
+ *
1086
+ * Send a new command to a session for execution by the AI assistant.
1087
+ */
1088
+ command(parameters, options) {
1089
+ const params = buildClientParams([parameters], [
1090
+ {
1091
+ args: [
1092
+ { in: "path", key: "sessionID" },
1093
+ { in: "query", key: "directory" },
1094
+ { in: "body", key: "messageID" },
1095
+ { in: "body", key: "agent" },
1096
+ { in: "body", key: "model" },
1097
+ { in: "body", key: "arguments" },
1098
+ { in: "body", key: "command" },
1099
+ { in: "body", key: "variant" },
1100
+ { in: "body", key: "parts" },
1101
+ ],
1102
+ },
1103
+ ]);
1104
+ return (options?.client ?? this.client).post({
1105
+ url: "/session/{sessionID}/command",
1106
+ ...options,
1107
+ ...params,
1108
+ headers: {
1109
+ "Content-Type": "application/json",
1110
+ ...options?.headers,
1111
+ ...params.headers,
1112
+ },
1113
+ });
1114
+ }
1115
+ /**
1116
+ * Run shell command
1117
+ *
1118
+ * Execute a shell command within the session context and return the AI's response.
1119
+ */
1120
+ shell(parameters, options) {
1121
+ const params = buildClientParams([parameters], [
1122
+ {
1123
+ args: [
1124
+ { in: "path", key: "sessionID" },
1125
+ { in: "query", key: "directory" },
1126
+ { in: "body", key: "agent" },
1127
+ { in: "body", key: "model" },
1128
+ { in: "body", key: "command" },
1129
+ ],
1130
+ },
1131
+ ]);
1132
+ return (options?.client ?? this.client).post({
1133
+ url: "/session/{sessionID}/shell",
1134
+ ...options,
1135
+ ...params,
1136
+ headers: {
1137
+ "Content-Type": "application/json",
1138
+ ...options?.headers,
1139
+ ...params.headers,
1140
+ },
1141
+ });
1142
+ }
1143
+ /**
1144
+ * Revert message
1145
+ *
1146
+ * Revert a specific message in a session, undoing its effects and restoring the previous state.
1147
+ */
1148
+ revert(parameters, options) {
1149
+ const params = buildClientParams([parameters], [
1150
+ {
1151
+ args: [
1152
+ { in: "path", key: "sessionID" },
1153
+ { in: "query", key: "directory" },
1154
+ { in: "body", key: "messageID" },
1155
+ { in: "body", key: "partID" },
1156
+ ],
1157
+ },
1158
+ ]);
1159
+ return (options?.client ?? this.client).post({
1160
+ url: "/session/{sessionID}/revert",
1161
+ ...options,
1162
+ ...params,
1163
+ headers: {
1164
+ "Content-Type": "application/json",
1165
+ ...options?.headers,
1166
+ ...params.headers,
1167
+ },
1168
+ });
1169
+ }
1170
+ /**
1171
+ * Restore reverted messages
1172
+ *
1173
+ * Restore all previously reverted messages in a session.
1174
+ */
1175
+ unrevert(parameters, options) {
1176
+ const params = buildClientParams([parameters], [
1177
+ {
1178
+ args: [
1179
+ { in: "path", key: "sessionID" },
1180
+ { in: "query", key: "directory" },
1181
+ ],
1182
+ },
1183
+ ]);
1184
+ return (options?.client ?? this.client).post({
1185
+ url: "/session/{sessionID}/unrevert",
1186
+ ...options,
1187
+ ...params,
1188
+ });
1189
+ }
1190
+ }
1191
+ export class Part extends HeyApiClient {
1192
+ /**
1193
+ * Delete a part from a message
1194
+ */
1195
+ delete(parameters, options) {
1196
+ const params = buildClientParams([parameters], [
1197
+ {
1198
+ args: [
1199
+ { in: "path", key: "sessionID" },
1200
+ { in: "path", key: "messageID" },
1201
+ { in: "path", key: "partID" },
1202
+ { in: "query", key: "directory" },
1203
+ ],
1204
+ },
1205
+ ]);
1206
+ return (options?.client ?? this.client).delete({
1207
+ url: "/session/{sessionID}/message/{messageID}/part/{partID}",
1208
+ ...options,
1209
+ ...params,
1210
+ });
1211
+ }
1212
+ /**
1213
+ * Update a part in a message
1214
+ */
1215
+ update(parameters, options) {
1216
+ const params = buildClientParams([parameters], [
1217
+ {
1218
+ args: [
1219
+ { in: "path", key: "sessionID" },
1220
+ { in: "path", key: "messageID" },
1221
+ { in: "path", key: "partID" },
1222
+ { in: "query", key: "directory" },
1223
+ { key: "part", map: "body" },
1224
+ ],
1225
+ },
1226
+ ]);
1227
+ return (options?.client ?? this.client).patch({
1228
+ url: "/session/{sessionID}/message/{messageID}/part/{partID}",
1229
+ ...options,
1230
+ ...params,
1231
+ headers: {
1232
+ "Content-Type": "application/json",
1233
+ ...options?.headers,
1234
+ ...params.headers,
1235
+ },
1236
+ });
1237
+ }
1238
+ }
1239
+ export class Permission extends HeyApiClient {
1240
+ /**
1241
+ * Respond to permission
1242
+ *
1243
+ * Approve or deny a permission request from the AI assistant.
1244
+ *
1245
+ * @deprecated
1246
+ */
1247
+ respond(parameters, options) {
1248
+ const params = buildClientParams([parameters], [
1249
+ {
1250
+ args: [
1251
+ { in: "path", key: "sessionID" },
1252
+ { in: "path", key: "permissionID" },
1253
+ { in: "query", key: "directory" },
1254
+ { in: "body", key: "response" },
1255
+ ],
1256
+ },
1257
+ ]);
1258
+ return (options?.client ?? this.client).post({
1259
+ url: "/session/{sessionID}/permissions/{permissionID}",
1260
+ ...options,
1261
+ ...params,
1262
+ headers: {
1263
+ "Content-Type": "application/json",
1264
+ ...options?.headers,
1265
+ ...params.headers,
1266
+ },
1267
+ });
1268
+ }
1269
+ /**
1270
+ * Respond to permission request
1271
+ *
1272
+ * Approve or deny a permission request from the AI assistant.
1273
+ */
1274
+ reply(parameters, options) {
1275
+ const params = buildClientParams([parameters], [
1276
+ {
1277
+ args: [
1278
+ { in: "path", key: "requestID" },
1279
+ { in: "query", key: "directory" },
1280
+ { in: "body", key: "reply" },
1281
+ { in: "body", key: "message" },
1282
+ ],
1283
+ },
1284
+ ]);
1285
+ return (options?.client ?? this.client).post({
1286
+ url: "/permission/{requestID}/reply",
1287
+ ...options,
1288
+ ...params,
1289
+ headers: {
1290
+ "Content-Type": "application/json",
1291
+ ...options?.headers,
1292
+ ...params.headers,
1293
+ },
1294
+ });
1295
+ }
1296
+ /**
1297
+ * List pending permissions
1298
+ *
1299
+ * Get all pending permission requests across all sessions.
1300
+ */
1301
+ list(parameters, options) {
1302
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1303
+ return (options?.client ?? this.client).get({
1304
+ url: "/permission",
1305
+ ...options,
1306
+ ...params,
1307
+ });
1308
+ }
1309
+ }
1310
+ export class Question extends HeyApiClient {
1311
+ /**
1312
+ * List pending questions
1313
+ *
1314
+ * Get all pending question requests across all sessions.
1315
+ */
1316
+ list(parameters, options) {
1317
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1318
+ return (options?.client ?? this.client).get({
1319
+ url: "/question",
1320
+ ...options,
1321
+ ...params,
1322
+ });
1323
+ }
1324
+ /**
1325
+ * Reply to question request
1326
+ *
1327
+ * Provide answers to a question request from the AI assistant.
1328
+ */
1329
+ reply(parameters, options) {
1330
+ const params = buildClientParams([parameters], [
1331
+ {
1332
+ args: [
1333
+ { in: "path", key: "requestID" },
1334
+ { in: "query", key: "directory" },
1335
+ { in: "body", key: "answers" },
1336
+ ],
1337
+ },
1338
+ ]);
1339
+ return (options?.client ?? this.client).post({
1340
+ url: "/question/{requestID}/reply",
1341
+ ...options,
1342
+ ...params,
1343
+ headers: {
1344
+ "Content-Type": "application/json",
1345
+ ...options?.headers,
1346
+ ...params.headers,
1347
+ },
1348
+ });
1349
+ }
1350
+ /**
1351
+ * Reject question request
1352
+ *
1353
+ * Reject a question request from the AI assistant.
1354
+ */
1355
+ reject(parameters, options) {
1356
+ const params = buildClientParams([parameters], [
1357
+ {
1358
+ args: [
1359
+ { in: "path", key: "requestID" },
1360
+ { in: "query", key: "directory" },
1361
+ ],
1362
+ },
1363
+ ]);
1364
+ return (options?.client ?? this.client).post({
1365
+ url: "/question/{requestID}/reject",
1366
+ ...options,
1367
+ ...params,
1368
+ });
1369
+ }
1370
+ }
1371
+ export class Oauth extends HeyApiClient {
1372
+ /**
1373
+ * OAuth authorize
1374
+ *
1375
+ * Initiate OAuth authorization for a specific AI provider to get an authorization URL.
1376
+ */
1377
+ authorize(parameters, options) {
1378
+ const params = buildClientParams([parameters], [
1379
+ {
1380
+ args: [
1381
+ { in: "path", key: "providerID" },
1382
+ { in: "query", key: "directory" },
1383
+ { in: "body", key: "method" },
1384
+ ],
1385
+ },
1386
+ ]);
1387
+ return (options?.client ?? this.client).post({
1388
+ url: "/provider/{providerID}/oauth/authorize",
1389
+ ...options,
1390
+ ...params,
1391
+ headers: {
1392
+ "Content-Type": "application/json",
1393
+ ...options?.headers,
1394
+ ...params.headers,
1395
+ },
1396
+ });
1397
+ }
1398
+ /**
1399
+ * OAuth callback
1400
+ *
1401
+ * Handle the OAuth callback from a provider after user authorization.
1402
+ */
1403
+ callback(parameters, options) {
1404
+ const params = buildClientParams([parameters], [
1405
+ {
1406
+ args: [
1407
+ { in: "path", key: "providerID" },
1408
+ { in: "query", key: "directory" },
1409
+ { in: "body", key: "method" },
1410
+ { in: "body", key: "code" },
1411
+ ],
1412
+ },
1413
+ ]);
1414
+ return (options?.client ?? this.client).post({
1415
+ url: "/provider/{providerID}/oauth/callback",
1416
+ ...options,
1417
+ ...params,
1418
+ headers: {
1419
+ "Content-Type": "application/json",
1420
+ ...options?.headers,
1421
+ ...params.headers,
1422
+ },
1423
+ });
1424
+ }
1425
+ }
1426
+ export class Provider extends HeyApiClient {
1427
+ /**
1428
+ * List providers
1429
+ *
1430
+ * Get a list of all available AI providers, including both available and connected ones.
1431
+ */
1432
+ list(parameters, options) {
1433
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1434
+ return (options?.client ?? this.client).get({
1435
+ url: "/provider",
1436
+ ...options,
1437
+ ...params,
1438
+ });
1439
+ }
1440
+ /**
1441
+ * Get provider auth methods
1442
+ *
1443
+ * Retrieve available authentication methods for all AI providers.
1444
+ */
1445
+ auth(parameters, options) {
1446
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1447
+ return (options?.client ?? this.client).get({
1448
+ url: "/provider/auth",
1449
+ ...options,
1450
+ ...params,
1451
+ });
1452
+ }
1453
+ _oauth;
1454
+ get oauth() {
1455
+ return (this._oauth ??= new Oauth({ client: this.client }));
1456
+ }
1457
+ }
1458
+ export class Find extends HeyApiClient {
1459
+ /**
1460
+ * Find text
1461
+ *
1462
+ * Search for text patterns across files in the project using ripgrep.
1463
+ */
1464
+ text(parameters, options) {
1465
+ const params = buildClientParams([parameters], [
1466
+ {
1467
+ args: [
1468
+ { in: "query", key: "directory" },
1469
+ { in: "query", key: "pattern" },
1470
+ ],
1471
+ },
1472
+ ]);
1473
+ return (options?.client ?? this.client).get({
1474
+ url: "/find",
1475
+ ...options,
1476
+ ...params,
1477
+ });
1478
+ }
1479
+ /**
1480
+ * Find files
1481
+ *
1482
+ * Search for files or directories by name or pattern in the project directory.
1483
+ */
1484
+ files(parameters, options) {
1485
+ const params = buildClientParams([parameters], [
1486
+ {
1487
+ args: [
1488
+ { in: "query", key: "directory" },
1489
+ { in: "query", key: "query" },
1490
+ { in: "query", key: "dirs" },
1491
+ { in: "query", key: "type" },
1492
+ { in: "query", key: "limit" },
1493
+ ],
1494
+ },
1495
+ ]);
1496
+ return (options?.client ?? this.client).get({
1497
+ url: "/find/file",
1498
+ ...options,
1499
+ ...params,
1500
+ });
1501
+ }
1502
+ /**
1503
+ * Find symbols
1504
+ *
1505
+ * Search for workspace symbols like functions, classes, and variables using LSP.
1506
+ */
1507
+ symbols(parameters, options) {
1508
+ const params = buildClientParams([parameters], [
1509
+ {
1510
+ args: [
1511
+ { in: "query", key: "directory" },
1512
+ { in: "query", key: "query" },
1513
+ ],
1514
+ },
1515
+ ]);
1516
+ return (options?.client ?? this.client).get({
1517
+ url: "/find/symbol",
1518
+ ...options,
1519
+ ...params,
1520
+ });
1521
+ }
1522
+ }
1523
+ export class File extends HeyApiClient {
1524
+ /**
1525
+ * List files
1526
+ *
1527
+ * List files and directories in a specified path.
1528
+ */
1529
+ list(parameters, options) {
1530
+ const params = buildClientParams([parameters], [
1531
+ {
1532
+ args: [
1533
+ { in: "query", key: "directory" },
1534
+ { in: "query", key: "path" },
1535
+ ],
1536
+ },
1537
+ ]);
1538
+ return (options?.client ?? this.client).get({
1539
+ url: "/file",
1540
+ ...options,
1541
+ ...params,
1542
+ });
1543
+ }
1544
+ /**
1545
+ * Read file
1546
+ *
1547
+ * Read the content of a specified file.
1548
+ */
1549
+ read(parameters, options) {
1550
+ const params = buildClientParams([parameters], [
1551
+ {
1552
+ args: [
1553
+ { in: "query", key: "directory" },
1554
+ { in: "query", key: "path" },
1555
+ ],
1556
+ },
1557
+ ]);
1558
+ return (options?.client ?? this.client).get({
1559
+ url: "/file/content",
1560
+ ...options,
1561
+ ...params,
1562
+ });
1563
+ }
1564
+ /**
1565
+ * Get file status
1566
+ *
1567
+ * Get the git status of all files in the project.
1568
+ */
1569
+ status(parameters, options) {
1570
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1571
+ return (options?.client ?? this.client).get({
1572
+ url: "/file/status",
1573
+ ...options,
1574
+ ...params,
1575
+ });
1576
+ }
1577
+ }
1578
+ export class Auth2 extends HeyApiClient {
1579
+ /**
1580
+ * Remove MCP OAuth
1581
+ *
1582
+ * Remove OAuth credentials for an MCP server
1583
+ */
1584
+ remove(parameters, options) {
1585
+ const params = buildClientParams([parameters], [
1586
+ {
1587
+ args: [
1588
+ { in: "path", key: "name" },
1589
+ { in: "query", key: "directory" },
1590
+ ],
1591
+ },
1592
+ ]);
1593
+ return (options?.client ?? this.client).delete({
1594
+ url: "/mcp/{name}/auth",
1595
+ ...options,
1596
+ ...params,
1597
+ });
1598
+ }
1599
+ /**
1600
+ * Start MCP OAuth
1601
+ *
1602
+ * Start OAuth authentication flow for a Model Context Protocol (MCP) server.
1603
+ */
1604
+ start(parameters, options) {
1605
+ const params = buildClientParams([parameters], [
1606
+ {
1607
+ args: [
1608
+ { in: "path", key: "name" },
1609
+ { in: "query", key: "directory" },
1610
+ ],
1611
+ },
1612
+ ]);
1613
+ return (options?.client ?? this.client).post({
1614
+ url: "/mcp/{name}/auth",
1615
+ ...options,
1616
+ ...params,
1617
+ });
1618
+ }
1619
+ /**
1620
+ * Complete MCP OAuth
1621
+ *
1622
+ * Complete OAuth authentication for a Model Context Protocol (MCP) server using the authorization code.
1623
+ */
1624
+ callback(parameters, options) {
1625
+ const params = buildClientParams([parameters], [
1626
+ {
1627
+ args: [
1628
+ { in: "path", key: "name" },
1629
+ { in: "query", key: "directory" },
1630
+ { in: "body", key: "code" },
1631
+ ],
1632
+ },
1633
+ ]);
1634
+ return (options?.client ?? this.client).post({
1635
+ url: "/mcp/{name}/auth/callback",
1636
+ ...options,
1637
+ ...params,
1638
+ headers: {
1639
+ "Content-Type": "application/json",
1640
+ ...options?.headers,
1641
+ ...params.headers,
1642
+ },
1643
+ });
1644
+ }
1645
+ /**
1646
+ * Authenticate MCP OAuth
1647
+ *
1648
+ * Start OAuth flow and wait for callback (opens browser)
1649
+ */
1650
+ authenticate(parameters, options) {
1651
+ const params = buildClientParams([parameters], [
1652
+ {
1653
+ args: [
1654
+ { in: "path", key: "name" },
1655
+ { in: "query", key: "directory" },
1656
+ ],
1657
+ },
1658
+ ]);
1659
+ return (options?.client ?? this.client).post({
1660
+ url: "/mcp/{name}/auth/authenticate",
1661
+ ...options,
1662
+ ...params,
1663
+ });
1664
+ }
1665
+ }
1666
+ export class Mcp extends HeyApiClient {
1667
+ /**
1668
+ * Get MCP status
1669
+ *
1670
+ * Get the status of all Model Context Protocol (MCP) servers.
1671
+ */
1672
+ status(parameters, options) {
1673
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1674
+ return (options?.client ?? this.client).get({
1675
+ url: "/mcp",
1676
+ ...options,
1677
+ ...params,
1678
+ });
1679
+ }
1680
+ /**
1681
+ * Add MCP server
1682
+ *
1683
+ * Dynamically add a new Model Context Protocol (MCP) server to the system.
1684
+ */
1685
+ add(parameters, options) {
1686
+ const params = buildClientParams([parameters], [
1687
+ {
1688
+ args: [
1689
+ { in: "query", key: "directory" },
1690
+ { in: "body", key: "name" },
1691
+ { in: "body", key: "config" },
1692
+ ],
1693
+ },
1694
+ ]);
1695
+ return (options?.client ?? this.client).post({
1696
+ url: "/mcp",
1697
+ ...options,
1698
+ ...params,
1699
+ headers: {
1700
+ "Content-Type": "application/json",
1701
+ ...options?.headers,
1702
+ ...params.headers,
1703
+ },
1704
+ });
1705
+ }
1706
+ /**
1707
+ * Connect an MCP server
1708
+ */
1709
+ connect(parameters, options) {
1710
+ const params = buildClientParams([parameters], [
1711
+ {
1712
+ args: [
1713
+ { in: "path", key: "name" },
1714
+ { in: "query", key: "directory" },
1715
+ ],
1716
+ },
1717
+ ]);
1718
+ return (options?.client ?? this.client).post({
1719
+ url: "/mcp/{name}/connect",
1720
+ ...options,
1721
+ ...params,
1722
+ });
1723
+ }
1724
+ /**
1725
+ * Disconnect an MCP server
1726
+ */
1727
+ disconnect(parameters, options) {
1728
+ const params = buildClientParams([parameters], [
1729
+ {
1730
+ args: [
1731
+ { in: "path", key: "name" },
1732
+ { in: "query", key: "directory" },
1733
+ ],
1734
+ },
1735
+ ]);
1736
+ return (options?.client ?? this.client).post({
1737
+ url: "/mcp/{name}/disconnect",
1738
+ ...options,
1739
+ ...params,
1740
+ });
1741
+ }
1742
+ _auth;
1743
+ get auth() {
1744
+ return (this._auth ??= new Auth2({ client: this.client }));
1745
+ }
1746
+ }
1747
+ export class Control extends HeyApiClient {
1748
+ /**
1749
+ * Get next TUI request
1750
+ *
1751
+ * Retrieve the next TUI (Terminal User Interface) request from the queue for processing.
1752
+ */
1753
+ next(parameters, options) {
1754
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1755
+ return (options?.client ?? this.client).get({
1756
+ url: "/tui/control/next",
1757
+ ...options,
1758
+ ...params,
1759
+ });
1760
+ }
1761
+ /**
1762
+ * Submit TUI response
1763
+ *
1764
+ * Submit a response to the TUI request queue to complete a pending request.
1765
+ */
1766
+ response(parameters, options) {
1767
+ const params = buildClientParams([parameters], [
1768
+ {
1769
+ args: [
1770
+ { in: "query", key: "directory" },
1771
+ { key: "body", map: "body" },
1772
+ ],
1773
+ },
1774
+ ]);
1775
+ return (options?.client ?? this.client).post({
1776
+ url: "/tui/control/response",
1777
+ ...options,
1778
+ ...params,
1779
+ headers: {
1780
+ "Content-Type": "application/json",
1781
+ ...options?.headers,
1782
+ ...params.headers,
1783
+ },
1784
+ });
1785
+ }
1786
+ }
1787
+ export class Tui extends HeyApiClient {
1788
+ /**
1789
+ * Append TUI prompt
1790
+ *
1791
+ * Append prompt to the TUI
1792
+ */
1793
+ appendPrompt(parameters, options) {
1794
+ const params = buildClientParams([parameters], [
1795
+ {
1796
+ args: [
1797
+ { in: "query", key: "directory" },
1798
+ { in: "body", key: "text" },
1799
+ ],
1800
+ },
1801
+ ]);
1802
+ return (options?.client ?? this.client).post({
1803
+ url: "/tui/append-prompt",
1804
+ ...options,
1805
+ ...params,
1806
+ headers: {
1807
+ "Content-Type": "application/json",
1808
+ ...options?.headers,
1809
+ ...params.headers,
1810
+ },
1811
+ });
1812
+ }
1813
+ /**
1814
+ * Open help dialog
1815
+ *
1816
+ * Open the help dialog in the TUI to display user assistance information.
1817
+ */
1818
+ openHelp(parameters, options) {
1819
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1820
+ return (options?.client ?? this.client).post({
1821
+ url: "/tui/open-help",
1822
+ ...options,
1823
+ ...params,
1824
+ });
1825
+ }
1826
+ /**
1827
+ * Open sessions dialog
1828
+ *
1829
+ * Open the session dialog
1830
+ */
1831
+ openSessions(parameters, options) {
1832
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1833
+ return (options?.client ?? this.client).post({
1834
+ url: "/tui/open-sessions",
1835
+ ...options,
1836
+ ...params,
1837
+ });
1838
+ }
1839
+ /**
1840
+ * Open themes dialog
1841
+ *
1842
+ * Open the theme dialog
1843
+ */
1844
+ openThemes(parameters, options) {
1845
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1846
+ return (options?.client ?? this.client).post({
1847
+ url: "/tui/open-themes",
1848
+ ...options,
1849
+ ...params,
1850
+ });
1851
+ }
1852
+ /**
1853
+ * Open models dialog
1854
+ *
1855
+ * Open the model dialog
1856
+ */
1857
+ openModels(parameters, options) {
1858
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1859
+ return (options?.client ?? this.client).post({
1860
+ url: "/tui/open-models",
1861
+ ...options,
1862
+ ...params,
1863
+ });
1864
+ }
1865
+ /**
1866
+ * Submit TUI prompt
1867
+ *
1868
+ * Submit the prompt
1869
+ */
1870
+ submitPrompt(parameters, options) {
1871
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1872
+ return (options?.client ?? this.client).post({
1873
+ url: "/tui/submit-prompt",
1874
+ ...options,
1875
+ ...params,
1876
+ });
1877
+ }
1878
+ /**
1879
+ * Clear TUI prompt
1880
+ *
1881
+ * Clear the prompt
1882
+ */
1883
+ clearPrompt(parameters, options) {
1884
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
1885
+ return (options?.client ?? this.client).post({
1886
+ url: "/tui/clear-prompt",
1887
+ ...options,
1888
+ ...params,
1889
+ });
1890
+ }
1891
+ /**
1892
+ * Execute TUI command
1893
+ *
1894
+ * Execute a TUI command (e.g. agent_cycle)
1895
+ */
1896
+ executeCommand(parameters, options) {
1897
+ const params = buildClientParams([parameters], [
1898
+ {
1899
+ args: [
1900
+ { in: "query", key: "directory" },
1901
+ { in: "body", key: "command" },
1902
+ ],
1903
+ },
1904
+ ]);
1905
+ return (options?.client ?? this.client).post({
1906
+ url: "/tui/execute-command",
1907
+ ...options,
1908
+ ...params,
1909
+ headers: {
1910
+ "Content-Type": "application/json",
1911
+ ...options?.headers,
1912
+ ...params.headers,
1913
+ },
1914
+ });
1915
+ }
1916
+ /**
1917
+ * Show TUI toast
1918
+ *
1919
+ * Show a toast notification in the TUI
1920
+ */
1921
+ showToast(parameters, options) {
1922
+ const params = buildClientParams([parameters], [
1923
+ {
1924
+ args: [
1925
+ { in: "query", key: "directory" },
1926
+ { in: "body", key: "title" },
1927
+ { in: "body", key: "message" },
1928
+ { in: "body", key: "variant" },
1929
+ { in: "body", key: "duration" },
1930
+ ],
1931
+ },
1932
+ ]);
1933
+ return (options?.client ?? this.client).post({
1934
+ url: "/tui/show-toast",
1935
+ ...options,
1936
+ ...params,
1937
+ headers: {
1938
+ "Content-Type": "application/json",
1939
+ ...options?.headers,
1940
+ ...params.headers,
1941
+ },
1942
+ });
1943
+ }
1944
+ /**
1945
+ * Publish TUI event
1946
+ *
1947
+ * Publish a TUI event
1948
+ */
1949
+ publish(parameters, options) {
1950
+ const params = buildClientParams([parameters], [
1951
+ {
1952
+ args: [
1953
+ { in: "query", key: "directory" },
1954
+ { key: "body", map: "body" },
1955
+ ],
1956
+ },
1957
+ ]);
1958
+ return (options?.client ?? this.client).post({
1959
+ url: "/tui/publish",
1960
+ ...options,
1961
+ ...params,
1962
+ headers: {
1963
+ "Content-Type": "application/json",
1964
+ ...options?.headers,
1965
+ ...params.headers,
1966
+ },
1967
+ });
1968
+ }
1969
+ /**
1970
+ * Select session
1971
+ *
1972
+ * Navigate the TUI to display the specified session.
1973
+ */
1974
+ selectSession(parameters, options) {
1975
+ const params = buildClientParams([parameters], [
1976
+ {
1977
+ args: [
1978
+ { in: "query", key: "directory" },
1979
+ { in: "body", key: "sessionID" },
1980
+ ],
1981
+ },
1982
+ ]);
1983
+ return (options?.client ?? this.client).post({
1984
+ url: "/tui/select-session",
1985
+ ...options,
1986
+ ...params,
1987
+ headers: {
1988
+ "Content-Type": "application/json",
1989
+ ...options?.headers,
1990
+ ...params.headers,
1991
+ },
1992
+ });
1993
+ }
1994
+ _control;
1995
+ get control() {
1996
+ return (this._control ??= new Control({ client: this.client }));
1997
+ }
1998
+ }
1999
+ export class Instance extends HeyApiClient {
2000
+ /**
2001
+ * Dispose instance
2002
+ *
2003
+ * Clean up and dispose the current OpenCode instance, releasing all resources.
2004
+ */
2005
+ dispose(parameters, options) {
2006
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2007
+ return (options?.client ?? this.client).post({
2008
+ url: "/instance/dispose",
2009
+ ...options,
2010
+ ...params,
2011
+ });
2012
+ }
2013
+ }
2014
+ export class Path extends HeyApiClient {
2015
+ /**
2016
+ * Get paths
2017
+ *
2018
+ * Retrieve the current working directory and related path information for the OpenCode instance.
2019
+ */
2020
+ get(parameters, options) {
2021
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2022
+ return (options?.client ?? this.client).get({
2023
+ url: "/path",
2024
+ ...options,
2025
+ ...params,
2026
+ });
2027
+ }
2028
+ }
2029
+ export class Vcs extends HeyApiClient {
2030
+ /**
2031
+ * Get VCS info
2032
+ *
2033
+ * Retrieve version control system (VCS) information for the current project, such as git branch.
2034
+ */
2035
+ get(parameters, options) {
2036
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2037
+ return (options?.client ?? this.client).get({
2038
+ url: "/vcs",
2039
+ ...options,
2040
+ ...params,
2041
+ });
2042
+ }
2043
+ }
2044
+ export class Command extends HeyApiClient {
2045
+ /**
2046
+ * List commands
2047
+ *
2048
+ * Get a list of all available commands in the OpenCode system.
2049
+ */
2050
+ list(parameters, options) {
2051
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2052
+ return (options?.client ?? this.client).get({
2053
+ url: "/command",
2054
+ ...options,
2055
+ ...params,
2056
+ });
2057
+ }
2058
+ }
2059
+ export class App extends HeyApiClient {
2060
+ /**
2061
+ * Write log
2062
+ *
2063
+ * Write a log entry to the server logs with specified level and metadata.
2064
+ */
2065
+ log(parameters, options) {
2066
+ const params = buildClientParams([parameters], [
2067
+ {
2068
+ args: [
2069
+ { in: "query", key: "directory" },
2070
+ { in: "body", key: "service" },
2071
+ { in: "body", key: "level" },
2072
+ { in: "body", key: "message" },
2073
+ { in: "body", key: "extra" },
2074
+ ],
2075
+ },
2076
+ ]);
2077
+ return (options?.client ?? this.client).post({
2078
+ url: "/log",
2079
+ ...options,
2080
+ ...params,
2081
+ headers: {
2082
+ "Content-Type": "application/json",
2083
+ ...options?.headers,
2084
+ ...params.headers,
2085
+ },
2086
+ });
2087
+ }
2088
+ /**
2089
+ * List agents
2090
+ *
2091
+ * Get a list of all available AI agents in the OpenCode system.
2092
+ */
2093
+ agents(parameters, options) {
2094
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2095
+ return (options?.client ?? this.client).get({
2096
+ url: "/agent",
2097
+ ...options,
2098
+ ...params,
2099
+ });
2100
+ }
2101
+ /**
2102
+ * List skills
2103
+ *
2104
+ * Get a list of all available skills in the OpenCode system.
2105
+ */
2106
+ skills(parameters, options) {
2107
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2108
+ return (options?.client ?? this.client).get({
2109
+ url: "/skill",
2110
+ ...options,
2111
+ ...params,
2112
+ });
2113
+ }
2114
+ }
2115
+ export class Lsp extends HeyApiClient {
2116
+ /**
2117
+ * Get LSP status
2118
+ *
2119
+ * Get LSP server status
2120
+ */
2121
+ status(parameters, options) {
2122
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2123
+ return (options?.client ?? this.client).get({
2124
+ url: "/lsp",
2125
+ ...options,
2126
+ ...params,
2127
+ });
2128
+ }
2129
+ }
2130
+ export class Formatter extends HeyApiClient {
2131
+ /**
2132
+ * Get formatter status
2133
+ *
2134
+ * Get formatter status
2135
+ */
2136
+ status(parameters, options) {
2137
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2138
+ return (options?.client ?? this.client).get({
2139
+ url: "/formatter",
2140
+ ...options,
2141
+ ...params,
2142
+ });
2143
+ }
2144
+ }
2145
+ export class Event extends HeyApiClient {
2146
+ /**
2147
+ * Subscribe to events
2148
+ *
2149
+ * Get events
2150
+ */
2151
+ subscribe(parameters, options) {
2152
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "directory" }] }]);
2153
+ return (options?.client ?? this.client).sse.get({
2154
+ url: "/event",
2155
+ ...options,
2156
+ ...params,
2157
+ });
2158
+ }
2159
+ }
2160
+ export class OpencodeClient extends HeyApiClient {
2161
+ static __registry = new HeyApiRegistry();
2162
+ constructor(args) {
2163
+ super(args);
2164
+ OpencodeClient.__registry.set(this, args?.key);
2165
+ }
2166
+ _global;
2167
+ get global() {
2168
+ return (this._global ??= new Global({ client: this.client }));
2169
+ }
2170
+ _auth;
2171
+ get auth() {
2172
+ return (this._auth ??= new Auth({ client: this.client }));
2173
+ }
2174
+ _project;
2175
+ get project() {
2176
+ return (this._project ??= new Project({ client: this.client }));
2177
+ }
2178
+ _pty;
2179
+ get pty() {
2180
+ return (this._pty ??= new Pty({ client: this.client }));
2181
+ }
2182
+ _config;
2183
+ get config() {
2184
+ return (this._config ??= new Config2({ client: this.client }));
2185
+ }
2186
+ _tool;
2187
+ get tool() {
2188
+ return (this._tool ??= new Tool({ client: this.client }));
2189
+ }
2190
+ _worktree;
2191
+ get worktree() {
2192
+ return (this._worktree ??= new Worktree({ client: this.client }));
2193
+ }
2194
+ _experimental;
2195
+ get experimental() {
2196
+ return (this._experimental ??= new Experimental({ client: this.client }));
2197
+ }
2198
+ _session;
2199
+ get session() {
2200
+ return (this._session ??= new Session2({ client: this.client }));
2201
+ }
2202
+ _part;
2203
+ get part() {
2204
+ return (this._part ??= new Part({ client: this.client }));
2205
+ }
2206
+ _permission;
2207
+ get permission() {
2208
+ return (this._permission ??= new Permission({ client: this.client }));
2209
+ }
2210
+ _question;
2211
+ get question() {
2212
+ return (this._question ??= new Question({ client: this.client }));
2213
+ }
2214
+ _provider;
2215
+ get provider() {
2216
+ return (this._provider ??= new Provider({ client: this.client }));
2217
+ }
2218
+ _find;
2219
+ get find() {
2220
+ return (this._find ??= new Find({ client: this.client }));
2221
+ }
2222
+ _file;
2223
+ get file() {
2224
+ return (this._file ??= new File({ client: this.client }));
2225
+ }
2226
+ _mcp;
2227
+ get mcp() {
2228
+ return (this._mcp ??= new Mcp({ client: this.client }));
2229
+ }
2230
+ _tui;
2231
+ get tui() {
2232
+ return (this._tui ??= new Tui({ client: this.client }));
2233
+ }
2234
+ _instance;
2235
+ get instance() {
2236
+ return (this._instance ??= new Instance({ client: this.client }));
2237
+ }
2238
+ _path;
2239
+ get path() {
2240
+ return (this._path ??= new Path({ client: this.client }));
2241
+ }
2242
+ _vcs;
2243
+ get vcs() {
2244
+ return (this._vcs ??= new Vcs({ client: this.client }));
2245
+ }
2246
+ _command;
2247
+ get command() {
2248
+ return (this._command ??= new Command({ client: this.client }));
2249
+ }
2250
+ _app;
2251
+ get app() {
2252
+ return (this._app ??= new App({ client: this.client }));
2253
+ }
2254
+ _lsp;
2255
+ get lsp() {
2256
+ return (this._lsp ??= new Lsp({ client: this.client }));
2257
+ }
2258
+ _formatter;
2259
+ get formatter() {
2260
+ return (this._formatter ??= new Formatter({ client: this.client }));
2261
+ }
2262
+ _event;
2263
+ get event() {
2264
+ return (this._event ??= new Event({ client: this.client }));
2265
+ }
2266
+ }