Skip to content

Commit 203c1c3

Browse files
fix(api): internal openapi updates
1 parent febf4dc commit 203c1c3

File tree

7 files changed

+22
-39
lines changed

7 files changed

+22
-39
lines changed

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 134
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-f59befea071ed7729cbb7bce219e7f837eccfdb57e01698514e6a0bd6052ff60.yml
3-
openapi_spec_hash: 49da48619d37932b2e257c532078b2bb
4-
config_hash: 1af83449a09a3b4f276444dbcdd3eb67
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-b062c33330de7e3bbf992fd4f0799afd868c30a66c39418dd2c62f4add3b45b6.yml
3+
openapi_spec_hash: fe067f5b1c0e93799b5ea7fde3c4b1b3
4+
config_hash: 4b6f471b24d659514b86b736c90a0c0a

src/resources/images.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -545,10 +545,7 @@ export interface ImageEditParamsBase {
545545
background?: 'transparent' | 'opaque' | 'auto' | null;
546546

547547
/**
548-
* Control how much effort the model will exert to match the style and features,
549-
* especially facial features, of input images. This parameter is only supported
550-
* for `gpt-image-1`. Unsupported for `gpt-image-1-mini`. Supports `high` and
551-
* `low`. Defaults to `low`.
548+
* Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1`. Unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.
552549
*/
553550
input_fidelity?: 'high' | 'low' | null;
554551

src/resources/responses/responses.ts

Lines changed: 13 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -229,10 +229,6 @@ export interface ComputerTool {
229229
type: 'computer_use_preview';
230230
}
231231

232-
/**
233-
* A custom tool that processes input using a specified format. Learn more about
234-
* [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools).
235-
*/
236232
export interface CustomTool {
237233
/**
238234
* The name of the custom tool, used to identify it in tool calls.
@@ -890,7 +886,7 @@ export namespace ResponseCodeInterpreterToolCall {
890886
logs: string;
891887

892888
/**
893-
* The type of the output. Always 'logs'.
889+
* The type of the output. Always `logs`.
894890
*/
895891
type: 'logs';
896892
}
@@ -900,7 +896,7 @@ export namespace ResponseCodeInterpreterToolCall {
900896
*/
901897
export interface Image {
902898
/**
903-
* The type of the output. Always 'image'.
899+
* The type of the output. Always `image`.
904900
*/
905901
type: 'image';
906902

@@ -990,8 +986,7 @@ export namespace ResponseComputerToolCall {
990986
button: 'left' | 'right' | 'wheel' | 'back' | 'forward';
991987

992988
/**
993-
* Specifies the event type. For a click action, this property is always set to
994-
* `click`.
989+
* Specifies the event type. For a click action, this property is always `click`.
995990
*/
996991
type: 'click';
997992

@@ -1053,7 +1048,7 @@ export namespace ResponseComputerToolCall {
10531048

10541049
export namespace Drag {
10551050
/**
1056-
* A series of x/y coordinate pairs in the drag path.
1051+
* An x/y coordinate pair, e.g. `{ x: 100, y: 200 }`.
10571052
*/
10581053
export interface Path {
10591054
/**
@@ -1187,12 +1182,12 @@ export namespace ResponseComputerToolCall {
11871182
/**
11881183
* The type of the pending safety check.
11891184
*/
1190-
code: string;
1185+
code?: string | null;
11911186

11921187
/**
11931188
* Details about the pending safety check.
11941189
*/
1195-
message: string;
1190+
message?: string | null;
11961191
}
11971192
}
11981193

@@ -1243,12 +1238,12 @@ export namespace ResponseComputerToolCallOutputItem {
12431238
/**
12441239
* The type of the pending safety check.
12451240
*/
1246-
code: string;
1241+
code?: string | null;
12471242

12481243
/**
12491244
* Details about the pending safety check.
12501245
*/
1251-
message: string;
1246+
message?: string | null;
12521247
}
12531248
}
12541249

@@ -2240,10 +2235,13 @@ export interface ResponseInProgressEvent {
22402235
*/
22412236
export type ResponseIncludable =
22422237
| 'file_search_call.results'
2238+
| 'web_search_call.results'
2239+
| 'web_search_call.action.sources'
22432240
| 'message.input_image.image_url'
22442241
| 'computer_call_output.output.image_url'
2242+
| 'code_interpreter_call.outputs'
22452243
| 'reasoning.encrypted_content'
2246-
| 'code_interpreter_call.outputs';
2244+
| 'message.output_text.logprobs';
22472245

22482246
/**
22492247
* An event that is emitted when a response finishes as incomplete.
@@ -5066,10 +5064,7 @@ export namespace Tool {
50665064
background?: 'transparent' | 'opaque' | 'auto';
50675065

50685066
/**
5069-
* Control how much effort the model will exert to match the style and features,
5070-
* especially facial features, of input images. This parameter is only supported
5071-
* for `gpt-image-1`. Unsupported for `gpt-image-1-mini`. Supports `high` and
5072-
* `low`. Defaults to `low`.
5067+
* Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1`. Unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.
50735068
*/
50745069
input_fidelity?: 'high' | 'low' | null;
50755070

@@ -5137,9 +5132,6 @@ export namespace Tool {
51375132
}
51385133
}
51395134

5140-
/**
5141-
* A tool that allows the model to execute shell commands in a local environment.
5142-
*/
51435135
export interface LocalShell {
51445136
/**
51455137
* The type of the local shell tool. Always `local_shell`.

src/resources/shared.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -135,19 +135,13 @@ export interface CompoundFilter {
135135
export type CustomToolInputFormat = CustomToolInputFormat.Text | CustomToolInputFormat.Grammar;
136136

137137
export namespace CustomToolInputFormat {
138-
/**
139-
* Unconstrained free-form text.
140-
*/
141138
export interface Text {
142139
/**
143140
* Unconstrained text format. Always `text`.
144141
*/
145142
type: 'text';
146143
}
147144

148-
/**
149-
* A grammar defined by the user.
150-
*/
151145
export interface Grammar {
152146
/**
153147
* The grammar definition.

tests/api-resources/conversations/items.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ describe('resource items', () => {
2424
test('create: required and optional params', async () => {
2525
const response = await client.conversations.items.create('conv_123', {
2626
items: [{ content: 'string', role: 'user', type: 'message' }],
27-
include: ['code_interpreter_call.outputs'],
27+
include: ['file_search_call.results'],
2828
});
2929
});
3030

@@ -42,7 +42,7 @@ describe('resource items', () => {
4242
test('retrieve: required and optional params', async () => {
4343
const response = await client.conversations.items.retrieve('msg_abc', {
4444
conversation_id: 'conv_123',
45-
include: ['code_interpreter_call.outputs'],
45+
include: ['file_search_call.results'],
4646
});
4747
});
4848

@@ -62,7 +62,7 @@ describe('resource items', () => {
6262
await expect(
6363
client.conversations.items.list(
6464
'conv_123',
65-
{ after: 'after', include: ['code_interpreter_call.outputs'], limit: 0, order: 'asc' },
65+
{ after: 'after', include: ['file_search_call.results'], limit: 0, order: 'asc' },
6666
{ path: '/_stainless_unknown_path' },
6767
),
6868
).rejects.toThrow(OpenAI.NotFoundError);

tests/api-resources/responses/input-items.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ describe('resource inputItems', () => {
2424
await expect(
2525
client.responses.inputItems.list(
2626
'response_id',
27-
{ after: 'after', include: ['code_interpreter_call.outputs'], limit: 0, order: 'asc' },
27+
{ after: 'after', include: ['file_search_call.results'], limit: 0, order: 'asc' },
2828
{ path: '/_stainless_unknown_path' },
2929
),
3030
).rejects.toThrow(OpenAI.NotFoundError);

tests/api-resources/responses/responses.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ describe('resource responses', () => {
4242
client.responses.retrieve(
4343
'resp_677efb5139a88190b512bc3fef8e535d',
4444
{
45-
include: ['code_interpreter_call.outputs'],
45+
include: ['file_search_call.results'],
4646
include_obfuscation: true,
4747
starting_after: 0,
4848
stream: false,

0 commit comments

Comments
 (0)