@opencode-ai/sdk 1.14.32 → 1.14.34

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.
@@ -1,5 +1,5 @@
1
1
  import { type Client, type Options as Options2, type TDataShape } from "./client/index.js";
2
- import type { AgentPartInput, AppAgentsResponses, AppLogErrors, AppLogResponses, AppSkillsResponses, Auth as Auth3, AuthRemoveErrors, AuthRemoveResponses, AuthSetErrors, AuthSetResponses, CommandListResponses, Config as Config3, ConfigGetResponses, ConfigProvidersResponses, ConfigUpdateErrors, ConfigUpdateResponses, EventSubscribeResponses, EventTuiCommandExecute, EventTuiPromptAppend, EventTuiSessionSelect, EventTuiToastShow, ExperimentalConsoleGetResponses, ExperimentalConsoleListOrgsResponses, ExperimentalConsoleSwitchOrgResponses, ExperimentalResourceListResponses, ExperimentalSessionListResponses, ExperimentalWorkspaceAdapterListResponses, ExperimentalWorkspaceCreateErrors, ExperimentalWorkspaceCreateResponses, ExperimentalWorkspaceListResponses, ExperimentalWorkspaceRemoveErrors, ExperimentalWorkspaceRemoveResponses, ExperimentalWorkspaceSessionRestoreErrors, ExperimentalWorkspaceSessionRestoreResponses, ExperimentalWorkspaceStatusResponses, FileListResponses, FilePartInput, FilePartSource, FileReadResponses, FileStatusResponses, FindFilesResponses, FindSymbolsResponses, FindTextResponses, FormatterStatusResponses, GlobalConfigGetResponses, GlobalConfigUpdateErrors, GlobalConfigUpdateResponses, GlobalDisposeResponses, GlobalEventResponses, GlobalHealthResponses, GlobalUpgradeErrors, GlobalUpgradeResponses, InstanceDisposeResponses, LspStatusResponses, McpAddErrors, McpAddResponses, McpAuthAuthenticateErrors, McpAuthAuthenticateResponses, McpAuthCallbackErrors, McpAuthCallbackResponses, McpAuthRemoveErrors, McpAuthRemoveResponses, McpAuthStartErrors, McpAuthStartResponses, McpConnectResponses, McpDisconnectResponses, McpLocalConfig, McpRemoteConfig, McpStatusResponses, OutputFormat, Part as Part2, PartDeleteErrors, PartDeleteResponses, PartUpdateErrors, PartUpdateResponses, PathGetResponses, PermissionListResponses, PermissionReplyErrors, PermissionReplyResponses, PermissionRespondErrors, PermissionRespondResponses, PermissionRuleset, ProjectCurrentResponses, ProjectInitGitResponses, ProjectListResponses, ProjectUpdateErrors, ProjectUpdateResponses, ProviderAuthResponses, ProviderListResponses, ProviderOauthAuthorizeErrors, ProviderOauthAuthorizeResponses, ProviderOauthCallbackErrors, ProviderOauthCallbackResponses, PtyConnectErrors, PtyConnectResponses, PtyCreateErrors, PtyCreateResponses, PtyGetErrors, PtyGetResponses, PtyListResponses, PtyRemoveErrors, PtyRemoveResponses, PtyShellsResponses, PtyUpdateErrors, PtyUpdateResponses, QuestionAnswer, QuestionListResponses, QuestionRejectErrors, QuestionRejectResponses, QuestionReplyErrors, QuestionReplyResponses, SessionAbortErrors, SessionAbortResponses, SessionChildrenErrors, SessionChildrenResponses, SessionCommandErrors, SessionCommandResponses, SessionCreateErrors, SessionCreateResponses, SessionDeleteErrors, SessionDeleteMessageErrors, SessionDeleteMessageResponses, SessionDeleteResponses, SessionDiffResponses, SessionForkResponses, SessionGetErrors, SessionGetResponses, SessionInitErrors, SessionInitResponses, SessionListResponses, SessionMessageErrors, SessionMessageResponses, SessionMessagesErrors, SessionMessagesResponses, SessionPromptAsyncErrors, SessionPromptAsyncResponses, SessionPromptErrors, SessionPromptResponses, SessionRevertErrors, SessionRevertResponses, SessionShareErrors, SessionShareResponses, SessionShellErrors, SessionShellResponses, SessionStatusErrors, SessionStatusResponses, SessionSummarizeErrors, SessionSummarizeResponses, SessionTodoErrors, SessionTodoResponses, SessionUnrevertErrors, SessionUnrevertResponses, SessionUnshareErrors, SessionUnshareResponses, SessionUpdateErrors, SessionUpdateResponses, SubtaskPartInput, SyncHistoryListErrors, SyncHistoryListResponses, SyncReplayErrors, SyncReplayResponses, SyncStartResponses, TextPartInput, ToolIdsErrors, ToolIdsResponses, ToolListErrors, ToolListResponses, TuiAppendPromptErrors, TuiAppendPromptResponses, TuiClearPromptResponses, TuiControlNextResponses, TuiControlResponseResponses, TuiExecuteCommandErrors, TuiExecuteCommandResponses, TuiOpenHelpResponses, TuiOpenModelsResponses, TuiOpenSessionsResponses, TuiOpenThemesResponses, TuiPublishErrors, TuiPublishResponses, TuiSelectSessionErrors, TuiSelectSessionResponses, TuiShowToastResponses, TuiSubmitPromptResponses, VcsDiffResponses, VcsGetResponses, WorktreeCreateErrors, WorktreeCreateInput, WorktreeCreateResponses, WorktreeListResponses, WorktreeRemoveErrors, WorktreeRemoveInput, WorktreeRemoveResponses, WorktreeResetErrors, WorktreeResetInput, WorktreeResetResponses } from "./types.gen.js";
2
+ import type { AgentPartInput, AppAgentsResponses, AppLogErrors, AppLogResponses, AppSkillsResponses, Auth as Auth3, AuthRemoveErrors, AuthRemoveResponses, AuthSetErrors, AuthSetResponses, CommandListResponses, Config as Config3, ConfigGetResponses, ConfigProvidersResponses, ConfigUpdateErrors, ConfigUpdateResponses, EventSubscribeResponses, EventTuiCommandExecute2, EventTuiPromptAppend2, EventTuiSessionSelect2, EventTuiToastShow2, ExperimentalConsoleGetResponses, ExperimentalConsoleListOrgsResponses, ExperimentalConsoleSwitchOrgResponses, ExperimentalResourceListResponses, ExperimentalSessionListResponses, ExperimentalWorkspaceAdapterListResponses, ExperimentalWorkspaceCreateErrors, ExperimentalWorkspaceCreateResponses, ExperimentalWorkspaceListResponses, ExperimentalWorkspaceRemoveErrors, ExperimentalWorkspaceRemoveResponses, ExperimentalWorkspaceSessionRestoreErrors, ExperimentalWorkspaceSessionRestoreResponses, ExperimentalWorkspaceStatusResponses, FileListResponses, FilePartInput, FilePartSource, FileReadResponses, FileStatusResponses, FindFilesResponses, FindSymbolsResponses, FindTextResponses, FormatterStatusResponses, GlobalConfigGetResponses, GlobalConfigUpdateErrors, GlobalConfigUpdateResponses, GlobalDisposeResponses, GlobalEventResponses, GlobalHealthResponses, GlobalUpgradeErrors, GlobalUpgradeResponses, InstanceDisposeResponses, LspStatusResponses, McpAddErrors, McpAddResponses, McpAuthAuthenticateErrors, McpAuthAuthenticateResponses, McpAuthCallbackErrors, McpAuthCallbackResponses, McpAuthRemoveErrors, McpAuthRemoveResponses, McpAuthStartErrors, McpAuthStartResponses, McpConnectResponses, McpDisconnectResponses, McpLocalConfig, McpRemoteConfig, McpStatusResponses, OutputFormat, Part as Part2, PartDeleteErrors, PartDeleteResponses, PartUpdateErrors, PartUpdateResponses, PathGetResponses, PermissionListResponses, PermissionReplyErrors, PermissionReplyResponses, PermissionRespondErrors, PermissionRespondResponses, PermissionRuleset, ProjectCurrentResponses, ProjectInitGitResponses, ProjectListResponses, ProjectUpdateErrors, ProjectUpdateResponses, Prompt, ProviderAuthResponses, ProviderListResponses, ProviderOauthAuthorizeErrors, ProviderOauthAuthorizeResponses, ProviderOauthCallbackErrors, ProviderOauthCallbackResponses, PtyConnectErrors, PtyConnectResponses, PtyConnectTokenErrors, PtyConnectTokenResponses, PtyCreateErrors, PtyCreateResponses, PtyGetErrors, PtyGetResponses, PtyListResponses, PtyRemoveErrors, PtyRemoveResponses, PtyShellsResponses, PtyUpdateErrors, PtyUpdateResponses, QuestionAnswer, QuestionListResponses, QuestionRejectErrors, QuestionRejectResponses, QuestionReplyErrors, QuestionReplyResponses, SessionAbortErrors, SessionAbortResponses, SessionChildrenErrors, SessionChildrenResponses, SessionCommandErrors, SessionCommandResponses, SessionCreateErrors, SessionCreateResponses, SessionDeleteErrors, SessionDeleteMessageErrors, SessionDeleteMessageResponses, SessionDeleteResponses, SessionDelivery, SessionDiffResponses, SessionForkResponses, SessionGetErrors, SessionGetResponses, SessionInitErrors, SessionInitResponses, SessionListResponses, SessionMessageErrors, SessionMessageResponses, SessionMessagesErrors, SessionMessagesResponses, SessionPromptAsyncErrors, SessionPromptAsyncResponses, SessionPromptErrors, SessionPromptResponses, SessionRevertErrors, SessionRevertResponses, SessionShareErrors, SessionShareResponses, SessionShellErrors, SessionShellResponses, SessionStatusErrors, SessionStatusResponses, SessionSummarizeErrors, SessionSummarizeResponses, SessionTodoErrors, SessionTodoResponses, SessionUnrevertErrors, SessionUnrevertResponses, SessionUnshareErrors, SessionUnshareResponses, SessionUpdateErrors, SessionUpdateResponses, SubtaskPartInput, SyncHistoryListErrors, SyncHistoryListResponses, SyncReplayErrors, SyncReplayResponses, SyncStartResponses, TextPartInput, ToolIdsErrors, ToolIdsResponses, ToolListErrors, ToolListResponses, TuiAppendPromptErrors, TuiAppendPromptResponses, TuiClearPromptResponses, TuiControlNextResponses, TuiControlResponseResponses, TuiExecuteCommandErrors, TuiExecuteCommandResponses, TuiOpenHelpResponses, TuiOpenModelsResponses, TuiOpenSessionsResponses, TuiOpenThemesResponses, TuiPublishErrors, TuiPublishResponses, TuiSelectSessionErrors, TuiSelectSessionResponses, TuiShowToastResponses, TuiSubmitPromptResponses, V2SessionCompactResponses, V2SessionContextResponses, V2SessionListErrors, V2SessionListResponses, V2SessionMessagesErrors, V2SessionMessagesResponses, V2SessionPromptResponses, V2SessionWaitResponses, VcsDiffResponses, VcsGetResponses, WorktreeCreateErrors, WorktreeCreateInput, WorktreeCreateResponses, WorktreeListResponses, WorktreeRemoveErrors, WorktreeRemoveInput, WorktreeRemoveResponses, WorktreeResetErrors, WorktreeResetInput, WorktreeResetResponses } from "./types.gen.js";
3
3
  export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = Options2<TData, ThrowOnError> & {
4
4
  /**
5
5
  * You can provide a client instance returned by `createClient()` instead of
@@ -25,52 +25,6 @@ declare class HeyApiRegistry<T> {
25
25
  get(key?: string): T;
26
26
  set(value: T, key?: string): void;
27
27
  }
28
- export declare class Config extends HeyApiClient {
29
- /**
30
- * Get global configuration
31
- *
32
- * Retrieve the current global OpenCode configuration settings and preferences.
33
- */
34
- get<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalConfigGetResponses, unknown, ThrowOnError, "fields">;
35
- /**
36
- * Update global configuration
37
- *
38
- * Update global OpenCode configuration settings and preferences.
39
- */
40
- update<ThrowOnError extends boolean = false>(parameters?: {
41
- config?: Config3;
42
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalConfigUpdateResponses, GlobalConfigUpdateErrors, ThrowOnError, "fields">;
43
- }
44
- export declare class Global extends HeyApiClient {
45
- /**
46
- * Get health
47
- *
48
- * Get health information about the OpenCode server.
49
- */
50
- health<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalHealthResponses, unknown, ThrowOnError, "fields">;
51
- /**
52
- * Get global events
53
- *
54
- * Subscribe to global events from the OpenCode system using server-sent events.
55
- */
56
- event<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): Promise<import("./core/serverSentEvents.gen.js").ServerSentEventsResult<GlobalEventResponses, unknown>>;
57
- /**
58
- * Dispose instance
59
- *
60
- * Clean up and dispose all OpenCode instances, releasing all resources.
61
- */
62
- dispose<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalDisposeResponses, unknown, ThrowOnError, "fields">;
63
- /**
64
- * Upgrade opencode
65
- *
66
- * Upgrade opencode to the specified version or latest if not specified.
67
- */
68
- upgrade<ThrowOnError extends boolean = false>(parameters?: {
69
- target?: string;
70
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalUpgradeResponses, GlobalUpgradeErrors, ThrowOnError, "fields">;
71
- private _config?;
72
- get config(): Config;
73
- }
74
28
  export declare class Auth extends HeyApiClient {
75
29
  /**
76
30
  * Remove auth credentials
@@ -125,72 +79,92 @@ export declare class App extends HeyApiClient {
125
79
  workspace?: string;
126
80
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<AppSkillsResponses, unknown, ThrowOnError, "fields">;
127
81
  }
128
- export declare class Adapter extends HeyApiClient {
82
+ export declare class Config extends HeyApiClient {
129
83
  /**
130
- * List workspace adapters
84
+ * Get global configuration
131
85
  *
132
- * List all available workspace adapters for the current project.
86
+ * Retrieve the current global OpenCode configuration settings and preferences.
133
87
  */
134
- list<ThrowOnError extends boolean = false>(parameters?: {
135
- directory?: string;
136
- workspace?: string;
137
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceAdapterListResponses, unknown, ThrowOnError, "fields">;
88
+ get<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalConfigGetResponses, unknown, ThrowOnError, "fields">;
89
+ /**
90
+ * Update global configuration
91
+ *
92
+ * Update global OpenCode configuration settings and preferences.
93
+ */
94
+ update<ThrowOnError extends boolean = false>(parameters?: {
95
+ config?: Config3;
96
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalConfigUpdateResponses, GlobalConfigUpdateErrors, ThrowOnError, "fields">;
138
97
  }
139
- export declare class Workspace extends HeyApiClient {
98
+ export declare class Global extends HeyApiClient {
140
99
  /**
141
- * List workspaces
100
+ * Get health
142
101
  *
143
- * List all workspaces.
102
+ * Get health information about the OpenCode server.
144
103
  */
145
- list<ThrowOnError extends boolean = false>(parameters?: {
146
- directory?: string;
147
- workspace?: string;
148
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceListResponses, unknown, ThrowOnError, "fields">;
104
+ health<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalHealthResponses, unknown, ThrowOnError, "fields">;
149
105
  /**
150
- * Create workspace
106
+ * Get global events
151
107
  *
152
- * Create a workspace for the current project.
108
+ * Subscribe to global events from the OpenCode system using server-sent events.
153
109
  */
154
- create<ThrowOnError extends boolean = false>(parameters?: {
110
+ event<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): Promise<import("./core/serverSentEvents.gen.js").ServerSentEventsResult<GlobalEventResponses, unknown>>;
111
+ /**
112
+ * Dispose instance
113
+ *
114
+ * Clean up and dispose all OpenCode instances, releasing all resources.
115
+ */
116
+ dispose<ThrowOnError extends boolean = false>(options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalDisposeResponses, unknown, ThrowOnError, "fields">;
117
+ /**
118
+ * Upgrade opencode
119
+ *
120
+ * Upgrade opencode to the specified version or latest if not specified.
121
+ */
122
+ upgrade<ThrowOnError extends boolean = false>(parameters?: {
123
+ target?: string;
124
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<GlobalUpgradeResponses, GlobalUpgradeErrors, ThrowOnError, "fields">;
125
+ private _config?;
126
+ get config(): Config;
127
+ }
128
+ export declare class Event extends HeyApiClient {
129
+ /**
130
+ * Subscribe to events
131
+ *
132
+ * Get events
133
+ */
134
+ subscribe<ThrowOnError extends boolean = false>(parameters?: {
155
135
  directory?: string;
156
136
  workspace?: string;
157
- id?: string;
158
- type?: string;
159
- branch?: string | null;
160
- extra?: unknown | null;
161
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceCreateResponses, ExperimentalWorkspaceCreateErrors, ThrowOnError, "fields">;
137
+ }, options?: Options<never, ThrowOnError>): Promise<import("./core/serverSentEvents.gen.js").ServerSentEventsResult<EventSubscribeResponses, unknown>>;
138
+ }
139
+ export declare class Config2 extends HeyApiClient {
162
140
  /**
163
- * Workspace status
141
+ * Get configuration
164
142
  *
165
- * Get connection status for workspaces in the current project.
143
+ * Retrieve the current OpenCode configuration settings and preferences.
166
144
  */
167
- status<ThrowOnError extends boolean = false>(parameters?: {
145
+ get<ThrowOnError extends boolean = false>(parameters?: {
168
146
  directory?: string;
169
147
  workspace?: string;
170
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceStatusResponses, unknown, ThrowOnError, "fields">;
148
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigGetResponses, unknown, ThrowOnError, "fields">;
171
149
  /**
172
- * Remove workspace
150
+ * Update configuration
173
151
  *
174
- * Remove an existing workspace.
152
+ * Update OpenCode configuration settings and preferences.
175
153
  */
176
- remove<ThrowOnError extends boolean = false>(parameters: {
177
- id: string;
154
+ update<ThrowOnError extends boolean = false>(parameters?: {
178
155
  directory?: string;
179
156
  workspace?: string;
180
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceRemoveResponses, ExperimentalWorkspaceRemoveErrors, ThrowOnError, "fields">;
157
+ config?: Config3;
158
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigUpdateResponses, ConfigUpdateErrors, ThrowOnError, "fields">;
181
159
  /**
182
- * Restore session into workspace
160
+ * List config providers
183
161
  *
184
- * Replay a session's sync events into the target workspace in batches.
162
+ * Get a list of all configured AI providers and their default models.
185
163
  */
186
- sessionRestore<ThrowOnError extends boolean = false>(parameters: {
187
- id: string;
164
+ providers<ThrowOnError extends boolean = false>(parameters?: {
188
165
  directory?: string;
189
166
  workspace?: string;
190
- sessionID?: string;
191
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceSessionRestoreResponses, ExperimentalWorkspaceSessionRestoreErrors, ThrowOnError, "fields">;
192
- private _adapter?;
193
- get adapter(): Adapter;
167
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigProvidersResponses, unknown, ThrowOnError, "fields">;
194
168
  }
195
169
  export declare class Console extends HeyApiClient {
196
170
  /**
@@ -251,412 +225,742 @@ export declare class Resource extends HeyApiClient {
251
225
  workspace?: string;
252
226
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalResourceListResponses, unknown, ThrowOnError, "fields">;
253
227
  }
254
- export declare class Experimental extends HeyApiClient {
255
- private _workspace?;
256
- get workspace(): Workspace;
257
- private _console?;
258
- get console(): Console;
259
- private _session?;
260
- get session(): Session;
261
- private _resource?;
262
- get resource(): Resource;
228
+ export declare class Adapter extends HeyApiClient {
229
+ /**
230
+ * List workspace adapters
231
+ *
232
+ * List all available workspace adapters for the current project.
233
+ */
234
+ list<ThrowOnError extends boolean = false>(parameters?: {
235
+ directory?: string;
236
+ workspace?: string;
237
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceAdapterListResponses, unknown, ThrowOnError, "fields">;
263
238
  }
264
- export declare class Project extends HeyApiClient {
239
+ export declare class Workspace extends HeyApiClient {
265
240
  /**
266
- * List all projects
241
+ * List workspaces
267
242
  *
268
- * Get a list of projects that have been opened with OpenCode.
243
+ * List all workspaces.
269
244
  */
270
245
  list<ThrowOnError extends boolean = false>(parameters?: {
271
246
  directory?: string;
272
247
  workspace?: string;
273
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectListResponses, unknown, ThrowOnError, "fields">;
248
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceListResponses, unknown, ThrowOnError, "fields">;
274
249
  /**
275
- * Get current project
250
+ * Create workspace
276
251
  *
277
- * Retrieve the currently active project that OpenCode is working with.
252
+ * Create a workspace for the current project.
278
253
  */
279
- current<ThrowOnError extends boolean = false>(parameters?: {
254
+ create<ThrowOnError extends boolean = false>(parameters?: {
280
255
  directory?: string;
281
256
  workspace?: string;
282
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectCurrentResponses, unknown, ThrowOnError, "fields">;
257
+ id?: string;
258
+ type?: string;
259
+ branch?: string | null;
260
+ extra?: unknown | null;
261
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceCreateResponses, ExperimentalWorkspaceCreateErrors, ThrowOnError, "fields">;
283
262
  /**
284
- * Initialize git repository
263
+ * Workspace status
285
264
  *
286
- * Create a git repository for the current project and return the refreshed project info.
265
+ * Get connection status for workspaces in the current project.
287
266
  */
288
- initGit<ThrowOnError extends boolean = false>(parameters?: {
267
+ status<ThrowOnError extends boolean = false>(parameters?: {
289
268
  directory?: string;
290
269
  workspace?: string;
291
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectInitGitResponses, unknown, ThrowOnError, "fields">;
270
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceStatusResponses, unknown, ThrowOnError, "fields">;
292
271
  /**
293
- * Update project
272
+ * Remove workspace
294
273
  *
295
- * Update project properties such as name, icon, and commands.
274
+ * Remove an existing workspace.
296
275
  */
297
- update<ThrowOnError extends boolean = false>(parameters: {
298
- projectID: string;
276
+ remove<ThrowOnError extends boolean = false>(parameters: {
277
+ id: string;
299
278
  directory?: string;
300
279
  workspace?: string;
301
- name?: string;
302
- icon?: {
303
- url?: string;
304
- override?: string;
305
- color?: string;
306
- };
307
- commands?: {
308
- /**
309
- * Startup script to run when creating a new workspace (worktree)
310
- */
311
- start?: string;
312
- };
313
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectUpdateResponses, ProjectUpdateErrors, ThrowOnError, "fields">;
314
- }
315
- export declare class Pty extends HeyApiClient {
280
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceRemoveResponses, ExperimentalWorkspaceRemoveErrors, ThrowOnError, "fields">;
316
281
  /**
317
- * List available shells
282
+ * Restore session into workspace
318
283
  *
319
- * Get a list of available shells on the system.
284
+ * Replay a session's sync events into the target workspace in batches.
320
285
  */
321
- shells<ThrowOnError extends boolean = false>(parameters?: {
286
+ sessionRestore<ThrowOnError extends boolean = false>(parameters: {
287
+ id: string;
322
288
  directory?: string;
323
289
  workspace?: string;
324
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyShellsResponses, unknown, ThrowOnError, "fields">;
290
+ sessionID?: string;
291
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalWorkspaceSessionRestoreResponses, ExperimentalWorkspaceSessionRestoreErrors, ThrowOnError, "fields">;
292
+ private _adapter?;
293
+ get adapter(): Adapter;
294
+ }
295
+ export declare class Experimental extends HeyApiClient {
296
+ private _console?;
297
+ get console(): Console;
298
+ private _session?;
299
+ get session(): Session;
300
+ private _resource?;
301
+ get resource(): Resource;
302
+ private _workspace?;
303
+ get workspace(): Workspace;
304
+ }
305
+ export declare class Tool extends HeyApiClient {
325
306
  /**
326
- * List PTY sessions
307
+ * List tools
327
308
  *
328
- * Get a list of all active pseudo-terminal (PTY) sessions managed by OpenCode.
309
+ * Get a list of available tools with their JSON schema parameters for a specific provider and model combination.
329
310
  */
330
- list<ThrowOnError extends boolean = false>(parameters?: {
311
+ list<ThrowOnError extends boolean = false>(parameters: {
331
312
  directory?: string;
332
313
  workspace?: string;
333
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyListResponses, unknown, ThrowOnError, "fields">;
314
+ provider: string;
315
+ model: string;
316
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ToolListResponses, ToolListErrors, ThrowOnError, "fields">;
334
317
  /**
335
- * Create PTY session
318
+ * List tool IDs
336
319
  *
337
- * Create a new pseudo-terminal (PTY) session for running shell commands and processes.
320
+ * Get a list of all available tool IDs, including both built-in tools and dynamically registered tools.
338
321
  */
339
- create<ThrowOnError extends boolean = false>(parameters?: {
322
+ ids<ThrowOnError extends boolean = false>(parameters?: {
340
323
  directory?: string;
341
324
  workspace?: string;
342
- command?: string;
343
- args?: Array<string>;
344
- cwd?: string;
345
- title?: string;
346
- env?: {
347
- [key: string]: string;
348
- };
349
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyCreateResponses, PtyCreateErrors, ThrowOnError, "fields">;
325
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ToolIdsResponses, ToolIdsErrors, ThrowOnError, "fields">;
326
+ }
327
+ export declare class Worktree extends HeyApiClient {
350
328
  /**
351
- * Remove PTY session
329
+ * Remove worktree
352
330
  *
353
- * Remove and terminate a specific pseudo-terminal (PTY) session.
331
+ * Remove a git worktree and delete its branch.
354
332
  */
355
- remove<ThrowOnError extends boolean = false>(parameters: {
356
- ptyID: string;
333
+ remove<ThrowOnError extends boolean = false>(parameters?: {
357
334
  directory?: string;
358
335
  workspace?: string;
359
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyRemoveResponses, PtyRemoveErrors, ThrowOnError, "fields">;
336
+ worktreeRemoveInput?: WorktreeRemoveInput;
337
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeRemoveResponses, WorktreeRemoveErrors, ThrowOnError, "fields">;
360
338
  /**
361
- * Get PTY session
339
+ * List worktrees
362
340
  *
363
- * Retrieve detailed information about a specific pseudo-terminal (PTY) session.
341
+ * List all sandbox worktrees for the current project.
364
342
  */
365
- get<ThrowOnError extends boolean = false>(parameters: {
366
- ptyID: string;
343
+ list<ThrowOnError extends boolean = false>(parameters?: {
367
344
  directory?: string;
368
345
  workspace?: string;
369
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyGetResponses, PtyGetErrors, ThrowOnError, "fields">;
346
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeListResponses, unknown, ThrowOnError, "fields">;
370
347
  /**
371
- * Update PTY session
348
+ * Create worktree
372
349
  *
373
- * Update properties of an existing pseudo-terminal (PTY) session.
350
+ * Create a new git worktree for the current project and run any configured startup scripts.
374
351
  */
375
- update<ThrowOnError extends boolean = false>(parameters: {
376
- ptyID: string;
352
+ create<ThrowOnError extends boolean = false>(parameters?: {
377
353
  directory?: string;
378
354
  workspace?: string;
379
- title?: string;
380
- size?: {
381
- rows: number;
382
- cols: number;
383
- };
384
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyUpdateResponses, PtyUpdateErrors, ThrowOnError, "fields">;
355
+ worktreeCreateInput?: WorktreeCreateInput;
356
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeCreateResponses, WorktreeCreateErrors, ThrowOnError, "fields">;
385
357
  /**
386
- * Connect to PTY session
358
+ * Reset worktree
387
359
  *
388
- * Establish a WebSocket connection to interact with a pseudo-terminal (PTY) session in real-time.
360
+ * Reset a worktree branch to the primary default branch.
389
361
  */
390
- connect<ThrowOnError extends boolean = false>(parameters: {
391
- ptyID: string;
362
+ reset<ThrowOnError extends boolean = false>(parameters?: {
392
363
  directory?: string;
393
364
  workspace?: string;
394
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyConnectResponses, PtyConnectErrors, ThrowOnError, "fields">;
365
+ worktreeResetInput?: WorktreeResetInput;
366
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeResetResponses, WorktreeResetErrors, ThrowOnError, "fields">;
395
367
  }
396
- export declare class Config2 extends HeyApiClient {
368
+ export declare class Find extends HeyApiClient {
397
369
  /**
398
- * Get configuration
370
+ * Find text
399
371
  *
400
- * Retrieve the current OpenCode configuration settings and preferences.
372
+ * Search for text patterns across files in the project using ripgrep.
401
373
  */
402
- get<ThrowOnError extends boolean = false>(parameters?: {
374
+ text<ThrowOnError extends boolean = false>(parameters: {
403
375
  directory?: string;
404
376
  workspace?: string;
405
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigGetResponses, unknown, ThrowOnError, "fields">;
377
+ pattern: string;
378
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindTextResponses, unknown, ThrowOnError, "fields">;
406
379
  /**
407
- * Update configuration
380
+ * Find files
408
381
  *
409
- * Update OpenCode configuration settings and preferences.
382
+ * Search for files or directories by name or pattern in the project directory.
410
383
  */
411
- update<ThrowOnError extends boolean = false>(parameters?: {
384
+ files<ThrowOnError extends boolean = false>(parameters: {
412
385
  directory?: string;
413
386
  workspace?: string;
414
- config?: Config3;
415
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigUpdateResponses, ConfigUpdateErrors, ThrowOnError, "fields">;
387
+ query: string;
388
+ dirs?: "true" | "false";
389
+ type?: "file" | "directory";
390
+ limit?: number;
391
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindFilesResponses, unknown, ThrowOnError, "fields">;
416
392
  /**
417
- * List config providers
393
+ * Find symbols
418
394
  *
419
- * Get a list of all configured AI providers and their default models.
395
+ * Search for workspace symbols like functions, classes, and variables using LSP.
420
396
  */
421
- providers<ThrowOnError extends boolean = false>(parameters?: {
397
+ symbols<ThrowOnError extends boolean = false>(parameters: {
422
398
  directory?: string;
423
399
  workspace?: string;
424
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ConfigProvidersResponses, unknown, ThrowOnError, "fields">;
400
+ query: string;
401
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindSymbolsResponses, unknown, ThrowOnError, "fields">;
425
402
  }
426
- export declare class Tool extends HeyApiClient {
403
+ export declare class File extends HeyApiClient {
427
404
  /**
428
- * List tool IDs
405
+ * List files
429
406
  *
430
- * Get a list of all available tool IDs, including both built-in tools and dynamically registered tools.
407
+ * List files and directories in a specified path.
431
408
  */
432
- ids<ThrowOnError extends boolean = false>(parameters?: {
409
+ list<ThrowOnError extends boolean = false>(parameters: {
433
410
  directory?: string;
434
411
  workspace?: string;
435
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ToolIdsResponses, ToolIdsErrors, ThrowOnError, "fields">;
412
+ path: string;
413
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileListResponses, unknown, ThrowOnError, "fields">;
436
414
  /**
437
- * List tools
415
+ * Read file
438
416
  *
439
- * Get a list of available tools with their JSON schema parameters for a specific provider and model combination.
417
+ * Read the content of a specified file.
440
418
  */
441
- list<ThrowOnError extends boolean = false>(parameters: {
419
+ read<ThrowOnError extends boolean = false>(parameters: {
442
420
  directory?: string;
443
421
  workspace?: string;
444
- provider: string;
445
- model: string;
446
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ToolListResponses, ToolListErrors, ThrowOnError, "fields">;
422
+ path: string;
423
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileReadResponses, unknown, ThrowOnError, "fields">;
424
+ /**
425
+ * Get file status
426
+ *
427
+ * Get the git status of all files in the project.
428
+ */
429
+ status<ThrowOnError extends boolean = false>(parameters?: {
430
+ directory?: string;
431
+ workspace?: string;
432
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileStatusResponses, unknown, ThrowOnError, "fields">;
447
433
  }
448
- export declare class Worktree extends HeyApiClient {
434
+ export declare class Instance extends HeyApiClient {
449
435
  /**
450
- * Remove worktree
436
+ * Dispose instance
451
437
  *
452
- * Remove a git worktree and delete its branch.
438
+ * Clean up and dispose the current OpenCode instance, releasing all resources.
453
439
  */
454
- remove<ThrowOnError extends boolean = false>(parameters?: {
440
+ dispose<ThrowOnError extends boolean = false>(parameters?: {
455
441
  directory?: string;
456
442
  workspace?: string;
457
- worktreeRemoveInput?: WorktreeRemoveInput;
458
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeRemoveResponses, WorktreeRemoveErrors, ThrowOnError, "fields">;
443
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<InstanceDisposeResponses, unknown, ThrowOnError, "fields">;
444
+ }
445
+ export declare class Path extends HeyApiClient {
459
446
  /**
460
- * List worktrees
447
+ * Get paths
461
448
  *
462
- * List all sandbox worktrees for the current project.
449
+ * Retrieve the current working directory and related path information for the OpenCode instance.
463
450
  */
464
- list<ThrowOnError extends boolean = false>(parameters?: {
451
+ get<ThrowOnError extends boolean = false>(parameters?: {
465
452
  directory?: string;
466
453
  workspace?: string;
467
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeListResponses, unknown, ThrowOnError, "fields">;
454
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PathGetResponses, unknown, ThrowOnError, "fields">;
455
+ }
456
+ export declare class Vcs extends HeyApiClient {
468
457
  /**
469
- * Create worktree
458
+ * Get VCS info
470
459
  *
471
- * Create a new git worktree for the current project and run any configured startup scripts.
460
+ * Retrieve version control system (VCS) information for the current project, such as git branch.
472
461
  */
473
- create<ThrowOnError extends boolean = false>(parameters?: {
462
+ get<ThrowOnError extends boolean = false>(parameters?: {
474
463
  directory?: string;
475
464
  workspace?: string;
476
- worktreeCreateInput?: WorktreeCreateInput;
477
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeCreateResponses, WorktreeCreateErrors, ThrowOnError, "fields">;
465
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<VcsGetResponses, unknown, ThrowOnError, "fields">;
478
466
  /**
479
- * Reset worktree
467
+ * Get VCS diff
480
468
  *
481
- * Reset a worktree branch to the primary default branch.
469
+ * Retrieve the current git diff for the working tree or against the default branch.
482
470
  */
483
- reset<ThrowOnError extends boolean = false>(parameters?: {
471
+ diff<ThrowOnError extends boolean = false>(parameters: {
484
472
  directory?: string;
485
473
  workspace?: string;
486
- worktreeResetInput?: WorktreeResetInput;
487
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeResetResponses, WorktreeResetErrors, ThrowOnError, "fields">;
474
+ mode: "git" | "branch";
475
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<VcsDiffResponses, unknown, ThrowOnError, "fields">;
488
476
  }
489
- export declare class Session2 extends HeyApiClient {
477
+ export declare class Command extends HeyApiClient {
490
478
  /**
491
- * List sessions
479
+ * List commands
492
480
  *
493
- * Get a list of all OpenCode sessions, sorted by most recently updated.
481
+ * Get a list of all available commands in the OpenCode system.
494
482
  */
495
483
  list<ThrowOnError extends boolean = false>(parameters?: {
496
484
  directory?: string;
497
485
  workspace?: string;
498
- scope?: "project";
499
- path?: string;
500
- roots?: boolean | "true" | "false";
501
- start?: number;
502
- search?: string;
503
- limit?: number;
504
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionListResponses, unknown, ThrowOnError, "fields">;
486
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<CommandListResponses, unknown, ThrowOnError, "fields">;
487
+ }
488
+ export declare class Lsp extends HeyApiClient {
505
489
  /**
506
- * Create session
490
+ * Get LSP status
507
491
  *
508
- * Create a new OpenCode session for interacting with AI assistants and managing conversations.
492
+ * Get LSP server status
509
493
  */
510
- create<ThrowOnError extends boolean = false>(parameters?: {
494
+ status<ThrowOnError extends boolean = false>(parameters?: {
511
495
  directory?: string;
512
496
  workspace?: string;
513
- parentID?: string;
514
- title?: string;
515
- permission?: PermissionRuleset;
516
- workspaceID?: string;
517
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionCreateResponses, SessionCreateErrors, ThrowOnError, "fields">;
497
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<LspStatusResponses, unknown, ThrowOnError, "fields">;
498
+ }
499
+ export declare class Formatter extends HeyApiClient {
518
500
  /**
519
- * Get session status
501
+ * Get formatter status
520
502
  *
521
- * Retrieve the current status of all sessions, including active, idle, and completed states.
503
+ * Get formatter status
522
504
  */
523
505
  status<ThrowOnError extends boolean = false>(parameters?: {
524
506
  directory?: string;
525
507
  workspace?: string;
526
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionStatusResponses, SessionStatusErrors, ThrowOnError, "fields">;
508
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FormatterStatusResponses, unknown, ThrowOnError, "fields">;
509
+ }
510
+ export declare class Auth2 extends HeyApiClient {
527
511
  /**
528
- * Delete session
512
+ * Remove MCP OAuth
529
513
  *
530
- * Delete a session and permanently remove all associated data, including messages and history.
514
+ * Remove OAuth credentials for an MCP server.
531
515
  */
532
- delete<ThrowOnError extends boolean = false>(parameters: {
533
- sessionID: string;
516
+ remove<ThrowOnError extends boolean = false>(parameters: {
517
+ name: string;
534
518
  directory?: string;
535
519
  workspace?: string;
536
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDeleteResponses, SessionDeleteErrors, ThrowOnError, "fields">;
520
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthRemoveResponses, McpAuthRemoveErrors, ThrowOnError, "fields">;
537
521
  /**
538
- * Get session
522
+ * Start MCP OAuth
539
523
  *
540
- * Retrieve detailed information about a specific OpenCode session.
524
+ * Start OAuth authentication flow for a Model Context Protocol (MCP) server.
541
525
  */
542
- get<ThrowOnError extends boolean = false>(parameters: {
543
- sessionID: string;
526
+ start<ThrowOnError extends boolean = false>(parameters: {
527
+ name: string;
544
528
  directory?: string;
545
529
  workspace?: string;
546
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionGetResponses, SessionGetErrors, ThrowOnError, "fields">;
530
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthStartResponses, McpAuthStartErrors, ThrowOnError, "fields">;
547
531
  /**
548
- * Update session
532
+ * Complete MCP OAuth
549
533
  *
550
- * Update properties of an existing session, such as title or other metadata.
534
+ * Complete OAuth authentication for a Model Context Protocol (MCP) server using the authorization code.
551
535
  */
552
- update<ThrowOnError extends boolean = false>(parameters: {
553
- sessionID: string;
536
+ callback<ThrowOnError extends boolean = false>(parameters: {
537
+ name: string;
554
538
  directory?: string;
555
539
  workspace?: string;
556
- title?: string;
557
- permission?: PermissionRuleset;
558
- time?: {
559
- archived?: number;
560
- };
561
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUpdateResponses, SessionUpdateErrors, ThrowOnError, "fields">;
540
+ code?: string;
541
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthCallbackResponses, McpAuthCallbackErrors, ThrowOnError, "fields">;
562
542
  /**
563
- * Get session children
543
+ * Authenticate MCP OAuth
564
544
  *
565
- * Retrieve all child sessions that were forked from the specified parent session.
545
+ * Start OAuth flow and wait for callback (opens browser).
566
546
  */
567
- children<ThrowOnError extends boolean = false>(parameters: {
568
- sessionID: string;
547
+ authenticate<ThrowOnError extends boolean = false>(parameters: {
548
+ name: string;
569
549
  directory?: string;
570
550
  workspace?: string;
571
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionChildrenResponses, SessionChildrenErrors, ThrowOnError, "fields">;
551
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthAuthenticateResponses, McpAuthAuthenticateErrors, ThrowOnError, "fields">;
552
+ }
553
+ export declare class Mcp extends HeyApiClient {
572
554
  /**
573
- * Get session todos
555
+ * Get MCP status
574
556
  *
575
- * Retrieve the todo list associated with a specific session, showing tasks and action items.
557
+ * Get the status of all Model Context Protocol (MCP) servers.
576
558
  */
577
- todo<ThrowOnError extends boolean = false>(parameters: {
578
- sessionID: string;
559
+ status<ThrowOnError extends boolean = false>(parameters?: {
579
560
  directory?: string;
580
561
  workspace?: string;
581
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionTodoResponses, SessionTodoErrors, ThrowOnError, "fields">;
562
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpStatusResponses, unknown, ThrowOnError, "fields">;
582
563
  /**
583
- * Initialize session
564
+ * Add MCP server
584
565
  *
585
- * Analyze the current application and create an AGENTS.md file with project-specific agent configurations.
566
+ * Dynamically add a new Model Context Protocol (MCP) server to the system.
586
567
  */
587
- init<ThrowOnError extends boolean = false>(parameters: {
568
+ add<ThrowOnError extends boolean = false>(parameters?: {
569
+ directory?: string;
570
+ workspace?: string;
571
+ name?: string;
572
+ config?: McpLocalConfig | McpRemoteConfig;
573
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAddResponses, McpAddErrors, ThrowOnError, "fields">;
574
+ /**
575
+ * Connect an MCP server.
576
+ */
577
+ connect<ThrowOnError extends boolean = false>(parameters: {
578
+ name: string;
579
+ directory?: string;
580
+ workspace?: string;
581
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpConnectResponses, unknown, ThrowOnError, "fields">;
582
+ /**
583
+ * Disconnect an MCP server.
584
+ */
585
+ disconnect<ThrowOnError extends boolean = false>(parameters: {
586
+ name: string;
587
+ directory?: string;
588
+ workspace?: string;
589
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpDisconnectResponses, unknown, ThrowOnError, "fields">;
590
+ private _auth?;
591
+ get auth(): Auth2;
592
+ }
593
+ export declare class Project extends HeyApiClient {
594
+ /**
595
+ * List all projects
596
+ *
597
+ * Get a list of projects that have been opened with OpenCode.
598
+ */
599
+ list<ThrowOnError extends boolean = false>(parameters?: {
600
+ directory?: string;
601
+ workspace?: string;
602
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectListResponses, unknown, ThrowOnError, "fields">;
603
+ /**
604
+ * Get current project
605
+ *
606
+ * Retrieve the currently active project that OpenCode is working with.
607
+ */
608
+ current<ThrowOnError extends boolean = false>(parameters?: {
609
+ directory?: string;
610
+ workspace?: string;
611
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectCurrentResponses, unknown, ThrowOnError, "fields">;
612
+ /**
613
+ * Initialize git repository
614
+ *
615
+ * Create a git repository for the current project and return the refreshed project info.
616
+ */
617
+ initGit<ThrowOnError extends boolean = false>(parameters?: {
618
+ directory?: string;
619
+ workspace?: string;
620
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectInitGitResponses, unknown, ThrowOnError, "fields">;
621
+ /**
622
+ * Update project
623
+ *
624
+ * Update project properties such as name, icon, and commands.
625
+ */
626
+ update<ThrowOnError extends boolean = false>(parameters: {
627
+ projectID: string;
628
+ directory?: string;
629
+ workspace?: string;
630
+ name?: string;
631
+ icon?: {
632
+ url?: string;
633
+ override?: string;
634
+ color?: string;
635
+ };
636
+ commands?: {
637
+ /**
638
+ * Startup script to run when creating a new workspace (worktree)
639
+ */
640
+ start?: string;
641
+ };
642
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProjectUpdateResponses, ProjectUpdateErrors, ThrowOnError, "fields">;
643
+ }
644
+ export declare class Pty extends HeyApiClient {
645
+ /**
646
+ * List available shells
647
+ *
648
+ * Get a list of available shells on the system.
649
+ */
650
+ shells<ThrowOnError extends boolean = false>(parameters?: {
651
+ directory?: string;
652
+ workspace?: string;
653
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyShellsResponses, unknown, ThrowOnError, "fields">;
654
+ /**
655
+ * List PTY sessions
656
+ *
657
+ * Get a list of all active pseudo-terminal (PTY) sessions managed by OpenCode.
658
+ */
659
+ list<ThrowOnError extends boolean = false>(parameters?: {
660
+ directory?: string;
661
+ workspace?: string;
662
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyListResponses, unknown, ThrowOnError, "fields">;
663
+ /**
664
+ * Create PTY session
665
+ *
666
+ * Create a new pseudo-terminal (PTY) session for running shell commands and processes.
667
+ */
668
+ create<ThrowOnError extends boolean = false>(parameters?: {
669
+ directory?: string;
670
+ workspace?: string;
671
+ command?: string;
672
+ args?: Array<string>;
673
+ cwd?: string;
674
+ title?: string;
675
+ env?: {
676
+ [key: string]: string;
677
+ };
678
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyCreateResponses, PtyCreateErrors, ThrowOnError, "fields">;
679
+ /**
680
+ * Remove PTY session
681
+ *
682
+ * Remove and terminate a specific pseudo-terminal (PTY) session.
683
+ */
684
+ remove<ThrowOnError extends boolean = false>(parameters: {
685
+ ptyID: string;
686
+ directory?: string;
687
+ workspace?: string;
688
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyRemoveResponses, PtyRemoveErrors, ThrowOnError, "fields">;
689
+ /**
690
+ * Get PTY session
691
+ *
692
+ * Retrieve detailed information about a specific pseudo-terminal (PTY) session.
693
+ */
694
+ get<ThrowOnError extends boolean = false>(parameters: {
695
+ ptyID: string;
696
+ directory?: string;
697
+ workspace?: string;
698
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyGetResponses, PtyGetErrors, ThrowOnError, "fields">;
699
+ /**
700
+ * Update PTY session
701
+ *
702
+ * Update properties of an existing pseudo-terminal (PTY) session.
703
+ */
704
+ update<ThrowOnError extends boolean = false>(parameters: {
705
+ ptyID: string;
706
+ directory?: string;
707
+ workspace?: string;
708
+ title?: string;
709
+ size?: {
710
+ rows: number;
711
+ cols: number;
712
+ };
713
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyUpdateResponses, PtyUpdateErrors, ThrowOnError, "fields">;
714
+ /**
715
+ * Create PTY WebSocket token
716
+ *
717
+ * Create a short-lived ticket for opening a PTY WebSocket connection.
718
+ */
719
+ connectToken<ThrowOnError extends boolean = false>(parameters: {
720
+ ptyID: string;
721
+ directory?: string;
722
+ workspace?: string;
723
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyConnectTokenResponses, PtyConnectTokenErrors, ThrowOnError, "fields">;
724
+ /**
725
+ * Connect to PTY session
726
+ *
727
+ * Establish a WebSocket connection to interact with a pseudo-terminal (PTY) session in real-time.
728
+ */
729
+ connect<ThrowOnError extends boolean = false>(parameters: {
730
+ ptyID: string;
731
+ directory?: string;
732
+ workspace?: string;
733
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PtyConnectResponses, PtyConnectErrors, ThrowOnError, "fields">;
734
+ }
735
+ export declare class Question extends HeyApiClient {
736
+ /**
737
+ * List pending questions
738
+ *
739
+ * Get all pending question requests across all sessions.
740
+ */
741
+ list<ThrowOnError extends boolean = false>(parameters?: {
742
+ directory?: string;
743
+ workspace?: string;
744
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionListResponses, unknown, ThrowOnError, "fields">;
745
+ /**
746
+ * Reply to question request
747
+ *
748
+ * Provide answers to a question request from the AI assistant.
749
+ */
750
+ reply<ThrowOnError extends boolean = false>(parameters: {
751
+ requestID: string;
752
+ directory?: string;
753
+ workspace?: string;
754
+ answers?: Array<QuestionAnswer>;
755
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionReplyResponses, QuestionReplyErrors, ThrowOnError, "fields">;
756
+ /**
757
+ * Reject question request
758
+ *
759
+ * Reject a question request from the AI assistant.
760
+ */
761
+ reject<ThrowOnError extends boolean = false>(parameters: {
762
+ requestID: string;
763
+ directory?: string;
764
+ workspace?: string;
765
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionRejectResponses, QuestionRejectErrors, ThrowOnError, "fields">;
766
+ }
767
+ export declare class Permission extends HeyApiClient {
768
+ /**
769
+ * List pending permissions
770
+ *
771
+ * Get all pending permission requests across all sessions.
772
+ */
773
+ list<ThrowOnError extends boolean = false>(parameters?: {
774
+ directory?: string;
775
+ workspace?: string;
776
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionListResponses, unknown, ThrowOnError, "fields">;
777
+ /**
778
+ * Respond to permission request
779
+ *
780
+ * Approve or deny a permission request from the AI assistant.
781
+ */
782
+ reply<ThrowOnError extends boolean = false>(parameters: {
783
+ requestID: string;
784
+ directory?: string;
785
+ workspace?: string;
786
+ reply?: "once" | "always" | "reject";
787
+ message?: string;
788
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionReplyResponses, PermissionReplyErrors, ThrowOnError, "fields">;
789
+ /**
790
+ * Respond to permission
791
+ *
792
+ * Approve or deny a permission request from the AI assistant.
793
+ *
794
+ * @deprecated
795
+ */
796
+ respond<ThrowOnError extends boolean = false>(parameters: {
588
797
  sessionID: string;
798
+ permissionID: string;
589
799
  directory?: string;
590
800
  workspace?: string;
591
- modelID?: string;
592
- providerID?: string;
593
- messageID?: string;
594
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionInitResponses, SessionInitErrors, ThrowOnError, "fields">;
801
+ response?: "once" | "always" | "reject";
802
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionRespondResponses, PermissionRespondErrors, ThrowOnError, "fields">;
803
+ }
804
+ export declare class Oauth extends HeyApiClient {
595
805
  /**
596
- * Fork session
806
+ * Start OAuth authorization
597
807
  *
598
- * Create a new session by forking an existing session at a specific message point.
808
+ * Start the OAuth authorization flow for a provider.
599
809
  */
600
- fork<ThrowOnError extends boolean = false>(parameters: {
810
+ authorize<ThrowOnError extends boolean = false>(parameters: {
811
+ providerID: string;
812
+ directory?: string;
813
+ workspace?: string;
814
+ method?: number;
815
+ inputs?: {
816
+ [key: string]: string;
817
+ };
818
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderOauthAuthorizeResponses, ProviderOauthAuthorizeErrors, ThrowOnError, "fields">;
819
+ /**
820
+ * Handle OAuth callback
821
+ *
822
+ * Handle the OAuth callback from a provider after user authorization.
823
+ */
824
+ callback<ThrowOnError extends boolean = false>(parameters: {
825
+ providerID: string;
826
+ directory?: string;
827
+ workspace?: string;
828
+ method?: number;
829
+ code?: string;
830
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderOauthCallbackResponses, ProviderOauthCallbackErrors, ThrowOnError, "fields">;
831
+ }
832
+ export declare class Provider extends HeyApiClient {
833
+ /**
834
+ * List providers
835
+ *
836
+ * Get a list of all available AI providers, including both available and connected ones.
837
+ */
838
+ list<ThrowOnError extends boolean = false>(parameters?: {
839
+ directory?: string;
840
+ workspace?: string;
841
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderListResponses, unknown, ThrowOnError, "fields">;
842
+ /**
843
+ * Get provider auth methods
844
+ *
845
+ * Retrieve available authentication methods for all AI providers.
846
+ */
847
+ auth<ThrowOnError extends boolean = false>(parameters?: {
848
+ directory?: string;
849
+ workspace?: string;
850
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderAuthResponses, unknown, ThrowOnError, "fields">;
851
+ private _oauth?;
852
+ get oauth(): Oauth;
853
+ }
854
+ export declare class Session2 extends HeyApiClient {
855
+ /**
856
+ * List sessions
857
+ *
858
+ * Get a list of all OpenCode sessions, sorted by most recently updated.
859
+ */
860
+ list<ThrowOnError extends boolean = false>(parameters?: {
861
+ directory?: string;
862
+ workspace?: string;
863
+ scope?: "project";
864
+ path?: string;
865
+ roots?: boolean | "true" | "false";
866
+ start?: number;
867
+ search?: string;
868
+ limit?: number;
869
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionListResponses, unknown, ThrowOnError, "fields">;
870
+ /**
871
+ * Create session
872
+ *
873
+ * Create a new OpenCode session for interacting with AI assistants and managing conversations.
874
+ */
875
+ create<ThrowOnError extends boolean = false>(parameters?: {
876
+ directory?: string;
877
+ workspace?: string;
878
+ parentID?: string;
879
+ title?: string;
880
+ agent?: string;
881
+ model?: {
882
+ id: string;
883
+ providerID: string;
884
+ variant?: string;
885
+ };
886
+ permission?: PermissionRuleset;
887
+ workspaceID?: string;
888
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionCreateResponses, SessionCreateErrors, ThrowOnError, "fields">;
889
+ /**
890
+ * Get session status
891
+ *
892
+ * Retrieve the current status of all sessions, including active, idle, and completed states.
893
+ */
894
+ status<ThrowOnError extends boolean = false>(parameters?: {
895
+ directory?: string;
896
+ workspace?: string;
897
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionStatusResponses, SessionStatusErrors, ThrowOnError, "fields">;
898
+ /**
899
+ * Delete session
900
+ *
901
+ * Delete a session and permanently remove all associated data, including messages and history.
902
+ */
903
+ delete<ThrowOnError extends boolean = false>(parameters: {
601
904
  sessionID: string;
602
905
  directory?: string;
603
906
  workspace?: string;
604
- messageID?: string;
605
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionForkResponses, unknown, ThrowOnError, "fields">;
907
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDeleteResponses, SessionDeleteErrors, ThrowOnError, "fields">;
606
908
  /**
607
- * Abort session
909
+ * Get session
608
910
  *
609
- * Abort an active session and stop any ongoing AI processing or command execution.
911
+ * Retrieve detailed information about a specific OpenCode session.
610
912
  */
611
- abort<ThrowOnError extends boolean = false>(parameters: {
913
+ get<ThrowOnError extends boolean = false>(parameters: {
612
914
  sessionID: string;
613
915
  directory?: string;
614
916
  workspace?: string;
615
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionAbortResponses, SessionAbortErrors, ThrowOnError, "fields">;
917
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionGetResponses, SessionGetErrors, ThrowOnError, "fields">;
616
918
  /**
617
- * Unshare session
919
+ * Update session
618
920
  *
619
- * Remove the shareable link for a session, making it private again.
921
+ * Update properties of an existing session, such as title or other metadata.
620
922
  */
621
- unshare<ThrowOnError extends boolean = false>(parameters: {
923
+ update<ThrowOnError extends boolean = false>(parameters: {
622
924
  sessionID: string;
623
925
  directory?: string;
624
926
  workspace?: string;
625
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUnshareResponses, SessionUnshareErrors, ThrowOnError, "fields">;
927
+ title?: string;
928
+ permission?: PermissionRuleset;
929
+ time?: {
930
+ archived?: number;
931
+ };
932
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUpdateResponses, SessionUpdateErrors, ThrowOnError, "fields">;
626
933
  /**
627
- * Share session
934
+ * Get session children
628
935
  *
629
- * Create a shareable link for a session, allowing others to view the conversation.
936
+ * Retrieve all child sessions that were forked from the specified parent session.
630
937
  */
631
- share<ThrowOnError extends boolean = false>(parameters: {
938
+ children<ThrowOnError extends boolean = false>(parameters: {
632
939
  sessionID: string;
633
940
  directory?: string;
634
941
  workspace?: string;
635
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionShareResponses, SessionShareErrors, ThrowOnError, "fields">;
942
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionChildrenResponses, SessionChildrenErrors, ThrowOnError, "fields">;
636
943
  /**
637
- * Get message diff
944
+ * Get session todos
638
945
  *
639
- * Get the file changes (diff) that resulted from a specific user message in the session.
946
+ * Retrieve the todo list associated with a specific session, showing tasks and action items.
640
947
  */
641
- diff<ThrowOnError extends boolean = false>(parameters: {
948
+ todo<ThrowOnError extends boolean = false>(parameters: {
642
949
  sessionID: string;
643
950
  directory?: string;
644
951
  workspace?: string;
645
- messageID?: string;
646
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDiffResponses, unknown, ThrowOnError, "fields">;
952
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionTodoResponses, SessionTodoErrors, ThrowOnError, "fields">;
647
953
  /**
648
- * Summarize session
954
+ * Get message diff
649
955
  *
650
- * Generate a concise summary of the session using AI compaction to preserve key information.
956
+ * Get the file changes (diff) that resulted from a specific user message in the session.
651
957
  */
652
- summarize<ThrowOnError extends boolean = false>(parameters: {
958
+ diff<ThrowOnError extends boolean = false>(parameters: {
653
959
  sessionID: string;
654
960
  directory?: string;
655
961
  workspace?: string;
656
- providerID?: string;
657
- modelID?: string;
658
- auto?: boolean;
659
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionSummarizeResponses, SessionSummarizeErrors, ThrowOnError, "fields">;
962
+ messageID?: string;
963
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDiffResponses, unknown, ThrowOnError, "fields">;
660
964
  /**
661
965
  * Get session messages
662
966
  *
@@ -694,27 +998,94 @@ export declare class Session2 extends HeyApiClient {
694
998
  parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
695
999
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionPromptResponses, SessionPromptErrors, ThrowOnError, "fields">;
696
1000
  /**
697
- * Delete message
1001
+ * Delete message
1002
+ *
1003
+ * Permanently delete a specific message and all of its parts from a session without reverting file changes.
1004
+ */
1005
+ deleteMessage<ThrowOnError extends boolean = false>(parameters: {
1006
+ sessionID: string;
1007
+ messageID: string;
1008
+ directory?: string;
1009
+ workspace?: string;
1010
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDeleteMessageResponses, SessionDeleteMessageErrors, ThrowOnError, "fields">;
1011
+ /**
1012
+ * Get message
1013
+ *
1014
+ * Retrieve a specific message from a session by its message ID.
1015
+ */
1016
+ message<ThrowOnError extends boolean = false>(parameters: {
1017
+ sessionID: string;
1018
+ messageID: string;
1019
+ directory?: string;
1020
+ workspace?: string;
1021
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionMessageResponses, SessionMessageErrors, ThrowOnError, "fields">;
1022
+ /**
1023
+ * Fork session
1024
+ *
1025
+ * Create a new session by forking an existing session at a specific message point.
1026
+ */
1027
+ fork<ThrowOnError extends boolean = false>(parameters: {
1028
+ sessionID: string;
1029
+ directory?: string;
1030
+ workspace?: string;
1031
+ messageID?: string;
1032
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionForkResponses, unknown, ThrowOnError, "fields">;
1033
+ /**
1034
+ * Abort session
1035
+ *
1036
+ * Abort an active session and stop any ongoing AI processing or command execution.
1037
+ */
1038
+ abort<ThrowOnError extends boolean = false>(parameters: {
1039
+ sessionID: string;
1040
+ directory?: string;
1041
+ workspace?: string;
1042
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionAbortResponses, SessionAbortErrors, ThrowOnError, "fields">;
1043
+ /**
1044
+ * Initialize session
1045
+ *
1046
+ * Analyze the current application and create an AGENTS.md file with project-specific agent configurations.
1047
+ */
1048
+ init<ThrowOnError extends boolean = false>(parameters: {
1049
+ sessionID: string;
1050
+ directory?: string;
1051
+ workspace?: string;
1052
+ modelID?: string;
1053
+ providerID?: string;
1054
+ messageID?: string;
1055
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionInitResponses, SessionInitErrors, ThrowOnError, "fields">;
1056
+ /**
1057
+ * Unshare session
1058
+ *
1059
+ * Remove the shareable link for a session, making it private again.
1060
+ */
1061
+ unshare<ThrowOnError extends boolean = false>(parameters: {
1062
+ sessionID: string;
1063
+ directory?: string;
1064
+ workspace?: string;
1065
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUnshareResponses, SessionUnshareErrors, ThrowOnError, "fields">;
1066
+ /**
1067
+ * Share session
698
1068
  *
699
- * Permanently delete a specific message (and all of its parts) from a session. This does not revert any file changes that may have been made while processing the message.
1069
+ * Create a shareable link for a session, allowing others to view the conversation.
700
1070
  */
701
- deleteMessage<ThrowOnError extends boolean = false>(parameters: {
1071
+ share<ThrowOnError extends boolean = false>(parameters: {
702
1072
  sessionID: string;
703
- messageID: string;
704
1073
  directory?: string;
705
1074
  workspace?: string;
706
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionDeleteMessageResponses, SessionDeleteMessageErrors, ThrowOnError, "fields">;
1075
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionShareResponses, SessionShareErrors, ThrowOnError, "fields">;
707
1076
  /**
708
- * Get message
1077
+ * Summarize session
709
1078
  *
710
- * Retrieve a specific message from a session by its message ID.
1079
+ * Generate a concise summary of the session using AI compaction to preserve key information.
711
1080
  */
712
- message<ThrowOnError extends boolean = false>(parameters: {
1081
+ summarize<ThrowOnError extends boolean = false>(parameters: {
713
1082
  sessionID: string;
714
- messageID: string;
715
1083
  directory?: string;
716
1084
  workspace?: string;
717
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionMessageResponses, SessionMessageErrors, ThrowOnError, "fields">;
1085
+ providerID?: string;
1086
+ modelID?: string;
1087
+ auto?: boolean;
1088
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionSummarizeResponses, SessionSummarizeErrors, ThrowOnError, "fields">;
718
1089
  /**
719
1090
  * Send async message
720
1091
  *
@@ -787,375 +1158,163 @@ export declare class Session2 extends HeyApiClient {
787
1158
  */
788
1159
  revert<ThrowOnError extends boolean = false>(parameters: {
789
1160
  sessionID: string;
790
- directory?: string;
791
- workspace?: string;
792
- messageID?: string;
793
- partID?: string;
794
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionRevertResponses, SessionRevertErrors, ThrowOnError, "fields">;
795
- /**
796
- * Restore reverted messages
797
- *
798
- * Restore all previously reverted messages in a session.
799
- */
800
- unrevert<ThrowOnError extends boolean = false>(parameters: {
801
- sessionID: string;
802
- directory?: string;
803
- workspace?: string;
804
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUnrevertResponses, SessionUnrevertErrors, ThrowOnError, "fields">;
805
- }
806
- export declare class Part extends HeyApiClient {
807
- /**
808
- * Delete a part from a message
809
- */
810
- delete<ThrowOnError extends boolean = false>(parameters: {
811
- sessionID: string;
812
- messageID: string;
813
- partID: string;
814
- directory?: string;
815
- workspace?: string;
816
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PartDeleteResponses, PartDeleteErrors, ThrowOnError, "fields">;
817
- /**
818
- * Update a part in a message
819
- */
820
- update<ThrowOnError extends boolean = false>(parameters: {
821
- sessionID: string;
822
- messageID: string;
823
- partID: string;
824
- directory?: string;
825
- workspace?: string;
826
- part?: Part2;
827
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PartUpdateResponses, PartUpdateErrors, ThrowOnError, "fields">;
828
- }
829
- export declare class Permission extends HeyApiClient {
830
- /**
831
- * Respond to permission
832
- *
833
- * Approve or deny a permission request from the AI assistant.
834
- *
835
- * @deprecated
836
- */
837
- respond<ThrowOnError extends boolean = false>(parameters: {
838
- sessionID: string;
839
- permissionID: string;
840
- directory?: string;
841
- workspace?: string;
842
- response?: "once" | "always" | "reject";
843
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionRespondResponses, PermissionRespondErrors, ThrowOnError, "fields">;
844
- /**
845
- * Respond to permission request
846
- *
847
- * Approve or deny a permission request from the AI assistant.
848
- */
849
- reply<ThrowOnError extends boolean = false>(parameters: {
850
- requestID: string;
851
- directory?: string;
852
- workspace?: string;
853
- reply?: "once" | "always" | "reject";
854
- message?: string;
855
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionReplyResponses, PermissionReplyErrors, ThrowOnError, "fields">;
856
- /**
857
- * List pending permissions
858
- *
859
- * Get all pending permission requests across all sessions.
860
- */
861
- list<ThrowOnError extends boolean = false>(parameters?: {
862
- directory?: string;
863
- workspace?: string;
864
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PermissionListResponses, unknown, ThrowOnError, "fields">;
865
- }
866
- export declare class Question extends HeyApiClient {
867
- /**
868
- * List pending questions
869
- *
870
- * Get all pending question requests across all sessions.
871
- */
872
- list<ThrowOnError extends boolean = false>(parameters?: {
873
- directory?: string;
874
- workspace?: string;
875
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionListResponses, unknown, ThrowOnError, "fields">;
876
- /**
877
- * Reply to question request
878
- *
879
- * Provide answers to a question request from the AI assistant.
880
- */
881
- reply<ThrowOnError extends boolean = false>(parameters: {
882
- requestID: string;
883
- directory?: string;
884
- workspace?: string;
885
- answers?: Array<QuestionAnswer>;
886
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionReplyResponses, QuestionReplyErrors, ThrowOnError, "fields">;
887
- /**
888
- * Reject question request
889
- *
890
- * Reject a question request from the AI assistant.
891
- */
892
- reject<ThrowOnError extends boolean = false>(parameters: {
893
- requestID: string;
894
- directory?: string;
895
- workspace?: string;
896
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<QuestionRejectResponses, QuestionRejectErrors, ThrowOnError, "fields">;
897
- }
898
- export declare class Oauth extends HeyApiClient {
899
- /**
900
- * OAuth authorize
901
- *
902
- * Initiate OAuth authorization for a specific AI provider to get an authorization URL.
903
- */
904
- authorize<ThrowOnError extends boolean = false>(parameters: {
905
- providerID: string;
906
- directory?: string;
907
- workspace?: string;
908
- method?: number;
909
- inputs?: {
910
- [key: string]: string;
911
- };
912
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderOauthAuthorizeResponses, ProviderOauthAuthorizeErrors, ThrowOnError, "fields">;
913
- /**
914
- * OAuth callback
915
- *
916
- * Handle the OAuth callback from a provider after user authorization.
917
- */
918
- callback<ThrowOnError extends boolean = false>(parameters: {
919
- providerID: string;
920
- directory?: string;
921
- workspace?: string;
922
- method?: number;
923
- code?: string;
924
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderOauthCallbackResponses, ProviderOauthCallbackErrors, ThrowOnError, "fields">;
925
- }
926
- export declare class Provider extends HeyApiClient {
927
- /**
928
- * List providers
929
- *
930
- * Get a list of all available AI providers, including both available and connected ones.
931
- */
932
- list<ThrowOnError extends boolean = false>(parameters?: {
933
- directory?: string;
934
- workspace?: string;
935
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderListResponses, unknown, ThrowOnError, "fields">;
936
- /**
937
- * Get provider auth methods
938
- *
939
- * Retrieve available authentication methods for all AI providers.
940
- */
941
- auth<ThrowOnError extends boolean = false>(parameters?: {
942
- directory?: string;
943
- workspace?: string;
944
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ProviderAuthResponses, unknown, ThrowOnError, "fields">;
945
- private _oauth?;
946
- get oauth(): Oauth;
947
- }
948
- export declare class History extends HeyApiClient {
949
- /**
950
- * List sync events
951
- *
952
- * List sync events for all aggregates. Keys are aggregate IDs the client already knows about, values are the last known sequence ID. Events with seq > value are returned for those aggregates. Aggregates not listed in the input get their full history.
953
- */
954
- list<ThrowOnError extends boolean = false>(parameters?: {
955
- directory?: string;
956
- workspace?: string;
957
- body?: {
958
- [key: string]: number;
959
- };
960
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncHistoryListResponses, SyncHistoryListErrors, ThrowOnError, "fields">;
961
- }
962
- export declare class Sync extends HeyApiClient {
963
- /**
964
- * Start workspace sync
965
- *
966
- * Start sync loops for workspaces in the current project that have active sessions.
967
- */
968
- start<ThrowOnError extends boolean = false>(parameters?: {
969
- directory?: string;
970
- workspace?: string;
971
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncStartResponses, unknown, ThrowOnError, "fields">;
972
- /**
973
- * Replay sync events
974
- *
975
- * Validate and replay a complete sync event history.
976
- */
977
- replay<ThrowOnError extends boolean = false>(parameters?: {
978
- query_directory?: string;
979
- workspace?: string;
980
- body_directory?: string;
981
- events?: Array<{
982
- id: string;
983
- aggregateID: string;
984
- seq: number;
985
- type: string;
986
- data: {
987
- [key: string]: unknown;
988
- };
989
- }>;
990
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncReplayResponses, SyncReplayErrors, ThrowOnError, "fields">;
991
- private _history?;
992
- get history(): History;
993
- }
994
- export declare class Find extends HeyApiClient {
995
- /**
996
- * Find text
997
- *
998
- * Search for text patterns across files in the project using ripgrep.
999
- */
1000
- text<ThrowOnError extends boolean = false>(parameters: {
1001
- directory?: string;
1002
- workspace?: string;
1003
- pattern: string;
1004
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindTextResponses, unknown, ThrowOnError, "fields">;
1005
- /**
1006
- * Find files
1007
- *
1008
- * Search for files or directories by name or pattern in the project directory.
1009
- */
1010
- files<ThrowOnError extends boolean = false>(parameters: {
1011
- directory?: string;
1012
- workspace?: string;
1013
- query: string;
1014
- dirs?: "true" | "false";
1015
- type?: "file" | "directory";
1016
- limit?: number;
1017
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindFilesResponses, unknown, ThrowOnError, "fields">;
1018
- /**
1019
- * Find symbols
1020
- *
1021
- * Search for workspace symbols like functions, classes, and variables using LSP.
1022
- */
1023
- symbols<ThrowOnError extends boolean = false>(parameters: {
1024
- directory?: string;
1025
- workspace?: string;
1026
- query: string;
1027
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FindSymbolsResponses, unknown, ThrowOnError, "fields">;
1028
- }
1029
- export declare class File extends HeyApiClient {
1161
+ directory?: string;
1162
+ workspace?: string;
1163
+ messageID?: string;
1164
+ partID?: string;
1165
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionRevertResponses, SessionRevertErrors, ThrowOnError, "fields">;
1030
1166
  /**
1031
- * List files
1167
+ * Restore reverted messages
1032
1168
  *
1033
- * List files and directories in a specified path.
1169
+ * Restore all previously reverted messages in a session.
1034
1170
  */
1035
- list<ThrowOnError extends boolean = false>(parameters: {
1171
+ unrevert<ThrowOnError extends boolean = false>(parameters: {
1172
+ sessionID: string;
1036
1173
  directory?: string;
1037
1174
  workspace?: string;
1038
- path: string;
1039
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileListResponses, unknown, ThrowOnError, "fields">;
1175
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionUnrevertResponses, SessionUnrevertErrors, ThrowOnError, "fields">;
1176
+ }
1177
+ export declare class Part extends HeyApiClient {
1040
1178
  /**
1041
- * Read file
1042
- *
1043
- * Read the content of a specified file.
1179
+ * Delete a part from a message.
1044
1180
  */
1045
- read<ThrowOnError extends boolean = false>(parameters: {
1181
+ delete<ThrowOnError extends boolean = false>(parameters: {
1182
+ sessionID: string;
1183
+ messageID: string;
1184
+ partID: string;
1046
1185
  directory?: string;
1047
1186
  workspace?: string;
1048
- path: string;
1049
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileReadResponses, unknown, ThrowOnError, "fields">;
1187
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PartDeleteResponses, PartDeleteErrors, ThrowOnError, "fields">;
1050
1188
  /**
1051
- * Get file status
1052
- *
1053
- * Get the git status of all files in the project.
1189
+ * Update a part in a message.
1054
1190
  */
1055
- status<ThrowOnError extends boolean = false>(parameters?: {
1191
+ update<ThrowOnError extends boolean = false>(parameters: {
1192
+ sessionID: string;
1193
+ messageID: string;
1194
+ partID: string;
1056
1195
  directory?: string;
1057
1196
  workspace?: string;
1058
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FileStatusResponses, unknown, ThrowOnError, "fields">;
1197
+ part?: Part2;
1198
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PartUpdateResponses, PartUpdateErrors, ThrowOnError, "fields">;
1059
1199
  }
1060
- export declare class Event extends HeyApiClient {
1200
+ export declare class History extends HeyApiClient {
1061
1201
  /**
1062
- * Subscribe to events
1202
+ * List sync events
1063
1203
  *
1064
- * Get events
1204
+ * List sync events for all aggregates. Keys are aggregate IDs the client already knows about, values are the last known sequence ID. Events with seq > value are returned for those aggregates. Aggregates not listed in the input get their full history.
1065
1205
  */
1066
- subscribe<ThrowOnError extends boolean = false>(parameters?: {
1206
+ list<ThrowOnError extends boolean = false>(parameters?: {
1067
1207
  directory?: string;
1068
1208
  workspace?: string;
1069
- }, options?: Options<never, ThrowOnError>): Promise<import("./core/serverSentEvents.gen.js").ServerSentEventsResult<EventSubscribeResponses, unknown>>;
1209
+ body?: {
1210
+ [key: string]: number;
1211
+ };
1212
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncHistoryListResponses, SyncHistoryListErrors, ThrowOnError, "fields">;
1070
1213
  }
1071
- export declare class Auth2 extends HeyApiClient {
1214
+ export declare class Sync extends HeyApiClient {
1072
1215
  /**
1073
- * Remove MCP OAuth
1216
+ * Start workspace sync
1074
1217
  *
1075
- * Remove OAuth credentials for an MCP server
1218
+ * Start sync loops for workspaces in the current project that have active sessions.
1076
1219
  */
1077
- remove<ThrowOnError extends boolean = false>(parameters: {
1078
- name: string;
1220
+ start<ThrowOnError extends boolean = false>(parameters?: {
1079
1221
  directory?: string;
1080
1222
  workspace?: string;
1081
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthRemoveResponses, McpAuthRemoveErrors, ThrowOnError, "fields">;
1223
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncStartResponses, unknown, ThrowOnError, "fields">;
1082
1224
  /**
1083
- * Start MCP OAuth
1225
+ * Replay sync events
1084
1226
  *
1085
- * Start OAuth authentication flow for a Model Context Protocol (MCP) server.
1227
+ * Validate and replay a complete sync event history.
1086
1228
  */
1087
- start<ThrowOnError extends boolean = false>(parameters: {
1088
- name: string;
1089
- directory?: string;
1229
+ replay<ThrowOnError extends boolean = false>(parameters?: {
1230
+ query_directory?: string;
1090
1231
  workspace?: string;
1091
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthStartResponses, McpAuthStartErrors, ThrowOnError, "fields">;
1232
+ body_directory?: string;
1233
+ events?: Array<{
1234
+ id: string;
1235
+ aggregateID: string;
1236
+ seq: number;
1237
+ type: string;
1238
+ data: {
1239
+ [key: string]: unknown;
1240
+ };
1241
+ }>;
1242
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SyncReplayResponses, SyncReplayErrors, ThrowOnError, "fields">;
1243
+ private _history?;
1244
+ get history(): History;
1245
+ }
1246
+ export declare class Session3 extends HeyApiClient {
1092
1247
  /**
1093
- * Complete MCP OAuth
1248
+ * List v2 sessions
1094
1249
  *
1095
- * Complete OAuth authentication for a Model Context Protocol (MCP) server using the authorization code.
1250
+ * Retrieve sessions in the requested order. Items keep that order across pages; use cursor.next or cursor.previous to move through the ordered list.
1096
1251
  */
1097
- callback<ThrowOnError extends boolean = false>(parameters: {
1098
- name: string;
1252
+ list<ThrowOnError extends boolean = false>(parameters?: {
1099
1253
  directory?: string;
1100
1254
  workspace?: string;
1101
- code?: string;
1102
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthCallbackResponses, McpAuthCallbackErrors, ThrowOnError, "fields">;
1255
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionListResponses, V2SessionListErrors, ThrowOnError, "fields">;
1103
1256
  /**
1104
- * Authenticate MCP OAuth
1257
+ * Send v2 message
1105
1258
  *
1106
- * Start OAuth flow and wait for callback (opens browser)
1259
+ * Create a v2 session message and queue it for the agent loop.
1107
1260
  */
1108
- authenticate<ThrowOnError extends boolean = false>(parameters: {
1109
- name: string;
1261
+ prompt<ThrowOnError extends boolean = false>(parameters: {
1262
+ sessionID: string;
1110
1263
  directory?: string;
1111
1264
  workspace?: string;
1112
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAuthAuthenticateResponses, McpAuthAuthenticateErrors, ThrowOnError, "fields">;
1113
- }
1114
- export declare class Mcp extends HeyApiClient {
1265
+ prompt?: Prompt;
1266
+ delivery?: SessionDelivery;
1267
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionPromptResponses, unknown, ThrowOnError, "fields">;
1115
1268
  /**
1116
- * Get MCP status
1269
+ * Compact v2 session
1117
1270
  *
1118
- * Get the status of all Model Context Protocol (MCP) servers.
1271
+ * Compact a v2 session conversation.
1119
1272
  */
1120
- status<ThrowOnError extends boolean = false>(parameters?: {
1273
+ compact<ThrowOnError extends boolean = false>(parameters: {
1274
+ sessionID: string;
1121
1275
  directory?: string;
1122
1276
  workspace?: string;
1123
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpStatusResponses, unknown, ThrowOnError, "fields">;
1277
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionCompactResponses, unknown, ThrowOnError, "fields">;
1124
1278
  /**
1125
- * Add MCP server
1279
+ * Wait for v2 session
1126
1280
  *
1127
- * Dynamically add a new Model Context Protocol (MCP) server to the system.
1281
+ * Wait for a v2 session agent loop to become idle.
1128
1282
  */
1129
- add<ThrowOnError extends boolean = false>(parameters?: {
1283
+ wait<ThrowOnError extends boolean = false>(parameters: {
1284
+ sessionID: string;
1130
1285
  directory?: string;
1131
1286
  workspace?: string;
1132
- name?: string;
1133
- config?: McpLocalConfig | McpRemoteConfig;
1134
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpAddResponses, McpAddErrors, ThrowOnError, "fields">;
1287
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionWaitResponses, unknown, ThrowOnError, "fields">;
1135
1288
  /**
1136
- * Connect an MCP server
1289
+ * Get v2 session context
1290
+ *
1291
+ * Retrieve the active context messages for a v2 session (all messages after the last compaction).
1137
1292
  */
1138
- connect<ThrowOnError extends boolean = false>(parameters: {
1139
- name: string;
1293
+ context<ThrowOnError extends boolean = false>(parameters: {
1294
+ sessionID: string;
1140
1295
  directory?: string;
1141
1296
  workspace?: string;
1142
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpConnectResponses, unknown, ThrowOnError, "fields">;
1297
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionContextResponses, unknown, ThrowOnError, "fields">;
1143
1298
  /**
1144
- * Disconnect an MCP server
1299
+ * Get v2 session messages
1300
+ *
1301
+ * 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.
1145
1302
  */
1146
- disconnect<ThrowOnError extends boolean = false>(parameters: {
1147
- name: string;
1303
+ messages<ThrowOnError extends boolean = false>(parameters: {
1304
+ sessionID: string;
1148
1305
  directory?: string;
1149
1306
  workspace?: string;
1150
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<McpDisconnectResponses, unknown, ThrowOnError, "fields">;
1151
- private _auth?;
1152
- get auth(): Auth2;
1307
+ }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<V2SessionMessagesResponses, V2SessionMessagesErrors, ThrowOnError, "fields">;
1308
+ }
1309
+ export declare class V2 extends HeyApiClient {
1310
+ private _session?;
1311
+ get session(): Session3;
1153
1312
  }
1154
1313
  export declare class Control extends HeyApiClient {
1155
1314
  /**
1156
1315
  * Get next TUI request
1157
1316
  *
1158
- * Retrieve the next TUI (Terminal User Interface) request from the queue for processing.
1317
+ * Retrieve the next TUI request from the queue for processing.
1159
1318
  */
1160
1319
  next<ThrowOnError extends boolean = false>(parameters?: {
1161
1320
  directory?: string;
@@ -1176,7 +1335,7 @@ export declare class Tui extends HeyApiClient {
1176
1335
  /**
1177
1336
  * Append TUI prompt
1178
1337
  *
1179
- * Append prompt to the TUI
1338
+ * Append prompt to the TUI.
1180
1339
  */
1181
1340
  appendPrompt<ThrowOnError extends boolean = false>(parameters?: {
1182
1341
  directory?: string;
@@ -1195,7 +1354,7 @@ export declare class Tui extends HeyApiClient {
1195
1354
  /**
1196
1355
  * Open sessions dialog
1197
1356
  *
1198
- * Open the session dialog
1357
+ * Open the session dialog.
1199
1358
  */
1200
1359
  openSessions<ThrowOnError extends boolean = false>(parameters?: {
1201
1360
  directory?: string;
@@ -1204,7 +1363,7 @@ export declare class Tui extends HeyApiClient {
1204
1363
  /**
1205
1364
  * Open themes dialog
1206
1365
  *
1207
- * Open the theme dialog
1366
+ * Open the theme dialog.
1208
1367
  */
1209
1368
  openThemes<ThrowOnError extends boolean = false>(parameters?: {
1210
1369
  directory?: string;
@@ -1213,7 +1372,7 @@ export declare class Tui extends HeyApiClient {
1213
1372
  /**
1214
1373
  * Open models dialog
1215
1374
  *
1216
- * Open the model dialog
1375
+ * Open the model dialog.
1217
1376
  */
1218
1377
  openModels<ThrowOnError extends boolean = false>(parameters?: {
1219
1378
  directory?: string;
@@ -1222,7 +1381,7 @@ export declare class Tui extends HeyApiClient {
1222
1381
  /**
1223
1382
  * Submit TUI prompt
1224
1383
  *
1225
- * Submit the prompt
1384
+ * Submit the prompt.
1226
1385
  */
1227
1386
  submitPrompt<ThrowOnError extends boolean = false>(parameters?: {
1228
1387
  directory?: string;
@@ -1231,7 +1390,7 @@ export declare class Tui extends HeyApiClient {
1231
1390
  /**
1232
1391
  * Clear TUI prompt
1233
1392
  *
1234
- * Clear the prompt
1393
+ * Clear the prompt.
1235
1394
  */
1236
1395
  clearPrompt<ThrowOnError extends boolean = false>(parameters?: {
1237
1396
  directory?: string;
@@ -1240,7 +1399,7 @@ export declare class Tui extends HeyApiClient {
1240
1399
  /**
1241
1400
  * Execute TUI command
1242
1401
  *
1243
- * Execute a TUI command (e.g. agent_cycle)
1402
+ * Execute a TUI command.
1244
1403
  */
1245
1404
  executeCommand<ThrowOnError extends boolean = false>(parameters?: {
1246
1405
  directory?: string;
@@ -1250,7 +1409,7 @@ export declare class Tui extends HeyApiClient {
1250
1409
  /**
1251
1410
  * Show TUI toast
1252
1411
  *
1253
- * Show a toast notification in the TUI
1412
+ * Show a toast notification in the TUI.
1254
1413
  */
1255
1414
  showToast<ThrowOnError extends boolean = false>(parameters?: {
1256
1415
  directory?: string;
@@ -1263,12 +1422,12 @@ export declare class Tui extends HeyApiClient {
1263
1422
  /**
1264
1423
  * Publish TUI event
1265
1424
  *
1266
- * Publish a TUI event
1425
+ * Publish a TUI event.
1267
1426
  */
1268
1427
  publish<ThrowOnError extends boolean = false>(parameters?: {
1269
1428
  directory?: string;
1270
1429
  workspace?: string;
1271
- body?: EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect;
1430
+ body?: EventTuiPromptAppend2 | EventTuiCommandExecute2 | EventTuiToastShow2 | EventTuiSessionSelect2;
1272
1431
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<TuiPublishResponses, TuiPublishErrors, ThrowOnError, "fields">;
1273
1432
  /**
1274
1433
  * Select session
@@ -1283,128 +1442,32 @@ export declare class Tui extends HeyApiClient {
1283
1442
  private _control?;
1284
1443
  get control(): Control;
1285
1444
  }
1286
- export declare class Instance extends HeyApiClient {
1287
- /**
1288
- * Dispose instance
1289
- *
1290
- * Clean up and dispose the current OpenCode instance, releasing all resources.
1291
- */
1292
- dispose<ThrowOnError extends boolean = false>(parameters?: {
1293
- directory?: string;
1294
- workspace?: string;
1295
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<InstanceDisposeResponses, unknown, ThrowOnError, "fields">;
1296
- }
1297
- export declare class Path extends HeyApiClient {
1298
- /**
1299
- * Get paths
1300
- *
1301
- * Retrieve the current working directory and related path information for the OpenCode instance.
1302
- */
1303
- get<ThrowOnError extends boolean = false>(parameters?: {
1304
- directory?: string;
1305
- workspace?: string;
1306
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<PathGetResponses, unknown, ThrowOnError, "fields">;
1307
- }
1308
- export declare class Vcs extends HeyApiClient {
1309
- /**
1310
- * Get VCS info
1311
- *
1312
- * Retrieve version control system (VCS) information for the current project, such as git branch.
1313
- */
1314
- get<ThrowOnError extends boolean = false>(parameters?: {
1315
- directory?: string;
1316
- workspace?: string;
1317
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<VcsGetResponses, unknown, ThrowOnError, "fields">;
1318
- /**
1319
- * Get VCS diff
1320
- *
1321
- * Retrieve the current git diff for the working tree or against the default branch.
1322
- */
1323
- diff<ThrowOnError extends boolean = false>(parameters: {
1324
- directory?: string;
1325
- workspace?: string;
1326
- mode: "git" | "branch";
1327
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<VcsDiffResponses, unknown, ThrowOnError, "fields">;
1328
- }
1329
- export declare class Command extends HeyApiClient {
1330
- /**
1331
- * List commands
1332
- *
1333
- * Get a list of all available commands in the OpenCode system.
1334
- */
1335
- list<ThrowOnError extends boolean = false>(parameters?: {
1336
- directory?: string;
1337
- workspace?: string;
1338
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<CommandListResponses, unknown, ThrowOnError, "fields">;
1339
- }
1340
- export declare class Lsp extends HeyApiClient {
1341
- /**
1342
- * Get LSP status
1343
- *
1344
- * Get LSP server status
1345
- */
1346
- status<ThrowOnError extends boolean = false>(parameters?: {
1347
- directory?: string;
1348
- workspace?: string;
1349
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<LspStatusResponses, unknown, ThrowOnError, "fields">;
1350
- }
1351
- export declare class Formatter extends HeyApiClient {
1352
- /**
1353
- * Get formatter status
1354
- *
1355
- * Get formatter status
1356
- */
1357
- status<ThrowOnError extends boolean = false>(parameters?: {
1358
- directory?: string;
1359
- workspace?: string;
1360
- }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<FormatterStatusResponses, unknown, ThrowOnError, "fields">;
1361
- }
1362
1445
  export declare class OpencodeClient extends HeyApiClient {
1363
1446
  static readonly __registry: HeyApiRegistry<OpencodeClient>;
1364
1447
  constructor(args?: {
1365
1448
  client?: Client;
1366
1449
  key?: string;
1367
1450
  });
1368
- private _global?;
1369
- get global(): Global;
1370
1451
  private _auth?;
1371
1452
  get auth(): Auth;
1372
1453
  private _app?;
1373
1454
  get app(): App;
1374
- private _experimental?;
1375
- get experimental(): Experimental;
1376
- private _project?;
1377
- get project(): Project;
1378
- private _pty?;
1379
- get pty(): Pty;
1455
+ private _global?;
1456
+ get global(): Global;
1457
+ private _event?;
1458
+ get event(): Event;
1380
1459
  private _config?;
1381
1460
  get config(): Config2;
1461
+ private _experimental?;
1462
+ get experimental(): Experimental;
1382
1463
  private _tool?;
1383
1464
  get tool(): Tool;
1384
1465
  private _worktree?;
1385
1466
  get worktree(): Worktree;
1386
- private _session?;
1387
- get session(): Session2;
1388
- private _part?;
1389
- get part(): Part;
1390
- private _permission?;
1391
- get permission(): Permission;
1392
- private _question?;
1393
- get question(): Question;
1394
- private _provider?;
1395
- get provider(): Provider;
1396
- private _sync?;
1397
- get sync(): Sync;
1398
1467
  private _find?;
1399
1468
  get find(): Find;
1400
1469
  private _file?;
1401
1470
  get file(): File;
1402
- private _event?;
1403
- get event(): Event;
1404
- private _mcp?;
1405
- get mcp(): Mcp;
1406
- private _tui?;
1407
- get tui(): Tui;
1408
1471
  private _instance?;
1409
1472
  get instance(): Instance;
1410
1473
  private _path?;
@@ -1417,5 +1480,27 @@ export declare class OpencodeClient extends HeyApiClient {
1417
1480
  get lsp(): Lsp;
1418
1481
  private _formatter?;
1419
1482
  get formatter(): Formatter;
1483
+ private _mcp?;
1484
+ get mcp(): Mcp;
1485
+ private _project?;
1486
+ get project(): Project;
1487
+ private _pty?;
1488
+ get pty(): Pty;
1489
+ private _question?;
1490
+ get question(): Question;
1491
+ private _permission?;
1492
+ get permission(): Permission;
1493
+ private _provider?;
1494
+ get provider(): Provider;
1495
+ private _session?;
1496
+ get session(): Session2;
1497
+ private _part?;
1498
+ get part(): Part;
1499
+ private _sync?;
1500
+ get sync(): Sync;
1501
+ private _v2?;
1502
+ get v2(): V2;
1503
+ private _tui?;
1504
+ get tui(): Tui;
1420
1505
  }
1421
1506
  export {};