summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authoropencode-agent[bot] <opencode-agent[bot]@users.noreply.github.com>2026-04-09 20:29:48 +0000
committeropencode-agent[bot] <opencode-agent[bot]@users.noreply.github.com>2026-04-09 20:29:48 +0000
commitbbe4a04f9fcba9e46eb1baf5e7152b22465808d5 (patch)
tree539c8cfcab4dcc91ff11a16da7ab37d43a7e6c28
parentb2f621b897ca636dc720b035072555e03c0da30a (diff)
downloadopencode-bbe4a04f9fcba9e46eb1baf5e7152b22465808d5.tar.gz
opencode-bbe4a04f9fcba9e46eb1baf5e7152b22465808d5.zip
chore: generate
-rw-r--r--packages/sdk/js/src/v2/gen/types.gen.ts378
-rw-r--r--packages/sdk/openapi.json794
2 files changed, 586 insertions, 586 deletions
diff --git a/packages/sdk/js/src/v2/gen/types.gen.ts b/packages/sdk/js/src/v2/gen/types.gen.ts
index 3d1495995..62c62e138 100644
--- a/packages/sdk/js/src/v2/gen/types.gen.ts
+++ b/packages/sdk/js/src/v2/gen/types.gen.ts
@@ -94,35 +94,6 @@ export type EventMessagePartDelta = {
}
}
-export type SessionStatus =
- | {
- type: "idle"
- }
- | {
- type: "retry"
- attempt: number
- message: string
- next: number
- }
- | {
- type: "busy"
- }
-
-export type EventSessionStatus = {
- type: "session.status"
- properties: {
- sessionID: string
- status: SessionStatus
- }
-}
-
-export type EventSessionIdle = {
- type: "session.idle"
- properties: {
- sessionID: string
- }
-}
-
export type PermissionRequest = {
id: string
sessionID: string
@@ -152,81 +123,95 @@ export type EventPermissionReplied = {
}
}
-export type QuestionOption = {
- /**
- * Display text (1-5 words, concise)
- */
- label: string
- /**
- * Explanation of choice
- */
- description: string
+export type SnapshotFileDiff = {
+ file: string
+ patch: string
+ additions: number
+ deletions: number
+ status?: "added" | "deleted" | "modified"
}
-export type QuestionInfo = {
- /**
- * Complete question
- */
- question: string
- /**
- * Very short label (max 30 chars)
- */
- header: string
- /**
- * Available choices
- */
- options: Array<QuestionOption>
- /**
- * Allow selecting multiple choices
- */
- multiple?: boolean
- /**
- * Allow typing a custom answer (default: true)
- */
- custom?: boolean
+export type EventSessionDiff = {
+ type: "session.diff"
+ properties: {
+ sessionID: string
+ diff: Array<SnapshotFileDiff>
+ }
}
-export type QuestionRequest = {
- id: string
- sessionID: string
- /**
- * Questions to ask
- */
- questions: Array<QuestionInfo>
- tool?: {
- messageID: string
- callID: string
+export type ProviderAuthError = {
+ name: "ProviderAuthError"
+ data: {
+ providerID: string
+ message: string
}
}
-export type EventQuestionAsked = {
- type: "question.asked"
- properties: QuestionRequest
+export type UnknownError = {
+ name: "UnknownError"
+ data: {
+ message: string
+ }
}
-export type QuestionAnswer = Array<string>
+export type MessageOutputLengthError = {
+ name: "MessageOutputLengthError"
+ data: {
+ [key: string]: unknown
+ }
+}
-export type EventQuestionReplied = {
- type: "question.replied"
- properties: {
- sessionID: string
- requestID: string
- answers: Array<QuestionAnswer>
+export type MessageAbortedError = {
+ name: "MessageAbortedError"
+ data: {
+ message: string
}
}
-export type EventQuestionRejected = {
- type: "question.rejected"
- properties: {
- sessionID: string
- requestID: string
+export type StructuredOutputError = {
+ name: "StructuredOutputError"
+ data: {
+ message: string
+ retries: number
}
}
-export type EventSessionCompacted = {
- type: "session.compacted"
+export type ContextOverflowError = {
+ name: "ContextOverflowError"
+ data: {
+ message: string
+ responseBody?: string
+ }
+}
+
+export type ApiError = {
+ name: "APIError"
+ data: {
+ message: string
+ statusCode?: number
+ isRetryable: boolean
+ responseHeaders?: {
+ [key: string]: string
+ }
+ responseBody?: string
+ metadata?: {
+ [key: string]: string
+ }
+ }
+}
+
+export type EventSessionError = {
+ type: "session.error"
properties: {
- sessionID: string
+ sessionID?: string
+ error?:
+ | ProviderAuthError
+ | UnknownError
+ | MessageOutputLengthError
+ | MessageAbortedError
+ | StructuredOutputError
+ | ContextOverflowError
+ | ApiError
}
}
@@ -245,26 +230,10 @@ export type EventFileWatcherUpdated = {
}
}
-export type Todo = {
- /**
- * Brief description of the task
- */
- content: string
- /**
- * Current status of the task: pending, in_progress, completed, cancelled
- */
- status: string
- /**
- * Priority level of the task: high, medium, low
- */
- priority: string
-}
-
-export type EventTodoUpdated = {
- type: "todo.updated"
+export type EventVcsBranchUpdated = {
+ type: "vcs.branch.updated"
properties: {
- sessionID: string
- todos: Array<Todo>
+ branch?: string
}
}
@@ -347,116 +316,147 @@ export type EventCommandExecuted = {
}
}
-export type SnapshotFileDiff = {
- file: string
- patch: string
- additions: number
- deletions: number
- status?: "added" | "deleted" | "modified"
-}
-
-export type EventSessionDiff = {
- type: "session.diff"
+export type EventWorkspaceReady = {
+ type: "workspace.ready"
properties: {
- sessionID: string
- diff: Array<SnapshotFileDiff>
+ name: string
}
}
-export type ProviderAuthError = {
- name: "ProviderAuthError"
- data: {
- providerID: string
+export type EventWorkspaceFailed = {
+ type: "workspace.failed"
+ properties: {
message: string
}
}
-export type UnknownError = {
- name: "UnknownError"
- data: {
- message: string
- }
+export type QuestionOption = {
+ /**
+ * Display text (1-5 words, concise)
+ */
+ label: string
+ /**
+ * Explanation of choice
+ */
+ description: string
}
-export type MessageOutputLengthError = {
- name: "MessageOutputLengthError"
- data: {
- [key: string]: unknown
- }
+export type QuestionInfo = {
+ /**
+ * Complete question
+ */
+ question: string
+ /**
+ * Very short label (max 30 chars)
+ */
+ header: string
+ /**
+ * Available choices
+ */
+ options: Array<QuestionOption>
+ /**
+ * Allow selecting multiple choices
+ */
+ multiple?: boolean
+ /**
+ * Allow typing a custom answer (default: true)
+ */
+ custom?: boolean
}
-export type MessageAbortedError = {
- name: "MessageAbortedError"
- data: {
- message: string
+export type QuestionRequest = {
+ id: string
+ sessionID: string
+ /**
+ * Questions to ask
+ */
+ questions: Array<QuestionInfo>
+ tool?: {
+ messageID: string
+ callID: string
}
}
-export type StructuredOutputError = {
- name: "StructuredOutputError"
- data: {
- message: string
- retries: number
+export type EventQuestionAsked = {
+ type: "question.asked"
+ properties: QuestionRequest
+}
+
+export type QuestionAnswer = Array<string>
+
+export type EventQuestionReplied = {
+ type: "question.replied"
+ properties: {
+ sessionID: string
+ requestID: string
+ answers: Array<QuestionAnswer>
}
}
-export type ContextOverflowError = {
- name: "ContextOverflowError"
- data: {
- message: string
- responseBody?: string
+export type EventQuestionRejected = {
+ type: "question.rejected"
+ properties: {
+ sessionID: string
+ requestID: string
}
}
-export type ApiError = {
- name: "APIError"
- data: {
- message: string
- statusCode?: number
- isRetryable: boolean
- responseHeaders?: {
- [key: string]: string
+export type SessionStatus =
+ | {
+ type: "idle"
}
- responseBody?: string
- metadata?: {
- [key: string]: string
+ | {
+ type: "retry"
+ attempt: number
+ message: string
+ next: number
+ }
+ | {
+ type: "busy"
}
- }
-}
-export type EventSessionError = {
- type: "session.error"
+export type EventSessionStatus = {
+ type: "session.status"
properties: {
- sessionID?: string
- error?:
- | ProviderAuthError
- | UnknownError
- | MessageOutputLengthError
- | MessageAbortedError
- | StructuredOutputError
- | ContextOverflowError
- | ApiError
+ sessionID: string
+ status: SessionStatus
}
}
-export type EventVcsBranchUpdated = {
- type: "vcs.branch.updated"
+export type EventSessionIdle = {
+ type: "session.idle"
properties: {
- branch?: string
+ sessionID: string
}
}
-export type EventWorkspaceReady = {
- type: "workspace.ready"
+export type EventSessionCompacted = {
+ type: "session.compacted"
properties: {
- name: string
+ sessionID: string
}
}
-export type EventWorkspaceFailed = {
- type: "workspace.failed"
+export type Todo = {
+ /**
+ * Brief description of the task
+ */
+ content: string
+ /**
+ * Current status of the task: pending, in_progress, completed, cancelled
+ */
+ status: string
+ /**
+ * Priority level of the task: high, medium, low
+ */
+ priority: string
+}
+
+export type EventTodoUpdated = {
+ type: "todo.updated"
properties: {
- message: string
+ sessionID: string
+ todos: Array<Todo>
}
}
@@ -972,17 +972,13 @@ export type Event =
| EventLspClientDiagnostics
| EventLspUpdated
| EventMessagePartDelta
- | EventSessionStatus
- | EventSessionIdle
| EventPermissionAsked
| EventPermissionReplied
- | EventQuestionAsked
- | EventQuestionReplied
- | EventQuestionRejected
- | EventSessionCompacted
+ | EventSessionDiff
+ | EventSessionError
| EventFileEdited
| EventFileWatcherUpdated
- | EventTodoUpdated
+ | EventVcsBranchUpdated
| EventTuiPromptAppend
| EventTuiCommandExecute
| EventTuiToastShow
@@ -990,11 +986,15 @@ export type Event =
| EventMcpToolsChanged
| EventMcpBrowserOpenFailed
| EventCommandExecuted
- | EventSessionDiff
- | EventSessionError
- | EventVcsBranchUpdated
| EventWorkspaceReady
| EventWorkspaceFailed
+ | EventQuestionAsked
+ | EventQuestionReplied
+ | EventQuestionRejected
+ | EventSessionStatus
+ | EventSessionIdle
+ | EventSessionCompacted
+ | EventTodoUpdated
| EventPtyCreated
| EventPtyUpdated
| EventPtyExited
diff --git a/packages/sdk/openapi.json b/packages/sdk/openapi.json
index 0de4dbdd9..450de5131 100644
--- a/packages/sdk/openapi.json
+++ b/packages/sdk/openapi.json
@@ -7324,92 +7324,6 @@
},
"required": ["type", "properties"]
},
- "SessionStatus": {
- "anyOf": [
- {
- "type": "object",
- "properties": {
- "type": {
- "type": "string",
- "const": "idle"
- }
- },
- "required": ["type"]
- },
- {
- "type": "object",
- "properties": {
- "type": {
- "type": "string",
- "const": "retry"
- },
- "attempt": {
- "type": "number"
- },
- "message": {
- "type": "string"
- },
- "next": {
- "type": "number"
- }
- },
- "required": ["type", "attempt", "message", "next"]
- },
- {
- "type": "object",
- "properties": {
- "type": {
- "type": "string",
- "const": "busy"
- }
- },
- "required": ["type"]
- }
- ]
- },
- "Event.session.status": {
- "type": "object",
- "properties": {
- "type": {
- "type": "string",
- "const": "session.status"
- },
- "properties": {
- "type": "object",
- "properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
- },
- "status": {
- "$ref": "#/components/schemas/SessionStatus"
- }
- },
- "required": ["sessionID", "status"]
- }
- },
- "required": ["type", "properties"]
- },
- "Event.session.idle": {
- "type": "object",
- "properties": {
- "type": {
- "type": "string",
- "const": "session.idle"
- },
- "properties": {
- "type": "object",
- "properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
- }
- },
- "required": ["sessionID"]
- }
- },
- "required": ["type", "properties"]
- },
"PermissionRequest": {
"type": "object",
"properties": {
@@ -7500,162 +7414,224 @@
},
"required": ["type", "properties"]
},
- "QuestionOption": {
+ "SnapshotFileDiff": {
"type": "object",
"properties": {
- "label": {
- "description": "Display text (1-5 words, concise)",
+ "file": {
"type": "string"
},
- "description": {
- "description": "Explanation of choice",
+ "patch": {
"type": "string"
+ },
+ "additions": {
+ "type": "number"
+ },
+ "deletions": {
+ "type": "number"
+ },
+ "status": {
+ "type": "string",
+ "enum": ["added", "deleted", "modified"]
}
},
- "required": ["label", "description"]
+ "required": ["file", "patch", "additions", "deletions"]
},
- "QuestionInfo": {
+ "Event.session.diff": {
"type": "object",
"properties": {
- "question": {
- "description": "Complete question",
- "type": "string"
- },
- "header": {
- "description": "Very short label (max 30 chars)",
- "type": "string"
- },
- "options": {
- "description": "Available choices",
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/QuestionOption"
- }
- },
- "multiple": {
- "description": "Allow selecting multiple choices",
- "type": "boolean"
+ "type": {
+ "type": "string",
+ "const": "session.diff"
},
- "custom": {
- "description": "Allow typing a custom answer (default: true)",
- "type": "boolean"
+ "properties": {
+ "type": "object",
+ "properties": {
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
+ },
+ "diff": {
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/SnapshotFileDiff"
+ }
+ }
+ },
+ "required": ["sessionID", "diff"]
}
},
- "required": ["question", "header", "options"]
+ "required": ["type", "properties"]
},
- "QuestionRequest": {
+ "ProviderAuthError": {
"type": "object",
"properties": {
- "id": {
+ "name": {
"type": "string",
- "pattern": "^que.*"
+ "const": "ProviderAuthError"
},
- "sessionID": {
+ "data": {
+ "type": "object",
+ "properties": {
+ "providerID": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": ["providerID", "message"]
+ }
+ },
+ "required": ["name", "data"]
+ },
+ "UnknownError": {
+ "type": "object",
+ "properties": {
+ "name": {
"type": "string",
- "pattern": "^ses.*"
- },
- "questions": {
- "description": "Questions to ask",
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/QuestionInfo"
- }
+ "const": "UnknownError"
},
- "tool": {
+ "data": {
"type": "object",
"properties": {
- "messageID": {
- "type": "string",
- "pattern": "^msg.*"
- },
- "callID": {
+ "message": {
"type": "string"
}
},
- "required": ["messageID", "callID"]
+ "required": ["message"]
}
},
- "required": ["id", "sessionID", "questions"]
+ "required": ["name", "data"]
},
- "Event.question.asked": {
+ "MessageOutputLengthError": {
"type": "object",
"properties": {
- "type": {
+ "name": {
"type": "string",
- "const": "question.asked"
+ "const": "MessageOutputLengthError"
},
- "properties": {
- "$ref": "#/components/schemas/QuestionRequest"
+ "data": {
+ "type": "object",
+ "properties": {}
}
},
- "required": ["type", "properties"]
+ "required": ["name", "data"]
},
- "QuestionAnswer": {
- "type": "array",
- "items": {
- "type": "string"
- }
+ "MessageAbortedError": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string",
+ "const": "MessageAbortedError"
+ },
+ "data": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": ["message"]
+ }
+ },
+ "required": ["name", "data"]
},
- "Event.question.replied": {
+ "StructuredOutputError": {
"type": "object",
"properties": {
- "type": {
+ "name": {
"type": "string",
- "const": "question.replied"
+ "const": "StructuredOutputError"
},
- "properties": {
+ "data": {
"type": "object",
"properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
+ "message": {
+ "type": "string"
},
- "requestID": {
- "type": "string",
- "pattern": "^que.*"
+ "retries": {
+ "type": "number"
+ }
+ },
+ "required": ["message", "retries"]
+ }
+ },
+ "required": ["name", "data"]
+ },
+ "ContextOverflowError": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string",
+ "const": "ContextOverflowError"
+ },
+ "data": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string"
},
- "answers": {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/QuestionAnswer"
- }
+ "responseBody": {
+ "type": "string"
}
},
- "required": ["sessionID", "requestID", "answers"]
+ "required": ["message"]
}
},
- "required": ["type", "properties"]
+ "required": ["name", "data"]
},
- "Event.question.rejected": {
+ "APIError": {
"type": "object",
"properties": {
- "type": {
+ "name": {
"type": "string",
- "const": "question.rejected"
+ "const": "APIError"
},
- "properties": {
+ "data": {
"type": "object",
"properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
+ "message": {
+ "type": "string"
},
- "requestID": {
- "type": "string",
- "pattern": "^que.*"
+ "statusCode": {
+ "type": "number"
+ },
+ "isRetryable": {
+ "type": "boolean"
+ },
+ "responseHeaders": {
+ "type": "object",
+ "propertyNames": {
+ "type": "string"
+ },
+ "additionalProperties": {
+ "type": "string"
+ }
+ },
+ "responseBody": {
+ "type": "string"
+ },
+ "metadata": {
+ "type": "object",
+ "propertyNames": {
+ "type": "string"
+ },
+ "additionalProperties": {
+ "type": "string"
+ }
}
},
- "required": ["sessionID", "requestID"]
+ "required": ["message", "isRetryable"]
}
},
- "required": ["type", "properties"]
+ "required": ["name", "data"]
},
- "Event.session.compacted": {
+ "Event.session.error": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "session.compacted"
+ "const": "session.error"
},
"properties": {
"type": "object",
@@ -7663,9 +7639,33 @@
"sessionID": {
"type": "string",
"pattern": "^ses.*"
+ },
+ "error": {
+ "anyOf": [
+ {
+ "$ref": "#/components/schemas/ProviderAuthError"
+ },
+ {
+ "$ref": "#/components/schemas/UnknownError"
+ },
+ {
+ "$ref": "#/components/schemas/MessageOutputLengthError"
+ },
+ {
+ "$ref": "#/components/schemas/MessageAbortedError"
+ },
+ {
+ "$ref": "#/components/schemas/StructuredOutputError"
+ },
+ {
+ "$ref": "#/components/schemas/ContextOverflowError"
+ },
+ {
+ "$ref": "#/components/schemas/APIError"
+ }
+ ]
}
- },
- "required": ["sessionID"]
+ }
}
},
"required": ["type", "properties"]
@@ -7724,46 +7724,20 @@
},
"required": ["type", "properties"]
},
- "Todo": {
- "type": "object",
- "properties": {
- "content": {
- "description": "Brief description of the task",
- "type": "string"
- },
- "status": {
- "description": "Current status of the task: pending, in_progress, completed, cancelled",
- "type": "string"
- },
- "priority": {
- "description": "Priority level of the task: high, medium, low",
- "type": "string"
- }
- },
- "required": ["content", "status", "priority"]
- },
- "Event.todo.updated": {
+ "Event.vcs.branch.updated": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "todo.updated"
+ "const": "vcs.branch.updated"
},
"properties": {
"type": "object",
"properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
- },
- "todos": {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/Todo"
- }
+ "branch": {
+ "type": "string"
}
- },
- "required": ["sessionID", "todos"]
+ }
}
},
"required": ["type", "properties"]
@@ -7954,224 +7928,243 @@
},
"required": ["type", "properties"]
},
- "SnapshotFileDiff": {
- "type": "object",
- "properties": {
- "file": {
- "type": "string"
- },
- "patch": {
- "type": "string"
- },
- "additions": {
- "type": "number"
- },
- "deletions": {
- "type": "number"
- },
- "status": {
- "type": "string",
- "enum": ["added", "deleted", "modified"]
- }
- },
- "required": ["file", "patch", "additions", "deletions"]
- },
- "Event.session.diff": {
+ "Event.workspace.ready": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "session.diff"
+ "const": "workspace.ready"
},
"properties": {
"type": "object",
"properties": {
- "sessionID": {
- "type": "string",
- "pattern": "^ses.*"
- },
- "diff": {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/SnapshotFileDiff"
- }
+ "name": {
+ "type": "string"
}
},
- "required": ["sessionID", "diff"]
+ "required": ["name"]
}
},
"required": ["type", "properties"]
},
- "ProviderAuthError": {
+ "Event.workspace.failed": {
"type": "object",
"properties": {
- "name": {
+ "type": {
"type": "string",
- "const": "ProviderAuthError"
+ "const": "workspace.failed"
},
- "data": {
+ "properties": {
"type": "object",
"properties": {
- "providerID": {
- "type": "string"
- },
"message": {
"type": "string"
}
},
- "required": ["providerID", "message"]
+ "required": ["message"]
}
},
- "required": ["name", "data"]
+ "required": ["type", "properties"]
},
- "UnknownError": {
+ "QuestionOption": {
"type": "object",
"properties": {
- "name": {
- "type": "string",
- "const": "UnknownError"
+ "label": {
+ "description": "Display text (1-5 words, concise)",
+ "type": "string"
},
- "data": {
- "type": "object",
- "properties": {
- "message": {
- "type": "string"
- }
- },
- "required": ["message"]
+ "description": {
+ "description": "Explanation of choice",
+ "type": "string"
}
},
- "required": ["name", "data"]
+ "required": ["label", "description"]
},
- "MessageOutputLengthError": {
+ "QuestionInfo": {
"type": "object",
"properties": {
- "name": {
- "type": "string",
- "const": "MessageOutputLengthError"
+ "question": {
+ "description": "Complete question",
+ "type": "string"
},
- "data": {
- "type": "object",
- "properties": {}
+ "header": {
+ "description": "Very short label (max 30 chars)",
+ "type": "string"
+ },
+ "options": {
+ "description": "Available choices",
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/QuestionOption"
+ }
+ },
+ "multiple": {
+ "description": "Allow selecting multiple choices",
+ "type": "boolean"
+ },
+ "custom": {
+ "description": "Allow typing a custom answer (default: true)",
+ "type": "boolean"
}
},
- "required": ["name", "data"]
+ "required": ["question", "header", "options"]
},
- "MessageAbortedError": {
+ "QuestionRequest": {
"type": "object",
"properties": {
- "name": {
+ "id": {
"type": "string",
- "const": "MessageAbortedError"
+ "pattern": "^que.*"
},
- "data": {
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
+ },
+ "questions": {
+ "description": "Questions to ask",
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/QuestionInfo"
+ }
+ },
+ "tool": {
"type": "object",
"properties": {
- "message": {
+ "messageID": {
+ "type": "string",
+ "pattern": "^msg.*"
+ },
+ "callID": {
"type": "string"
}
},
- "required": ["message"]
+ "required": ["messageID", "callID"]
}
},
- "required": ["name", "data"]
+ "required": ["id", "sessionID", "questions"]
},
- "StructuredOutputError": {
+ "Event.question.asked": {
"type": "object",
"properties": {
- "name": {
+ "type": {
"type": "string",
- "const": "StructuredOutputError"
+ "const": "question.asked"
},
- "data": {
+ "properties": {
+ "$ref": "#/components/schemas/QuestionRequest"
+ }
+ },
+ "required": ["type", "properties"]
+ },
+ "QuestionAnswer": {
+ "type": "array",
+ "items": {
+ "type": "string"
+ }
+ },
+ "Event.question.replied": {
+ "type": "object",
+ "properties": {
+ "type": {
+ "type": "string",
+ "const": "question.replied"
+ },
+ "properties": {
"type": "object",
"properties": {
- "message": {
- "type": "string"
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
},
- "retries": {
- "type": "number"
+ "requestID": {
+ "type": "string",
+ "pattern": "^que.*"
+ },
+ "answers": {
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/QuestionAnswer"
+ }
}
},
- "required": ["message", "retries"]
+ "required": ["sessionID", "requestID", "answers"]
}
},
- "required": ["name", "data"]
+ "required": ["type", "properties"]
},
- "ContextOverflowError": {
+ "Event.question.rejected": {
"type": "object",
"properties": {
- "name": {
+ "type": {
"type": "string",
- "const": "ContextOverflowError"
+ "const": "question.rejected"
},
- "data": {
+ "properties": {
"type": "object",
"properties": {
- "message": {
- "type": "string"
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
},
- "responseBody": {
- "type": "string"
+ "requestID": {
+ "type": "string",
+ "pattern": "^que.*"
}
},
- "required": ["message"]
+ "required": ["sessionID", "requestID"]
}
},
- "required": ["name", "data"]
+ "required": ["type", "properties"]
},
- "APIError": {
- "type": "object",
- "properties": {
- "name": {
- "type": "string",
- "const": "APIError"
+ "SessionStatus": {
+ "anyOf": [
+ {
+ "type": "object",
+ "properties": {
+ "type": {
+ "type": "string",
+ "const": "idle"
+ }
+ },
+ "required": ["type"]
},
- "data": {
+ {
"type": "object",
"properties": {
- "message": {
- "type": "string"
+ "type": {
+ "type": "string",
+ "const": "retry"
},
- "statusCode": {
+ "attempt": {
"type": "number"
},
- "isRetryable": {
- "type": "boolean"
- },
- "responseHeaders": {
- "type": "object",
- "propertyNames": {
- "type": "string"
- },
- "additionalProperties": {
- "type": "string"
- }
- },
- "responseBody": {
+ "message": {
"type": "string"
},
- "metadata": {
- "type": "object",
- "propertyNames": {
- "type": "string"
- },
- "additionalProperties": {
- "type": "string"
- }
+ "next": {
+ "type": "number"
}
},
- "required": ["message", "isRetryable"]
+ "required": ["type", "attempt", "message", "next"]
+ },
+ {
+ "type": "object",
+ "properties": {
+ "type": {
+ "type": "string",
+ "const": "busy"
+ }
+ },
+ "required": ["type"]
}
- },
- "required": ["name", "data"]
+ ]
},
- "Event.session.error": {
+ "Event.session.status": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "session.error"
+ "const": "session.status"
},
"properties": {
"type": "object",
@@ -8180,88 +8173,95 @@
"type": "string",
"pattern": "^ses.*"
},
- "error": {
- "anyOf": [
- {
- "$ref": "#/components/schemas/ProviderAuthError"
- },
- {
- "$ref": "#/components/schemas/UnknownError"
- },
- {
- "$ref": "#/components/schemas/MessageOutputLengthError"
- },
- {
- "$ref": "#/components/schemas/MessageAbortedError"
- },
- {
- "$ref": "#/components/schemas/StructuredOutputError"
- },
- {
- "$ref": "#/components/schemas/ContextOverflowError"
- },
- {
- "$ref": "#/components/schemas/APIError"
- }
- ]
+ "status": {
+ "$ref": "#/components/schemas/SessionStatus"
}
- }
+ },
+ "required": ["sessionID", "status"]
}
},
"required": ["type", "properties"]
},
- "Event.vcs.branch.updated": {
+ "Event.session.idle": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "vcs.branch.updated"
+ "const": "session.idle"
},
"properties": {
"type": "object",
"properties": {
- "branch": {
- "type": "string"
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
}
- }
+ },
+ "required": ["sessionID"]
}
},
"required": ["type", "properties"]
},
- "Event.workspace.ready": {
+ "Event.session.compacted": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "workspace.ready"
+ "const": "session.compacted"
},
"properties": {
"type": "object",
"properties": {
- "name": {
- "type": "string"
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
}
},
- "required": ["name"]
+ "required": ["sessionID"]
}
},
"required": ["type", "properties"]
},
- "Event.workspace.failed": {
+ "Todo": {
+ "type": "object",
+ "properties": {
+ "content": {
+ "description": "Brief description of the task",
+ "type": "string"
+ },
+ "status": {
+ "description": "Current status of the task: pending, in_progress, completed, cancelled",
+ "type": "string"
+ },
+ "priority": {
+ "description": "Priority level of the task: high, medium, low",
+ "type": "string"
+ }
+ },
+ "required": ["content", "status", "priority"]
+ },
+ "Event.todo.updated": {
"type": "object",
"properties": {
"type": {
"type": "string",
- "const": "workspace.failed"
+ "const": "todo.updated"
},
"properties": {
"type": "object",
"properties": {
- "message": {
- "type": "string"
+ "sessionID": {
+ "type": "string",
+ "pattern": "^ses.*"
+ },
+ "todos": {
+ "type": "array",
+ "items": {
+ "$ref": "#/components/schemas/Todo"
+ }
}
},
- "required": ["message"]
+ "required": ["sessionID", "todos"]
}
},
"required": ["type", "properties"]
@@ -9811,28 +9811,16 @@
"$ref": "#/components/schemas/Event.message.part.delta"
},
{
- "$ref": "#/components/schemas/Event.session.status"
- },
- {
- "$ref": "#/components/schemas/Event.session.idle"
- },
- {
"$ref": "#/components/schemas/Event.permission.asked"
},
{
"$ref": "#/components/schemas/Event.permission.replied"
},
{
- "$ref": "#/components/schemas/Event.question.asked"
- },
- {
- "$ref": "#/components/schemas/Event.question.replied"
- },
- {
- "$ref": "#/components/schemas/Event.question.rejected"
+ "$ref": "#/components/schemas/Event.session.diff"
},
{
- "$ref": "#/components/schemas/Event.session.compacted"
+ "$ref": "#/components/schemas/Event.session.error"
},
{
"$ref": "#/components/schemas/Event.file.edited"
@@ -9841,7 +9829,7 @@
"$ref": "#/components/schemas/Event.file.watcher.updated"
},
{
- "$ref": "#/components/schemas/Event.todo.updated"
+ "$ref": "#/components/schemas/Event.vcs.branch.updated"
},
{
"$ref": "#/components/schemas/Event.tui.prompt.append"
@@ -9865,19 +9853,31 @@
"$ref": "#/components/schemas/Event.command.executed"
},
{
- "$ref": "#/components/schemas/Event.session.diff"
+ "$ref": "#/components/schemas/Event.workspace.ready"
},
{
- "$ref": "#/components/schemas/Event.session.error"
+ "$ref": "#/components/schemas/Event.workspace.failed"
},
{
- "$ref": "#/components/schemas/Event.vcs.branch.updated"
+ "$ref": "#/components/schemas/Event.question.asked"
},
{
- "$ref": "#/components/schemas/Event.workspace.ready"
+ "$ref": "#/components/schemas/Event.question.replied"
},
{
- "$ref": "#/components/schemas/Event.workspace.failed"
+ "$ref": "#/components/schemas/Event.question.rejected"
+ },
+ {
+ "$ref": "#/components/schemas/Event.session.status"
+ },
+ {
+ "$ref": "#/components/schemas/Event.session.idle"
+ },
+ {
+ "$ref": "#/components/schemas/Event.session.compacted"
+ },
+ {
+ "$ref": "#/components/schemas/Event.todo.updated"
},
{
"$ref": "#/components/schemas/Event.pty.created"