Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "6.9.0"
".": "6.9.1"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 135
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-ca24bc4d8125b5153514ce643c4e3220f25971b7d67ca384d56d493c72c0d977.yml
openapi_spec_hash: c6f048c7b3d29f4de48fde0e845ba33f
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-a7e92d12ebe89ca019a7ac5b29759064eefa2c38fe08d03516f2620e66abb32b.yml
openapi_spec_hash: acbc703b2739447abc6312b2d753631c
config_hash: b876221dfb213df9f0a999e75d38a65e
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 6.9.1 (2025-11-17)

Full Changelog: [v6.9.0...v6.9.1](https://github.com/openai/openai-node/compare/v6.9.0...v6.9.1)

### Bug Fixes

* **api:** align types of input items / output items for typescript ([99adaa7](https://github.com/openai/openai-node/commit/99adaa70dc31d07d5c7fa4d67194ac4de375c98f))

## 6.9.0 (2025-11-13)

Full Changelog: [v6.8.1...v6.9.0](https://github.com/openai/openai-node/compare/v6.8.1...v6.9.0)
Expand Down
2 changes: 1 addition & 1 deletion jsr.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@openai/openai",
"version": "6.9.0",
"version": "6.9.1",
"exports": {
".": "./index.ts",
"./helpers/zod": "./helpers/zod.ts",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "openai",
"version": "6.9.0",
"version": "6.9.1",
"description": "The official TypeScript library for the OpenAI API",
"author": "OpenAI <support@openai.com>",
"types": "dist/index.d.ts",
Expand Down
4 changes: 2 additions & 2 deletions src/helpers/zod.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ResponseFormatJSONSchema } from '../resources/index';
import { z as z3 } from 'zod/v3';
import { z as z4 } from 'zod/v4';
import * as z3 from 'zod/v3';
import * as z4 from 'zod/v4';
import {
AutoParseableResponseFormat,
AutoParseableTextFormat,
Expand Down
30 changes: 15 additions & 15 deletions src/resources/responses/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -709,6 +709,15 @@ export interface ResponseApplyPatchToolCall {
*/
call_id: string;

/**
* One of the create_file, delete_file, or update_file operations applied via
* apply_patch.
*/
operation:
| ResponseApplyPatchToolCall.CreateFile
| ResponseApplyPatchToolCall.DeleteFile
| ResponseApplyPatchToolCall.UpdateFile;

/**
* The status of the apply patch tool call. One of `in_progress` or `completed`.
*/
Expand All @@ -723,15 +732,6 @@ export interface ResponseApplyPatchToolCall {
* The ID of the entity that created this tool call.
*/
created_by?: string;

/**
* One of the create_file, delete_file, or update_file operations applied via
* apply_patch.
*/
operation?:
| ResponseApplyPatchToolCall.CreateFile
| ResponseApplyPatchToolCall.DeleteFile
| ResponseApplyPatchToolCall.UpdateFile;
}

export namespace ResponseApplyPatchToolCall {
Expand Down Expand Up @@ -806,11 +806,6 @@ export interface ResponseApplyPatchToolCallOutput {
*/
call_id: string;

/**
* Optional textual output returned by the apply patch tool.
*/
output: string | null;

/**
* The status of the apply patch tool call output. One of `completed` or `failed`.
*/
Expand All @@ -825,6 +820,11 @@ export interface ResponseApplyPatchToolCallOutput {
* The ID of the entity that created this tool call output.
*/
created_by?: string;

/**
* Optional textual output returned by the apply patch tool.
*/
output?: string | null;
}

/**
Expand Down Expand Up @@ -3275,7 +3275,7 @@ export namespace ResponseInputItem {
* Optional human-readable log text from the apply patch tool (e.g., patch results
* or errors).
*/
output?: string;
output?: string | null;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '6.9.0'; // x-release-please-version
export const VERSION = '6.9.1'; // x-release-please-version
21 changes: 21 additions & 0 deletions tests/responsesItems.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import OpenAI from 'openai/index';
const openai = new OpenAI({ apiKey: 'example-api-key' });

describe('responses item types', () => {
test('response output items are compatible with input items', async () => {
expect(true).toBe(true);
});
});

const unused = async () => {
const response = await openai.responses.create({
model: 'gpt-5.1',
input: 'You are a helpful assistant.',
});
await openai.responses.create({
model: 'gpt-5.1',
// check type compatibility
input: response.output,
});
expect(true).toBe(true);
};