diff options
| author | opencode <[email protected]> | 2025-08-11 00:53:06 +0000 |
|---|---|---|
| committer | opencode <[email protected]> | 2025-08-11 00:53:06 +0000 |
| commit | 95e410db88769f0cfdf64aeee9ec2ea3c42d11bc (patch) | |
| tree | 46ec6f3080dc6c972c1ea34661ba7eacfebf85e5 /packages/sdk/js | |
| parent | 13d3fba86bfe7c582df9297fa0a941d56aeb6a61 (diff) | |
| download | opencode-95e410db88769f0cfdf64aeee9ec2ea3c42d11bc.tar.gz opencode-95e410db88769f0cfdf64aeee9ec2ea3c42d11bc.zip | |
release: v0.4.3
Diffstat (limited to 'packages/sdk/js')
| -rw-r--r-- | packages/sdk/js/package.json | 2 | ||||
| -rw-r--r-- | packages/sdk/js/src/gen/types.gen.ts | 68 |
2 files changed, 49 insertions, 21 deletions
diff --git a/packages/sdk/js/package.json b/packages/sdk/js/package.json index 1a11d9ccd..fd4d1df80 100644 --- a/packages/sdk/js/package.json +++ b/packages/sdk/js/package.json @@ -1,7 +1,7 @@ { "$schema": "https://json.schemastore.org/package.json", "name": "@opencode-ai/sdk", - "version": "0.4.1", + "version": "0.4.3", "type": "module", "scripts": { "typecheck": "tsc --noEmit" diff --git a/packages/sdk/js/src/gen/types.gen.ts b/packages/sdk/js/src/gen/types.gen.ts index 3a97c2835..31917e4ca 100644 --- a/packages/sdk/js/src/gen/types.gen.ts +++ b/packages/sdk/js/src/gen/types.gen.ts @@ -23,18 +23,15 @@ export type Event = type: "storage.write" } & EventStorageWrite) | ({ - type: "file.edited" - } & EventFileEdited) - | ({ - type: "server.connected" - } & EventServerConnected) - | ({ type: "permission.updated" } & EventPermissionUpdated) | ({ type: "permission.replied" } & EventPermissionReplied) | ({ + type: "file.edited" + } & EventFileEdited) + | ({ type: "session.updated" } & EventSessionUpdated) | ({ @@ -47,6 +44,9 @@ export type Event = type: "session.error" } & EventSessionError) | ({ + type: "server.connected" + } & EventServerConnected) + | ({ type: "file.watcher.updated" } & EventFileWatcherUpdated) | ({ @@ -183,6 +183,9 @@ export type Part = type: "text" } & TextPart) | ({ + type: "reasoning" + } & ReasoningPart) + | ({ type: "file" } & FilePart) | ({ @@ -217,6 +220,21 @@ export type TextPart = { } } +export type ReasoningPart = { + id: string + sessionID: string + messageID: string + type: string + text: string + metadata?: { + [key: string]: unknown + } + time: { + start: number + end?: number + } +} + export type FilePart = { id: string sessionID: string @@ -407,20 +425,6 @@ export type EventStorageWrite = { } } -export type EventFileEdited = { - type: string - properties: { - file: string - } -} - -export type EventServerConnected = { - type: string - properties: { - [key: string]: unknown - } -} - export type EventPermissionUpdated = { type: string properties: Permission @@ -451,6 +455,13 @@ export type EventPermissionReplied = { } } +export type EventFileEdited = { + type: string + properties: { + file: string + } +} + export type EventSessionUpdated = { type: string properties: { @@ -512,6 +523,13 @@ export type EventSessionError = { } } +export type EventServerConnected = { + type: string + properties: { + [key: string]: unknown + } +} + export type EventFileWatcherUpdated = { type: string properties: { @@ -691,6 +709,7 @@ export type Config = { | { [key: string]: string } + webfetch?: string } experimental?: { hook?: { @@ -888,6 +907,12 @@ export type AgentConfig = { * Description of when to use the agent */ description?: string + /** + * Additional model options passed through to provider + */ + options?: { + [key: string]: unknown + } mode?: string } @@ -1028,6 +1053,9 @@ export type Agent = { mode: string topP?: number temperature?: number + options: { + [key: string]: unknown + } model?: { modelID: string providerID: string |
