From 1c1082edaf8068abe62b7dc9f6a349767212c5c2 Mon Sep 17 00:00:00 2001 From: OpenRouter SDK Bot Date: Mon, 10 Aug 2026 19:23:34 +0000 Subject: [PATCH] chore: update OpenAPI spec [sdk-bot] --- .speakeasy/in.openapi.yaml | 350 ++++++++++++++++++++++++++++++++----- 1 file changed, 311 insertions(+), 39 deletions(-) diff --git a/.speakeasy/in.openapi.yaml b/.speakeasy/in.openapi.yaml index ba46979d..02ef09f9 100644 --- a/.speakeasy/in.openapi.yaml +++ b/.speakeasy/in.openapi.yaml @@ -3877,6 +3877,7 @@ components: discriminator: mapping: apply_patch_call: '#/components/schemas/OutputItemApplyPatchCall' + code_interpreter_call: '#/components/schemas/OutputItemCodeInterpreterCall' custom_tool_call: '#/components/schemas/OutputItemCustomToolCall' file_search_call: '#/components/schemas/OutputItemFileSearchCall' function_call: '#/components/schemas/OutputItemFunctionCall' @@ -3894,6 +3895,7 @@ components: - $ref: '#/components/schemas/OutputItemFileSearchCall' - $ref: '#/components/schemas/OutputItemImageGenerationCall' - $ref: '#/components/schemas/OutputItemApplyPatchCall' + - $ref: '#/components/schemas/OutputItemCodeInterpreterCall' type: 'array' output_text: type: 'string' @@ -6151,7 +6153,69 @@ components: required: - 'type' type: 'object' + CodeInterpreterCallCodeDeltaEvent: + allOf: + - $ref: '#/components/schemas/OpenAIResponsesCodeInterpreterCallCodeDelta' + - properties: {} + type: 'object' + description: 'Incremental chunk of code being streamed for a `code_interpreter_call`.' + example: + delta: 'print("hello")' + item_id: 'ci-abc123' + output_index: 0 + sequence_number: 3 + type: 'response.code_interpreter_call_code.delta' + CodeInterpreterCallCodeDoneEvent: + allOf: + - $ref: '#/components/schemas/OpenAIResponsesCodeInterpreterCallCodeDone' + - properties: {} + type: 'object' + description: 'Emitted when code streaming completes for a `code_interpreter_call`.' + example: + code: 'print("hello")' + item_id: 'ci-abc123' + output_index: 0 + sequence_number: 8 + type: 'response.code_interpreter_call_code.done' + CodeInterpreterCallCompletedEvent: + allOf: + - $ref: '#/components/schemas/OpenAIResponsesCodeInterpreterCallCompleted' + - properties: {} + type: 'object' + description: 'Code interpreter call completed' + example: + item_id: 'ci-abc123' + output_index: 0 + sequence_number: 10 + type: 'response.code_interpreter_call.completed' + CodeInterpreterCallInProgressEvent: + allOf: + - $ref: '#/components/schemas/OpenAIResponsesCodeInterpreterCallInProgress' + - properties: {} + type: 'object' + description: 'Code interpreter call in progress' + example: + item_id: 'ci-abc123' + output_index: 0 + sequence_number: 2 + type: 'response.code_interpreter_call.in_progress' + CodeInterpreterCallInterpretingEvent: + allOf: + - $ref: '#/components/schemas/OpenAIResponsesCodeInterpreterCallInterpreting' + - properties: {} + type: 'object' + description: 'Code interpreter is executing the code' + example: + item_id: 'ci-abc123' + output_index: 0 + sequence_number: 9 + type: 'response.code_interpreter_call.interpreting' CodeInterpreterCallItem: + allOf: + - $ref: '#/components/schemas/OutputItemCodeInterpreterCall' + - additionalProperties: {} + properties: {} + type: 'object' description: 'A code interpreter execution call with outputs' example: code: 'print("Hello, World!")' @@ -6162,56 +6226,73 @@ components: type: 'logs' status: 'completed' type: 'code_interpreter_call' + CodeInterpreterFileOutput: + example: + download_url: 'https://example.com/download/file_abc123' + filename: 'summary.txt' + id: 'file_abc123' + type: 'file' properties: - code: + download_url: + description: 'Provider-issued download URL for the generated file. Typically signed and time-limited (see `expires_at`); fetch promptly rather than persisting the URL.' + type: 'string' + error_code: + description: 'Provider error code when generating or persisting the file failed; null or absent on success.' type: - 'string' - 'null' - container_id: + expires_at: + description: 'When the `download_url` stops working, as an ISO 8601 timestamp. After this time the file must be regenerated.' + type: 'string' + filename: type: 'string' id: type: 'string' - outputs: - items: - anyOf: - - properties: - type: - enum: - - 'image' - type: 'string' - url: - type: 'string' - required: - - 'type' - - 'url' - type: 'object' - - properties: - logs: - type: 'string' - type: - enum: - - 'logs' - type: 'string' - required: - - 'type' - - 'logs' - type: 'object' - type: - - 'array' - - 'null' + media_type: + type: 'string' + sha256: + type: 'string' + size_bytes: + type: 'integer' status: - $ref: '#/components/schemas/ToolCallStatus' + description: 'Provider-reported readiness of the generated file (e.g. `ready`). Values other than `ready` indicate the artifact may not be downloadable.' + type: 'string' type: enum: - - 'code_interpreter_call' + - 'file' type: 'string' required: - 'type' - - 'id' - - 'code' - - 'outputs' - - 'status' - - 'container_id' + type: 'object' + CodeInterpreterImageOutput: + example: + type: 'image' + url: 'https://example.com/plot.png' + properties: + type: + enum: + - 'image' + type: 'string' + url: + type: 'string' + required: + - 'type' + - 'url' + type: 'object' + CodeInterpreterLogsOutput: + example: + logs: "hello\n" + type: 'logs' + properties: + logs: + type: 'string' + type: + enum: + - 'logs' + type: 'string' + required: + - 'type' + - 'logs' type: 'object' CodeInterpreterServerTool: description: 'Code interpreter tool configuration' @@ -16940,6 +17021,129 @@ components: filename: 'research_paper.pdf' index: 0 type: 'file_citation' + OpenAIResponsesCodeInterpreterCallCodeDelta: + example: + delta: 'print("hello")' + item_id: 'ci_abc123' + output_index: 0 + sequence_number: 2 + type: 'response.code_interpreter_call_code.delta' + properties: + delta: + type: 'string' + item_id: + type: 'string' + output_index: + type: 'integer' + sequence_number: + type: 'integer' + type: + enum: + - 'response.code_interpreter_call_code.delta' + type: 'string' + required: + - 'type' + - 'item_id' + - 'output_index' + - 'sequence_number' + - 'delta' + type: 'object' + OpenAIResponsesCodeInterpreterCallCodeDone: + example: + code: 'print("hello")' + item_id: 'ci_abc123' + output_index: 0 + sequence_number: 3 + type: 'response.code_interpreter_call_code.done' + properties: + code: + type: 'string' + item_id: + type: 'string' + output_index: + type: 'integer' + sequence_number: + type: 'integer' + type: + enum: + - 'response.code_interpreter_call_code.done' + type: 'string' + required: + - 'type' + - 'item_id' + - 'output_index' + - 'sequence_number' + - 'code' + type: 'object' + OpenAIResponsesCodeInterpreterCallCompleted: + example: + item_id: 'ci_abc123' + output_index: 0 + sequence_number: 3 + type: 'response.code_interpreter_call.completed' + properties: + item_id: + type: 'string' + output_index: + type: 'integer' + sequence_number: + type: 'integer' + type: + enum: + - 'response.code_interpreter_call.completed' + type: 'string' + required: + - 'type' + - 'item_id' + - 'output_index' + - 'sequence_number' + type: 'object' + OpenAIResponsesCodeInterpreterCallInProgress: + example: + item_id: 'ci_abc123' + output_index: 0 + sequence_number: 1 + type: 'response.code_interpreter_call.in_progress' + properties: + item_id: + type: 'string' + output_index: + type: 'integer' + sequence_number: + type: 'integer' + type: + enum: + - 'response.code_interpreter_call.in_progress' + type: 'string' + required: + - 'type' + - 'item_id' + - 'output_index' + - 'sequence_number' + type: 'object' + OpenAIResponsesCodeInterpreterCallInterpreting: + example: + item_id: 'ci_abc123' + output_index: 0 + sequence_number: 2 + type: 'response.code_interpreter_call.interpreting' + properties: + item_id: + type: 'string' + output_index: + type: 'integer' + sequence_number: + type: 'integer' + type: + enum: + - 'response.code_interpreter_call.interpreting' + type: 'string' + required: + - 'type' + - 'item_id' + - 'output_index' + - 'sequence_number' + type: 'object' OpenAIResponsesImageGenCallCompleted: example: item_id: 'ig_abc123' @@ -17873,7 +18077,8 @@ components: OutputCodeInterpreterCallItem: allOf: - $ref: '#/components/schemas/CodeInterpreterCallItem' - - properties: {} + - additionalProperties: {} + properties: {} type: 'object' description: 'A code interpreter execution call with outputs' example: @@ -18235,6 +18440,7 @@ components: discriminator: mapping: apply_patch_call: '#/components/schemas/OutputItemApplyPatchCall' + code_interpreter_call: '#/components/schemas/OutputItemCodeInterpreterCall' custom_tool_call: '#/components/schemas/OutputItemCustomToolCall' file_search_call: '#/components/schemas/OutputItemFileSearchCall' function_call: '#/components/schemas/OutputItemFunctionCall' @@ -18252,6 +18458,7 @@ components: - $ref: '#/components/schemas/OutputItemFileSearchCall' - $ref: '#/components/schemas/OutputItemImageGenerationCall' - $ref: '#/components/schemas/OutputItemApplyPatchCall' + - $ref: '#/components/schemas/OutputItemCodeInterpreterCall' output_index: type: 'integer' sequence_number: @@ -18310,6 +18517,57 @@ components: - 'operation' - 'status' type: 'object' + OutputItemCodeInterpreterCall: + additionalProperties: {} + example: + code: 'print("hello")' + id: 'ci_abc123' + outputs: + - logs: "hello\n" + type: 'logs' + status: 'completed' + type: 'code_interpreter_call' + properties: + code: + type: + - 'string' + - 'null' + container_id: + type: 'string' + id: + type: 'string' + outputs: + items: + discriminator: + mapping: + file: '#/components/schemas/CodeInterpreterFileOutput' + image: '#/components/schemas/CodeInterpreterImageOutput' + logs: '#/components/schemas/CodeInterpreterLogsOutput' + propertyName: 'type' + oneOf: + - $ref: '#/components/schemas/CodeInterpreterLogsOutput' + - $ref: '#/components/schemas/CodeInterpreterImageOutput' + - $ref: '#/components/schemas/CodeInterpreterFileOutput' + type: + - 'array' + - 'null' + status: + enum: + - 'in_progress' + - 'completed' + - 'incomplete' + - 'interpreting' + - 'failed' + type: 'string' + type: + enum: + - 'code_interpreter_call' + type: 'string' + required: + - 'type' + - 'id' + - 'status' + type: 'object' OutputItemCustomToolCall: example: call_id: 'call-abc123' @@ -18359,6 +18617,7 @@ components: discriminator: mapping: apply_patch_call: '#/components/schemas/OutputItemApplyPatchCall' + code_interpreter_call: '#/components/schemas/OutputItemCodeInterpreterCall' custom_tool_call: '#/components/schemas/OutputItemCustomToolCall' file_search_call: '#/components/schemas/OutputItemFileSearchCall' function_call: '#/components/schemas/OutputItemFunctionCall' @@ -18376,6 +18635,7 @@ components: - $ref: '#/components/schemas/OutputItemFileSearchCall' - $ref: '#/components/schemas/OutputItemImageGenerationCall' - $ref: '#/components/schemas/OutputItemApplyPatchCall' + - $ref: '#/components/schemas/OutputItemCodeInterpreterCall' output_index: type: 'integer' sequence_number: @@ -18599,6 +18859,7 @@ components: - $ref: '#/components/schemas/OutputFilesServerToolItem' - $ref: '#/components/schemas/OutputCustomToolCallItem' OutputItemWebSearchCall: + additionalProperties: {} example: action: query: 'OpenAI API' @@ -19114,7 +19375,8 @@ components: OutputWebSearchCallItem: allOf: - $ref: '#/components/schemas/OutputItemWebSearchCall' - - properties: {} + - additionalProperties: {} + properties: {} type: 'object' example: id: 'ws-abc123' @@ -22584,6 +22846,11 @@ components: error: '#/components/schemas/ErrorEvent' response.apply_patch_call_operation_diff.delta: '#/components/schemas/ApplyPatchCallOperationDiffDeltaEvent' response.apply_patch_call_operation_diff.done: '#/components/schemas/ApplyPatchCallOperationDiffDoneEvent' + response.code_interpreter_call_code.delta: '#/components/schemas/CodeInterpreterCallCodeDeltaEvent' + response.code_interpreter_call_code.done: '#/components/schemas/CodeInterpreterCallCodeDoneEvent' + response.code_interpreter_call.completed: '#/components/schemas/CodeInterpreterCallCompletedEvent' + response.code_interpreter_call.in_progress: '#/components/schemas/CodeInterpreterCallInProgressEvent' + response.code_interpreter_call.interpreting: '#/components/schemas/CodeInterpreterCallInterpretingEvent' response.completed: '#/components/schemas/StreamEventsResponseCompleted' response.content_part.added: '#/components/schemas/ContentPartAddedEvent' response.content_part.done: '#/components/schemas/ContentPartDoneEvent' @@ -22677,6 +22944,11 @@ components: - $ref: '#/components/schemas/ImageGenCallGeneratingEvent' - $ref: '#/components/schemas/ImageGenCallPartialImageEvent' - $ref: '#/components/schemas/ImageGenCallCompletedEvent' + - $ref: '#/components/schemas/CodeInterpreterCallInProgressEvent' + - $ref: '#/components/schemas/CodeInterpreterCallInterpretingEvent' + - $ref: '#/components/schemas/CodeInterpreterCallCompletedEvent' + - $ref: '#/components/schemas/CodeInterpreterCallCodeDeltaEvent' + - $ref: '#/components/schemas/CodeInterpreterCallCodeDoneEvent' - $ref: '#/components/schemas/WebSearchCallInProgressEvent' - $ref: '#/components/schemas/WebSearchCallSearchingEvent' - $ref: '#/components/schemas/WebSearchCallCompletedEvent'