@engineer-ai/sdk 1.2.3 → 1.2.4

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