Merge branch 'dev' into feature/session-handoff

This commit is contained in:
Adam 2026-02-12 06:10:30 -06:00 committed by GitHub
commit 89ca7986bf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
576 changed files with 15054 additions and 11725 deletions

View file

@ -1,7 +1,7 @@
{
"$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/sdk",
"version": "1.1.59",
"version": "1.1.60",
"type": "module",
"license": "MIT",
"scripts": {

View file

@ -57,6 +57,7 @@ import type {
McpLocalConfig,
McpRemoteConfig,
McpStatusResponses,
OutputFormat,
Part as Part2,
PartDeleteErrors,
PartDeleteResponses,
@ -1475,6 +1476,7 @@ export class Session extends HeyApiClient {
tools?: {
[key: string]: boolean
}
format?: OutputFormat
system?: string
variant?: string
parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>
@ -1493,6 +1495,7 @@ export class Session extends HeyApiClient {
{ in: "body", key: "agent" },
{ in: "body", key: "noReply" },
{ in: "body", key: "tools" },
{ in: "body", key: "format" },
{ in: "body", key: "system" },
{ in: "body", key: "variant" },
{ in: "body", key: "parts" },
@ -1563,6 +1566,7 @@ export class Session extends HeyApiClient {
tools?: {
[key: string]: boolean
}
format?: OutputFormat
system?: string
variant?: string
parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>
@ -1581,6 +1585,7 @@ export class Session extends HeyApiClient {
{ in: "body", key: "agent" },
{ in: "body", key: "noReply" },
{ in: "body", key: "tools" },
{ in: "body", key: "format" },
{ in: "body", key: "system" },
{ in: "body", key: "variant" },
{ in: "body", key: "parts" },

View file

@ -90,6 +90,22 @@ export type EventFileEdited = {
}
}
export type OutputFormatText = {
type: "text"
}
export type JsonSchema = {
[key: string]: unknown
}
export type OutputFormatJsonSchema = {
type: "json_schema"
schema: JsonSchema
retryCount?: number
}
export type OutputFormat = OutputFormatText | OutputFormatJsonSchema
export type FileDiff = {
file: string
before: string
@ -106,6 +122,7 @@ export type UserMessage = {
time: {
created: number
}
format?: OutputFormat
summary?: {
title?: string
body?: string
@ -152,6 +169,14 @@ export type MessageAbortedError = {
}
}
export type StructuredOutputError = {
name: "StructuredOutputError"
data: {
message: string
retries: number
}
}
export type ContextOverflowError = {
name: "ContextOverflowError"
data: {
@ -189,6 +214,7 @@ export type AssistantMessage = {
| UnknownError
| MessageOutputLengthError
| MessageAbortedError
| StructuredOutputError
| ContextOverflowError
| ApiError
parentID: string
@ -212,6 +238,7 @@ export type AssistantMessage = {
write: number
}
}
structured?: unknown
variant?: string
finish?: string
}
@ -841,6 +868,7 @@ export type EventSessionError = {
| UnknownError
| MessageOutputLengthError
| MessageAbortedError
| StructuredOutputError
| ContextOverflowError
| ApiError
}
@ -1521,6 +1549,7 @@ export type ProviderConfig = {
}
provider?: {
npm: string
api: string
}
/**
* Variant-specific configuration
@ -3402,6 +3431,7 @@ export type SessionPromptData = {
tools?: {
[key: string]: boolean
}
format?: OutputFormat
system?: string
variant?: string
parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>
@ -3589,6 +3619,7 @@ export type SessionPromptAsyncData = {
tools?: {
[key: string]: boolean
}
format?: OutputFormat
system?: string
variant?: string
parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>
@ -4083,6 +4114,7 @@ export type ProviderListResponses = {
}
provider?: {
npm: string
api: string
}
variants?: {
[key: string]: {

View file

@ -2420,6 +2420,9 @@
"type": "boolean"
}
},
"format": {
"$ref": "#/components/schemas/OutputFormat"
},
"system": {
"type": "string"
},
@ -2796,6 +2799,9 @@
"type": "boolean"
}
},
"format": {
"$ref": "#/components/schemas/OutputFormat"
},
"system": {
"type": "string"
},
@ -3892,9 +3898,12 @@
"properties": {
"npm": {
"type": "string"
},
"api": {
"type": "string"
}
},
"required": ["npm"]
"required": ["npm", "api"]
},
"variants": {
"type": "object",
@ -6172,6 +6181,52 @@
},
"required": ["type", "properties"]
},
"OutputFormatText": {
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "text"
}
},
"required": ["type"]
},
"JSONSchema": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
},
"OutputFormatJsonSchema": {
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "json_schema"
},
"schema": {
"$ref": "#/components/schemas/JSONSchema"
},
"retryCount": {
"default": 2,
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": ["type", "schema"]
},
"OutputFormat": {
"anyOf": [
{
"$ref": "#/components/schemas/OutputFormatText"
},
{
"$ref": "#/components/schemas/OutputFormatJsonSchema"
}
]
},
"FileDiff": {
"type": "object",
"properties": {
@ -6219,6 +6274,9 @@
},
"required": ["created"]
},
"format": {
"$ref": "#/components/schemas/OutputFormat"
},
"summary": {
"type": "object",
"properties": {
@ -6344,6 +6402,28 @@
},
"required": ["name", "data"]
},
"StructuredOutputError": {
"type": "object",
"properties": {
"name": {
"type": "string",
"const": "StructuredOutputError"
},
"data": {
"type": "object",
"properties": {
"message": {
"type": "string"
},
"retries": {
"type": "number"
}
},
"required": ["message", "retries"]
}
},
"required": ["name", "data"]
},
"ContextOverflowError": {
"type": "object",
"properties": {
@ -6451,6 +6531,9 @@
{
"$ref": "#/components/schemas/MessageAbortedError"
},
{
"$ref": "#/components/schemas/StructuredOutputError"
},
{
"$ref": "#/components/schemas/ContextOverflowError"
},
@ -6522,6 +6605,7 @@
},
"required": ["input", "output", "reasoning", "cache"]
},
"structured": {},
"variant": {
"type": "string"
},
@ -8227,6 +8311,9 @@
{
"$ref": "#/components/schemas/MessageAbortedError"
},
{
"$ref": "#/components/schemas/StructuredOutputError"
},
{
"$ref": "#/components/schemas/ContextOverflowError"
},
@ -9416,9 +9503,12 @@
"properties": {
"npm": {
"type": "string"
},
"api": {
"type": "string"
}
},
"required": ["npm"]
"required": ["npm", "api"]
},
"variants": {
"description": "Variant-specific configuration",