release: v0.4.6

This commit is contained in:
opencode 2025-08-11 01:59:27 +00:00
parent 70db372466
commit 55c294c013
10 changed files with 42 additions and 38 deletions

View file

@ -1,7 +1,7 @@
{
"$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/sdk",
"version": "0.4.3",
"version": "0.4.6",
"type": "module",
"scripts": {
"typecheck": "tsc --noEmit"

View file

@ -22,15 +22,18 @@ 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)
@ -43,9 +46,6 @@ export type Event =
| ({
type: "session.error"
} & EventSessionError)
| ({
type: "server.connected"
} & EventServerConnected)
| ({
type: "file.watcher.updated"
} & EventFileWatcherUpdated)
@ -425,6 +425,20 @@ 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
@ -455,13 +469,6 @@ export type EventPermissionReplied = {
}
}
export type EventFileEdited = {
type: string
properties: {
file: string
}
}
export type EventSessionUpdated = {
type: string
properties: {
@ -523,13 +530,6 @@ export type EventSessionError = {
}
}
export type EventServerConnected = {
type: string
properties: {
[key: string]: unknown
}
}
export type EventFileWatcherUpdated = {
type: string
properties: {
@ -907,13 +907,17 @@ 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
[key: string]:
| unknown
| string
| number
| {
[key: string]: boolean
}
| boolean
| string
| undefined
}
export type Provider = {
@ -1053,9 +1057,6 @@ export type Agent = {
mode: string
topP?: number
temperature?: number
options: {
[key: string]: unknown
}
model?: {
modelID: string
providerID: string
@ -1064,6 +1065,9 @@ export type Agent = {
tools: {
[key: string]: boolean
}
options: {
[key: string]: unknown
}
}
export type EventSubscribeData = {