@opencode-ai/sdk 1.15.12 → 1.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -132,80 +132,24 @@ export class App extends HeyApiClient {
132
132
  });
133
133
  }
134
134
  }
135
- export class Config extends HeyApiClient {
136
- /**
137
- * Get global configuration
138
- *
139
- * Retrieve the current global OpenCode configuration settings and preferences.
140
- */
141
- get(options) {
142
- return (options?.client ?? this.client).get({
143
- url: "/global/config",
144
- ...options,
145
- });
146
- }
135
+ export class ControlPlane extends HeyApiClient {
147
136
  /**
148
- * Update global configuration
137
+ * Move session
149
138
  *
150
- * Update global OpenCode configuration settings and preferences.
139
+ * Move a session to another project directory, optionally transferring local changes.
151
140
  */
152
- update(parameters, options) {
153
- const params = buildClientParams([parameters], [{ args: [{ key: "config", map: "body" }] }]);
154
- return (options?.client ?? this.client).patch({
155
- url: "/global/config",
156
- ...options,
157
- ...params,
158
- headers: {
159
- "Content-Type": "application/json",
160
- ...options?.headers,
161
- ...params.headers,
141
+ moveSession(parameters, options) {
142
+ const params = buildClientParams([parameters], [
143
+ {
144
+ args: [
145
+ { in: "body", key: "sessionID" },
146
+ { in: "body", key: "destination" },
147
+ { in: "body", key: "moveChanges" },
148
+ ],
162
149
  },
163
- });
164
- }
165
- }
166
- export class Global extends HeyApiClient {
167
- /**
168
- * Get health
169
- *
170
- * Get health information about the OpenCode server.
171
- */
172
- health(options) {
173
- return (options?.client ?? this.client).get({
174
- url: "/global/health",
175
- ...options,
176
- });
177
- }
178
- /**
179
- * Get global events
180
- *
181
- * Subscribe to global events from the OpenCode system using server-sent events.
182
- */
183
- event(options) {
184
- return (options?.client ?? this.client).sse.get({
185
- url: "/global/event",
186
- ...options,
187
- });
188
- }
189
- /**
190
- * Dispose instance
191
- *
192
- * Clean up and dispose all OpenCode instances, releasing all resources.
193
- */
194
- dispose(options) {
195
- return (options?.client ?? this.client).post({
196
- url: "/global/dispose",
197
- ...options,
198
- });
199
- }
200
- /**
201
- * Upgrade opencode
202
- *
203
- * Upgrade opencode to the specified version or latest if not specified.
204
- */
205
- upgrade(parameters, options) {
206
- const params = buildClientParams([parameters], [{ args: [{ in: "body", key: "target" }] }]);
150
+ ]);
207
151
  return (options?.client ?? this.client).post({
208
- url: "/global/upgrade",
152
+ url: "/experimental/control-plane/move-session",
209
153
  ...options,
210
154
  ...params,
211
155
  headers: {
@@ -215,18 +159,14 @@ export class Global extends HeyApiClient {
215
159
  },
216
160
  });
217
161
  }
218
- _config;
219
- get config() {
220
- return (this._config ??= new Config({ client: this.client }));
221
- }
222
162
  }
223
- export class Event extends HeyApiClient {
163
+ export class Console extends HeyApiClient {
224
164
  /**
225
- * Subscribe to events
165
+ * Get active Console provider metadata
226
166
  *
227
- * Get events
167
+ * Get the active Console org name and the set of provider IDs managed by that Console org.
228
168
  */
229
- subscribe(parameters, options) {
169
+ get(parameters, options) {
230
170
  const params = buildClientParams([parameters], [
231
171
  {
232
172
  args: [
@@ -235,20 +175,18 @@ export class Event extends HeyApiClient {
235
175
  ],
236
176
  },
237
177
  ]);
238
- return (options?.client ?? this.client).sse.get({
239
- url: "/event",
178
+ return (options?.client ?? this.client).get({
179
+ url: "/experimental/console",
240
180
  ...options,
241
181
  ...params,
242
182
  });
243
183
  }
244
- }
245
- export class Config2 extends HeyApiClient {
246
184
  /**
247
- * Get configuration
185
+ * List switchable Console orgs
248
186
  *
249
- * Retrieve the current OpenCode configuration settings and preferences.
187
+ * Get the available Console orgs across logged-in accounts, including the current active org.
250
188
  */
251
- get(parameters, options) {
189
+ listOrgs(parameters, options) {
252
190
  const params = buildClientParams([parameters], [
253
191
  {
254
192
  args: [
@@ -258,28 +196,29 @@ export class Config2 extends HeyApiClient {
258
196
  },
259
197
  ]);
260
198
  return (options?.client ?? this.client).get({
261
- url: "/config",
199
+ url: "/experimental/console/orgs",
262
200
  ...options,
263
201
  ...params,
264
202
  });
265
203
  }
266
204
  /**
267
- * Update configuration
205
+ * Switch active Console org
268
206
  *
269
- * Update OpenCode configuration settings and preferences.
207
+ * Persist a new active Console account/org selection for the current local OpenCode state.
270
208
  */
271
- update(parameters, options) {
209
+ switchOrg(parameters, options) {
272
210
  const params = buildClientParams([parameters], [
273
211
  {
274
212
  args: [
275
213
  { in: "query", key: "directory" },
276
214
  { in: "query", key: "workspace" },
277
- { key: "config", map: "body" },
215
+ { in: "body", key: "accountID" },
216
+ { in: "body", key: "orgID" },
278
217
  ],
279
218
  },
280
219
  ]);
281
- return (options?.client ?? this.client).patch({
282
- url: "/config",
220
+ return (options?.client ?? this.client).post({
221
+ url: "/experimental/console/switch",
283
222
  ...options,
284
223
  ...params,
285
224
  headers: {
@@ -289,34 +228,42 @@ export class Config2 extends HeyApiClient {
289
228
  },
290
229
  });
291
230
  }
231
+ }
232
+ export class Session extends HeyApiClient {
292
233
  /**
293
- * List config providers
234
+ * List sessions
294
235
  *
295
- * Get a list of all configured AI providers and their default models.
236
+ * Get a list of all OpenCode sessions across projects, sorted by most recently updated. Archived sessions are excluded by default.
296
237
  */
297
- providers(parameters, options) {
238
+ list(parameters, options) {
298
239
  const params = buildClientParams([parameters], [
299
240
  {
300
241
  args: [
301
242
  { in: "query", key: "directory" },
302
243
  { in: "query", key: "workspace" },
244
+ { in: "query", key: "roots" },
245
+ { in: "query", key: "start" },
246
+ { in: "query", key: "cursor" },
247
+ { in: "query", key: "search" },
248
+ { in: "query", key: "limit" },
249
+ { in: "query", key: "archived" },
303
250
  ],
304
251
  },
305
252
  ]);
306
253
  return (options?.client ?? this.client).get({
307
- url: "/config/providers",
254
+ url: "/experimental/session",
308
255
  ...options,
309
256
  ...params,
310
257
  });
311
258
  }
312
259
  }
313
- export class Console extends HeyApiClient {
260
+ export class Resource extends HeyApiClient {
314
261
  /**
315
- * Get active Console provider metadata
262
+ * Get MCP resources
316
263
  *
317
- * Get the active Console org name and the set of provider IDs managed by that Console org.
264
+ * Get all available MCP resources from connected servers. Optionally filter by name.
318
265
  */
319
- get(parameters, options) {
266
+ list(parameters, options) {
320
267
  const params = buildClientParams([parameters], [
321
268
  {
322
269
  args: [
@@ -326,49 +273,68 @@ export class Console extends HeyApiClient {
326
273
  },
327
274
  ]);
328
275
  return (options?.client ?? this.client).get({
329
- url: "/experimental/console",
276
+ url: "/experimental/resource",
330
277
  ...options,
331
278
  ...params,
332
279
  });
333
280
  }
281
+ }
282
+ export class ProjectCopy extends HeyApiClient {
334
283
  /**
335
- * List switchable Console orgs
284
+ * Remove project copy
336
285
  *
337
- * Get the available Console orgs across logged-in accounts, including the current active org.
286
+ * Remove a local physical copy of a project using the selected strategy.
338
287
  */
339
- listOrgs(parameters, options) {
288
+ remove(parameters, options) {
340
289
  const params = buildClientParams([parameters], [
341
290
  {
342
291
  args: [
343
- { in: "query", key: "directory" },
292
+ { in: "path", key: "projectID" },
293
+ {
294
+ in: "query",
295
+ key: "query_directory",
296
+ map: "directory",
297
+ },
344
298
  { in: "query", key: "workspace" },
299
+ {
300
+ in: "body",
301
+ key: "body_directory",
302
+ map: "directory",
303
+ },
345
304
  ],
346
305
  },
347
306
  ]);
348
- return (options?.client ?? this.client).get({
349
- url: "/experimental/console/orgs",
307
+ return (options?.client ?? this.client).delete({
308
+ url: "/experimental/project/{projectID}/copy",
350
309
  ...options,
351
310
  ...params,
311
+ headers: {
312
+ "Content-Type": "application/json",
313
+ ...options?.headers,
314
+ ...params.headers,
315
+ },
352
316
  });
353
317
  }
354
318
  /**
355
- * Switch active Console org
319
+ * Create project copy
356
320
  *
357
- * Persist a new active Console account/org selection for the current local OpenCode state.
321
+ * Create a local physical copy of a project using the selected strategy.
358
322
  */
359
- switchOrg(parameters, options) {
323
+ create(parameters, options) {
360
324
  const params = buildClientParams([parameters], [
361
325
  {
362
326
  args: [
363
- { in: "query", key: "directory" },
327
+ { in: "path", key: "projectID" },
364
328
  { in: "query", key: "workspace" },
365
- { in: "body", key: "accountID" },
366
- { in: "body", key: "orgID" },
329
+ { in: "body", key: "strategy" },
330
+ { in: "body", key: "directory" },
331
+ { in: "body", key: "name" },
332
+ { in: "body", key: "context" },
367
333
  ],
368
334
  },
369
335
  ]);
370
336
  return (options?.client ?? this.client).post({
371
- url: "/experimental/console/switch",
337
+ url: "/experimental/project/{projectID}/copy",
372
338
  ...options,
373
339
  ...params,
374
340
  headers: {
@@ -378,52 +344,23 @@ export class Console extends HeyApiClient {
378
344
  },
379
345
  });
380
346
  }
381
- }
382
- export class Session extends HeyApiClient {
383
- /**
384
- * List sessions
385
- *
386
- * Get a list of all OpenCode sessions across projects, sorted by most recently updated. Archived sessions are excluded by default.
387
- */
388
- list(parameters, options) {
389
- const params = buildClientParams([parameters], [
390
- {
391
- args: [
392
- { in: "query", key: "directory" },
393
- { in: "query", key: "workspace" },
394
- { in: "query", key: "roots" },
395
- { in: "query", key: "start" },
396
- { in: "query", key: "cursor" },
397
- { in: "query", key: "search" },
398
- { in: "query", key: "limit" },
399
- { in: "query", key: "archived" },
400
- ],
401
- },
402
- ]);
403
- return (options?.client ?? this.client).get({
404
- url: "/experimental/session",
405
- ...options,
406
- ...params,
407
- });
408
- }
409
- }
410
- export class Resource extends HeyApiClient {
411
347
  /**
412
- * Get MCP resources
348
+ * Refresh project copies
413
349
  *
414
- * Get all available MCP resources from connected servers. Optionally filter by name.
350
+ * Discover local project copies using one or all configured strategies.
415
351
  */
416
- list(parameters, options) {
352
+ refresh(parameters, options) {
417
353
  const params = buildClientParams([parameters], [
418
354
  {
419
355
  args: [
356
+ { in: "path", key: "projectID" },
420
357
  { in: "query", key: "directory" },
421
358
  { in: "query", key: "workspace" },
422
359
  ],
423
360
  },
424
361
  ]);
425
- return (options?.client ?? this.client).get({
426
- url: "/experimental/resource",
362
+ return (options?.client ?? this.client).post({
363
+ url: "/experimental/project/{projectID}/copy/refresh",
427
364
  ...options,
428
365
  ...params,
429
366
  });
@@ -596,6 +533,10 @@ export class Workspace extends HeyApiClient {
596
533
  }
597
534
  }
598
535
  export class Experimental extends HeyApiClient {
536
+ _controlPlane;
537
+ get controlPlane() {
538
+ return (this._controlPlane ??= new ControlPlane({ client: this.client }));
539
+ }
599
540
  _console;
600
541
  get console() {
601
542
  return (this._console ??= new Console({ client: this.client }));
@@ -608,54 +549,236 @@ export class Experimental extends HeyApiClient {
608
549
  get resource() {
609
550
  return (this._resource ??= new Resource({ client: this.client }));
610
551
  }
552
+ _projectCopy;
553
+ get projectCopy() {
554
+ return (this._projectCopy ??= new ProjectCopy({ client: this.client }));
555
+ }
611
556
  _workspace;
612
557
  get workspace() {
613
558
  return (this._workspace ??= new Workspace({ client: this.client }));
614
559
  }
615
560
  }
616
- export class Tool extends HeyApiClient {
561
+ export class Config extends HeyApiClient {
617
562
  /**
618
- * List tools
563
+ * Get global configuration
619
564
  *
620
- * Get a list of available tools with their JSON schema parameters for a specific provider and model combination.
565
+ * Retrieve the current global OpenCode configuration settings and preferences.
621
566
  */
622
- list(parameters, options) {
623
- const params = buildClientParams([parameters], [
624
- {
625
- args: [
626
- { in: "query", key: "directory" },
627
- { in: "query", key: "workspace" },
628
- { in: "query", key: "provider" },
629
- { in: "query", key: "model" },
630
- ],
631
- },
632
- ]);
567
+ get(options) {
633
568
  return (options?.client ?? this.client).get({
634
- url: "/experimental/tool",
569
+ url: "/global/config",
635
570
  ...options,
636
- ...params,
637
571
  });
638
572
  }
639
573
  /**
640
- * List tool IDs
574
+ * Update global configuration
641
575
  *
642
- * Get a list of all available tool IDs, including both built-in tools and dynamically registered tools.
576
+ * Update global OpenCode configuration settings and preferences.
643
577
  */
644
- ids(parameters, options) {
645
- const params = buildClientParams([parameters], [
646
- {
647
- args: [
648
- { in: "query", key: "directory" },
649
- { in: "query", key: "workspace" },
650
- ],
651
- },
652
- ]);
653
- return (options?.client ?? this.client).get({
654
- url: "/experimental/tool/ids",
578
+ update(parameters, options) {
579
+ const params = buildClientParams([parameters], [{ args: [{ key: "config", map: "body" }] }]);
580
+ return (options?.client ?? this.client).patch({
581
+ url: "/global/config",
655
582
  ...options,
656
583
  ...params,
657
- });
658
- }
584
+ headers: {
585
+ "Content-Type": "application/json",
586
+ ...options?.headers,
587
+ ...params.headers,
588
+ },
589
+ });
590
+ }
591
+ }
592
+ export class Global extends HeyApiClient {
593
+ /**
594
+ * Get health
595
+ *
596
+ * Get health information about the OpenCode server.
597
+ */
598
+ health(options) {
599
+ return (options?.client ?? this.client).get({
600
+ url: "/global/health",
601
+ ...options,
602
+ });
603
+ }
604
+ /**
605
+ * Get global events
606
+ *
607
+ * Subscribe to global events from the OpenCode system using server-sent events.
608
+ */
609
+ event(options) {
610
+ return (options?.client ?? this.client).sse.get({
611
+ url: "/global/event",
612
+ ...options,
613
+ });
614
+ }
615
+ /**
616
+ * Dispose instance
617
+ *
618
+ * Clean up and dispose all OpenCode instances, releasing all resources.
619
+ */
620
+ dispose(options) {
621
+ return (options?.client ?? this.client).post({
622
+ url: "/global/dispose",
623
+ ...options,
624
+ });
625
+ }
626
+ /**
627
+ * Upgrade opencode
628
+ *
629
+ * Upgrade opencode to the specified version or latest if not specified.
630
+ */
631
+ upgrade(parameters, options) {
632
+ const params = buildClientParams([parameters], [{ args: [{ in: "body", key: "target" }] }]);
633
+ return (options?.client ?? this.client).post({
634
+ url: "/global/upgrade",
635
+ ...options,
636
+ ...params,
637
+ headers: {
638
+ "Content-Type": "application/json",
639
+ ...options?.headers,
640
+ ...params.headers,
641
+ },
642
+ });
643
+ }
644
+ _config;
645
+ get config() {
646
+ return (this._config ??= new Config({ client: this.client }));
647
+ }
648
+ }
649
+ export class Event extends HeyApiClient {
650
+ /**
651
+ * Subscribe to events
652
+ *
653
+ * Get events
654
+ */
655
+ subscribe(parameters, options) {
656
+ const params = buildClientParams([parameters], [
657
+ {
658
+ args: [
659
+ { in: "query", key: "directory" },
660
+ { in: "query", key: "workspace" },
661
+ ],
662
+ },
663
+ ]);
664
+ return (options?.client ?? this.client).sse.get({
665
+ url: "/event",
666
+ ...options,
667
+ ...params,
668
+ });
669
+ }
670
+ }
671
+ export class Config2 extends HeyApiClient {
672
+ /**
673
+ * Get configuration
674
+ *
675
+ * Retrieve the current OpenCode configuration settings and preferences.
676
+ */
677
+ get(parameters, options) {
678
+ const params = buildClientParams([parameters], [
679
+ {
680
+ args: [
681
+ { in: "query", key: "directory" },
682
+ { in: "query", key: "workspace" },
683
+ ],
684
+ },
685
+ ]);
686
+ return (options?.client ?? this.client).get({
687
+ url: "/config",
688
+ ...options,
689
+ ...params,
690
+ });
691
+ }
692
+ /**
693
+ * Update configuration
694
+ *
695
+ * Update OpenCode configuration settings and preferences.
696
+ */
697
+ update(parameters, options) {
698
+ const params = buildClientParams([parameters], [
699
+ {
700
+ args: [
701
+ { in: "query", key: "directory" },
702
+ { in: "query", key: "workspace" },
703
+ { key: "config", map: "body" },
704
+ ],
705
+ },
706
+ ]);
707
+ return (options?.client ?? this.client).patch({
708
+ url: "/config",
709
+ ...options,
710
+ ...params,
711
+ headers: {
712
+ "Content-Type": "application/json",
713
+ ...options?.headers,
714
+ ...params.headers,
715
+ },
716
+ });
717
+ }
718
+ /**
719
+ * List config providers
720
+ *
721
+ * Get a list of all configured AI providers and their default models.
722
+ */
723
+ providers(parameters, options) {
724
+ const params = buildClientParams([parameters], [
725
+ {
726
+ args: [
727
+ { in: "query", key: "directory" },
728
+ { in: "query", key: "workspace" },
729
+ ],
730
+ },
731
+ ]);
732
+ return (options?.client ?? this.client).get({
733
+ url: "/config/providers",
734
+ ...options,
735
+ ...params,
736
+ });
737
+ }
738
+ }
739
+ export class Tool extends HeyApiClient {
740
+ /**
741
+ * List tools
742
+ *
743
+ * Get a list of available tools with their JSON schema parameters for a specific provider and model combination.
744
+ */
745
+ list(parameters, options) {
746
+ const params = buildClientParams([parameters], [
747
+ {
748
+ args: [
749
+ { in: "query", key: "directory" },
750
+ { in: "query", key: "workspace" },
751
+ { in: "query", key: "provider" },
752
+ { in: "query", key: "model" },
753
+ ],
754
+ },
755
+ ]);
756
+ return (options?.client ?? this.client).get({
757
+ url: "/experimental/tool",
758
+ ...options,
759
+ ...params,
760
+ });
761
+ }
762
+ /**
763
+ * List tool IDs
764
+ *
765
+ * Get a list of all available tool IDs, including both built-in tools and dynamically registered tools.
766
+ */
767
+ ids(parameters, options) {
768
+ const params = buildClientParams([parameters], [
769
+ {
770
+ args: [
771
+ { in: "query", key: "directory" },
772
+ { in: "query", key: "workspace" },
773
+ ],
774
+ },
775
+ ]);
776
+ return (options?.client ?? this.client).get({
777
+ url: "/experimental/tool/ids",
778
+ ...options,
779
+ ...params,
780
+ });
781
+ }
659
782
  }
660
783
  export class Worktree extends HeyApiClient {
661
784
  /**
@@ -1388,6 +1511,27 @@ export class Project extends HeyApiClient {
1388
1511
  },
1389
1512
  });
1390
1513
  }
1514
+ /**
1515
+ * List project directories
1516
+ *
1517
+ * List known local absolute directories for a project.
1518
+ */
1519
+ directories(parameters, options) {
1520
+ const params = buildClientParams([parameters], [
1521
+ {
1522
+ args: [
1523
+ { in: "path", key: "projectID" },
1524
+ { in: "query", key: "directory" },
1525
+ { in: "query", key: "workspace" },
1526
+ ],
1527
+ },
1528
+ ]);
1529
+ return (options?.client ?? this.client).get({
1530
+ url: "/project/{projectID}/directories",
1531
+ ...options,
1532
+ ...params,
1533
+ });
1534
+ }
1391
1535
  }
1392
1536
  export class Pty extends HeyApiClient {
1393
1537
  /**
@@ -1871,6 +2015,7 @@ export class Session2 extends HeyApiClient {
1871
2015
  { in: "body", key: "title" },
1872
2016
  { in: "body", key: "agent" },
1873
2017
  { in: "body", key: "model" },
2018
+ { in: "body", key: "metadata" },
1874
2019
  { in: "body", key: "permission" },
1875
2020
  { in: "body", key: "workspaceID" },
1876
2021
  ],
@@ -1962,6 +2107,7 @@ export class Session2 extends HeyApiClient {
1962
2107
  { in: "query", key: "directory" },
1963
2108
  { in: "query", key: "workspace" },
1964
2109
  { in: "body", key: "title" },
2110
+ { in: "body", key: "metadata" },
1965
2111
  { in: "body", key: "permission" },
1966
2112
  { in: "body", key: "time" },
1967
2113
  ],
@@ -2605,53 +2751,44 @@ export class Sync extends HeyApiClient {
2605
2751
  return (this._history ??= new History({ client: this.client }));
2606
2752
  }
2607
2753
  }
2608
- export class Session3 extends HeyApiClient {
2754
+ export class Control extends HeyApiClient {
2609
2755
  /**
2610
- * List v2 sessions
2756
+ * Get next TUI request
2611
2757
  *
2612
- * Retrieve sessions in the requested order. Items keep that order across pages; use cursor.next or cursor.previous to move through the ordered list.
2758
+ * Retrieve the next TUI request from the queue for processing.
2613
2759
  */
2614
- list(parameters, options) {
2760
+ next(parameters, options) {
2615
2761
  const params = buildClientParams([parameters], [
2616
2762
  {
2617
2763
  args: [
2618
2764
  { in: "query", key: "directory" },
2619
2765
  { in: "query", key: "workspace" },
2620
- { in: "query", key: "limit" },
2621
- { in: "query", key: "order" },
2622
- { in: "query", key: "path" },
2623
- { in: "query", key: "roots" },
2624
- { in: "query", key: "start" },
2625
- { in: "query", key: "search" },
2626
- { in: "query", key: "cursor" },
2627
2766
  ],
2628
2767
  },
2629
2768
  ]);
2630
2769
  return (options?.client ?? this.client).get({
2631
- url: "/api/session",
2770
+ url: "/tui/control/next",
2632
2771
  ...options,
2633
2772
  ...params,
2634
2773
  });
2635
2774
  }
2636
2775
  /**
2637
- * Send v2 message
2776
+ * Submit TUI response
2638
2777
  *
2639
- * Create a v2 session message and queue it for the agent loop.
2778
+ * Submit a response to the TUI request queue to complete a pending request.
2640
2779
  */
2641
- prompt(parameters, options) {
2780
+ response(parameters, options) {
2642
2781
  const params = buildClientParams([parameters], [
2643
2782
  {
2644
2783
  args: [
2645
- { in: "path", key: "sessionID" },
2646
2784
  { in: "query", key: "directory" },
2647
2785
  { in: "query", key: "workspace" },
2648
- { in: "body", key: "prompt" },
2649
- { in: "body", key: "delivery" },
2786
+ { key: "body", map: "body" },
2650
2787
  ],
2651
2788
  },
2652
2789
  ]);
2653
2790
  return (options?.client ?? this.client).post({
2654
- url: "/api/session/{sessionID}/prompt",
2791
+ url: "/tui/control/response",
2655
2792
  ...options,
2656
2793
  ...params,
2657
2794
  headers: {
@@ -2661,224 +2798,25 @@ export class Session3 extends HeyApiClient {
2661
2798
  },
2662
2799
  });
2663
2800
  }
2801
+ }
2802
+ export class Tui extends HeyApiClient {
2664
2803
  /**
2665
- * Compact v2 session
2804
+ * Append TUI prompt
2666
2805
  *
2667
- * Compact a v2 session conversation.
2806
+ * Append prompt to the TUI.
2668
2807
  */
2669
- compact(parameters, options) {
2808
+ appendPrompt(parameters, options) {
2670
2809
  const params = buildClientParams([parameters], [
2671
2810
  {
2672
2811
  args: [
2673
- { in: "path", key: "sessionID" },
2674
2812
  { in: "query", key: "directory" },
2675
2813
  { in: "query", key: "workspace" },
2814
+ { in: "body", key: "text" },
2676
2815
  ],
2677
2816
  },
2678
2817
  ]);
2679
2818
  return (options?.client ?? this.client).post({
2680
- url: "/api/session/{sessionID}/compact",
2681
- ...options,
2682
- ...params,
2683
- });
2684
- }
2685
- /**
2686
- * Wait for v2 session
2687
- *
2688
- * Wait for a v2 session agent loop to become idle.
2689
- */
2690
- wait(parameters, options) {
2691
- const params = buildClientParams([parameters], [
2692
- {
2693
- args: [
2694
- { in: "path", key: "sessionID" },
2695
- { in: "query", key: "directory" },
2696
- { in: "query", key: "workspace" },
2697
- ],
2698
- },
2699
- ]);
2700
- return (options?.client ?? this.client).post({
2701
- url: "/api/session/{sessionID}/wait",
2702
- ...options,
2703
- ...params,
2704
- });
2705
- }
2706
- /**
2707
- * Get v2 session context
2708
- *
2709
- * Retrieve the active context messages for a v2 session (all messages after the last compaction).
2710
- */
2711
- context(parameters, options) {
2712
- const params = buildClientParams([parameters], [
2713
- {
2714
- args: [
2715
- { in: "path", key: "sessionID" },
2716
- { in: "query", key: "directory" },
2717
- { in: "query", key: "workspace" },
2718
- ],
2719
- },
2720
- ]);
2721
- return (options?.client ?? this.client).get({
2722
- url: "/api/session/{sessionID}/context",
2723
- ...options,
2724
- ...params,
2725
- });
2726
- }
2727
- /**
2728
- * Get v2 session messages
2729
- *
2730
- * Retrieve projected v2 messages for a session. Items keep the requested order across pages; use cursor.next or cursor.previous to move through the ordered timeline.
2731
- */
2732
- messages(parameters, options) {
2733
- const params = buildClientParams([parameters], [
2734
- {
2735
- args: [
2736
- { in: "path", key: "sessionID" },
2737
- { in: "query", key: "directory" },
2738
- { in: "query", key: "workspace" },
2739
- { in: "query", key: "limit" },
2740
- { in: "query", key: "order" },
2741
- { in: "query", key: "cursor" },
2742
- ],
2743
- },
2744
- ]);
2745
- return (options?.client ?? this.client).get({
2746
- url: "/api/session/{sessionID}/message",
2747
- ...options,
2748
- ...params,
2749
- });
2750
- }
2751
- }
2752
- export class Model extends HeyApiClient {
2753
- /**
2754
- * List v2 models
2755
- *
2756
- * Retrieve available v2 models ordered by release date.
2757
- */
2758
- list(parameters, options) {
2759
- const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
2760
- return (options?.client ?? this.client).get({
2761
- url: "/api/model",
2762
- ...options,
2763
- ...params,
2764
- });
2765
- }
2766
- }
2767
- export class Provider2 extends HeyApiClient {
2768
- /**
2769
- * List v2 providers
2770
- *
2771
- * Retrieve active v2 AI providers so clients can show provider availability and configuration.
2772
- */
2773
- list(parameters, options) {
2774
- const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
2775
- return (options?.client ?? this.client).get({
2776
- url: "/api/provider",
2777
- ...options,
2778
- ...params,
2779
- });
2780
- }
2781
- /**
2782
- * Get v2 provider
2783
- *
2784
- * Retrieve a single v2 AI provider so clients can inspect its availability and endpoint settings.
2785
- */
2786
- get(parameters, options) {
2787
- const params = buildClientParams([parameters], [
2788
- {
2789
- args: [
2790
- { in: "path", key: "providerID" },
2791
- { in: "query", key: "location" },
2792
- ],
2793
- },
2794
- ]);
2795
- return (options?.client ?? this.client).get({
2796
- url: "/api/provider/{providerID}",
2797
- ...options,
2798
- ...params,
2799
- });
2800
- }
2801
- }
2802
- export class V2 extends HeyApiClient {
2803
- _session;
2804
- get session() {
2805
- return (this._session ??= new Session3({ client: this.client }));
2806
- }
2807
- _model;
2808
- get model() {
2809
- return (this._model ??= new Model({ client: this.client }));
2810
- }
2811
- _provider;
2812
- get provider() {
2813
- return (this._provider ??= new Provider2({ client: this.client }));
2814
- }
2815
- }
2816
- export class Control extends HeyApiClient {
2817
- /**
2818
- * Get next TUI request
2819
- *
2820
- * Retrieve the next TUI request from the queue for processing.
2821
- */
2822
- next(parameters, options) {
2823
- const params = buildClientParams([parameters], [
2824
- {
2825
- args: [
2826
- { in: "query", key: "directory" },
2827
- { in: "query", key: "workspace" },
2828
- ],
2829
- },
2830
- ]);
2831
- return (options?.client ?? this.client).get({
2832
- url: "/tui/control/next",
2833
- ...options,
2834
- ...params,
2835
- });
2836
- }
2837
- /**
2838
- * Submit TUI response
2839
- *
2840
- * Submit a response to the TUI request queue to complete a pending request.
2841
- */
2842
- response(parameters, options) {
2843
- const params = buildClientParams([parameters], [
2844
- {
2845
- args: [
2846
- { in: "query", key: "directory" },
2847
- { in: "query", key: "workspace" },
2848
- { key: "body", map: "body" },
2849
- ],
2850
- },
2851
- ]);
2852
- return (options?.client ?? this.client).post({
2853
- url: "/tui/control/response",
2854
- ...options,
2855
- ...params,
2856
- headers: {
2857
- "Content-Type": "application/json",
2858
- ...options?.headers,
2859
- ...params.headers,
2860
- },
2861
- });
2862
- }
2863
- }
2864
- export class Tui extends HeyApiClient {
2865
- /**
2866
- * Append TUI prompt
2867
- *
2868
- * Append prompt to the TUI.
2869
- */
2870
- appendPrompt(parameters, options) {
2871
- const params = buildClientParams([parameters], [
2872
- {
2873
- args: [
2874
- { in: "query", key: "directory" },
2875
- { in: "query", key: "workspace" },
2876
- { in: "body", key: "text" },
2877
- ],
2878
- },
2879
- ]);
2880
- return (options?.client ?? this.client).post({
2881
- url: "/tui/append-prompt",
2819
+ url: "/tui/append-prompt",
2882
2820
  ...options,
2883
2821
  ...params,
2884
2822
  headers: {
@@ -3120,39 +3058,541 @@ export class Tui extends HeyApiClient {
3120
3058
  return (this._control ??= new Control({ client: this.client }));
3121
3059
  }
3122
3060
  }
3123
- export class OpencodeClient extends HeyApiClient {
3124
- static __registry = new HeyApiRegistry();
3125
- constructor(args) {
3126
- super(args);
3127
- OpencodeClient.__registry.set(this, args?.key);
3128
- }
3129
- _auth;
3130
- get auth() {
3131
- return (this._auth ??= new Auth({ client: this.client }));
3132
- }
3133
- _app;
3134
- get app() {
3135
- return (this._app ??= new App({ client: this.client }));
3136
- }
3137
- _global;
3138
- get global() {
3139
- return (this._global ??= new Global({ client: this.client }));
3140
- }
3141
- _event;
3142
- get event() {
3143
- return (this._event ??= new Event({ client: this.client }));
3061
+ export class Health extends HeyApiClient {
3062
+ /**
3063
+ * Check v2 server health
3064
+ *
3065
+ * Check whether the v2 API server is ready to accept requests.
3066
+ */
3067
+ get(options) {
3068
+ return (options?.client ?? this.client).get({
3069
+ url: "/api/health",
3070
+ ...options,
3071
+ });
3144
3072
  }
3145
- _config;
3146
- get config() {
3147
- return (this._config ??= new Config2({ client: this.client }));
3073
+ }
3074
+ export class Agent extends HeyApiClient {
3075
+ /**
3076
+ * List v2 agents
3077
+ *
3078
+ * Retrieve currently registered v2 agents.
3079
+ */
3080
+ list(parameters, options) {
3081
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3082
+ return (options?.client ?? this.client).get({
3083
+ url: "/api/agent",
3084
+ ...options,
3085
+ ...params,
3086
+ });
3148
3087
  }
3149
- _experimental;
3150
- get experimental() {
3151
- return (this._experimental ??= new Experimental({ client: this.client }));
3088
+ }
3089
+ export class Permission2 extends HeyApiClient {
3090
+ /**
3091
+ * List session permission requests
3092
+ *
3093
+ * Retrieve pending permission requests owned by a session.
3094
+ */
3095
+ list(parameters, options) {
3096
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "sessionID" }] }]);
3097
+ return (options?.client ?? this.client).get({
3098
+ url: "/api/session/{sessionID}/permission/request",
3099
+ ...options,
3100
+ ...params,
3101
+ });
3152
3102
  }
3153
- _tool;
3154
- get tool() {
3155
- return (this._tool ??= new Tool({ client: this.client }));
3103
+ /**
3104
+ * Reply to pending permission request
3105
+ *
3106
+ * Respond to a pending permission request owned by a session.
3107
+ */
3108
+ reply(parameters, options) {
3109
+ const params = buildClientParams([parameters], [
3110
+ {
3111
+ args: [
3112
+ { in: "path", key: "sessionID" },
3113
+ { in: "path", key: "requestID" },
3114
+ { in: "body", key: "reply" },
3115
+ { in: "body", key: "message" },
3116
+ ],
3117
+ },
3118
+ ]);
3119
+ return (options?.client ?? this.client).post({
3120
+ url: "/api/session/{sessionID}/permission/request/{requestID}/reply",
3121
+ ...options,
3122
+ ...params,
3123
+ headers: {
3124
+ "Content-Type": "application/json",
3125
+ ...options?.headers,
3126
+ ...params.headers,
3127
+ },
3128
+ });
3129
+ }
3130
+ }
3131
+ export class Question2 extends HeyApiClient {
3132
+ /**
3133
+ * Reply to pending question request
3134
+ *
3135
+ * Answer a pending question request owned by a session.
3136
+ */
3137
+ reply(parameters, options) {
3138
+ const params = buildClientParams([parameters], [
3139
+ {
3140
+ args: [
3141
+ { in: "path", key: "sessionID" },
3142
+ { in: "path", key: "requestID" },
3143
+ { key: "questionV2Reply", map: "body" },
3144
+ ],
3145
+ },
3146
+ ]);
3147
+ return (options?.client ?? this.client).post({
3148
+ url: "/api/session/{sessionID}/question/request/{requestID}/reply",
3149
+ ...options,
3150
+ ...params,
3151
+ headers: {
3152
+ "Content-Type": "application/json",
3153
+ ...options?.headers,
3154
+ ...params.headers,
3155
+ },
3156
+ });
3157
+ }
3158
+ /**
3159
+ * Reject pending question request
3160
+ *
3161
+ * Reject a pending question request owned by a session.
3162
+ */
3163
+ reject(parameters, options) {
3164
+ const params = buildClientParams([parameters], [
3165
+ {
3166
+ args: [
3167
+ { in: "path", key: "sessionID" },
3168
+ { in: "path", key: "requestID" },
3169
+ ],
3170
+ },
3171
+ ]);
3172
+ return (options?.client ?? this.client).post({
3173
+ url: "/api/session/{sessionID}/question/request/{requestID}/reject",
3174
+ ...options,
3175
+ ...params,
3176
+ });
3177
+ }
3178
+ }
3179
+ export class Session3 extends HeyApiClient {
3180
+ /**
3181
+ * List v2 sessions
3182
+ *
3183
+ * Retrieve sessions in the requested order. Items keep that order across pages; use cursor.next or cursor.previous to move through the ordered list.
3184
+ */
3185
+ list(parameters, options) {
3186
+ const params = buildClientParams([parameters], [
3187
+ {
3188
+ args: [
3189
+ { in: "query", key: "workspace" },
3190
+ { in: "query", key: "limit" },
3191
+ { in: "query", key: "order" },
3192
+ { in: "query", key: "search" },
3193
+ { in: "query", key: "directory" },
3194
+ { in: "query", key: "project" },
3195
+ { in: "query", key: "subpath" },
3196
+ { in: "query", key: "cursor" },
3197
+ ],
3198
+ },
3199
+ ]);
3200
+ return (options?.client ?? this.client).get({
3201
+ url: "/api/session",
3202
+ ...options,
3203
+ ...params,
3204
+ });
3205
+ }
3206
+ /**
3207
+ * Send v2 message
3208
+ *
3209
+ * Durably admit one v2 session input and schedule agent-loop execution unless resume is false.
3210
+ */
3211
+ prompt(parameters, options) {
3212
+ const params = buildClientParams([parameters], [
3213
+ {
3214
+ args: [
3215
+ { in: "path", key: "sessionID" },
3216
+ { in: "body", key: "id" },
3217
+ { in: "body", key: "prompt" },
3218
+ { in: "body", key: "delivery" },
3219
+ { in: "body", key: "resume" },
3220
+ ],
3221
+ },
3222
+ ]);
3223
+ return (options?.client ?? this.client).post({
3224
+ url: "/api/session/{sessionID}/prompt",
3225
+ ...options,
3226
+ ...params,
3227
+ headers: {
3228
+ "Content-Type": "application/json",
3229
+ ...options?.headers,
3230
+ ...params.headers,
3231
+ },
3232
+ });
3233
+ }
3234
+ /**
3235
+ * Compact v2 session
3236
+ *
3237
+ * Compact a v2 session conversation.
3238
+ */
3239
+ compact(parameters, options) {
3240
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "sessionID" }] }]);
3241
+ return (options?.client ?? this.client).post({
3242
+ url: "/api/session/{sessionID}/compact",
3243
+ ...options,
3244
+ ...params,
3245
+ });
3246
+ }
3247
+ /**
3248
+ * Wait for v2 session
3249
+ *
3250
+ * Wait for a v2 session agent loop to become idle.
3251
+ */
3252
+ wait(parameters, options) {
3253
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "sessionID" }] }]);
3254
+ return (options?.client ?? this.client).post({
3255
+ url: "/api/session/{sessionID}/wait",
3256
+ ...options,
3257
+ ...params,
3258
+ });
3259
+ }
3260
+ /**
3261
+ * Get v2 session context
3262
+ *
3263
+ * Retrieve the active context messages for a v2 session (all messages after the last compaction).
3264
+ */
3265
+ context(parameters, options) {
3266
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "sessionID" }] }]);
3267
+ return (options?.client ?? this.client).get({
3268
+ url: "/api/session/{sessionID}/context",
3269
+ ...options,
3270
+ ...params,
3271
+ });
3272
+ }
3273
+ /**
3274
+ * Get v2 session messages
3275
+ *
3276
+ * Retrieve projected v2 messages for a session. Items keep the requested order across pages; use cursor.next or cursor.previous to move through the ordered timeline.
3277
+ */
3278
+ messages(parameters, options) {
3279
+ const params = buildClientParams([parameters], [
3280
+ {
3281
+ args: [
3282
+ { in: "path", key: "sessionID" },
3283
+ { in: "query", key: "limit" },
3284
+ { in: "query", key: "order" },
3285
+ { in: "query", key: "cursor" },
3286
+ ],
3287
+ },
3288
+ ]);
3289
+ return (options?.client ?? this.client).get({
3290
+ url: "/api/session/{sessionID}/message",
3291
+ ...options,
3292
+ ...params,
3293
+ });
3294
+ }
3295
+ _permission;
3296
+ get permission() {
3297
+ return (this._permission ??= new Permission2({ client: this.client }));
3298
+ }
3299
+ _question;
3300
+ get question() {
3301
+ return (this._question ??= new Question2({ client: this.client }));
3302
+ }
3303
+ }
3304
+ export class Model extends HeyApiClient {
3305
+ /**
3306
+ * List v2 models
3307
+ *
3308
+ * Retrieve available v2 models ordered by release date.
3309
+ */
3310
+ list(parameters, options) {
3311
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3312
+ return (options?.client ?? this.client).get({
3313
+ url: "/api/model",
3314
+ ...options,
3315
+ ...params,
3316
+ });
3317
+ }
3318
+ }
3319
+ export class Provider2 extends HeyApiClient {
3320
+ /**
3321
+ * List v2 providers
3322
+ *
3323
+ * Retrieve active v2 AI providers so clients can show provider availability and configuration.
3324
+ */
3325
+ list(parameters, options) {
3326
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3327
+ return (options?.client ?? this.client).get({
3328
+ url: "/api/provider",
3329
+ ...options,
3330
+ ...params,
3331
+ });
3332
+ }
3333
+ /**
3334
+ * Get v2 provider
3335
+ *
3336
+ * Retrieve a single v2 AI provider so clients can inspect its availability and endpoint settings.
3337
+ */
3338
+ get(parameters, options) {
3339
+ const params = buildClientParams([parameters], [
3340
+ {
3341
+ args: [
3342
+ { in: "path", key: "providerID" },
3343
+ { in: "query", key: "location" },
3344
+ ],
3345
+ },
3346
+ ]);
3347
+ return (options?.client ?? this.client).get({
3348
+ url: "/api/provider/{providerID}",
3349
+ ...options,
3350
+ ...params,
3351
+ });
3352
+ }
3353
+ }
3354
+ export class Request extends HeyApiClient {
3355
+ /**
3356
+ * List pending permission requests
3357
+ *
3358
+ * Retrieve pending permission requests for a location.
3359
+ */
3360
+ list(parameters, options) {
3361
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3362
+ return (options?.client ?? this.client).get({
3363
+ url: "/api/permission/request",
3364
+ ...options,
3365
+ ...params,
3366
+ });
3367
+ }
3368
+ }
3369
+ export class Saved extends HeyApiClient {
3370
+ /**
3371
+ * List saved permissions
3372
+ *
3373
+ * Retrieve saved permissions, optionally filtered by project.
3374
+ */
3375
+ list(parameters, options) {
3376
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "projectID" }] }]);
3377
+ return (options?.client ?? this.client).get({
3378
+ url: "/api/permission/saved",
3379
+ ...options,
3380
+ ...params,
3381
+ });
3382
+ }
3383
+ /**
3384
+ * Remove saved permission
3385
+ *
3386
+ * Remove a saved permission by ID.
3387
+ */
3388
+ remove(parameters, options) {
3389
+ const params = buildClientParams([parameters], [{ args: [{ in: "path", key: "id" }] }]);
3390
+ return (options?.client ?? this.client).delete({
3391
+ url: "/api/permission/saved/{id}",
3392
+ ...options,
3393
+ ...params,
3394
+ });
3395
+ }
3396
+ }
3397
+ export class Permission3 extends HeyApiClient {
3398
+ _request;
3399
+ get request() {
3400
+ return (this._request ??= new Request({ client: this.client }));
3401
+ }
3402
+ _saved;
3403
+ get saved() {
3404
+ return (this._saved ??= new Saved({ client: this.client }));
3405
+ }
3406
+ }
3407
+ export class Fs extends HeyApiClient {
3408
+ /**
3409
+ * Read file
3410
+ *
3411
+ * Read one file relative to the requested location.
3412
+ */
3413
+ read(parameters, options) {
3414
+ const params = buildClientParams([parameters], [
3415
+ {
3416
+ args: [
3417
+ { in: "query", key: "location" },
3418
+ { in: "query", key: "path" },
3419
+ { in: "query", key: "reference" },
3420
+ ],
3421
+ },
3422
+ ]);
3423
+ return (options?.client ?? this.client).get({
3424
+ url: "/api/fs/read",
3425
+ ...options,
3426
+ ...params,
3427
+ });
3428
+ }
3429
+ /**
3430
+ * List directory
3431
+ *
3432
+ * List direct children of one directory relative to the requested location.
3433
+ */
3434
+ list(parameters, options) {
3435
+ const params = buildClientParams([parameters], [
3436
+ {
3437
+ args: [
3438
+ { in: "query", key: "location" },
3439
+ { in: "query", key: "path" },
3440
+ { in: "query", key: "reference" },
3441
+ ],
3442
+ },
3443
+ ]);
3444
+ return (options?.client ?? this.client).get({
3445
+ url: "/api/fs/list",
3446
+ ...options,
3447
+ ...params,
3448
+ });
3449
+ }
3450
+ }
3451
+ export class Command2 extends HeyApiClient {
3452
+ /**
3453
+ * List v2 commands
3454
+ *
3455
+ * Retrieve currently registered v2 commands.
3456
+ */
3457
+ list(parameters, options) {
3458
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3459
+ return (options?.client ?? this.client).get({
3460
+ url: "/api/command",
3461
+ ...options,
3462
+ ...params,
3463
+ });
3464
+ }
3465
+ }
3466
+ export class Skill extends HeyApiClient {
3467
+ /**
3468
+ * List v2 skills
3469
+ *
3470
+ * Retrieve currently registered v2 skills.
3471
+ */
3472
+ list(parameters, options) {
3473
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3474
+ return (options?.client ?? this.client).get({
3475
+ url: "/api/skill",
3476
+ ...options,
3477
+ ...params,
3478
+ });
3479
+ }
3480
+ }
3481
+ export class Event2 extends HeyApiClient {
3482
+ /**
3483
+ * Subscribe to v2 events
3484
+ *
3485
+ * Subscribe to native EventV2 payloads for a location.
3486
+ */
3487
+ subscribe(parameters, options) {
3488
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3489
+ return (options?.client ?? this.client).sse.get({
3490
+ url: "/api/event",
3491
+ ...options,
3492
+ ...params,
3493
+ });
3494
+ }
3495
+ }
3496
+ export class Request2 extends HeyApiClient {
3497
+ /**
3498
+ * List pending question requests
3499
+ *
3500
+ * Retrieve pending question requests for a location.
3501
+ */
3502
+ list(parameters, options) {
3503
+ const params = buildClientParams([parameters], [{ args: [{ in: "query", key: "location" }] }]);
3504
+ return (options?.client ?? this.client).get({
3505
+ url: "/api/question/request",
3506
+ ...options,
3507
+ ...params,
3508
+ });
3509
+ }
3510
+ }
3511
+ export class Question3 extends HeyApiClient {
3512
+ _request;
3513
+ get request() {
3514
+ return (this._request ??= new Request2({ client: this.client }));
3515
+ }
3516
+ }
3517
+ export class V2 extends HeyApiClient {
3518
+ _health;
3519
+ get health() {
3520
+ return (this._health ??= new Health({ client: this.client }));
3521
+ }
3522
+ _agent;
3523
+ get agent() {
3524
+ return (this._agent ??= new Agent({ client: this.client }));
3525
+ }
3526
+ _session;
3527
+ get session() {
3528
+ return (this._session ??= new Session3({ client: this.client }));
3529
+ }
3530
+ _model;
3531
+ get model() {
3532
+ return (this._model ??= new Model({ client: this.client }));
3533
+ }
3534
+ _provider;
3535
+ get provider() {
3536
+ return (this._provider ??= new Provider2({ client: this.client }));
3537
+ }
3538
+ _permission;
3539
+ get permission() {
3540
+ return (this._permission ??= new Permission3({ client: this.client }));
3541
+ }
3542
+ _fs;
3543
+ get fs() {
3544
+ return (this._fs ??= new Fs({ client: this.client }));
3545
+ }
3546
+ _command;
3547
+ get command() {
3548
+ return (this._command ??= new Command2({ client: this.client }));
3549
+ }
3550
+ _skill;
3551
+ get skill() {
3552
+ return (this._skill ??= new Skill({ client: this.client }));
3553
+ }
3554
+ _event;
3555
+ get event() {
3556
+ return (this._event ??= new Event2({ client: this.client }));
3557
+ }
3558
+ _question;
3559
+ get question() {
3560
+ return (this._question ??= new Question3({ client: this.client }));
3561
+ }
3562
+ }
3563
+ export class OpencodeClient extends HeyApiClient {
3564
+ static __registry = new HeyApiRegistry();
3565
+ constructor(args) {
3566
+ super(args);
3567
+ OpencodeClient.__registry.set(this, args?.key);
3568
+ }
3569
+ _auth;
3570
+ get auth() {
3571
+ return (this._auth ??= new Auth({ client: this.client }));
3572
+ }
3573
+ _app;
3574
+ get app() {
3575
+ return (this._app ??= new App({ client: this.client }));
3576
+ }
3577
+ _experimental;
3578
+ get experimental() {
3579
+ return (this._experimental ??= new Experimental({ client: this.client }));
3580
+ }
3581
+ _global;
3582
+ get global() {
3583
+ return (this._global ??= new Global({ client: this.client }));
3584
+ }
3585
+ _event;
3586
+ get event() {
3587
+ return (this._event ??= new Event({ client: this.client }));
3588
+ }
3589
+ _config;
3590
+ get config() {
3591
+ return (this._config ??= new Config2({ client: this.client }));
3592
+ }
3593
+ _tool;
3594
+ get tool() {
3595
+ return (this._tool ??= new Tool({ client: this.client }));
3156
3596
  }
3157
3597
  _worktree;
3158
3598
  get worktree() {
@@ -3226,12 +3666,12 @@ export class OpencodeClient extends HeyApiClient {
3226
3666
  get sync() {
3227
3667
  return (this._sync ??= new Sync({ client: this.client }));
3228
3668
  }
3229
- _v2;
3230
- get v2() {
3231
- return (this._v2 ??= new V2({ client: this.client }));
3232
- }
3233
3669
  _tui;
3234
3670
  get tui() {
3235
3671
  return (this._tui ??= new Tui({ client: this.client }));
3236
3672
  }
3673
+ _v2;
3674
+ get v2() {
3675
+ return (this._v2 ??= new V2({ client: this.client }));
3676
+ }
3237
3677
  }