ADAPT-Chase commited on
Commit
0af763d
·
verified ·
1 Parent(s): e7cdb8f

Add files using upload-large-folder tool

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/realtime/realtime.d.mts +2329 -0
  2. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/messages.d.ts +594 -0
  3. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/messages.js.map +1 -0
  4. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs.js +6 -0
  5. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/index.d.ts +3 -0
  6. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/runs.d.mts.map +1 -0
  7. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/steps.d.ts +615 -0
  8. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/steps.js.map +1 -0
  9. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/threads.d.ts.map +1 -0
  10. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/threads.js.map +1 -0
  11. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/completions.d.mts +1624 -0
  12. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/completions.d.ts +1624 -0
  13. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/index.d.ts.map +1 -0
  14. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/index.js +11 -0
  15. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.d.ts +34 -0
  16. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.d.ts.map +1 -0
  17. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.js.map +1 -0
  18. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/content.d.ts.map +1 -0
  19. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/content.js +22 -0
  20. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.mts.map +1 -0
  21. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.ts +148 -0
  22. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.ts.map +1 -0
  23. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.js +56 -0
  24. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.js.map +1 -0
  25. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.mjs +51 -0
  26. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.mjs.map +1 -0
  27. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.mts +3 -0
  28. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.mts.map +1 -0
  29. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.ts +3 -0
  30. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.ts.map +1 -0
  31. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.js +9 -0
  32. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.js.map +1 -0
  33. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.mjs +4 -0
  34. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.mjs.map +1 -0
  35. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/index.d.ts +3 -0
  36. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs.d.ts.map +1 -0
  37. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.mts.map +1 -0
  38. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.ts +3 -0
  39. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.ts.map +1 -0
  40. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.js +9 -0
  41. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.js.map +1 -0
  42. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.mjs +4 -0
  43. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.d.mts +330 -0
  44. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.d.ts +330 -0
  45. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.js +25 -0
  46. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.js.map +1 -0
  47. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.mjs +21 -0
  48. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.mjs.map +1 -0
  49. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/runs.d.mts +2227 -0
  50. platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/runs.d.mts.map +1 -0
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/realtime/realtime.d.mts ADDED
@@ -0,0 +1,2329 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import * as RealtimeAPI from "./realtime.mjs";
3
+ import * as Shared from "../../shared.mjs";
4
+ import * as SessionsAPI from "./sessions.mjs";
5
+ import { Session as SessionsAPISession, SessionCreateParams, SessionCreateResponse, Sessions } from "./sessions.mjs";
6
+ import * as TranscriptionSessionsAPI from "./transcription-sessions.mjs";
7
+ import { TranscriptionSession, TranscriptionSessionCreateParams, TranscriptionSessions } from "./transcription-sessions.mjs";
8
+ export declare class Realtime extends APIResource {
9
+ sessions: SessionsAPI.Sessions;
10
+ transcriptionSessions: TranscriptionSessionsAPI.TranscriptionSessions;
11
+ }
12
+ /**
13
+ * Returned when a conversation is created. Emitted right after session creation.
14
+ */
15
+ export interface ConversationCreatedEvent {
16
+ /**
17
+ * The conversation resource.
18
+ */
19
+ conversation: ConversationCreatedEvent.Conversation;
20
+ /**
21
+ * The unique ID of the server event.
22
+ */
23
+ event_id: string;
24
+ /**
25
+ * The event type, must be `conversation.created`.
26
+ */
27
+ type: 'conversation.created';
28
+ }
29
+ export declare namespace ConversationCreatedEvent {
30
+ /**
31
+ * The conversation resource.
32
+ */
33
+ interface Conversation {
34
+ /**
35
+ * The unique ID of the conversation.
36
+ */
37
+ id?: string;
38
+ /**
39
+ * The object type, must be `realtime.conversation`.
40
+ */
41
+ object?: 'realtime.conversation';
42
+ }
43
+ }
44
+ /**
45
+ * The item to add to the conversation.
46
+ */
47
+ export interface ConversationItem {
48
+ /**
49
+ * The unique ID of the item, this can be generated by the client to help manage
50
+ * server-side context, but is not required because the server will generate one if
51
+ * not provided.
52
+ */
53
+ id?: string;
54
+ /**
55
+ * The arguments of the function call (for `function_call` items).
56
+ */
57
+ arguments?: string;
58
+ /**
59
+ * The ID of the function call (for `function_call` and `function_call_output`
60
+ * items). If passed on a `function_call_output` item, the server will check that a
61
+ * `function_call` item with the same ID exists in the conversation history.
62
+ */
63
+ call_id?: string;
64
+ /**
65
+ * The content of the message, applicable for `message` items.
66
+ *
67
+ * - Message items of role `system` support only `input_text` content
68
+ * - Message items of role `user` support `input_text` and `input_audio` content
69
+ * - Message items of role `assistant` support `text` content.
70
+ */
71
+ content?: Array<ConversationItemContent>;
72
+ /**
73
+ * The name of the function being called (for `function_call` items).
74
+ */
75
+ name?: string;
76
+ /**
77
+ * Identifier for the API object being returned - always `realtime.item`.
78
+ */
79
+ object?: 'realtime.item';
80
+ /**
81
+ * The output of the function call (for `function_call_output` items).
82
+ */
83
+ output?: string;
84
+ /**
85
+ * The role of the message sender (`user`, `assistant`, `system`), only applicable
86
+ * for `message` items.
87
+ */
88
+ role?: 'user' | 'assistant' | 'system';
89
+ /**
90
+ * The status of the item (`completed`, `incomplete`, `in_progress`). These have no
91
+ * effect on the conversation, but are accepted for consistency with the
92
+ * `conversation.item.created` event.
93
+ */
94
+ status?: 'completed' | 'incomplete' | 'in_progress';
95
+ /**
96
+ * The type of the item (`message`, `function_call`, `function_call_output`).
97
+ */
98
+ type?: 'message' | 'function_call' | 'function_call_output';
99
+ }
100
+ export interface ConversationItemContent {
101
+ /**
102
+ * ID of a previous conversation item to reference (for `item_reference` content
103
+ * types in `response.create` events). These can reference both client and server
104
+ * created items.
105
+ */
106
+ id?: string;
107
+ /**
108
+ * Base64-encoded audio bytes, used for `input_audio` content type.
109
+ */
110
+ audio?: string;
111
+ /**
112
+ * The text content, used for `input_text` and `text` content types.
113
+ */
114
+ text?: string;
115
+ /**
116
+ * The transcript of the audio, used for `input_audio` and `audio` content types.
117
+ */
118
+ transcript?: string;
119
+ /**
120
+ * The content type (`input_text`, `input_audio`, `item_reference`, `text`,
121
+ * `audio`).
122
+ */
123
+ type?: 'input_text' | 'input_audio' | 'item_reference' | 'text' | 'audio';
124
+ }
125
+ /**
126
+ * Add a new Item to the Conversation's context, including messages, function
127
+ * calls, and function call responses. This event can be used both to populate a
128
+ * "history" of the conversation and to add new items mid-stream, but has the
129
+ * current limitation that it cannot populate assistant audio messages.
130
+ *
131
+ * If successful, the server will respond with a `conversation.item.created` event,
132
+ * otherwise an `error` event will be sent.
133
+ */
134
+ export interface ConversationItemCreateEvent {
135
+ /**
136
+ * The item to add to the conversation.
137
+ */
138
+ item: ConversationItem;
139
+ /**
140
+ * The event type, must be `conversation.item.create`.
141
+ */
142
+ type: 'conversation.item.create';
143
+ /**
144
+ * Optional client-generated ID used to identify this event.
145
+ */
146
+ event_id?: string;
147
+ /**
148
+ * The ID of the preceding item after which the new item will be inserted. If not
149
+ * set, the new item will be appended to the end of the conversation. If set to
150
+ * `root`, the new item will be added to the beginning of the conversation. If set
151
+ * to an existing ID, it allows an item to be inserted mid-conversation. If the ID
152
+ * cannot be found, an error will be returned and the item will not be added.
153
+ */
154
+ previous_item_id?: string;
155
+ }
156
+ /**
157
+ * Returned when a conversation item is created. There are several scenarios that
158
+ * produce this event:
159
+ *
160
+ * - The server is generating a Response, which if successful will produce either
161
+ * one or two Items, which will be of type `message` (role `assistant`) or type
162
+ * `function_call`.
163
+ * - The input audio buffer has been committed, either by the client or the server
164
+ * (in `server_vad` mode). The server will take the content of the input audio
165
+ * buffer and add it to a new user message Item.
166
+ * - The client has sent a `conversation.item.create` event to add a new Item to
167
+ * the Conversation.
168
+ */
169
+ export interface ConversationItemCreatedEvent {
170
+ /**
171
+ * The unique ID of the server event.
172
+ */
173
+ event_id: string;
174
+ /**
175
+ * The item to add to the conversation.
176
+ */
177
+ item: ConversationItem;
178
+ /**
179
+ * The event type, must be `conversation.item.created`.
180
+ */
181
+ type: 'conversation.item.created';
182
+ /**
183
+ * The ID of the preceding item in the Conversation context, allows the client to
184
+ * understand the order of the conversation. Can be `null` if the item has no
185
+ * predecessor.
186
+ */
187
+ previous_item_id?: string | null;
188
+ }
189
+ /**
190
+ * Send this event when you want to remove any item from the conversation history.
191
+ * The server will respond with a `conversation.item.deleted` event, unless the
192
+ * item does not exist in the conversation history, in which case the server will
193
+ * respond with an error.
194
+ */
195
+ export interface ConversationItemDeleteEvent {
196
+ /**
197
+ * The ID of the item to delete.
198
+ */
199
+ item_id: string;
200
+ /**
201
+ * The event type, must be `conversation.item.delete`.
202
+ */
203
+ type: 'conversation.item.delete';
204
+ /**
205
+ * Optional client-generated ID used to identify this event.
206
+ */
207
+ event_id?: string;
208
+ }
209
+ /**
210
+ * Returned when an item in the conversation is deleted by the client with a
211
+ * `conversation.item.delete` event. This event is used to synchronize the server's
212
+ * understanding of the conversation history with the client's view.
213
+ */
214
+ export interface ConversationItemDeletedEvent {
215
+ /**
216
+ * The unique ID of the server event.
217
+ */
218
+ event_id: string;
219
+ /**
220
+ * The ID of the item that was deleted.
221
+ */
222
+ item_id: string;
223
+ /**
224
+ * The event type, must be `conversation.item.deleted`.
225
+ */
226
+ type: 'conversation.item.deleted';
227
+ }
228
+ /**
229
+ * This event is the output of audio transcription for user audio written to the
230
+ * user audio buffer. Transcription begins when the input audio buffer is committed
231
+ * by the client or server (in `server_vad` mode). Transcription runs
232
+ * asynchronously with Response creation, so this event may come before or after
233
+ * the Response events.
234
+ *
235
+ * Realtime API models accept audio natively, and thus input transcription is a
236
+ * separate process run on a separate ASR (Automatic Speech Recognition) model. The
237
+ * transcript may diverge somewhat from the model's interpretation, and should be
238
+ * treated as a rough guide.
239
+ */
240
+ export interface ConversationItemInputAudioTranscriptionCompletedEvent {
241
+ /**
242
+ * The index of the content part containing the audio.
243
+ */
244
+ content_index: number;
245
+ /**
246
+ * The unique ID of the server event.
247
+ */
248
+ event_id: string;
249
+ /**
250
+ * The ID of the user message item containing the audio.
251
+ */
252
+ item_id: string;
253
+ /**
254
+ * The transcribed text.
255
+ */
256
+ transcript: string;
257
+ /**
258
+ * The event type, must be `conversation.item.input_audio_transcription.completed`.
259
+ */
260
+ type: 'conversation.item.input_audio_transcription.completed';
261
+ /**
262
+ * Usage statistics for the transcription.
263
+ */
264
+ usage: ConversationItemInputAudioTranscriptionCompletedEvent.TranscriptTextUsageTokens | ConversationItemInputAudioTranscriptionCompletedEvent.TranscriptTextUsageDuration;
265
+ /**
266
+ * The log probabilities of the transcription.
267
+ */
268
+ logprobs?: Array<ConversationItemInputAudioTranscriptionCompletedEvent.Logprob> | null;
269
+ }
270
+ export declare namespace ConversationItemInputAudioTranscriptionCompletedEvent {
271
+ /**
272
+ * Usage statistics for models billed by token usage.
273
+ */
274
+ interface TranscriptTextUsageTokens {
275
+ /**
276
+ * Number of input tokens billed for this request.
277
+ */
278
+ input_tokens: number;
279
+ /**
280
+ * Number of output tokens generated.
281
+ */
282
+ output_tokens: number;
283
+ /**
284
+ * Total number of tokens used (input + output).
285
+ */
286
+ total_tokens: number;
287
+ /**
288
+ * The type of the usage object. Always `tokens` for this variant.
289
+ */
290
+ type: 'tokens';
291
+ /**
292
+ * Details about the input tokens billed for this request.
293
+ */
294
+ input_token_details?: TranscriptTextUsageTokens.InputTokenDetails;
295
+ }
296
+ namespace TranscriptTextUsageTokens {
297
+ /**
298
+ * Details about the input tokens billed for this request.
299
+ */
300
+ interface InputTokenDetails {
301
+ /**
302
+ * Number of audio tokens billed for this request.
303
+ */
304
+ audio_tokens?: number;
305
+ /**
306
+ * Number of text tokens billed for this request.
307
+ */
308
+ text_tokens?: number;
309
+ }
310
+ }
311
+ /**
312
+ * Usage statistics for models billed by audio input duration.
313
+ */
314
+ interface TranscriptTextUsageDuration {
315
+ /**
316
+ * Duration of the input audio in seconds.
317
+ */
318
+ seconds: number;
319
+ /**
320
+ * The type of the usage object. Always `duration` for this variant.
321
+ */
322
+ type: 'duration';
323
+ }
324
+ /**
325
+ * A log probability object.
326
+ */
327
+ interface Logprob {
328
+ /**
329
+ * The token that was used to generate the log probability.
330
+ */
331
+ token: string;
332
+ /**
333
+ * The bytes that were used to generate the log probability.
334
+ */
335
+ bytes: Array<number>;
336
+ /**
337
+ * The log probability of the token.
338
+ */
339
+ logprob: number;
340
+ }
341
+ }
342
+ /**
343
+ * Returned when the text value of an input audio transcription content part is
344
+ * updated.
345
+ */
346
+ export interface ConversationItemInputAudioTranscriptionDeltaEvent {
347
+ /**
348
+ * The unique ID of the server event.
349
+ */
350
+ event_id: string;
351
+ /**
352
+ * The ID of the item.
353
+ */
354
+ item_id: string;
355
+ /**
356
+ * The event type, must be `conversation.item.input_audio_transcription.delta`.
357
+ */
358
+ type: 'conversation.item.input_audio_transcription.delta';
359
+ /**
360
+ * The index of the content part in the item's content array.
361
+ */
362
+ content_index?: number;
363
+ /**
364
+ * The text delta.
365
+ */
366
+ delta?: string;
367
+ /**
368
+ * The log probabilities of the transcription.
369
+ */
370
+ logprobs?: Array<ConversationItemInputAudioTranscriptionDeltaEvent.Logprob> | null;
371
+ }
372
+ export declare namespace ConversationItemInputAudioTranscriptionDeltaEvent {
373
+ /**
374
+ * A log probability object.
375
+ */
376
+ interface Logprob {
377
+ /**
378
+ * The token that was used to generate the log probability.
379
+ */
380
+ token: string;
381
+ /**
382
+ * The bytes that were used to generate the log probability.
383
+ */
384
+ bytes: Array<number>;
385
+ /**
386
+ * The log probability of the token.
387
+ */
388
+ logprob: number;
389
+ }
390
+ }
391
+ /**
392
+ * Returned when input audio transcription is configured, and a transcription
393
+ * request for a user message failed. These events are separate from other `error`
394
+ * events so that the client can identify the related Item.
395
+ */
396
+ export interface ConversationItemInputAudioTranscriptionFailedEvent {
397
+ /**
398
+ * The index of the content part containing the audio.
399
+ */
400
+ content_index: number;
401
+ /**
402
+ * Details of the transcription error.
403
+ */
404
+ error: ConversationItemInputAudioTranscriptionFailedEvent.Error;
405
+ /**
406
+ * The unique ID of the server event.
407
+ */
408
+ event_id: string;
409
+ /**
410
+ * The ID of the user message item.
411
+ */
412
+ item_id: string;
413
+ /**
414
+ * The event type, must be `conversation.item.input_audio_transcription.failed`.
415
+ */
416
+ type: 'conversation.item.input_audio_transcription.failed';
417
+ }
418
+ export declare namespace ConversationItemInputAudioTranscriptionFailedEvent {
419
+ /**
420
+ * Details of the transcription error.
421
+ */
422
+ interface Error {
423
+ /**
424
+ * Error code, if any.
425
+ */
426
+ code?: string;
427
+ /**
428
+ * A human-readable error message.
429
+ */
430
+ message?: string;
431
+ /**
432
+ * Parameter related to the error, if any.
433
+ */
434
+ param?: string;
435
+ /**
436
+ * The type of error.
437
+ */
438
+ type?: string;
439
+ }
440
+ }
441
+ /**
442
+ * Send this event when you want to retrieve the server's representation of a
443
+ * specific item in the conversation history. This is useful, for example, to
444
+ * inspect user audio after noise cancellation and VAD. The server will respond
445
+ * with a `conversation.item.retrieved` event, unless the item does not exist in
446
+ * the conversation history, in which case the server will respond with an error.
447
+ */
448
+ export interface ConversationItemRetrieveEvent {
449
+ /**
450
+ * The ID of the item to retrieve.
451
+ */
452
+ item_id: string;
453
+ /**
454
+ * The event type, must be `conversation.item.retrieve`.
455
+ */
456
+ type: 'conversation.item.retrieve';
457
+ /**
458
+ * Optional client-generated ID used to identify this event.
459
+ */
460
+ event_id?: string;
461
+ }
462
+ /**
463
+ * Send this event to truncate a previous assistant message’s audio. The server
464
+ * will produce audio faster than realtime, so this event is useful when the user
465
+ * interrupts to truncate audio that has already been sent to the client but not
466
+ * yet played. This will synchronize the server's understanding of the audio with
467
+ * the client's playback.
468
+ *
469
+ * Truncating audio will delete the server-side text transcript to ensure there is
470
+ * not text in the context that hasn't been heard by the user.
471
+ *
472
+ * If successful, the server will respond with a `conversation.item.truncated`
473
+ * event.
474
+ */
475
+ export interface ConversationItemTruncateEvent {
476
+ /**
477
+ * Inclusive duration up to which audio is truncated, in milliseconds. If the
478
+ * audio_end_ms is greater than the actual audio duration, the server will respond
479
+ * with an error.
480
+ */
481
+ audio_end_ms: number;
482
+ /**
483
+ * The index of the content part to truncate. Set this to 0.
484
+ */
485
+ content_index: number;
486
+ /**
487
+ * The ID of the assistant message item to truncate. Only assistant message items
488
+ * can be truncated.
489
+ */
490
+ item_id: string;
491
+ /**
492
+ * The event type, must be `conversation.item.truncate`.
493
+ */
494
+ type: 'conversation.item.truncate';
495
+ /**
496
+ * Optional client-generated ID used to identify this event.
497
+ */
498
+ event_id?: string;
499
+ }
500
+ /**
501
+ * Returned when an earlier assistant audio message item is truncated by the client
502
+ * with a `conversation.item.truncate` event. This event is used to synchronize the
503
+ * server's understanding of the audio with the client's playback.
504
+ *
505
+ * This action will truncate the audio and remove the server-side text transcript
506
+ * to ensure there is no text in the context that hasn't been heard by the user.
507
+ */
508
+ export interface ConversationItemTruncatedEvent {
509
+ /**
510
+ * The duration up to which the audio was truncated, in milliseconds.
511
+ */
512
+ audio_end_ms: number;
513
+ /**
514
+ * The index of the content part that was truncated.
515
+ */
516
+ content_index: number;
517
+ /**
518
+ * The unique ID of the server event.
519
+ */
520
+ event_id: string;
521
+ /**
522
+ * The ID of the assistant message item that was truncated.
523
+ */
524
+ item_id: string;
525
+ /**
526
+ * The event type, must be `conversation.item.truncated`.
527
+ */
528
+ type: 'conversation.item.truncated';
529
+ }
530
+ /**
531
+ * The item to add to the conversation.
532
+ */
533
+ export interface ConversationItemWithReference {
534
+ /**
535
+ * For an item of type (`message` | `function_call` | `function_call_output`) this
536
+ * field allows the client to assign the unique ID of the item. It is not required
537
+ * because the server will generate one if not provided.
538
+ *
539
+ * For an item of type `item_reference`, this field is required and is a reference
540
+ * to any item that has previously existed in the conversation.
541
+ */
542
+ id?: string;
543
+ /**
544
+ * The arguments of the function call (for `function_call` items).
545
+ */
546
+ arguments?: string;
547
+ /**
548
+ * The ID of the function call (for `function_call` and `function_call_output`
549
+ * items). If passed on a `function_call_output` item, the server will check that a
550
+ * `function_call` item with the same ID exists in the conversation history.
551
+ */
552
+ call_id?: string;
553
+ /**
554
+ * The content of the message, applicable for `message` items.
555
+ *
556
+ * - Message items of role `system` support only `input_text` content
557
+ * - Message items of role `user` support `input_text` and `input_audio` content
558
+ * - Message items of role `assistant` support `text` content.
559
+ */
560
+ content?: Array<ConversationItemWithReference.Content>;
561
+ /**
562
+ * The name of the function being called (for `function_call` items).
563
+ */
564
+ name?: string;
565
+ /**
566
+ * Identifier for the API object being returned - always `realtime.item`.
567
+ */
568
+ object?: 'realtime.item';
569
+ /**
570
+ * The output of the function call (for `function_call_output` items).
571
+ */
572
+ output?: string;
573
+ /**
574
+ * The role of the message sender (`user`, `assistant`, `system`), only applicable
575
+ * for `message` items.
576
+ */
577
+ role?: 'user' | 'assistant' | 'system';
578
+ /**
579
+ * The status of the item (`completed`, `incomplete`, `in_progress`). These have no
580
+ * effect on the conversation, but are accepted for consistency with the
581
+ * `conversation.item.created` event.
582
+ */
583
+ status?: 'completed' | 'incomplete' | 'in_progress';
584
+ /**
585
+ * The type of the item (`message`, `function_call`, `function_call_output`,
586
+ * `item_reference`).
587
+ */
588
+ type?: 'message' | 'function_call' | 'function_call_output' | 'item_reference';
589
+ }
590
+ export declare namespace ConversationItemWithReference {
591
+ interface Content {
592
+ /**
593
+ * ID of a previous conversation item to reference (for `item_reference` content
594
+ * types in `response.create` events). These can reference both client and server
595
+ * created items.
596
+ */
597
+ id?: string;
598
+ /**
599
+ * Base64-encoded audio bytes, used for `input_audio` content type.
600
+ */
601
+ audio?: string;
602
+ /**
603
+ * The text content, used for `input_text` and `text` content types.
604
+ */
605
+ text?: string;
606
+ /**
607
+ * The transcript of the audio, used for `input_audio` content type.
608
+ */
609
+ transcript?: string;
610
+ /**
611
+ * The content type (`input_text`, `input_audio`, `item_reference`, `text`).
612
+ */
613
+ type?: 'input_text' | 'input_audio' | 'item_reference' | 'text';
614
+ }
615
+ }
616
+ /**
617
+ * Returned when an error occurs, which could be a client problem or a server
618
+ * problem. Most errors are recoverable and the session will stay open, we
619
+ * recommend to implementors to monitor and log error messages by default.
620
+ */
621
+ export interface ErrorEvent {
622
+ /**
623
+ * Details of the error.
624
+ */
625
+ error: ErrorEvent.Error;
626
+ /**
627
+ * The unique ID of the server event.
628
+ */
629
+ event_id: string;
630
+ /**
631
+ * The event type, must be `error`.
632
+ */
633
+ type: 'error';
634
+ }
635
+ export declare namespace ErrorEvent {
636
+ /**
637
+ * Details of the error.
638
+ */
639
+ interface Error {
640
+ /**
641
+ * A human-readable error message.
642
+ */
643
+ message: string;
644
+ /**
645
+ * The type of error (e.g., "invalid_request_error", "server_error").
646
+ */
647
+ type: string;
648
+ /**
649
+ * Error code, if any.
650
+ */
651
+ code?: string | null;
652
+ /**
653
+ * The event_id of the client event that caused the error, if applicable.
654
+ */
655
+ event_id?: string | null;
656
+ /**
657
+ * Parameter related to the error, if any.
658
+ */
659
+ param?: string | null;
660
+ }
661
+ }
662
+ /**
663
+ * Send this event to append audio bytes to the input audio buffer. The audio
664
+ * buffer is temporary storage you can write to and later commit. In Server VAD
665
+ * mode, the audio buffer is used to detect speech and the server will decide when
666
+ * to commit. When Server VAD is disabled, you must commit the audio buffer
667
+ * manually.
668
+ *
669
+ * The client may choose how much audio to place in each event up to a maximum of
670
+ * 15 MiB, for example streaming smaller chunks from the client may allow the VAD
671
+ * to be more responsive. Unlike made other client events, the server will not send
672
+ * a confirmation response to this event.
673
+ */
674
+ export interface InputAudioBufferAppendEvent {
675
+ /**
676
+ * Base64-encoded audio bytes. This must be in the format specified by the
677
+ * `input_audio_format` field in the session configuration.
678
+ */
679
+ audio: string;
680
+ /**
681
+ * The event type, must be `input_audio_buffer.append`.
682
+ */
683
+ type: 'input_audio_buffer.append';
684
+ /**
685
+ * Optional client-generated ID used to identify this event.
686
+ */
687
+ event_id?: string;
688
+ }
689
+ /**
690
+ * Send this event to clear the audio bytes in the buffer. The server will respond
691
+ * with an `input_audio_buffer.cleared` event.
692
+ */
693
+ export interface InputAudioBufferClearEvent {
694
+ /**
695
+ * The event type, must be `input_audio_buffer.clear`.
696
+ */
697
+ type: 'input_audio_buffer.clear';
698
+ /**
699
+ * Optional client-generated ID used to identify this event.
700
+ */
701
+ event_id?: string;
702
+ }
703
+ /**
704
+ * Returned when the input audio buffer is cleared by the client with a
705
+ * `input_audio_buffer.clear` event.
706
+ */
707
+ export interface InputAudioBufferClearedEvent {
708
+ /**
709
+ * The unique ID of the server event.
710
+ */
711
+ event_id: string;
712
+ /**
713
+ * The event type, must be `input_audio_buffer.cleared`.
714
+ */
715
+ type: 'input_audio_buffer.cleared';
716
+ }
717
+ /**
718
+ * Send this event to commit the user input audio buffer, which will create a new
719
+ * user message item in the conversation. This event will produce an error if the
720
+ * input audio buffer is empty. When in Server VAD mode, the client does not need
721
+ * to send this event, the server will commit the audio buffer automatically.
722
+ *
723
+ * Committing the input audio buffer will trigger input audio transcription (if
724
+ * enabled in session configuration), but it will not create a response from the
725
+ * model. The server will respond with an `input_audio_buffer.committed` event.
726
+ */
727
+ export interface InputAudioBufferCommitEvent {
728
+ /**
729
+ * The event type, must be `input_audio_buffer.commit`.
730
+ */
731
+ type: 'input_audio_buffer.commit';
732
+ /**
733
+ * Optional client-generated ID used to identify this event.
734
+ */
735
+ event_id?: string;
736
+ }
737
+ /**
738
+ * Returned when an input audio buffer is committed, either by the client or
739
+ * automatically in server VAD mode. The `item_id` property is the ID of the user
740
+ * message item that will be created, thus a `conversation.item.created` event will
741
+ * also be sent to the client.
742
+ */
743
+ export interface InputAudioBufferCommittedEvent {
744
+ /**
745
+ * The unique ID of the server event.
746
+ */
747
+ event_id: string;
748
+ /**
749
+ * The ID of the user message item that will be created.
750
+ */
751
+ item_id: string;
752
+ /**
753
+ * The event type, must be `input_audio_buffer.committed`.
754
+ */
755
+ type: 'input_audio_buffer.committed';
756
+ /**
757
+ * The ID of the preceding item after which the new item will be inserted. Can be
758
+ * `null` if the item has no predecessor.
759
+ */
760
+ previous_item_id?: string | null;
761
+ }
762
+ /**
763
+ * Sent by the server when in `server_vad` mode to indicate that speech has been
764
+ * detected in the audio buffer. This can happen any time audio is added to the
765
+ * buffer (unless speech is already detected). The client may want to use this
766
+ * event to interrupt audio playback or provide visual feedback to the user.
767
+ *
768
+ * The client should expect to receive a `input_audio_buffer.speech_stopped` event
769
+ * when speech stops. The `item_id` property is the ID of the user message item
770
+ * that will be created when speech stops and will also be included in the
771
+ * `input_audio_buffer.speech_stopped` event (unless the client manually commits
772
+ * the audio buffer during VAD activation).
773
+ */
774
+ export interface InputAudioBufferSpeechStartedEvent {
775
+ /**
776
+ * Milliseconds from the start of all audio written to the buffer during the
777
+ * session when speech was first detected. This will correspond to the beginning of
778
+ * audio sent to the model, and thus includes the `prefix_padding_ms` configured in
779
+ * the Session.
780
+ */
781
+ audio_start_ms: number;
782
+ /**
783
+ * The unique ID of the server event.
784
+ */
785
+ event_id: string;
786
+ /**
787
+ * The ID of the user message item that will be created when speech stops.
788
+ */
789
+ item_id: string;
790
+ /**
791
+ * The event type, must be `input_audio_buffer.speech_started`.
792
+ */
793
+ type: 'input_audio_buffer.speech_started';
794
+ }
795
+ /**
796
+ * Returned in `server_vad` mode when the server detects the end of speech in the
797
+ * audio buffer. The server will also send an `conversation.item.created` event
798
+ * with the user message item that is created from the audio buffer.
799
+ */
800
+ export interface InputAudioBufferSpeechStoppedEvent {
801
+ /**
802
+ * Milliseconds since the session started when speech stopped. This will correspond
803
+ * to the end of audio sent to the model, and thus includes the
804
+ * `min_silence_duration_ms` configured in the Session.
805
+ */
806
+ audio_end_ms: number;
807
+ /**
808
+ * The unique ID of the server event.
809
+ */
810
+ event_id: string;
811
+ /**
812
+ * The ID of the user message item that will be created.
813
+ */
814
+ item_id: string;
815
+ /**
816
+ * The event type, must be `input_audio_buffer.speech_stopped`.
817
+ */
818
+ type: 'input_audio_buffer.speech_stopped';
819
+ }
820
+ /**
821
+ * Emitted at the beginning of a Response to indicate the updated rate limits. When
822
+ * a Response is created some tokens will be "reserved" for the output tokens, the
823
+ * rate limits shown here reflect that reservation, which is then adjusted
824
+ * accordingly once the Response is completed.
825
+ */
826
+ export interface RateLimitsUpdatedEvent {
827
+ /**
828
+ * The unique ID of the server event.
829
+ */
830
+ event_id: string;
831
+ /**
832
+ * List of rate limit information.
833
+ */
834
+ rate_limits: Array<RateLimitsUpdatedEvent.RateLimit>;
835
+ /**
836
+ * The event type, must be `rate_limits.updated`.
837
+ */
838
+ type: 'rate_limits.updated';
839
+ }
840
+ export declare namespace RateLimitsUpdatedEvent {
841
+ interface RateLimit {
842
+ /**
843
+ * The maximum allowed value for the rate limit.
844
+ */
845
+ limit?: number;
846
+ /**
847
+ * The name of the rate limit (`requests`, `tokens`).
848
+ */
849
+ name?: 'requests' | 'tokens';
850
+ /**
851
+ * The remaining value before the limit is reached.
852
+ */
853
+ remaining?: number;
854
+ /**
855
+ * Seconds until the rate limit resets.
856
+ */
857
+ reset_seconds?: number;
858
+ }
859
+ }
860
+ /**
861
+ * A realtime client event.
862
+ */
863
+ export type RealtimeClientEvent = ConversationItemCreateEvent | ConversationItemDeleteEvent | ConversationItemRetrieveEvent | ConversationItemTruncateEvent | InputAudioBufferAppendEvent | InputAudioBufferClearEvent | RealtimeClientEvent.OutputAudioBufferClear | InputAudioBufferCommitEvent | ResponseCancelEvent | ResponseCreateEvent | SessionUpdateEvent | TranscriptionSessionUpdate;
864
+ export declare namespace RealtimeClientEvent {
865
+ /**
866
+ * **WebRTC Only:** Emit to cut off the current audio response. This will trigger
867
+ * the server to stop generating audio and emit a `output_audio_buffer.cleared`
868
+ * event. This event should be preceded by a `response.cancel` client event to stop
869
+ * the generation of the current response.
870
+ * [Learn more](https://platform.openai.com/docs/guides/realtime-conversations#client-and-server-events-for-audio-in-webrtc).
871
+ */
872
+ interface OutputAudioBufferClear {
873
+ /**
874
+ * The event type, must be `output_audio_buffer.clear`.
875
+ */
876
+ type: 'output_audio_buffer.clear';
877
+ /**
878
+ * The unique ID of the client event used for error handling.
879
+ */
880
+ event_id?: string;
881
+ }
882
+ }
883
+ /**
884
+ * The response resource.
885
+ */
886
+ export interface RealtimeResponse {
887
+ /**
888
+ * The unique ID of the response.
889
+ */
890
+ id?: string;
891
+ /**
892
+ * Which conversation the response is added to, determined by the `conversation`
893
+ * field in the `response.create` event. If `auto`, the response will be added to
894
+ * the default conversation and the value of `conversation_id` will be an id like
895
+ * `conv_1234`. If `none`, the response will not be added to any conversation and
896
+ * the value of `conversation_id` will be `null`. If responses are being triggered
897
+ * by server VAD, the response will be added to the default conversation, thus the
898
+ * `conversation_id` will be an id like `conv_1234`.
899
+ */
900
+ conversation_id?: string;
901
+ /**
902
+ * Maximum number of output tokens for a single assistant response, inclusive of
903
+ * tool calls, that was used in this response.
904
+ */
905
+ max_output_tokens?: number | 'inf';
906
+ /**
907
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
908
+ * for storing additional information about the object in a structured format, and
909
+ * querying for objects via API or the dashboard.
910
+ *
911
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
912
+ * a maximum length of 512 characters.
913
+ */
914
+ metadata?: Shared.Metadata | null;
915
+ /**
916
+ * The set of modalities the model used to respond. If there are multiple
917
+ * modalities, the model will pick one, for example if `modalities` is
918
+ * `["text", "audio"]`, the model could be responding in either text or audio.
919
+ */
920
+ modalities?: Array<'text' | 'audio'>;
921
+ /**
922
+ * The object type, must be `realtime.response`.
923
+ */
924
+ object?: 'realtime.response';
925
+ /**
926
+ * The list of output items generated by the response.
927
+ */
928
+ output?: Array<ConversationItem>;
929
+ /**
930
+ * The format of output audio. Options are `pcm16`, `g711_ulaw`, or `g711_alaw`.
931
+ */
932
+ output_audio_format?: 'pcm16' | 'g711_ulaw' | 'g711_alaw';
933
+ /**
934
+ * The final status of the response (`completed`, `cancelled`, `failed`, or
935
+ * `incomplete`, `in_progress`).
936
+ */
937
+ status?: 'completed' | 'cancelled' | 'failed' | 'incomplete' | 'in_progress';
938
+ /**
939
+ * Additional details about the status.
940
+ */
941
+ status_details?: RealtimeResponseStatus;
942
+ /**
943
+ * Sampling temperature for the model, limited to [0.6, 1.2]. Defaults to 0.8.
944
+ */
945
+ temperature?: number;
946
+ /**
947
+ * Usage statistics for the Response, this will correspond to billing. A Realtime
948
+ * API session will maintain a conversation context and append new Items to the
949
+ * Conversation, thus output from previous turns (text and audio tokens) will
950
+ * become the input for later turns.
951
+ */
952
+ usage?: RealtimeResponseUsage;
953
+ /**
954
+ * The voice the model used to respond. Current voice options are `alloy`, `ash`,
955
+ * `ballad`, `coral`, `echo`, `sage`, `shimmer`, and `verse`.
956
+ */
957
+ voice?: (string & {}) | 'alloy' | 'ash' | 'ballad' | 'coral' | 'echo' | 'sage' | 'shimmer' | 'verse';
958
+ }
959
+ /**
960
+ * Additional details about the status.
961
+ */
962
+ export interface RealtimeResponseStatus {
963
+ /**
964
+ * A description of the error that caused the response to fail, populated when the
965
+ * `status` is `failed`.
966
+ */
967
+ error?: RealtimeResponseStatus.Error;
968
+ /**
969
+ * The reason the Response did not complete. For a `cancelled` Response, one of
970
+ * `turn_detected` (the server VAD detected a new start of speech) or
971
+ * `client_cancelled` (the client sent a cancel event). For an `incomplete`
972
+ * Response, one of `max_output_tokens` or `content_filter` (the server-side safety
973
+ * filter activated and cut off the response).
974
+ */
975
+ reason?: 'turn_detected' | 'client_cancelled' | 'max_output_tokens' | 'content_filter';
976
+ /**
977
+ * The type of error that caused the response to fail, corresponding with the
978
+ * `status` field (`completed`, `cancelled`, `incomplete`, `failed`).
979
+ */
980
+ type?: 'completed' | 'cancelled' | 'incomplete' | 'failed';
981
+ }
982
+ export declare namespace RealtimeResponseStatus {
983
+ /**
984
+ * A description of the error that caused the response to fail, populated when the
985
+ * `status` is `failed`.
986
+ */
987
+ interface Error {
988
+ /**
989
+ * Error code, if any.
990
+ */
991
+ code?: string;
992
+ /**
993
+ * The type of error.
994
+ */
995
+ type?: string;
996
+ }
997
+ }
998
+ /**
999
+ * Usage statistics for the Response, this will correspond to billing. A Realtime
1000
+ * API session will maintain a conversation context and append new Items to the
1001
+ * Conversation, thus output from previous turns (text and audio tokens) will
1002
+ * become the input for later turns.
1003
+ */
1004
+ export interface RealtimeResponseUsage {
1005
+ /**
1006
+ * Details about the input tokens used in the Response.
1007
+ */
1008
+ input_token_details?: RealtimeResponseUsage.InputTokenDetails;
1009
+ /**
1010
+ * The number of input tokens used in the Response, including text and audio
1011
+ * tokens.
1012
+ */
1013
+ input_tokens?: number;
1014
+ /**
1015
+ * Details about the output tokens used in the Response.
1016
+ */
1017
+ output_token_details?: RealtimeResponseUsage.OutputTokenDetails;
1018
+ /**
1019
+ * The number of output tokens sent in the Response, including text and audio
1020
+ * tokens.
1021
+ */
1022
+ output_tokens?: number;
1023
+ /**
1024
+ * The total number of tokens in the Response including input and output text and
1025
+ * audio tokens.
1026
+ */
1027
+ total_tokens?: number;
1028
+ }
1029
+ export declare namespace RealtimeResponseUsage {
1030
+ /**
1031
+ * Details about the input tokens used in the Response.
1032
+ */
1033
+ interface InputTokenDetails {
1034
+ /**
1035
+ * The number of audio tokens used in the Response.
1036
+ */
1037
+ audio_tokens?: number;
1038
+ /**
1039
+ * The number of cached tokens used in the Response.
1040
+ */
1041
+ cached_tokens?: number;
1042
+ /**
1043
+ * The number of text tokens used in the Response.
1044
+ */
1045
+ text_tokens?: number;
1046
+ }
1047
+ /**
1048
+ * Details about the output tokens used in the Response.
1049
+ */
1050
+ interface OutputTokenDetails {
1051
+ /**
1052
+ * The number of audio tokens used in the Response.
1053
+ */
1054
+ audio_tokens?: number;
1055
+ /**
1056
+ * The number of text tokens used in the Response.
1057
+ */
1058
+ text_tokens?: number;
1059
+ }
1060
+ }
1061
+ /**
1062
+ * A realtime server event.
1063
+ */
1064
+ export type RealtimeServerEvent = ConversationCreatedEvent | ConversationItemCreatedEvent | ConversationItemDeletedEvent | ConversationItemInputAudioTranscriptionCompletedEvent | ConversationItemInputAudioTranscriptionDeltaEvent | ConversationItemInputAudioTranscriptionFailedEvent | RealtimeServerEvent.ConversationItemRetrieved | ConversationItemTruncatedEvent | ErrorEvent | InputAudioBufferClearedEvent | InputAudioBufferCommittedEvent | InputAudioBufferSpeechStartedEvent | InputAudioBufferSpeechStoppedEvent | RateLimitsUpdatedEvent | ResponseAudioDeltaEvent | ResponseAudioDoneEvent | ResponseAudioTranscriptDeltaEvent | ResponseAudioTranscriptDoneEvent | ResponseContentPartAddedEvent | ResponseContentPartDoneEvent | ResponseCreatedEvent | ResponseDoneEvent | ResponseFunctionCallArgumentsDeltaEvent | ResponseFunctionCallArgumentsDoneEvent | ResponseOutputItemAddedEvent | ResponseOutputItemDoneEvent | ResponseTextDeltaEvent | ResponseTextDoneEvent | SessionCreatedEvent | SessionUpdatedEvent | TranscriptionSessionUpdatedEvent | RealtimeServerEvent.OutputAudioBufferStarted | RealtimeServerEvent.OutputAudioBufferStopped | RealtimeServerEvent.OutputAudioBufferCleared;
1065
+ export declare namespace RealtimeServerEvent {
1066
+ /**
1067
+ * Returned when a conversation item is retrieved with
1068
+ * `conversation.item.retrieve`.
1069
+ */
1070
+ interface ConversationItemRetrieved {
1071
+ /**
1072
+ * The unique ID of the server event.
1073
+ */
1074
+ event_id: string;
1075
+ /**
1076
+ * The item to add to the conversation.
1077
+ */
1078
+ item: RealtimeAPI.ConversationItem;
1079
+ /**
1080
+ * The event type, must be `conversation.item.retrieved`.
1081
+ */
1082
+ type: 'conversation.item.retrieved';
1083
+ }
1084
+ /**
1085
+ * **WebRTC Only:** Emitted when the server begins streaming audio to the client.
1086
+ * This event is emitted after an audio content part has been added
1087
+ * (`response.content_part.added`) to the response.
1088
+ * [Learn more](https://platform.openai.com/docs/guides/realtime-conversations#client-and-server-events-for-audio-in-webrtc).
1089
+ */
1090
+ interface OutputAudioBufferStarted {
1091
+ /**
1092
+ * The unique ID of the server event.
1093
+ */
1094
+ event_id: string;
1095
+ /**
1096
+ * The unique ID of the response that produced the audio.
1097
+ */
1098
+ response_id: string;
1099
+ /**
1100
+ * The event type, must be `output_audio_buffer.started`.
1101
+ */
1102
+ type: 'output_audio_buffer.started';
1103
+ }
1104
+ /**
1105
+ * **WebRTC Only:** Emitted when the output audio buffer has been completely
1106
+ * drained on the server, and no more audio is forthcoming. This event is emitted
1107
+ * after the full response data has been sent to the client (`response.done`).
1108
+ * [Learn more](https://platform.openai.com/docs/guides/realtime-conversations#client-and-server-events-for-audio-in-webrtc).
1109
+ */
1110
+ interface OutputAudioBufferStopped {
1111
+ /**
1112
+ * The unique ID of the server event.
1113
+ */
1114
+ event_id: string;
1115
+ /**
1116
+ * The unique ID of the response that produced the audio.
1117
+ */
1118
+ response_id: string;
1119
+ /**
1120
+ * The event type, must be `output_audio_buffer.stopped`.
1121
+ */
1122
+ type: 'output_audio_buffer.stopped';
1123
+ }
1124
+ /**
1125
+ * **WebRTC Only:** Emitted when the output audio buffer is cleared. This happens
1126
+ * either in VAD mode when the user has interrupted
1127
+ * (`input_audio_buffer.speech_started`), or when the client has emitted the
1128
+ * `output_audio_buffer.clear` event to manually cut off the current audio
1129
+ * response.
1130
+ * [Learn more](https://platform.openai.com/docs/guides/realtime-conversations#client-and-server-events-for-audio-in-webrtc).
1131
+ */
1132
+ interface OutputAudioBufferCleared {
1133
+ /**
1134
+ * The unique ID of the server event.
1135
+ */
1136
+ event_id: string;
1137
+ /**
1138
+ * The unique ID of the response that produced the audio.
1139
+ */
1140
+ response_id: string;
1141
+ /**
1142
+ * The event type, must be `output_audio_buffer.cleared`.
1143
+ */
1144
+ type: 'output_audio_buffer.cleared';
1145
+ }
1146
+ }
1147
+ /**
1148
+ * Returned when the model-generated audio is updated.
1149
+ */
1150
+ export interface ResponseAudioDeltaEvent {
1151
+ /**
1152
+ * The index of the content part in the item's content array.
1153
+ */
1154
+ content_index: number;
1155
+ /**
1156
+ * Base64-encoded audio data delta.
1157
+ */
1158
+ delta: string;
1159
+ /**
1160
+ * The unique ID of the server event.
1161
+ */
1162
+ event_id: string;
1163
+ /**
1164
+ * The ID of the item.
1165
+ */
1166
+ item_id: string;
1167
+ /**
1168
+ * The index of the output item in the response.
1169
+ */
1170
+ output_index: number;
1171
+ /**
1172
+ * The ID of the response.
1173
+ */
1174
+ response_id: string;
1175
+ /**
1176
+ * The event type, must be `response.audio.delta`.
1177
+ */
1178
+ type: 'response.audio.delta';
1179
+ }
1180
+ /**
1181
+ * Returned when the model-generated audio is done. Also emitted when a Response is
1182
+ * interrupted, incomplete, or cancelled.
1183
+ */
1184
+ export interface ResponseAudioDoneEvent {
1185
+ /**
1186
+ * The index of the content part in the item's content array.
1187
+ */
1188
+ content_index: number;
1189
+ /**
1190
+ * The unique ID of the server event.
1191
+ */
1192
+ event_id: string;
1193
+ /**
1194
+ * The ID of the item.
1195
+ */
1196
+ item_id: string;
1197
+ /**
1198
+ * The index of the output item in the response.
1199
+ */
1200
+ output_index: number;
1201
+ /**
1202
+ * The ID of the response.
1203
+ */
1204
+ response_id: string;
1205
+ /**
1206
+ * The event type, must be `response.audio.done`.
1207
+ */
1208
+ type: 'response.audio.done';
1209
+ }
1210
+ /**
1211
+ * Returned when the model-generated transcription of audio output is updated.
1212
+ */
1213
+ export interface ResponseAudioTranscriptDeltaEvent {
1214
+ /**
1215
+ * The index of the content part in the item's content array.
1216
+ */
1217
+ content_index: number;
1218
+ /**
1219
+ * The transcript delta.
1220
+ */
1221
+ delta: string;
1222
+ /**
1223
+ * The unique ID of the server event.
1224
+ */
1225
+ event_id: string;
1226
+ /**
1227
+ * The ID of the item.
1228
+ */
1229
+ item_id: string;
1230
+ /**
1231
+ * The index of the output item in the response.
1232
+ */
1233
+ output_index: number;
1234
+ /**
1235
+ * The ID of the response.
1236
+ */
1237
+ response_id: string;
1238
+ /**
1239
+ * The event type, must be `response.audio_transcript.delta`.
1240
+ */
1241
+ type: 'response.audio_transcript.delta';
1242
+ }
1243
+ /**
1244
+ * Returned when the model-generated transcription of audio output is done
1245
+ * streaming. Also emitted when a Response is interrupted, incomplete, or
1246
+ * cancelled.
1247
+ */
1248
+ export interface ResponseAudioTranscriptDoneEvent {
1249
+ /**
1250
+ * The index of the content part in the item's content array.
1251
+ */
1252
+ content_index: number;
1253
+ /**
1254
+ * The unique ID of the server event.
1255
+ */
1256
+ event_id: string;
1257
+ /**
1258
+ * The ID of the item.
1259
+ */
1260
+ item_id: string;
1261
+ /**
1262
+ * The index of the output item in the response.
1263
+ */
1264
+ output_index: number;
1265
+ /**
1266
+ * The ID of the response.
1267
+ */
1268
+ response_id: string;
1269
+ /**
1270
+ * The final transcript of the audio.
1271
+ */
1272
+ transcript: string;
1273
+ /**
1274
+ * The event type, must be `response.audio_transcript.done`.
1275
+ */
1276
+ type: 'response.audio_transcript.done';
1277
+ }
1278
+ /**
1279
+ * Send this event to cancel an in-progress response. The server will respond with
1280
+ * a `response.done` event with a status of `response.status=cancelled`. If there
1281
+ * is no response to cancel, the server will respond with an error.
1282
+ */
1283
+ export interface ResponseCancelEvent {
1284
+ /**
1285
+ * The event type, must be `response.cancel`.
1286
+ */
1287
+ type: 'response.cancel';
1288
+ /**
1289
+ * Optional client-generated ID used to identify this event.
1290
+ */
1291
+ event_id?: string;
1292
+ /**
1293
+ * A specific response ID to cancel - if not provided, will cancel an in-progress
1294
+ * response in the default conversation.
1295
+ */
1296
+ response_id?: string;
1297
+ }
1298
+ /**
1299
+ * Returned when a new content part is added to an assistant message item during
1300
+ * response generation.
1301
+ */
1302
+ export interface ResponseContentPartAddedEvent {
1303
+ /**
1304
+ * The index of the content part in the item's content array.
1305
+ */
1306
+ content_index: number;
1307
+ /**
1308
+ * The unique ID of the server event.
1309
+ */
1310
+ event_id: string;
1311
+ /**
1312
+ * The ID of the item to which the content part was added.
1313
+ */
1314
+ item_id: string;
1315
+ /**
1316
+ * The index of the output item in the response.
1317
+ */
1318
+ output_index: number;
1319
+ /**
1320
+ * The content part that was added.
1321
+ */
1322
+ part: ResponseContentPartAddedEvent.Part;
1323
+ /**
1324
+ * The ID of the response.
1325
+ */
1326
+ response_id: string;
1327
+ /**
1328
+ * The event type, must be `response.content_part.added`.
1329
+ */
1330
+ type: 'response.content_part.added';
1331
+ }
1332
+ export declare namespace ResponseContentPartAddedEvent {
1333
+ /**
1334
+ * The content part that was added.
1335
+ */
1336
+ interface Part {
1337
+ /**
1338
+ * Base64-encoded audio data (if type is "audio").
1339
+ */
1340
+ audio?: string;
1341
+ /**
1342
+ * The text content (if type is "text").
1343
+ */
1344
+ text?: string;
1345
+ /**
1346
+ * The transcript of the audio (if type is "audio").
1347
+ */
1348
+ transcript?: string;
1349
+ /**
1350
+ * The content type ("text", "audio").
1351
+ */
1352
+ type?: 'text' | 'audio';
1353
+ }
1354
+ }
1355
+ /**
1356
+ * Returned when a content part is done streaming in an assistant message item.
1357
+ * Also emitted when a Response is interrupted, incomplete, or cancelled.
1358
+ */
1359
+ export interface ResponseContentPartDoneEvent {
1360
+ /**
1361
+ * The index of the content part in the item's content array.
1362
+ */
1363
+ content_index: number;
1364
+ /**
1365
+ * The unique ID of the server event.
1366
+ */
1367
+ event_id: string;
1368
+ /**
1369
+ * The ID of the item.
1370
+ */
1371
+ item_id: string;
1372
+ /**
1373
+ * The index of the output item in the response.
1374
+ */
1375
+ output_index: number;
1376
+ /**
1377
+ * The content part that is done.
1378
+ */
1379
+ part: ResponseContentPartDoneEvent.Part;
1380
+ /**
1381
+ * The ID of the response.
1382
+ */
1383
+ response_id: string;
1384
+ /**
1385
+ * The event type, must be `response.content_part.done`.
1386
+ */
1387
+ type: 'response.content_part.done';
1388
+ }
1389
+ export declare namespace ResponseContentPartDoneEvent {
1390
+ /**
1391
+ * The content part that is done.
1392
+ */
1393
+ interface Part {
1394
+ /**
1395
+ * Base64-encoded audio data (if type is "audio").
1396
+ */
1397
+ audio?: string;
1398
+ /**
1399
+ * The text content (if type is "text").
1400
+ */
1401
+ text?: string;
1402
+ /**
1403
+ * The transcript of the audio (if type is "audio").
1404
+ */
1405
+ transcript?: string;
1406
+ /**
1407
+ * The content type ("text", "audio").
1408
+ */
1409
+ type?: 'text' | 'audio';
1410
+ }
1411
+ }
1412
+ /**
1413
+ * This event instructs the server to create a Response, which means triggering
1414
+ * model inference. When in Server VAD mode, the server will create Responses
1415
+ * automatically.
1416
+ *
1417
+ * A Response will include at least one Item, and may have two, in which case the
1418
+ * second will be a function call. These Items will be appended to the conversation
1419
+ * history.
1420
+ *
1421
+ * The server will respond with a `response.created` event, events for Items and
1422
+ * content created, and finally a `response.done` event to indicate the Response is
1423
+ * complete.
1424
+ *
1425
+ * The `response.create` event includes inference configuration like
1426
+ * `instructions`, and `temperature`. These fields will override the Session's
1427
+ * configuration for this Response only.
1428
+ */
1429
+ export interface ResponseCreateEvent {
1430
+ /**
1431
+ * The event type, must be `response.create`.
1432
+ */
1433
+ type: 'response.create';
1434
+ /**
1435
+ * Optional client-generated ID used to identify this event.
1436
+ */
1437
+ event_id?: string;
1438
+ /**
1439
+ * Create a new Realtime response with these parameters
1440
+ */
1441
+ response?: ResponseCreateEvent.Response;
1442
+ }
1443
+ export declare namespace ResponseCreateEvent {
1444
+ /**
1445
+ * Create a new Realtime response with these parameters
1446
+ */
1447
+ interface Response {
1448
+ /**
1449
+ * Controls which conversation the response is added to. Currently supports `auto`
1450
+ * and `none`, with `auto` as the default value. The `auto` value means that the
1451
+ * contents of the response will be added to the default conversation. Set this to
1452
+ * `none` to create an out-of-band response which will not add items to default
1453
+ * conversation.
1454
+ */
1455
+ conversation?: (string & {}) | 'auto' | 'none';
1456
+ /**
1457
+ * Input items to include in the prompt for the model. Using this field creates a
1458
+ * new context for this Response instead of using the default conversation. An
1459
+ * empty array `[]` will clear the context for this Response. Note that this can
1460
+ * include references to items from the default conversation.
1461
+ */
1462
+ input?: Array<RealtimeAPI.ConversationItemWithReference>;
1463
+ /**
1464
+ * The default system instructions (i.e. system message) prepended to model calls.
1465
+ * This field allows the client to guide the model on desired responses. The model
1466
+ * can be instructed on response content and format, (e.g. "be extremely succinct",
1467
+ * "act friendly", "here are examples of good responses") and on audio behavior
1468
+ * (e.g. "talk quickly", "inject emotion into your voice", "laugh frequently"). The
1469
+ * instructions are not guaranteed to be followed by the model, but they provide
1470
+ * guidance to the model on the desired behavior.
1471
+ *
1472
+ * Note that the server sets default instructions which will be used if this field
1473
+ * is not set and are visible in the `session.created` event at the start of the
1474
+ * session.
1475
+ */
1476
+ instructions?: string;
1477
+ /**
1478
+ * Maximum number of output tokens for a single assistant response, inclusive of
1479
+ * tool calls. Provide an integer between 1 and 4096 to limit output tokens, or
1480
+ * `inf` for the maximum available tokens for a given model. Defaults to `inf`.
1481
+ */
1482
+ max_response_output_tokens?: number | 'inf';
1483
+ /**
1484
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1485
+ * for storing additional information about the object in a structured format, and
1486
+ * querying for objects via API or the dashboard.
1487
+ *
1488
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1489
+ * a maximum length of 512 characters.
1490
+ */
1491
+ metadata?: Shared.Metadata | null;
1492
+ /**
1493
+ * The set of modalities the model can respond with. To disable audio, set this to
1494
+ * ["text"].
1495
+ */
1496
+ modalities?: Array<'text' | 'audio'>;
1497
+ /**
1498
+ * The format of output audio. Options are `pcm16`, `g711_ulaw`, or `g711_alaw`.
1499
+ */
1500
+ output_audio_format?: 'pcm16' | 'g711_ulaw' | 'g711_alaw';
1501
+ /**
1502
+ * Sampling temperature for the model, limited to [0.6, 1.2]. Defaults to 0.8.
1503
+ */
1504
+ temperature?: number;
1505
+ /**
1506
+ * How the model chooses tools. Options are `auto`, `none`, `required`, or specify
1507
+ * a function, like `{"type": "function", "function": {"name": "my_function"}}`.
1508
+ */
1509
+ tool_choice?: string;
1510
+ /**
1511
+ * Tools (functions) available to the model.
1512
+ */
1513
+ tools?: Array<Response.Tool>;
1514
+ /**
1515
+ * The voice the model uses to respond. Voice cannot be changed during the session
1516
+ * once the model has responded with audio at least once. Current voice options are
1517
+ * `alloy`, `ash`, `ballad`, `coral`, `echo`, `sage`, `shimmer`, and `verse`.
1518
+ */
1519
+ voice?: (string & {}) | 'alloy' | 'ash' | 'ballad' | 'coral' | 'echo' | 'sage' | 'shimmer' | 'verse';
1520
+ }
1521
+ namespace Response {
1522
+ interface Tool {
1523
+ /**
1524
+ * The description of the function, including guidance on when and how to call it,
1525
+ * and guidance about what to tell the user when calling (if anything).
1526
+ */
1527
+ description?: string;
1528
+ /**
1529
+ * The name of the function.
1530
+ */
1531
+ name?: string;
1532
+ /**
1533
+ * Parameters of the function in JSON Schema.
1534
+ */
1535
+ parameters?: unknown;
1536
+ /**
1537
+ * The type of the tool, i.e. `function`.
1538
+ */
1539
+ type?: 'function';
1540
+ }
1541
+ }
1542
+ }
1543
+ /**
1544
+ * Returned when a new Response is created. The first event of response creation,
1545
+ * where the response is in an initial state of `in_progress`.
1546
+ */
1547
+ export interface ResponseCreatedEvent {
1548
+ /**
1549
+ * The unique ID of the server event.
1550
+ */
1551
+ event_id: string;
1552
+ /**
1553
+ * The response resource.
1554
+ */
1555
+ response: RealtimeResponse;
1556
+ /**
1557
+ * The event type, must be `response.created`.
1558
+ */
1559
+ type: 'response.created';
1560
+ }
1561
+ /**
1562
+ * Returned when a Response is done streaming. Always emitted, no matter the final
1563
+ * state. The Response object included in the `response.done` event will include
1564
+ * all output Items in the Response but will omit the raw audio data.
1565
+ */
1566
+ export interface ResponseDoneEvent {
1567
+ /**
1568
+ * The unique ID of the server event.
1569
+ */
1570
+ event_id: string;
1571
+ /**
1572
+ * The response resource.
1573
+ */
1574
+ response: RealtimeResponse;
1575
+ /**
1576
+ * The event type, must be `response.done`.
1577
+ */
1578
+ type: 'response.done';
1579
+ }
1580
+ /**
1581
+ * Returned when the model-generated function call arguments are updated.
1582
+ */
1583
+ export interface ResponseFunctionCallArgumentsDeltaEvent {
1584
+ /**
1585
+ * The ID of the function call.
1586
+ */
1587
+ call_id: string;
1588
+ /**
1589
+ * The arguments delta as a JSON string.
1590
+ */
1591
+ delta: string;
1592
+ /**
1593
+ * The unique ID of the server event.
1594
+ */
1595
+ event_id: string;
1596
+ /**
1597
+ * The ID of the function call item.
1598
+ */
1599
+ item_id: string;
1600
+ /**
1601
+ * The index of the output item in the response.
1602
+ */
1603
+ output_index: number;
1604
+ /**
1605
+ * The ID of the response.
1606
+ */
1607
+ response_id: string;
1608
+ /**
1609
+ * The event type, must be `response.function_call_arguments.delta`.
1610
+ */
1611
+ type: 'response.function_call_arguments.delta';
1612
+ }
1613
+ /**
1614
+ * Returned when the model-generated function call arguments are done streaming.
1615
+ * Also emitted when a Response is interrupted, incomplete, or cancelled.
1616
+ */
1617
+ export interface ResponseFunctionCallArgumentsDoneEvent {
1618
+ /**
1619
+ * The final arguments as a JSON string.
1620
+ */
1621
+ arguments: string;
1622
+ /**
1623
+ * The ID of the function call.
1624
+ */
1625
+ call_id: string;
1626
+ /**
1627
+ * The unique ID of the server event.
1628
+ */
1629
+ event_id: string;
1630
+ /**
1631
+ * The ID of the function call item.
1632
+ */
1633
+ item_id: string;
1634
+ /**
1635
+ * The index of the output item in the response.
1636
+ */
1637
+ output_index: number;
1638
+ /**
1639
+ * The ID of the response.
1640
+ */
1641
+ response_id: string;
1642
+ /**
1643
+ * The event type, must be `response.function_call_arguments.done`.
1644
+ */
1645
+ type: 'response.function_call_arguments.done';
1646
+ }
1647
+ /**
1648
+ * Returned when a new Item is created during Response generation.
1649
+ */
1650
+ export interface ResponseOutputItemAddedEvent {
1651
+ /**
1652
+ * The unique ID of the server event.
1653
+ */
1654
+ event_id: string;
1655
+ /**
1656
+ * The item to add to the conversation.
1657
+ */
1658
+ item: ConversationItem;
1659
+ /**
1660
+ * The index of the output item in the Response.
1661
+ */
1662
+ output_index: number;
1663
+ /**
1664
+ * The ID of the Response to which the item belongs.
1665
+ */
1666
+ response_id: string;
1667
+ /**
1668
+ * The event type, must be `response.output_item.added`.
1669
+ */
1670
+ type: 'response.output_item.added';
1671
+ }
1672
+ /**
1673
+ * Returned when an Item is done streaming. Also emitted when a Response is
1674
+ * interrupted, incomplete, or cancelled.
1675
+ */
1676
+ export interface ResponseOutputItemDoneEvent {
1677
+ /**
1678
+ * The unique ID of the server event.
1679
+ */
1680
+ event_id: string;
1681
+ /**
1682
+ * The item to add to the conversation.
1683
+ */
1684
+ item: ConversationItem;
1685
+ /**
1686
+ * The index of the output item in the Response.
1687
+ */
1688
+ output_index: number;
1689
+ /**
1690
+ * The ID of the Response to which the item belongs.
1691
+ */
1692
+ response_id: string;
1693
+ /**
1694
+ * The event type, must be `response.output_item.done`.
1695
+ */
1696
+ type: 'response.output_item.done';
1697
+ }
1698
+ /**
1699
+ * Returned when the text value of a "text" content part is updated.
1700
+ */
1701
+ export interface ResponseTextDeltaEvent {
1702
+ /**
1703
+ * The index of the content part in the item's content array.
1704
+ */
1705
+ content_index: number;
1706
+ /**
1707
+ * The text delta.
1708
+ */
1709
+ delta: string;
1710
+ /**
1711
+ * The unique ID of the server event.
1712
+ */
1713
+ event_id: string;
1714
+ /**
1715
+ * The ID of the item.
1716
+ */
1717
+ item_id: string;
1718
+ /**
1719
+ * The index of the output item in the response.
1720
+ */
1721
+ output_index: number;
1722
+ /**
1723
+ * The ID of the response.
1724
+ */
1725
+ response_id: string;
1726
+ /**
1727
+ * The event type, must be `response.text.delta`.
1728
+ */
1729
+ type: 'response.text.delta';
1730
+ }
1731
+ /**
1732
+ * Returned when the text value of a "text" content part is done streaming. Also
1733
+ * emitted when a Response is interrupted, incomplete, or cancelled.
1734
+ */
1735
+ export interface ResponseTextDoneEvent {
1736
+ /**
1737
+ * The index of the content part in the item's content array.
1738
+ */
1739
+ content_index: number;
1740
+ /**
1741
+ * The unique ID of the server event.
1742
+ */
1743
+ event_id: string;
1744
+ /**
1745
+ * The ID of the item.
1746
+ */
1747
+ item_id: string;
1748
+ /**
1749
+ * The index of the output item in the response.
1750
+ */
1751
+ output_index: number;
1752
+ /**
1753
+ * The ID of the response.
1754
+ */
1755
+ response_id: string;
1756
+ /**
1757
+ * The final text content.
1758
+ */
1759
+ text: string;
1760
+ /**
1761
+ * The event type, must be `response.text.done`.
1762
+ */
1763
+ type: 'response.text.done';
1764
+ }
1765
+ /**
1766
+ * Returned when a Session is created. Emitted automatically when a new connection
1767
+ * is established as the first server event. This event will contain the default
1768
+ * Session configuration.
1769
+ */
1770
+ export interface SessionCreatedEvent {
1771
+ /**
1772
+ * The unique ID of the server event.
1773
+ */
1774
+ event_id: string;
1775
+ /**
1776
+ * Realtime session object configuration.
1777
+ */
1778
+ session: SessionsAPI.Session;
1779
+ /**
1780
+ * The event type, must be `session.created`.
1781
+ */
1782
+ type: 'session.created';
1783
+ }
1784
+ /**
1785
+ * Send this event to update the session’s default configuration. The client may
1786
+ * send this event at any time to update any field, except for `voice`. However,
1787
+ * note that once a session has been initialized with a particular `model`, it
1788
+ * can’t be changed to another model using `session.update`.
1789
+ *
1790
+ * When the server receives a `session.update`, it will respond with a
1791
+ * `session.updated` event showing the full, effective configuration. Only the
1792
+ * fields that are present are updated. To clear a field like `instructions`, pass
1793
+ * an empty string.
1794
+ */
1795
+ export interface SessionUpdateEvent {
1796
+ /**
1797
+ * Realtime session object configuration.
1798
+ */
1799
+ session: SessionUpdateEvent.Session;
1800
+ /**
1801
+ * The event type, must be `session.update`.
1802
+ */
1803
+ type: 'session.update';
1804
+ /**
1805
+ * Optional client-generated ID used to identify this event.
1806
+ */
1807
+ event_id?: string;
1808
+ }
1809
+ export declare namespace SessionUpdateEvent {
1810
+ /**
1811
+ * Realtime session object configuration.
1812
+ */
1813
+ interface Session {
1814
+ /**
1815
+ * Configuration options for the generated client secret.
1816
+ */
1817
+ client_secret?: Session.ClientSecret;
1818
+ /**
1819
+ * The format of input audio. Options are `pcm16`, `g711_ulaw`, or `g711_alaw`. For
1820
+ * `pcm16`, input audio must be 16-bit PCM at a 24kHz sample rate, single channel
1821
+ * (mono), and little-endian byte order.
1822
+ */
1823
+ input_audio_format?: 'pcm16' | 'g711_ulaw' | 'g711_alaw';
1824
+ /**
1825
+ * Configuration for input audio noise reduction. This can be set to `null` to turn
1826
+ * off. Noise reduction filters audio added to the input audio buffer before it is
1827
+ * sent to VAD and the model. Filtering the audio can improve VAD and turn
1828
+ * detection accuracy (reducing false positives) and model performance by improving
1829
+ * perception of the input audio.
1830
+ */
1831
+ input_audio_noise_reduction?: Session.InputAudioNoiseReduction;
1832
+ /**
1833
+ * Configuration for input audio transcription, defaults to off and can be set to
1834
+ * `null` to turn off once on. Input audio transcription is not native to the
1835
+ * model, since the model consumes audio directly. Transcription runs
1836
+ * asynchronously through
1837
+ * [the /audio/transcriptions endpoint](https://platform.openai.com/docs/api-reference/audio/createTranscription)
1838
+ * and should be treated as guidance of input audio content rather than precisely
1839
+ * what the model heard. The client can optionally set the language and prompt for
1840
+ * transcription, these offer additional guidance to the transcription service.
1841
+ */
1842
+ input_audio_transcription?: Session.InputAudioTranscription;
1843
+ /**
1844
+ * The default system instructions (i.e. system message) prepended to model calls.
1845
+ * This field allows the client to guide the model on desired responses. The model
1846
+ * can be instructed on response content and format, (e.g. "be extremely succinct",
1847
+ * "act friendly", "here are examples of good responses") and on audio behavior
1848
+ * (e.g. "talk quickly", "inject emotion into your voice", "laugh frequently"). The
1849
+ * instructions are not guaranteed to be followed by the model, but they provide
1850
+ * guidance to the model on the desired behavior.
1851
+ *
1852
+ * Note that the server sets default instructions which will be used if this field
1853
+ * is not set and are visible in the `session.created` event at the start of the
1854
+ * session.
1855
+ */
1856
+ instructions?: string;
1857
+ /**
1858
+ * Maximum number of output tokens for a single assistant response, inclusive of
1859
+ * tool calls. Provide an integer between 1 and 4096 to limit output tokens, or
1860
+ * `inf` for the maximum available tokens for a given model. Defaults to `inf`.
1861
+ */
1862
+ max_response_output_tokens?: number | 'inf';
1863
+ /**
1864
+ * The set of modalities the model can respond with. To disable audio, set this to
1865
+ * ["text"].
1866
+ */
1867
+ modalities?: Array<'text' | 'audio'>;
1868
+ /**
1869
+ * The Realtime model used for this session.
1870
+ */
1871
+ model?: 'gpt-4o-realtime-preview' | 'gpt-4o-realtime-preview-2024-10-01' | 'gpt-4o-realtime-preview-2024-12-17' | 'gpt-4o-realtime-preview-2025-06-03' | 'gpt-4o-mini-realtime-preview' | 'gpt-4o-mini-realtime-preview-2024-12-17';
1872
+ /**
1873
+ * The format of output audio. Options are `pcm16`, `g711_ulaw`, or `g711_alaw`.
1874
+ * For `pcm16`, output audio is sampled at a rate of 24kHz.
1875
+ */
1876
+ output_audio_format?: 'pcm16' | 'g711_ulaw' | 'g711_alaw';
1877
+ /**
1878
+ * The speed of the model's spoken response. 1.0 is the default speed. 0.25 is the
1879
+ * minimum speed. 1.5 is the maximum speed. This value can only be changed in
1880
+ * between model turns, not while a response is in progress.
1881
+ */
1882
+ speed?: number;
1883
+ /**
1884
+ * Sampling temperature for the model, limited to [0.6, 1.2]. For audio models a
1885
+ * temperature of 0.8 is highly recommended for best performance.
1886
+ */
1887
+ temperature?: number;
1888
+ /**
1889
+ * How the model chooses tools. Options are `auto`, `none`, `required`, or specify
1890
+ * a function.
1891
+ */
1892
+ tool_choice?: string;
1893
+ /**
1894
+ * Tools (functions) available to the model.
1895
+ */
1896
+ tools?: Array<Session.Tool>;
1897
+ /**
1898
+ * Configuration options for tracing. Set to null to disable tracing. Once tracing
1899
+ * is enabled for a session, the configuration cannot be modified.
1900
+ *
1901
+ * `auto` will create a trace for the session with default values for the workflow
1902
+ * name, group id, and metadata.
1903
+ */
1904
+ tracing?: 'auto' | Session.TracingConfiguration;
1905
+ /**
1906
+ * Configuration for turn detection, ether Server VAD or Semantic VAD. This can be
1907
+ * set to `null` to turn off, in which case the client must manually trigger model
1908
+ * response. Server VAD means that the model will detect the start and end of
1909
+ * speech based on audio volume and respond at the end of user speech. Semantic VAD
1910
+ * is more advanced and uses a turn detection model (in conjunction with VAD) to
1911
+ * semantically estimate whether the user has finished speaking, then dynamically
1912
+ * sets a timeout based on this probability. For example, if user audio trails off
1913
+ * with "uhhm", the model will score a low probability of turn end and wait longer
1914
+ * for the user to continue speaking. This can be useful for more natural
1915
+ * conversations, but may have a higher latency.
1916
+ */
1917
+ turn_detection?: Session.TurnDetection;
1918
+ /**
1919
+ * The voice the model uses to respond. Voice cannot be changed during the session
1920
+ * once the model has responded with audio at least once. Current voice options are
1921
+ * `alloy`, `ash`, `ballad`, `coral`, `echo`, `sage`, `shimmer`, and `verse`.
1922
+ */
1923
+ voice?: (string & {}) | 'alloy' | 'ash' | 'ballad' | 'coral' | 'echo' | 'sage' | 'shimmer' | 'verse';
1924
+ }
1925
+ namespace Session {
1926
+ /**
1927
+ * Configuration options for the generated client secret.
1928
+ */
1929
+ interface ClientSecret {
1930
+ /**
1931
+ * Configuration for the ephemeral token expiration.
1932
+ */
1933
+ expires_after?: ClientSecret.ExpiresAfter;
1934
+ }
1935
+ namespace ClientSecret {
1936
+ /**
1937
+ * Configuration for the ephemeral token expiration.
1938
+ */
1939
+ interface ExpiresAfter {
1940
+ /**
1941
+ * The anchor point for the ephemeral token expiration. Only `created_at` is
1942
+ * currently supported.
1943
+ */
1944
+ anchor: 'created_at';
1945
+ /**
1946
+ * The number of seconds from the anchor point to the expiration. Select a value
1947
+ * between `10` and `7200`.
1948
+ */
1949
+ seconds?: number;
1950
+ }
1951
+ }
1952
+ /**
1953
+ * Configuration for input audio noise reduction. This can be set to `null` to turn
1954
+ * off. Noise reduction filters audio added to the input audio buffer before it is
1955
+ * sent to VAD and the model. Filtering the audio can improve VAD and turn
1956
+ * detection accuracy (reducing false positives) and model performance by improving
1957
+ * perception of the input audio.
1958
+ */
1959
+ interface InputAudioNoiseReduction {
1960
+ /**
1961
+ * Type of noise reduction. `near_field` is for close-talking microphones such as
1962
+ * headphones, `far_field` is for far-field microphones such as laptop or
1963
+ * conference room microphones.
1964
+ */
1965
+ type?: 'near_field' | 'far_field';
1966
+ }
1967
+ /**
1968
+ * Configuration for input audio transcription, defaults to off and can be set to
1969
+ * `null` to turn off once on. Input audio transcription is not native to the
1970
+ * model, since the model consumes audio directly. Transcription runs
1971
+ * asynchronously through
1972
+ * [the /audio/transcriptions endpoint](https://platform.openai.com/docs/api-reference/audio/createTranscription)
1973
+ * and should be treated as guidance of input audio content rather than precisely
1974
+ * what the model heard. The client can optionally set the language and prompt for
1975
+ * transcription, these offer additional guidance to the transcription service.
1976
+ */
1977
+ interface InputAudioTranscription {
1978
+ /**
1979
+ * The language of the input audio. Supplying the input language in
1980
+ * [ISO-639-1](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) (e.g. `en`)
1981
+ * format will improve accuracy and latency.
1982
+ */
1983
+ language?: string;
1984
+ /**
1985
+ * The model to use for transcription, current options are `gpt-4o-transcribe`,
1986
+ * `gpt-4o-mini-transcribe`, and `whisper-1`.
1987
+ */
1988
+ model?: string;
1989
+ /**
1990
+ * An optional text to guide the model's style or continue a previous audio
1991
+ * segment. For `whisper-1`, the
1992
+ * [prompt is a list of keywords](https://platform.openai.com/docs/guides/speech-to-text#prompting).
1993
+ * For `gpt-4o-transcribe` models, the prompt is a free text string, for example
1994
+ * "expect words related to technology".
1995
+ */
1996
+ prompt?: string;
1997
+ }
1998
+ interface Tool {
1999
+ /**
2000
+ * The description of the function, including guidance on when and how to call it,
2001
+ * and guidance about what to tell the user when calling (if anything).
2002
+ */
2003
+ description?: string;
2004
+ /**
2005
+ * The name of the function.
2006
+ */
2007
+ name?: string;
2008
+ /**
2009
+ * Parameters of the function in JSON Schema.
2010
+ */
2011
+ parameters?: unknown;
2012
+ /**
2013
+ * The type of the tool, i.e. `function`.
2014
+ */
2015
+ type?: 'function';
2016
+ }
2017
+ /**
2018
+ * Granular configuration for tracing.
2019
+ */
2020
+ interface TracingConfiguration {
2021
+ /**
2022
+ * The group id to attach to this trace to enable filtering and grouping in the
2023
+ * traces dashboard.
2024
+ */
2025
+ group_id?: string;
2026
+ /**
2027
+ * The arbitrary metadata to attach to this trace to enable filtering in the traces
2028
+ * dashboard.
2029
+ */
2030
+ metadata?: unknown;
2031
+ /**
2032
+ * The name of the workflow to attach to this trace. This is used to name the trace
2033
+ * in the traces dashboard.
2034
+ */
2035
+ workflow_name?: string;
2036
+ }
2037
+ /**
2038
+ * Configuration for turn detection, ether Server VAD or Semantic VAD. This can be
2039
+ * set to `null` to turn off, in which case the client must manually trigger model
2040
+ * response. Server VAD means that the model will detect the start and end of
2041
+ * speech based on audio volume and respond at the end of user speech. Semantic VAD
2042
+ * is more advanced and uses a turn detection model (in conjunction with VAD) to
2043
+ * semantically estimate whether the user has finished speaking, then dynamically
2044
+ * sets a timeout based on this probability. For example, if user audio trails off
2045
+ * with "uhhm", the model will score a low probability of turn end and wait longer
2046
+ * for the user to continue speaking. This can be useful for more natural
2047
+ * conversations, but may have a higher latency.
2048
+ */
2049
+ interface TurnDetection {
2050
+ /**
2051
+ * Whether or not to automatically generate a response when a VAD stop event
2052
+ * occurs.
2053
+ */
2054
+ create_response?: boolean;
2055
+ /**
2056
+ * Used only for `semantic_vad` mode. The eagerness of the model to respond. `low`
2057
+ * will wait longer for the user to continue speaking, `high` will respond more
2058
+ * quickly. `auto` is the default and is equivalent to `medium`.
2059
+ */
2060
+ eagerness?: 'low' | 'medium' | 'high' | 'auto';
2061
+ /**
2062
+ * Whether or not to automatically interrupt any ongoing response with output to
2063
+ * the default conversation (i.e. `conversation` of `auto`) when a VAD start event
2064
+ * occurs.
2065
+ */
2066
+ interrupt_response?: boolean;
2067
+ /**
2068
+ * Used only for `server_vad` mode. Amount of audio to include before the VAD
2069
+ * detected speech (in milliseconds). Defaults to 300ms.
2070
+ */
2071
+ prefix_padding_ms?: number;
2072
+ /**
2073
+ * Used only for `server_vad` mode. Duration of silence to detect speech stop (in
2074
+ * milliseconds). Defaults to 500ms. With shorter values the model will respond
2075
+ * more quickly, but may jump in on short pauses from the user.
2076
+ */
2077
+ silence_duration_ms?: number;
2078
+ /**
2079
+ * Used only for `server_vad` mode. Activation threshold for VAD (0.0 to 1.0), this
2080
+ * defaults to 0.5. A higher threshold will require louder audio to activate the
2081
+ * model, and thus might perform better in noisy environments.
2082
+ */
2083
+ threshold?: number;
2084
+ /**
2085
+ * Type of turn detection.
2086
+ */
2087
+ type?: 'server_vad' | 'semantic_vad';
2088
+ }
2089
+ }
2090
+ }
2091
+ /**
2092
+ * Returned when a session is updated with a `session.update` event, unless there
2093
+ * is an error.
2094
+ */
2095
+ export interface SessionUpdatedEvent {
2096
+ /**
2097
+ * The unique ID of the server event.
2098
+ */
2099
+ event_id: string;
2100
+ /**
2101
+ * Realtime session object configuration.
2102
+ */
2103
+ session: SessionsAPI.Session;
2104
+ /**
2105
+ * The event type, must be `session.updated`.
2106
+ */
2107
+ type: 'session.updated';
2108
+ }
2109
+ /**
2110
+ * Send this event to update a transcription session.
2111
+ */
2112
+ export interface TranscriptionSessionUpdate {
2113
+ /**
2114
+ * Realtime transcription session object configuration.
2115
+ */
2116
+ session: TranscriptionSessionUpdate.Session;
2117
+ /**
2118
+ * The event type, must be `transcription_session.update`.
2119
+ */
2120
+ type: 'transcription_session.update';
2121
+ /**
2122
+ * Optional client-generated ID used to identify this event.
2123
+ */
2124
+ event_id?: string;
2125
+ }
2126
+ export declare namespace TranscriptionSessionUpdate {
2127
+ /**
2128
+ * Realtime transcription session object configuration.
2129
+ */
2130
+ interface Session {
2131
+ /**
2132
+ * Configuration options for the generated client secret.
2133
+ */
2134
+ client_secret?: Session.ClientSecret;
2135
+ /**
2136
+ * The set of items to include in the transcription. Current available items are:
2137
+ *
2138
+ * - `item.input_audio_transcription.logprobs`
2139
+ */
2140
+ include?: Array<string>;
2141
+ /**
2142
+ * The format of input audio. Options are `pcm16`, `g711_ulaw`, or `g711_alaw`. For
2143
+ * `pcm16`, input audio must be 16-bit PCM at a 24kHz sample rate, single channel
2144
+ * (mono), and little-endian byte order.
2145
+ */
2146
+ input_audio_format?: 'pcm16' | 'g711_ulaw' | 'g711_alaw';
2147
+ /**
2148
+ * Configuration for input audio noise reduction. This can be set to `null` to turn
2149
+ * off. Noise reduction filters audio added to the input audio buffer before it is
2150
+ * sent to VAD and the model. Filtering the audio can improve VAD and turn
2151
+ * detection accuracy (reducing false positives) and model performance by improving
2152
+ * perception of the input audio.
2153
+ */
2154
+ input_audio_noise_reduction?: Session.InputAudioNoiseReduction;
2155
+ /**
2156
+ * Configuration for input audio transcription. The client can optionally set the
2157
+ * language and prompt for transcription, these offer additional guidance to the
2158
+ * transcription service.
2159
+ */
2160
+ input_audio_transcription?: Session.InputAudioTranscription;
2161
+ /**
2162
+ * The set of modalities the model can respond with. To disable audio, set this to
2163
+ * ["text"].
2164
+ */
2165
+ modalities?: Array<'text' | 'audio'>;
2166
+ /**
2167
+ * Configuration for turn detection, ether Server VAD or Semantic VAD. This can be
2168
+ * set to `null` to turn off, in which case the client must manually trigger model
2169
+ * response. Server VAD means that the model will detect the start and end of
2170
+ * speech based on audio volume and respond at the end of user speech. Semantic VAD
2171
+ * is more advanced and uses a turn detection model (in conjunction with VAD) to
2172
+ * semantically estimate whether the user has finished speaking, then dynamically
2173
+ * sets a timeout based on this probability. For example, if user audio trails off
2174
+ * with "uhhm", the model will score a low probability of turn end and wait longer
2175
+ * for the user to continue speaking. This can be useful for more natural
2176
+ * conversations, but may have a higher latency.
2177
+ */
2178
+ turn_detection?: Session.TurnDetection;
2179
+ }
2180
+ namespace Session {
2181
+ /**
2182
+ * Configuration options for the generated client secret.
2183
+ */
2184
+ interface ClientSecret {
2185
+ /**
2186
+ * Configuration for the ephemeral token expiration.
2187
+ */
2188
+ expires_at?: ClientSecret.ExpiresAt;
2189
+ }
2190
+ namespace ClientSecret {
2191
+ /**
2192
+ * Configuration for the ephemeral token expiration.
2193
+ */
2194
+ interface ExpiresAt {
2195
+ /**
2196
+ * The anchor point for the ephemeral token expiration. Only `created_at` is
2197
+ * currently supported.
2198
+ */
2199
+ anchor?: 'created_at';
2200
+ /**
2201
+ * The number of seconds from the anchor point to the expiration. Select a value
2202
+ * between `10` and `7200`.
2203
+ */
2204
+ seconds?: number;
2205
+ }
2206
+ }
2207
+ /**
2208
+ * Configuration for input audio noise reduction. This can be set to `null` to turn
2209
+ * off. Noise reduction filters audio added to the input audio buffer before it is
2210
+ * sent to VAD and the model. Filtering the audio can improve VAD and turn
2211
+ * detection accuracy (reducing false positives) and model performance by improving
2212
+ * perception of the input audio.
2213
+ */
2214
+ interface InputAudioNoiseReduction {
2215
+ /**
2216
+ * Type of noise reduction. `near_field` is for close-talking microphones such as
2217
+ * headphones, `far_field` is for far-field microphones such as laptop or
2218
+ * conference room microphones.
2219
+ */
2220
+ type?: 'near_field' | 'far_field';
2221
+ }
2222
+ /**
2223
+ * Configuration for input audio transcription. The client can optionally set the
2224
+ * language and prompt for transcription, these offer additional guidance to the
2225
+ * transcription service.
2226
+ */
2227
+ interface InputAudioTranscription {
2228
+ /**
2229
+ * The language of the input audio. Supplying the input language in
2230
+ * [ISO-639-1](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) (e.g. `en`)
2231
+ * format will improve accuracy and latency.
2232
+ */
2233
+ language?: string;
2234
+ /**
2235
+ * The model to use for transcription, current options are `gpt-4o-transcribe`,
2236
+ * `gpt-4o-mini-transcribe`, and `whisper-1`.
2237
+ */
2238
+ model?: 'gpt-4o-transcribe' | 'gpt-4o-mini-transcribe' | 'whisper-1';
2239
+ /**
2240
+ * An optional text to guide the model's style or continue a previous audio
2241
+ * segment. For `whisper-1`, the
2242
+ * [prompt is a list of keywords](https://platform.openai.com/docs/guides/speech-to-text#prompting).
2243
+ * For `gpt-4o-transcribe` models, the prompt is a free text string, for example
2244
+ * "expect words related to technology".
2245
+ */
2246
+ prompt?: string;
2247
+ }
2248
+ /**
2249
+ * Configuration for turn detection, ether Server VAD or Semantic VAD. This can be
2250
+ * set to `null` to turn off, in which case the client must manually trigger model
2251
+ * response. Server VAD means that the model will detect the start and end of
2252
+ * speech based on audio volume and respond at the end of user speech. Semantic VAD
2253
+ * is more advanced and uses a turn detection model (in conjunction with VAD) to
2254
+ * semantically estimate whether the user has finished speaking, then dynamically
2255
+ * sets a timeout based on this probability. For example, if user audio trails off
2256
+ * with "uhhm", the model will score a low probability of turn end and wait longer
2257
+ * for the user to continue speaking. This can be useful for more natural
2258
+ * conversations, but may have a higher latency.
2259
+ */
2260
+ interface TurnDetection {
2261
+ /**
2262
+ * Whether or not to automatically generate a response when a VAD stop event
2263
+ * occurs. Not available for transcription sessions.
2264
+ */
2265
+ create_response?: boolean;
2266
+ /**
2267
+ * Used only for `semantic_vad` mode. The eagerness of the model to respond. `low`
2268
+ * will wait longer for the user to continue speaking, `high` will respond more
2269
+ * quickly. `auto` is the default and is equivalent to `medium`.
2270
+ */
2271
+ eagerness?: 'low' | 'medium' | 'high' | 'auto';
2272
+ /**
2273
+ * Whether or not to automatically interrupt any ongoing response with output to
2274
+ * the default conversation (i.e. `conversation` of `auto`) when a VAD start event
2275
+ * occurs. Not available for transcription sessions.
2276
+ */
2277
+ interrupt_response?: boolean;
2278
+ /**
2279
+ * Used only for `server_vad` mode. Amount of audio to include before the VAD
2280
+ * detected speech (in milliseconds). Defaults to 300ms.
2281
+ */
2282
+ prefix_padding_ms?: number;
2283
+ /**
2284
+ * Used only for `server_vad` mode. Duration of silence to detect speech stop (in
2285
+ * milliseconds). Defaults to 500ms. With shorter values the model will respond
2286
+ * more quickly, but may jump in on short pauses from the user.
2287
+ */
2288
+ silence_duration_ms?: number;
2289
+ /**
2290
+ * Used only for `server_vad` mode. Activation threshold for VAD (0.0 to 1.0), this
2291
+ * defaults to 0.5. A higher threshold will require louder audio to activate the
2292
+ * model, and thus might perform better in noisy environments.
2293
+ */
2294
+ threshold?: number;
2295
+ /**
2296
+ * Type of turn detection.
2297
+ */
2298
+ type?: 'server_vad' | 'semantic_vad';
2299
+ }
2300
+ }
2301
+ }
2302
+ /**
2303
+ * Returned when a transcription session is updated with a
2304
+ * `transcription_session.update` event, unless there is an error.
2305
+ */
2306
+ export interface TranscriptionSessionUpdatedEvent {
2307
+ /**
2308
+ * The unique ID of the server event.
2309
+ */
2310
+ event_id: string;
2311
+ /**
2312
+ * A new Realtime transcription session configuration.
2313
+ *
2314
+ * When a session is created on the server via REST API, the session object also
2315
+ * contains an ephemeral key. Default TTL for keys is 10 minutes. This property is
2316
+ * not present when a session is updated via the WebSocket API.
2317
+ */
2318
+ session: TranscriptionSessionsAPI.TranscriptionSession;
2319
+ /**
2320
+ * The event type, must be `transcription_session.updated`.
2321
+ */
2322
+ type: 'transcription_session.updated';
2323
+ }
2324
+ export declare namespace Realtime {
2325
+ export { type ConversationCreatedEvent as ConversationCreatedEvent, type ConversationItem as ConversationItem, type ConversationItemContent as ConversationItemContent, type ConversationItemCreateEvent as ConversationItemCreateEvent, type ConversationItemCreatedEvent as ConversationItemCreatedEvent, type ConversationItemDeleteEvent as ConversationItemDeleteEvent, type ConversationItemDeletedEvent as ConversationItemDeletedEvent, type ConversationItemInputAudioTranscriptionCompletedEvent as ConversationItemInputAudioTranscriptionCompletedEvent, type ConversationItemInputAudioTranscriptionDeltaEvent as ConversationItemInputAudioTranscriptionDeltaEvent, type ConversationItemInputAudioTranscriptionFailedEvent as ConversationItemInputAudioTranscriptionFailedEvent, type ConversationItemRetrieveEvent as ConversationItemRetrieveEvent, type ConversationItemTruncateEvent as ConversationItemTruncateEvent, type ConversationItemTruncatedEvent as ConversationItemTruncatedEvent, type ConversationItemWithReference as ConversationItemWithReference, type ErrorEvent as ErrorEvent, type InputAudioBufferAppendEvent as InputAudioBufferAppendEvent, type InputAudioBufferClearEvent as InputAudioBufferClearEvent, type InputAudioBufferClearedEvent as InputAudioBufferClearedEvent, type InputAudioBufferCommitEvent as InputAudioBufferCommitEvent, type InputAudioBufferCommittedEvent as InputAudioBufferCommittedEvent, type InputAudioBufferSpeechStartedEvent as InputAudioBufferSpeechStartedEvent, type InputAudioBufferSpeechStoppedEvent as InputAudioBufferSpeechStoppedEvent, type RateLimitsUpdatedEvent as RateLimitsUpdatedEvent, type RealtimeClientEvent as RealtimeClientEvent, type RealtimeResponse as RealtimeResponse, type RealtimeResponseStatus as RealtimeResponseStatus, type RealtimeResponseUsage as RealtimeResponseUsage, type RealtimeServerEvent as RealtimeServerEvent, type ResponseAudioDeltaEvent as ResponseAudioDeltaEvent, type ResponseAudioDoneEvent as ResponseAudioDoneEvent, type ResponseAudioTranscriptDeltaEvent as ResponseAudioTranscriptDeltaEvent, type ResponseAudioTranscriptDoneEvent as ResponseAudioTranscriptDoneEvent, type ResponseCancelEvent as ResponseCancelEvent, type ResponseContentPartAddedEvent as ResponseContentPartAddedEvent, type ResponseContentPartDoneEvent as ResponseContentPartDoneEvent, type ResponseCreateEvent as ResponseCreateEvent, type ResponseCreatedEvent as ResponseCreatedEvent, type ResponseDoneEvent as ResponseDoneEvent, type ResponseFunctionCallArgumentsDeltaEvent as ResponseFunctionCallArgumentsDeltaEvent, type ResponseFunctionCallArgumentsDoneEvent as ResponseFunctionCallArgumentsDoneEvent, type ResponseOutputItemAddedEvent as ResponseOutputItemAddedEvent, type ResponseOutputItemDoneEvent as ResponseOutputItemDoneEvent, type ResponseTextDeltaEvent as ResponseTextDeltaEvent, type ResponseTextDoneEvent as ResponseTextDoneEvent, type SessionCreatedEvent as SessionCreatedEvent, type SessionUpdateEvent as SessionUpdateEvent, type SessionUpdatedEvent as SessionUpdatedEvent, type TranscriptionSessionUpdate as TranscriptionSessionUpdate, type TranscriptionSessionUpdatedEvent as TranscriptionSessionUpdatedEvent, };
2326
+ export { Sessions as Sessions, type SessionsAPISession as Session, type SessionCreateResponse as SessionCreateResponse, type SessionCreateParams as SessionCreateParams, };
2327
+ export { TranscriptionSessions as TranscriptionSessions, type TranscriptionSession as TranscriptionSession, type TranscriptionSessionCreateParams as TranscriptionSessionCreateParams, };
2328
+ }
2329
+ //# sourceMappingURL=realtime.d.mts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/messages.d.ts ADDED
@@ -0,0 +1,594 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import * as Shared from "../../shared.js";
3
+ import * as AssistantsAPI from "../assistants.js";
4
+ import { APIPromise } from "../../../core/api-promise.js";
5
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.js";
6
+ import { RequestOptions } from "../../../internal/request-options.js";
7
+ /**
8
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
9
+ */
10
+ export declare class Messages extends APIResource {
11
+ /**
12
+ * Create a message.
13
+ *
14
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
15
+ */
16
+ create(threadID: string, body: MessageCreateParams, options?: RequestOptions): APIPromise<Message>;
17
+ /**
18
+ * Retrieve a message.
19
+ *
20
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
21
+ */
22
+ retrieve(messageID: string, params: MessageRetrieveParams, options?: RequestOptions): APIPromise<Message>;
23
+ /**
24
+ * Modifies a message.
25
+ *
26
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
27
+ */
28
+ update(messageID: string, params: MessageUpdateParams, options?: RequestOptions): APIPromise<Message>;
29
+ /**
30
+ * Returns a list of messages for a given thread.
31
+ *
32
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
33
+ */
34
+ list(threadID: string, query?: MessageListParams | null | undefined, options?: RequestOptions): PagePromise<MessagesPage, Message>;
35
+ /**
36
+ * Deletes a message.
37
+ *
38
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
39
+ */
40
+ delete(messageID: string, params: MessageDeleteParams, options?: RequestOptions): APIPromise<MessageDeleted>;
41
+ }
42
+ export type MessagesPage = CursorPage<Message>;
43
+ /**
44
+ * A citation within the message that points to a specific quote from a specific
45
+ * File associated with the assistant or the message. Generated when the assistant
46
+ * uses the "file_search" tool to search files.
47
+ */
48
+ export type Annotation = FileCitationAnnotation | FilePathAnnotation;
49
+ /**
50
+ * A citation within the message that points to a specific quote from a specific
51
+ * File associated with the assistant or the message. Generated when the assistant
52
+ * uses the "file_search" tool to search files.
53
+ */
54
+ export type AnnotationDelta = FileCitationDeltaAnnotation | FilePathDeltaAnnotation;
55
+ /**
56
+ * A citation within the message that points to a specific quote from a specific
57
+ * File associated with the assistant or the message. Generated when the assistant
58
+ * uses the "file_search" tool to search files.
59
+ */
60
+ export interface FileCitationAnnotation {
61
+ end_index: number;
62
+ file_citation: FileCitationAnnotation.FileCitation;
63
+ start_index: number;
64
+ /**
65
+ * The text in the message content that needs to be replaced.
66
+ */
67
+ text: string;
68
+ /**
69
+ * Always `file_citation`.
70
+ */
71
+ type: 'file_citation';
72
+ }
73
+ export declare namespace FileCitationAnnotation {
74
+ interface FileCitation {
75
+ /**
76
+ * The ID of the specific File the citation is from.
77
+ */
78
+ file_id: string;
79
+ }
80
+ }
81
+ /**
82
+ * A citation within the message that points to a specific quote from a specific
83
+ * File associated with the assistant or the message. Generated when the assistant
84
+ * uses the "file_search" tool to search files.
85
+ */
86
+ export interface FileCitationDeltaAnnotation {
87
+ /**
88
+ * The index of the annotation in the text content part.
89
+ */
90
+ index: number;
91
+ /**
92
+ * Always `file_citation`.
93
+ */
94
+ type: 'file_citation';
95
+ end_index?: number;
96
+ file_citation?: FileCitationDeltaAnnotation.FileCitation;
97
+ start_index?: number;
98
+ /**
99
+ * The text in the message content that needs to be replaced.
100
+ */
101
+ text?: string;
102
+ }
103
+ export declare namespace FileCitationDeltaAnnotation {
104
+ interface FileCitation {
105
+ /**
106
+ * The ID of the specific File the citation is from.
107
+ */
108
+ file_id?: string;
109
+ /**
110
+ * The specific quote in the file.
111
+ */
112
+ quote?: string;
113
+ }
114
+ }
115
+ /**
116
+ * A URL for the file that's generated when the assistant used the
117
+ * `code_interpreter` tool to generate a file.
118
+ */
119
+ export interface FilePathAnnotation {
120
+ end_index: number;
121
+ file_path: FilePathAnnotation.FilePath;
122
+ start_index: number;
123
+ /**
124
+ * The text in the message content that needs to be replaced.
125
+ */
126
+ text: string;
127
+ /**
128
+ * Always `file_path`.
129
+ */
130
+ type: 'file_path';
131
+ }
132
+ export declare namespace FilePathAnnotation {
133
+ interface FilePath {
134
+ /**
135
+ * The ID of the file that was generated.
136
+ */
137
+ file_id: string;
138
+ }
139
+ }
140
+ /**
141
+ * A URL for the file that's generated when the assistant used the
142
+ * `code_interpreter` tool to generate a file.
143
+ */
144
+ export interface FilePathDeltaAnnotation {
145
+ /**
146
+ * The index of the annotation in the text content part.
147
+ */
148
+ index: number;
149
+ /**
150
+ * Always `file_path`.
151
+ */
152
+ type: 'file_path';
153
+ end_index?: number;
154
+ file_path?: FilePathDeltaAnnotation.FilePath;
155
+ start_index?: number;
156
+ /**
157
+ * The text in the message content that needs to be replaced.
158
+ */
159
+ text?: string;
160
+ }
161
+ export declare namespace FilePathDeltaAnnotation {
162
+ interface FilePath {
163
+ /**
164
+ * The ID of the file that was generated.
165
+ */
166
+ file_id?: string;
167
+ }
168
+ }
169
+ export interface ImageFile {
170
+ /**
171
+ * The [File](https://platform.openai.com/docs/api-reference/files) ID of the image
172
+ * in the message content. Set `purpose="vision"` when uploading the File if you
173
+ * need to later display the file content.
174
+ */
175
+ file_id: string;
176
+ /**
177
+ * Specifies the detail level of the image if specified by the user. `low` uses
178
+ * fewer tokens, you can opt in to high resolution using `high`.
179
+ */
180
+ detail?: 'auto' | 'low' | 'high';
181
+ }
182
+ /**
183
+ * References an image [File](https://platform.openai.com/docs/api-reference/files)
184
+ * in the content of a message.
185
+ */
186
+ export interface ImageFileContentBlock {
187
+ image_file: ImageFile;
188
+ /**
189
+ * Always `image_file`.
190
+ */
191
+ type: 'image_file';
192
+ }
193
+ export interface ImageFileDelta {
194
+ /**
195
+ * Specifies the detail level of the image if specified by the user. `low` uses
196
+ * fewer tokens, you can opt in to high resolution using `high`.
197
+ */
198
+ detail?: 'auto' | 'low' | 'high';
199
+ /**
200
+ * The [File](https://platform.openai.com/docs/api-reference/files) ID of the image
201
+ * in the message content. Set `purpose="vision"` when uploading the File if you
202
+ * need to later display the file content.
203
+ */
204
+ file_id?: string;
205
+ }
206
+ /**
207
+ * References an image [File](https://platform.openai.com/docs/api-reference/files)
208
+ * in the content of a message.
209
+ */
210
+ export interface ImageFileDeltaBlock {
211
+ /**
212
+ * The index of the content part in the message.
213
+ */
214
+ index: number;
215
+ /**
216
+ * Always `image_file`.
217
+ */
218
+ type: 'image_file';
219
+ image_file?: ImageFileDelta;
220
+ }
221
+ export interface ImageURL {
222
+ /**
223
+ * The external URL of the image, must be a supported image types: jpeg, jpg, png,
224
+ * gif, webp.
225
+ */
226
+ url: string;
227
+ /**
228
+ * Specifies the detail level of the image. `low` uses fewer tokens, you can opt in
229
+ * to high resolution using `high`. Default value is `auto`
230
+ */
231
+ detail?: 'auto' | 'low' | 'high';
232
+ }
233
+ /**
234
+ * References an image URL in the content of a message.
235
+ */
236
+ export interface ImageURLContentBlock {
237
+ image_url: ImageURL;
238
+ /**
239
+ * The type of the content part.
240
+ */
241
+ type: 'image_url';
242
+ }
243
+ export interface ImageURLDelta {
244
+ /**
245
+ * Specifies the detail level of the image. `low` uses fewer tokens, you can opt in
246
+ * to high resolution using `high`.
247
+ */
248
+ detail?: 'auto' | 'low' | 'high';
249
+ /**
250
+ * The URL of the image, must be a supported image types: jpeg, jpg, png, gif,
251
+ * webp.
252
+ */
253
+ url?: string;
254
+ }
255
+ /**
256
+ * References an image URL in the content of a message.
257
+ */
258
+ export interface ImageURLDeltaBlock {
259
+ /**
260
+ * The index of the content part in the message.
261
+ */
262
+ index: number;
263
+ /**
264
+ * Always `image_url`.
265
+ */
266
+ type: 'image_url';
267
+ image_url?: ImageURLDelta;
268
+ }
269
+ /**
270
+ * Represents a message within a
271
+ * [thread](https://platform.openai.com/docs/api-reference/threads).
272
+ */
273
+ export interface Message {
274
+ /**
275
+ * The identifier, which can be referenced in API endpoints.
276
+ */
277
+ id: string;
278
+ /**
279
+ * If applicable, the ID of the
280
+ * [assistant](https://platform.openai.com/docs/api-reference/assistants) that
281
+ * authored this message.
282
+ */
283
+ assistant_id: string | null;
284
+ /**
285
+ * A list of files attached to the message, and the tools they were added to.
286
+ */
287
+ attachments: Array<Message.Attachment> | null;
288
+ /**
289
+ * The Unix timestamp (in seconds) for when the message was completed.
290
+ */
291
+ completed_at: number | null;
292
+ /**
293
+ * The content of the message in array of text and/or images.
294
+ */
295
+ content: Array<MessageContent>;
296
+ /**
297
+ * The Unix timestamp (in seconds) for when the message was created.
298
+ */
299
+ created_at: number;
300
+ /**
301
+ * The Unix timestamp (in seconds) for when the message was marked as incomplete.
302
+ */
303
+ incomplete_at: number | null;
304
+ /**
305
+ * On an incomplete message, details about why the message is incomplete.
306
+ */
307
+ incomplete_details: Message.IncompleteDetails | null;
308
+ /**
309
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
310
+ * for storing additional information about the object in a structured format, and
311
+ * querying for objects via API or the dashboard.
312
+ *
313
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
314
+ * a maximum length of 512 characters.
315
+ */
316
+ metadata: Shared.Metadata | null;
317
+ /**
318
+ * The object type, which is always `thread.message`.
319
+ */
320
+ object: 'thread.message';
321
+ /**
322
+ * The entity that produced the message. One of `user` or `assistant`.
323
+ */
324
+ role: 'user' | 'assistant';
325
+ /**
326
+ * The ID of the [run](https://platform.openai.com/docs/api-reference/runs)
327
+ * associated with the creation of this message. Value is `null` when messages are
328
+ * created manually using the create message or create thread endpoints.
329
+ */
330
+ run_id: string | null;
331
+ /**
332
+ * The status of the message, which can be either `in_progress`, `incomplete`, or
333
+ * `completed`.
334
+ */
335
+ status: 'in_progress' | 'incomplete' | 'completed';
336
+ /**
337
+ * The [thread](https://platform.openai.com/docs/api-reference/threads) ID that
338
+ * this message belongs to.
339
+ */
340
+ thread_id: string;
341
+ }
342
+ export declare namespace Message {
343
+ interface Attachment {
344
+ /**
345
+ * The ID of the file to attach to the message.
346
+ */
347
+ file_id?: string;
348
+ /**
349
+ * The tools to add this file to.
350
+ */
351
+ tools?: Array<AssistantsAPI.CodeInterpreterTool | Attachment.AssistantToolsFileSearchTypeOnly>;
352
+ }
353
+ namespace Attachment {
354
+ interface AssistantToolsFileSearchTypeOnly {
355
+ /**
356
+ * The type of tool being defined: `file_search`
357
+ */
358
+ type: 'file_search';
359
+ }
360
+ }
361
+ /**
362
+ * On an incomplete message, details about why the message is incomplete.
363
+ */
364
+ interface IncompleteDetails {
365
+ /**
366
+ * The reason the message is incomplete.
367
+ */
368
+ reason: 'content_filter' | 'max_tokens' | 'run_cancelled' | 'run_expired' | 'run_failed';
369
+ }
370
+ }
371
+ /**
372
+ * References an image [File](https://platform.openai.com/docs/api-reference/files)
373
+ * in the content of a message.
374
+ */
375
+ export type MessageContent = ImageFileContentBlock | ImageURLContentBlock | TextContentBlock | RefusalContentBlock;
376
+ /**
377
+ * References an image [File](https://platform.openai.com/docs/api-reference/files)
378
+ * in the content of a message.
379
+ */
380
+ export type MessageContentDelta = ImageFileDeltaBlock | TextDeltaBlock | RefusalDeltaBlock | ImageURLDeltaBlock;
381
+ /**
382
+ * References an image [File](https://platform.openai.com/docs/api-reference/files)
383
+ * in the content of a message.
384
+ */
385
+ export type MessageContentPartParam = ImageFileContentBlock | ImageURLContentBlock | TextContentBlockParam;
386
+ export interface MessageDeleted {
387
+ id: string;
388
+ deleted: boolean;
389
+ object: 'thread.message.deleted';
390
+ }
391
+ /**
392
+ * The delta containing the fields that have changed on the Message.
393
+ */
394
+ export interface MessageDelta {
395
+ /**
396
+ * The content of the message in array of text and/or images.
397
+ */
398
+ content?: Array<MessageContentDelta>;
399
+ /**
400
+ * The entity that produced the message. One of `user` or `assistant`.
401
+ */
402
+ role?: 'user' | 'assistant';
403
+ }
404
+ /**
405
+ * Represents a message delta i.e. any changed fields on a message during
406
+ * streaming.
407
+ */
408
+ export interface MessageDeltaEvent {
409
+ /**
410
+ * The identifier of the message, which can be referenced in API endpoints.
411
+ */
412
+ id: string;
413
+ /**
414
+ * The delta containing the fields that have changed on the Message.
415
+ */
416
+ delta: MessageDelta;
417
+ /**
418
+ * The object type, which is always `thread.message.delta`.
419
+ */
420
+ object: 'thread.message.delta';
421
+ }
422
+ /**
423
+ * The refusal content generated by the assistant.
424
+ */
425
+ export interface RefusalContentBlock {
426
+ refusal: string;
427
+ /**
428
+ * Always `refusal`.
429
+ */
430
+ type: 'refusal';
431
+ }
432
+ /**
433
+ * The refusal content that is part of a message.
434
+ */
435
+ export interface RefusalDeltaBlock {
436
+ /**
437
+ * The index of the refusal part in the message.
438
+ */
439
+ index: number;
440
+ /**
441
+ * Always `refusal`.
442
+ */
443
+ type: 'refusal';
444
+ refusal?: string;
445
+ }
446
+ export interface Text {
447
+ annotations: Array<Annotation>;
448
+ /**
449
+ * The data that makes up the text.
450
+ */
451
+ value: string;
452
+ }
453
+ /**
454
+ * The text content that is part of a message.
455
+ */
456
+ export interface TextContentBlock {
457
+ text: Text;
458
+ /**
459
+ * Always `text`.
460
+ */
461
+ type: 'text';
462
+ }
463
+ /**
464
+ * The text content that is part of a message.
465
+ */
466
+ export interface TextContentBlockParam {
467
+ /**
468
+ * Text content to be sent to the model
469
+ */
470
+ text: string;
471
+ /**
472
+ * Always `text`.
473
+ */
474
+ type: 'text';
475
+ }
476
+ export interface TextDelta {
477
+ annotations?: Array<AnnotationDelta>;
478
+ /**
479
+ * The data that makes up the text.
480
+ */
481
+ value?: string;
482
+ }
483
+ /**
484
+ * The text content that is part of a message.
485
+ */
486
+ export interface TextDeltaBlock {
487
+ /**
488
+ * The index of the content part in the message.
489
+ */
490
+ index: number;
491
+ /**
492
+ * Always `text`.
493
+ */
494
+ type: 'text';
495
+ text?: TextDelta;
496
+ }
497
+ export interface MessageCreateParams {
498
+ /**
499
+ * The text contents of the message.
500
+ */
501
+ content: string | Array<MessageContentPartParam>;
502
+ /**
503
+ * The role of the entity that is creating the message. Allowed values include:
504
+ *
505
+ * - `user`: Indicates the message is sent by an actual user and should be used in
506
+ * most cases to represent user-generated messages.
507
+ * - `assistant`: Indicates the message is generated by the assistant. Use this
508
+ * value to insert messages from the assistant into the conversation.
509
+ */
510
+ role: 'user' | 'assistant';
511
+ /**
512
+ * A list of files attached to the message, and the tools they should be added to.
513
+ */
514
+ attachments?: Array<MessageCreateParams.Attachment> | null;
515
+ /**
516
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
517
+ * for storing additional information about the object in a structured format, and
518
+ * querying for objects via API or the dashboard.
519
+ *
520
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
521
+ * a maximum length of 512 characters.
522
+ */
523
+ metadata?: Shared.Metadata | null;
524
+ }
525
+ export declare namespace MessageCreateParams {
526
+ interface Attachment {
527
+ /**
528
+ * The ID of the file to attach to the message.
529
+ */
530
+ file_id?: string;
531
+ /**
532
+ * The tools to add this file to.
533
+ */
534
+ tools?: Array<AssistantsAPI.CodeInterpreterTool | Attachment.FileSearch>;
535
+ }
536
+ namespace Attachment {
537
+ interface FileSearch {
538
+ /**
539
+ * The type of tool being defined: `file_search`
540
+ */
541
+ type: 'file_search';
542
+ }
543
+ }
544
+ }
545
+ export interface MessageRetrieveParams {
546
+ /**
547
+ * The ID of the [thread](https://platform.openai.com/docs/api-reference/threads)
548
+ * to which this message belongs.
549
+ */
550
+ thread_id: string;
551
+ }
552
+ export interface MessageUpdateParams {
553
+ /**
554
+ * Path param: The ID of the thread to which this message belongs.
555
+ */
556
+ thread_id: string;
557
+ /**
558
+ * Body param: Set of 16 key-value pairs that can be attached to an object. This
559
+ * can be useful for storing additional information about the object in a
560
+ * structured format, and querying for objects via API or the dashboard.
561
+ *
562
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
563
+ * a maximum length of 512 characters.
564
+ */
565
+ metadata?: Shared.Metadata | null;
566
+ }
567
+ export interface MessageListParams extends CursorPageParams {
568
+ /**
569
+ * A cursor for use in pagination. `before` is an object ID that defines your place
570
+ * in the list. For instance, if you make a list request and receive 100 objects,
571
+ * starting with obj_foo, your subsequent call can include before=obj_foo in order
572
+ * to fetch the previous page of the list.
573
+ */
574
+ before?: string;
575
+ /**
576
+ * Sort order by the `created_at` timestamp of the objects. `asc` for ascending
577
+ * order and `desc` for descending order.
578
+ */
579
+ order?: 'asc' | 'desc';
580
+ /**
581
+ * Filter messages by the run ID that generated them.
582
+ */
583
+ run_id?: string;
584
+ }
585
+ export interface MessageDeleteParams {
586
+ /**
587
+ * The ID of the thread to which this message belongs.
588
+ */
589
+ thread_id: string;
590
+ }
591
+ export declare namespace Messages {
592
+ export { type Annotation as Annotation, type AnnotationDelta as AnnotationDelta, type FileCitationAnnotation as FileCitationAnnotation, type FileCitationDeltaAnnotation as FileCitationDeltaAnnotation, type FilePathAnnotation as FilePathAnnotation, type FilePathDeltaAnnotation as FilePathDeltaAnnotation, type ImageFile as ImageFile, type ImageFileContentBlock as ImageFileContentBlock, type ImageFileDelta as ImageFileDelta, type ImageFileDeltaBlock as ImageFileDeltaBlock, type ImageURL as ImageURL, type ImageURLContentBlock as ImageURLContentBlock, type ImageURLDelta as ImageURLDelta, type ImageURLDeltaBlock as ImageURLDeltaBlock, type Message as Message, type MessageContent as MessageContent, type MessageContentDelta as MessageContentDelta, type MessageContentPartParam as MessageContentPartParam, type MessageDeleted as MessageDeleted, type MessageDelta as MessageDelta, type MessageDeltaEvent as MessageDeltaEvent, type RefusalContentBlock as RefusalContentBlock, type RefusalDeltaBlock as RefusalDeltaBlock, type Text as Text, type TextContentBlock as TextContentBlock, type TextContentBlockParam as TextContentBlockParam, type TextDelta as TextDelta, type TextDeltaBlock as TextDeltaBlock, type MessagesPage as MessagesPage, type MessageCreateParams as MessageCreateParams, type MessageRetrieveParams as MessageRetrieveParams, type MessageUpdateParams as MessageUpdateParams, type MessageListParams as MessageListParams, type MessageDeleteParams as MessageDeleteParams, };
593
+ }
594
+ //# sourceMappingURL=messages.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/messages.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/resources/beta/threads/messages.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAIrD,4DAA0F;AAC1F,0DAAyD;AAEzD,0DAAoD;AAEpD;;GAEG;AACH,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;OAIG;IACH,MAAM,CAAC,QAAgB,E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,uBAAmB,CAAA,EAAE;YACvF,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,aAAa,EAAE,eAAe,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC9E,CAAC,CAAC;IACL,CAAC;IAED;;;;OAIG;IACH,MAAM,CACJ,SAAiB,EACjB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC;QAC7B,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,YAAY,SAAS,aAAa,SAAS,EAAE,EAAE;YAC5E,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,aAAa,EAAE,eAAe,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC9E,CAAC,CAAC;IACL,CAAC;CACF;AA1ED,4BA0EC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs.js ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ const tslib_1 = require("../../../internal/tslib.js");
5
+ tslib_1.__exportStar(require("./runs/index.js"), exports);
6
+ //# sourceMappingURL=runs.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/index.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export { Runs, type RequiredActionFunctionToolCall, type Run, type RunStatus, type RunCreateParams, type RunCreateParamsNonStreaming, type RunCreateParamsStreaming, type RunRetrieveParams, type RunUpdateParams, type RunListParams, type RunCancelParams, type RunSubmitToolOutputsParams, type RunSubmitToolOutputsParamsNonStreaming, type RunSubmitToolOutputsParamsStreaming, type RunsPage, type RunCreateAndPollParams, type RunCreateAndStreamParams, type RunStreamParams, type RunSubmitToolOutputsAndPollParams, type RunSubmitToolOutputsStreamParams, } from "./runs.js";
2
+ export { Steps, type CodeInterpreterLogs, type CodeInterpreterOutputImage, type CodeInterpreterToolCall, type CodeInterpreterToolCallDelta, type FileSearchToolCall, type FileSearchToolCallDelta, type FunctionToolCall, type FunctionToolCallDelta, type MessageCreationStepDetails, type RunStep, type RunStepInclude, type RunStepDelta, type RunStepDeltaEvent, type RunStepDeltaMessageDelta, type ToolCall, type ToolCallDelta, type ToolCallDeltaObject, type ToolCallsStepDetails, type StepRetrieveParams, type StepListParams, type RunStepsPage, } from "./steps.js";
3
+ //# sourceMappingURL=index.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/runs.d.mts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"runs.d.mts","sourceRoot":"","sources":["../../../../src/resources/beta/threads/runs/runs.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,OAAO;OACZ,KAAK,MAAM;OACX,KAAK,aAAa;OAClB,KAAK,WAAW;OAChB,KAAK,UAAU;OACf,KAAK,QAAQ;OACb,EACL,mBAAmB,EACnB,0BAA0B,EAC1B,uBAAuB,EACvB,4BAA4B,EAC5B,kBAAkB,EAClB,uBAAuB,EACvB,gBAAgB,EAChB,qBAAqB,EACrB,0BAA0B,EAC1B,OAAO,EACP,YAAY,EACZ,iBAAiB,EACjB,wBAAwB,EACxB,cAAc,EACd,YAAY,EACZ,cAAc,EACd,kBAAkB,EAClB,KAAK,EACL,QAAQ,EACR,aAAa,EACb,mBAAmB,EACnB,oBAAoB,EACrB;OACM,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAClD,EAAE,MAAM,EAAE;OAEV,EAAE,cAAc,EAAE;OAClB,EAAE,eAAe,EAAE,yBAAyB,EAAE;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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../../core/resource.js";
2
+ import * as StepsAPI from "./steps.js";
3
+ import * as Shared from "../../../shared.js";
4
+ import { APIPromise } from "../../../../core/api-promise.js";
5
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../../core/pagination.js";
6
+ import { RequestOptions } from "../../../../internal/request-options.js";
7
+ /**
8
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
9
+ */
10
+ export declare class Steps extends APIResource {
11
+ /**
12
+ * Retrieves a run step.
13
+ *
14
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
15
+ */
16
+ retrieve(stepID: string, params: StepRetrieveParams, options?: RequestOptions): APIPromise<RunStep>;
17
+ /**
18
+ * Returns a list of run steps belonging to a run.
19
+ *
20
+ * @deprecated The Assistants API is deprecated in favor of the Responses API
21
+ */
22
+ list(runID: string, params: StepListParams, options?: RequestOptions): PagePromise<RunStepsPage, RunStep>;
23
+ }
24
+ export type RunStepsPage = CursorPage<RunStep>;
25
+ /**
26
+ * Text output from the Code Interpreter tool call as part of a run step.
27
+ */
28
+ export interface CodeInterpreterLogs {
29
+ /**
30
+ * The index of the output in the outputs array.
31
+ */
32
+ index: number;
33
+ /**
34
+ * Always `logs`.
35
+ */
36
+ type: 'logs';
37
+ /**
38
+ * The text output from the Code Interpreter tool call.
39
+ */
40
+ logs?: string;
41
+ }
42
+ export interface CodeInterpreterOutputImage {
43
+ /**
44
+ * The index of the output in the outputs array.
45
+ */
46
+ index: number;
47
+ /**
48
+ * Always `image`.
49
+ */
50
+ type: 'image';
51
+ image?: CodeInterpreterOutputImage.Image;
52
+ }
53
+ export declare namespace CodeInterpreterOutputImage {
54
+ interface Image {
55
+ /**
56
+ * The [file](https://platform.openai.com/docs/api-reference/files) ID of the
57
+ * image.
58
+ */
59
+ file_id?: string;
60
+ }
61
+ }
62
+ /**
63
+ * Details of the Code Interpreter tool call the run step was involved in.
64
+ */
65
+ export interface CodeInterpreterToolCall {
66
+ /**
67
+ * The ID of the tool call.
68
+ */
69
+ id: string;
70
+ /**
71
+ * The Code Interpreter tool call definition.
72
+ */
73
+ code_interpreter: CodeInterpreterToolCall.CodeInterpreter;
74
+ /**
75
+ * The type of tool call. This is always going to be `code_interpreter` for this
76
+ * type of tool call.
77
+ */
78
+ type: 'code_interpreter';
79
+ }
80
+ export declare namespace CodeInterpreterToolCall {
81
+ /**
82
+ * The Code Interpreter tool call definition.
83
+ */
84
+ interface CodeInterpreter {
85
+ /**
86
+ * The input to the Code Interpreter tool call.
87
+ */
88
+ input: string;
89
+ /**
90
+ * The outputs from the Code Interpreter tool call. Code Interpreter can output one
91
+ * or more items, including text (`logs`) or images (`image`). Each of these are
92
+ * represented by a different object type.
93
+ */
94
+ outputs: Array<CodeInterpreter.Logs | CodeInterpreter.Image>;
95
+ }
96
+ namespace CodeInterpreter {
97
+ /**
98
+ * Text output from the Code Interpreter tool call as part of a run step.
99
+ */
100
+ interface Logs {
101
+ /**
102
+ * The text output from the Code Interpreter tool call.
103
+ */
104
+ logs: string;
105
+ /**
106
+ * Always `logs`.
107
+ */
108
+ type: 'logs';
109
+ }
110
+ interface Image {
111
+ image: Image.Image;
112
+ /**
113
+ * Always `image`.
114
+ */
115
+ type: 'image';
116
+ }
117
+ namespace Image {
118
+ interface Image {
119
+ /**
120
+ * The [file](https://platform.openai.com/docs/api-reference/files) ID of the
121
+ * image.
122
+ */
123
+ file_id: string;
124
+ }
125
+ }
126
+ }
127
+ }
128
+ /**
129
+ * Details of the Code Interpreter tool call the run step was involved in.
130
+ */
131
+ export interface CodeInterpreterToolCallDelta {
132
+ /**
133
+ * The index of the tool call in the tool calls array.
134
+ */
135
+ index: number;
136
+ /**
137
+ * The type of tool call. This is always going to be `code_interpreter` for this
138
+ * type of tool call.
139
+ */
140
+ type: 'code_interpreter';
141
+ /**
142
+ * The ID of the tool call.
143
+ */
144
+ id?: string;
145
+ /**
146
+ * The Code Interpreter tool call definition.
147
+ */
148
+ code_interpreter?: CodeInterpreterToolCallDelta.CodeInterpreter;
149
+ }
150
+ export declare namespace CodeInterpreterToolCallDelta {
151
+ /**
152
+ * The Code Interpreter tool call definition.
153
+ */
154
+ interface CodeInterpreter {
155
+ /**
156
+ * The input to the Code Interpreter tool call.
157
+ */
158
+ input?: string;
159
+ /**
160
+ * The outputs from the Code Interpreter tool call. Code Interpreter can output one
161
+ * or more items, including text (`logs`) or images (`image`). Each of these are
162
+ * represented by a different object type.
163
+ */
164
+ outputs?: Array<StepsAPI.CodeInterpreterLogs | StepsAPI.CodeInterpreterOutputImage>;
165
+ }
166
+ }
167
+ export interface FileSearchToolCall {
168
+ /**
169
+ * The ID of the tool call object.
170
+ */
171
+ id: string;
172
+ /**
173
+ * For now, this is always going to be an empty object.
174
+ */
175
+ file_search: FileSearchToolCall.FileSearch;
176
+ /**
177
+ * The type of tool call. This is always going to be `file_search` for this type of
178
+ * tool call.
179
+ */
180
+ type: 'file_search';
181
+ }
182
+ export declare namespace FileSearchToolCall {
183
+ /**
184
+ * For now, this is always going to be an empty object.
185
+ */
186
+ interface FileSearch {
187
+ /**
188
+ * The ranking options for the file search.
189
+ */
190
+ ranking_options?: FileSearch.RankingOptions;
191
+ /**
192
+ * The results of the file search.
193
+ */
194
+ results?: Array<FileSearch.Result>;
195
+ }
196
+ namespace FileSearch {
197
+ /**
198
+ * The ranking options for the file search.
199
+ */
200
+ interface RankingOptions {
201
+ /**
202
+ * The ranker to use for the file search. If not specified will use the `auto`
203
+ * ranker.
204
+ */
205
+ ranker: 'auto' | 'default_2024_08_21';
206
+ /**
207
+ * The score threshold for the file search. All values must be a floating point
208
+ * number between 0 and 1.
209
+ */
210
+ score_threshold: number;
211
+ }
212
+ /**
213
+ * A result instance of the file search.
214
+ */
215
+ interface Result {
216
+ /**
217
+ * The ID of the file that result was found in.
218
+ */
219
+ file_id: string;
220
+ /**
221
+ * The name of the file that result was found in.
222
+ */
223
+ file_name: string;
224
+ /**
225
+ * The score of the result. All values must be a floating point number between 0
226
+ * and 1.
227
+ */
228
+ score: number;
229
+ /**
230
+ * The content of the result that was found. The content is only included if
231
+ * requested via the include query parameter.
232
+ */
233
+ content?: Array<Result.Content>;
234
+ }
235
+ namespace Result {
236
+ interface Content {
237
+ /**
238
+ * The text content of the file.
239
+ */
240
+ text?: string;
241
+ /**
242
+ * The type of the content.
243
+ */
244
+ type?: 'text';
245
+ }
246
+ }
247
+ }
248
+ }
249
+ export interface FileSearchToolCallDelta {
250
+ /**
251
+ * For now, this is always going to be an empty object.
252
+ */
253
+ file_search: unknown;
254
+ /**
255
+ * The index of the tool call in the tool calls array.
256
+ */
257
+ index: number;
258
+ /**
259
+ * The type of tool call. This is always going to be `file_search` for this type of
260
+ * tool call.
261
+ */
262
+ type: 'file_search';
263
+ /**
264
+ * The ID of the tool call object.
265
+ */
266
+ id?: string;
267
+ }
268
+ export interface FunctionToolCall {
269
+ /**
270
+ * The ID of the tool call object.
271
+ */
272
+ id: string;
273
+ /**
274
+ * The definition of the function that was called.
275
+ */
276
+ function: FunctionToolCall.Function;
277
+ /**
278
+ * The type of tool call. This is always going to be `function` for this type of
279
+ * tool call.
280
+ */
281
+ type: 'function';
282
+ }
283
+ export declare namespace FunctionToolCall {
284
+ /**
285
+ * The definition of the function that was called.
286
+ */
287
+ interface Function {
288
+ /**
289
+ * The arguments passed to the function.
290
+ */
291
+ arguments: string;
292
+ /**
293
+ * The name of the function.
294
+ */
295
+ name: string;
296
+ /**
297
+ * The output of the function. This will be `null` if the outputs have not been
298
+ * [submitted](https://platform.openai.com/docs/api-reference/runs/submitToolOutputs)
299
+ * yet.
300
+ */
301
+ output: string | null;
302
+ }
303
+ }
304
+ export interface FunctionToolCallDelta {
305
+ /**
306
+ * The index of the tool call in the tool calls array.
307
+ */
308
+ index: number;
309
+ /**
310
+ * The type of tool call. This is always going to be `function` for this type of
311
+ * tool call.
312
+ */
313
+ type: 'function';
314
+ /**
315
+ * The ID of the tool call object.
316
+ */
317
+ id?: string;
318
+ /**
319
+ * The definition of the function that was called.
320
+ */
321
+ function?: FunctionToolCallDelta.Function;
322
+ }
323
+ export declare namespace FunctionToolCallDelta {
324
+ /**
325
+ * The definition of the function that was called.
326
+ */
327
+ interface Function {
328
+ /**
329
+ * The arguments passed to the function.
330
+ */
331
+ arguments?: string;
332
+ /**
333
+ * The name of the function.
334
+ */
335
+ name?: string;
336
+ /**
337
+ * The output of the function. This will be `null` if the outputs have not been
338
+ * [submitted](https://platform.openai.com/docs/api-reference/runs/submitToolOutputs)
339
+ * yet.
340
+ */
341
+ output?: string | null;
342
+ }
343
+ }
344
+ /**
345
+ * Details of the message creation by the run step.
346
+ */
347
+ export interface MessageCreationStepDetails {
348
+ message_creation: MessageCreationStepDetails.MessageCreation;
349
+ /**
350
+ * Always `message_creation`.
351
+ */
352
+ type: 'message_creation';
353
+ }
354
+ export declare namespace MessageCreationStepDetails {
355
+ interface MessageCreation {
356
+ /**
357
+ * The ID of the message that was created by this run step.
358
+ */
359
+ message_id: string;
360
+ }
361
+ }
362
+ /**
363
+ * Represents a step in execution of a run.
364
+ */
365
+ export interface RunStep {
366
+ /**
367
+ * The identifier of the run step, which can be referenced in API endpoints.
368
+ */
369
+ id: string;
370
+ /**
371
+ * The ID of the
372
+ * [assistant](https://platform.openai.com/docs/api-reference/assistants)
373
+ * associated with the run step.
374
+ */
375
+ assistant_id: string;
376
+ /**
377
+ * The Unix timestamp (in seconds) for when the run step was cancelled.
378
+ */
379
+ cancelled_at: number | null;
380
+ /**
381
+ * The Unix timestamp (in seconds) for when the run step completed.
382
+ */
383
+ completed_at: number | null;
384
+ /**
385
+ * The Unix timestamp (in seconds) for when the run step was created.
386
+ */
387
+ created_at: number;
388
+ /**
389
+ * The Unix timestamp (in seconds) for when the run step expired. A step is
390
+ * considered expired if the parent run is expired.
391
+ */
392
+ expired_at: number | null;
393
+ /**
394
+ * The Unix timestamp (in seconds) for when the run step failed.
395
+ */
396
+ failed_at: number | null;
397
+ /**
398
+ * The last error associated with this run step. Will be `null` if there are no
399
+ * errors.
400
+ */
401
+ last_error: RunStep.LastError | null;
402
+ /**
403
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
404
+ * for storing additional information about the object in a structured format, and
405
+ * querying for objects via API or the dashboard.
406
+ *
407
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
408
+ * a maximum length of 512 characters.
409
+ */
410
+ metadata: Shared.Metadata | null;
411
+ /**
412
+ * The object type, which is always `thread.run.step`.
413
+ */
414
+ object: 'thread.run.step';
415
+ /**
416
+ * The ID of the [run](https://platform.openai.com/docs/api-reference/runs) that
417
+ * this run step is a part of.
418
+ */
419
+ run_id: string;
420
+ /**
421
+ * The status of the run step, which can be either `in_progress`, `cancelled`,
422
+ * `failed`, `completed`, or `expired`.
423
+ */
424
+ status: 'in_progress' | 'cancelled' | 'failed' | 'completed' | 'expired';
425
+ /**
426
+ * The details of the run step.
427
+ */
428
+ step_details: MessageCreationStepDetails | ToolCallsStepDetails;
429
+ /**
430
+ * The ID of the [thread](https://platform.openai.com/docs/api-reference/threads)
431
+ * that was run.
432
+ */
433
+ thread_id: string;
434
+ /**
435
+ * The type of run step, which can be either `message_creation` or `tool_calls`.
436
+ */
437
+ type: 'message_creation' | 'tool_calls';
438
+ /**
439
+ * Usage statistics related to the run step. This value will be `null` while the
440
+ * run step's status is `in_progress`.
441
+ */
442
+ usage: RunStep.Usage | null;
443
+ }
444
+ export declare namespace RunStep {
445
+ /**
446
+ * The last error associated with this run step. Will be `null` if there are no
447
+ * errors.
448
+ */
449
+ interface LastError {
450
+ /**
451
+ * One of `server_error` or `rate_limit_exceeded`.
452
+ */
453
+ code: 'server_error' | 'rate_limit_exceeded';
454
+ /**
455
+ * A human-readable description of the error.
456
+ */
457
+ message: string;
458
+ }
459
+ /**
460
+ * Usage statistics related to the run step. This value will be `null` while the
461
+ * run step's status is `in_progress`.
462
+ */
463
+ interface Usage {
464
+ /**
465
+ * Number of completion tokens used over the course of the run step.
466
+ */
467
+ completion_tokens: number;
468
+ /**
469
+ * Number of prompt tokens used over the course of the run step.
470
+ */
471
+ prompt_tokens: number;
472
+ /**
473
+ * Total number of tokens used (prompt + completion).
474
+ */
475
+ total_tokens: number;
476
+ }
477
+ }
478
+ /**
479
+ * The delta containing the fields that have changed on the run step.
480
+ */
481
+ export interface RunStepDelta {
482
+ /**
483
+ * The details of the run step.
484
+ */
485
+ step_details?: RunStepDeltaMessageDelta | ToolCallDeltaObject;
486
+ }
487
+ /**
488
+ * Represents a run step delta i.e. any changed fields on a run step during
489
+ * streaming.
490
+ */
491
+ export interface RunStepDeltaEvent {
492
+ /**
493
+ * The identifier of the run step, which can be referenced in API endpoints.
494
+ */
495
+ id: string;
496
+ /**
497
+ * The delta containing the fields that have changed on the run step.
498
+ */
499
+ delta: RunStepDelta;
500
+ /**
501
+ * The object type, which is always `thread.run.step.delta`.
502
+ */
503
+ object: 'thread.run.step.delta';
504
+ }
505
+ /**
506
+ * Details of the message creation by the run step.
507
+ */
508
+ export interface RunStepDeltaMessageDelta {
509
+ /**
510
+ * Always `message_creation`.
511
+ */
512
+ type: 'message_creation';
513
+ message_creation?: RunStepDeltaMessageDelta.MessageCreation;
514
+ }
515
+ export declare namespace RunStepDeltaMessageDelta {
516
+ interface MessageCreation {
517
+ /**
518
+ * The ID of the message that was created by this run step.
519
+ */
520
+ message_id?: string;
521
+ }
522
+ }
523
+ export type RunStepInclude = 'step_details.tool_calls[*].file_search.results[*].content';
524
+ /**
525
+ * Details of the Code Interpreter tool call the run step was involved in.
526
+ */
527
+ export type ToolCall = CodeInterpreterToolCall | FileSearchToolCall | FunctionToolCall;
528
+ /**
529
+ * Details of the Code Interpreter tool call the run step was involved in.
530
+ */
531
+ export type ToolCallDelta = CodeInterpreterToolCallDelta | FileSearchToolCallDelta | FunctionToolCallDelta;
532
+ /**
533
+ * Details of the tool call.
534
+ */
535
+ export interface ToolCallDeltaObject {
536
+ /**
537
+ * Always `tool_calls`.
538
+ */
539
+ type: 'tool_calls';
540
+ /**
541
+ * An array of tool calls the run step was involved in. These can be associated
542
+ * with one of three types of tools: `code_interpreter`, `file_search`, or
543
+ * `function`.
544
+ */
545
+ tool_calls?: Array<ToolCallDelta>;
546
+ }
547
+ /**
548
+ * Details of the tool call.
549
+ */
550
+ export interface ToolCallsStepDetails {
551
+ /**
552
+ * An array of tool calls the run step was involved in. These can be associated
553
+ * with one of three types of tools: `code_interpreter`, `file_search`, or
554
+ * `function`.
555
+ */
556
+ tool_calls: Array<ToolCall>;
557
+ /**
558
+ * Always `tool_calls`.
559
+ */
560
+ type: 'tool_calls';
561
+ }
562
+ export interface StepRetrieveParams {
563
+ /**
564
+ * Path param: The ID of the thread to which the run and run step belongs.
565
+ */
566
+ thread_id: string;
567
+ /**
568
+ * Path param: The ID of the run to which the run step belongs.
569
+ */
570
+ run_id: string;
571
+ /**
572
+ * Query param: A list of additional fields to include in the response. Currently
573
+ * the only supported value is
574
+ * `step_details.tool_calls[*].file_search.results[*].content` to fetch the file
575
+ * search result content.
576
+ *
577
+ * See the
578
+ * [file search tool documentation](https://platform.openai.com/docs/assistants/tools/file-search#customizing-file-search-settings)
579
+ * for more information.
580
+ */
581
+ include?: Array<RunStepInclude>;
582
+ }
583
+ export interface StepListParams extends CursorPageParams {
584
+ /**
585
+ * Path param: The ID of the thread the run and run steps belong to.
586
+ */
587
+ thread_id: string;
588
+ /**
589
+ * Query param: A cursor for use in pagination. `before` is an object ID that
590
+ * defines your place in the list. For instance, if you make a list request and
591
+ * receive 100 objects, starting with obj_foo, your subsequent call can include
592
+ * before=obj_foo in order to fetch the previous page of the list.
593
+ */
594
+ before?: string;
595
+ /**
596
+ * Query param: A list of additional fields to include in the response. Currently
597
+ * the only supported value is
598
+ * `step_details.tool_calls[*].file_search.results[*].content` to fetch the file
599
+ * search result content.
600
+ *
601
+ * See the
602
+ * [file search tool documentation](https://platform.openai.com/docs/assistants/tools/file-search#customizing-file-search-settings)
603
+ * for more information.
604
+ */
605
+ include?: Array<RunStepInclude>;
606
+ /**
607
+ * Query param: Sort order by the `created_at` timestamp of the objects. `asc` for
608
+ * ascending order and `desc` for descending order.
609
+ */
610
+ order?: 'asc' | 'desc';
611
+ }
612
+ export declare namespace Steps {
613
+ export { type CodeInterpreterLogs as CodeInterpreterLogs, type CodeInterpreterOutputImage as CodeInterpreterOutputImage, type CodeInterpreterToolCall as CodeInterpreterToolCall, type CodeInterpreterToolCallDelta as CodeInterpreterToolCallDelta, type FileSearchToolCall as FileSearchToolCall, type FileSearchToolCallDelta as FileSearchToolCallDelta, type FunctionToolCall as FunctionToolCall, type FunctionToolCallDelta as FunctionToolCallDelta, type MessageCreationStepDetails as MessageCreationStepDetails, type RunStep as RunStep, type RunStepDelta as RunStepDelta, type RunStepDeltaEvent as RunStepDeltaEvent, type RunStepDeltaMessageDelta as RunStepDeltaMessageDelta, type RunStepInclude as RunStepInclude, type ToolCall as ToolCall, type ToolCallDelta as ToolCallDelta, type ToolCallDeltaObject as ToolCallDeltaObject, type ToolCallsStepDetails as ToolCallsStepDetails, type RunStepsPage as RunStepsPage, type StepRetrieveParams as StepRetrieveParams, type StepListParams as StepListParams, };
614
+ }
615
+ //# sourceMappingURL=steps.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/runs/steps.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"steps.js","sourceRoot":"","sources":["../../../../src/resources/beta/threads/runs/steps.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,2DAAwD;AAIxD,+DAA6F;AAC7F,6DAA4D;AAE5D,6DAAuD;AAEvD;;GAEG;AACH,MAAa,KAAM,SAAQ,sBAAW;IACpC;;;;OAIG;IACH,QAAQ,CAAC,MAAc,EAAE,MAA0B,EAAE,OAAwB;QAC3E,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QAC/C,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,YAAY,SAAS,SAAS,MAAM,UAAU,MAAM,EAAE,EAAE;YAClF,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,aAAa,EAAE,eAAe,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC9E,CAAC,CAAC;IACL,CAAC;IAED;;;;OAIG;IACH,IAAI,CAAC,KAAa,EAAE,MAAsB,EAAE,OAAwB;QAClE,MAAM,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,IAAA,WAAI,EAAA,YAAY,SAAS,SAAS,KAAK,QAAQ,EAAE,CAAA,uBAAmB,CAAA,EAAE;YACnG,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,aAAa,EAAE,eAAe,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC9E,CAAC,CAAC;IACL,CAAC;CACF;AA5BD,sBA4BC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/threads.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"threads.d.ts","sourceRoot":"","sources":["../../../src/resources/beta/threads/threads.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAA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,EACnD,KAAK,SAAS,IAAI,SAAS,EAC3B,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,YAAY,IAAI,YAAY,EACjC,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;IAEF,OAAO,EAAE,eAAe,EAAE,CAAC;CAC5B"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/beta/threads/threads.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"threads.js","sourceRoot":"","sources":["../../../src/resources/beta/threads/threads.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AAIrD,mEAA0C;AAC1C,4CAoCoB;AACpB,gEAAuC;AACvC,yCAqBqB;AAGrB,0DAAyD;AAEzD,qEAAmG;AACnG,0DAAoD;AAEpD;;GAEG;AACH,MAAa,OAAQ,SAAQ,sBAAW;IAAxC;;QACE,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACpD,aAAQ,GAAyB,IAAI,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAiG1E,CAAC;IA/FC;;;;OAIG;IACH,MAAM,CAAC,OAA8C,EAAE,EAAE,OAAwB;QAC/E,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE;YACnC,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,aAAa,EAAE,eAAe,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC9E,CAAC,CAAC;IACL,CAAC;IAED;;;;OAIG;IACH,QAAQ,CAAC,QAAgB,EAAE,OAAwB;QACjD,OAA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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import * as CompletionsCompletionsAPI from "./completions.mjs";
3
+ import * as CompletionsAPI from "../../completions.mjs";
4
+ import * as Shared from "../../shared.mjs";
5
+ import * as MessagesAPI from "./messages.mjs";
6
+ import { MessageListParams, Messages } from "./messages.mjs";
7
+ import { APIPromise } from "../../../core/api-promise.mjs";
8
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.mjs";
9
+ import { Stream } from "../../../core/streaming.mjs";
10
+ import { RequestOptions } from "../../../internal/request-options.mjs";
11
+ import { ChatCompletionRunner } from "../../../lib/ChatCompletionRunner.mjs";
12
+ import { ChatCompletionStreamingRunner } from "../../../lib/ChatCompletionStreamingRunner.mjs";
13
+ import { RunnerOptions } from "../../../lib/AbstractChatCompletionRunner.mjs";
14
+ import { ChatCompletionToolRunnerParams } from "../../../lib/ChatCompletionRunner.mjs";
15
+ import { ChatCompletionStreamingToolRunnerParams } from "../../../lib/ChatCompletionStreamingRunner.mjs";
16
+ import { ChatCompletionStream, type ChatCompletionStreamParams } from "../../../lib/ChatCompletionStream.mjs";
17
+ import { ExtractParsedContentFromParams } from "../../../lib/parser.mjs";
18
+ export declare class Completions extends APIResource {
19
+ messages: MessagesAPI.Messages;
20
+ /**
21
+ * **Starting a new project?** We recommend trying
22
+ * [Responses](https://platform.openai.com/docs/api-reference/responses) to take
23
+ * advantage of the latest OpenAI platform features. Compare
24
+ * [Chat Completions with Responses](https://platform.openai.com/docs/guides/responses-vs-chat-completions?api-mode=responses).
25
+ *
26
+ * ---
27
+ *
28
+ * Creates a model response for the given chat conversation. Learn more in the
29
+ * [text generation](https://platform.openai.com/docs/guides/text-generation),
30
+ * [vision](https://platform.openai.com/docs/guides/vision), and
31
+ * [audio](https://platform.openai.com/docs/guides/audio) guides.
32
+ *
33
+ * Parameter support can differ depending on the model used to generate the
34
+ * response, particularly for newer reasoning models. Parameters that are only
35
+ * supported for reasoning models are noted below. For the current state of
36
+ * unsupported parameters in reasoning models,
37
+ * [refer to the reasoning guide](https://platform.openai.com/docs/guides/reasoning).
38
+ *
39
+ * @example
40
+ * ```ts
41
+ * const chatCompletion = await client.chat.completions.create(
42
+ * {
43
+ * messages: [{ content: 'string', role: 'developer' }],
44
+ * model: 'gpt-4o',
45
+ * },
46
+ * );
47
+ * ```
48
+ */
49
+ create(body: ChatCompletionCreateParamsNonStreaming, options?: RequestOptions): APIPromise<ChatCompletion>;
50
+ create(body: ChatCompletionCreateParamsStreaming, options?: RequestOptions): APIPromise<Stream<ChatCompletionChunk>>;
51
+ create(body: ChatCompletionCreateParamsBase, options?: RequestOptions): APIPromise<Stream<ChatCompletionChunk> | ChatCompletion>;
52
+ /**
53
+ * Get a stored chat completion. Only Chat Completions that have been created with
54
+ * the `store` parameter set to `true` will be returned.
55
+ *
56
+ * @example
57
+ * ```ts
58
+ * const chatCompletion =
59
+ * await client.chat.completions.retrieve('completion_id');
60
+ * ```
61
+ */
62
+ retrieve(completionID: string, options?: RequestOptions): APIPromise<ChatCompletion>;
63
+ /**
64
+ * Modify a stored chat completion. Only Chat Completions that have been created
65
+ * with the `store` parameter set to `true` can be modified. Currently, the only
66
+ * supported modification is to update the `metadata` field.
67
+ *
68
+ * @example
69
+ * ```ts
70
+ * const chatCompletion = await client.chat.completions.update(
71
+ * 'completion_id',
72
+ * { metadata: { foo: 'string' } },
73
+ * );
74
+ * ```
75
+ */
76
+ update(completionID: string, body: ChatCompletionUpdateParams, options?: RequestOptions): APIPromise<ChatCompletion>;
77
+ /**
78
+ * List stored Chat Completions. Only Chat Completions that have been stored with
79
+ * the `store` parameter set to `true` will be returned.
80
+ *
81
+ * @example
82
+ * ```ts
83
+ * // Automatically fetches more pages as needed.
84
+ * for await (const chatCompletion of client.chat.completions.list()) {
85
+ * // ...
86
+ * }
87
+ * ```
88
+ */
89
+ list(query?: ChatCompletionListParams | null | undefined, options?: RequestOptions): PagePromise<ChatCompletionsPage, ChatCompletion>;
90
+ /**
91
+ * Delete a stored chat completion. Only Chat Completions that have been created
92
+ * with the `store` parameter set to `true` can be deleted.
93
+ *
94
+ * @example
95
+ * ```ts
96
+ * const chatCompletionDeleted =
97
+ * await client.chat.completions.delete('completion_id');
98
+ * ```
99
+ */
100
+ delete(completionID: string, options?: RequestOptions): APIPromise<ChatCompletionDeleted>;
101
+ parse<Params extends ChatCompletionParseParams, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RequestOptions): APIPromise<ParsedChatCompletion<ParsedT>>;
102
+ /**
103
+ * A convenience helper for using tool calls with the /chat/completions endpoint
104
+ * which automatically calls the JavaScript functions you provide and sends their
105
+ * results back to the /chat/completions endpoint, looping as long as the model
106
+ * requests function calls.
107
+ *
108
+ * For more details and examples, see
109
+ * [the docs](https://github.com/openai/openai-node#automated-function-calls)
110
+ */
111
+ runTools<Params extends ChatCompletionToolRunnerParams<any>, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RunnerOptions): ChatCompletionRunner<ParsedT>;
112
+ runTools<Params extends ChatCompletionStreamingToolRunnerParams<any>, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RunnerOptions): ChatCompletionStreamingRunner<ParsedT>;
113
+ /**
114
+ * Creates a chat completion stream
115
+ */
116
+ stream<Params extends ChatCompletionStreamParams, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RequestOptions): ChatCompletionStream<ParsedT>;
117
+ }
118
+ export interface ParsedFunction extends ChatCompletionMessageFunctionToolCall.Function {
119
+ parsed_arguments?: unknown;
120
+ }
121
+ export interface ParsedFunctionToolCall extends ChatCompletionMessageFunctionToolCall {
122
+ function: ParsedFunction;
123
+ }
124
+ export interface ParsedChatCompletionMessage<ParsedT> extends ChatCompletionMessage {
125
+ parsed: ParsedT | null;
126
+ tool_calls?: Array<ParsedFunctionToolCall>;
127
+ }
128
+ export interface ParsedChoice<ParsedT> extends ChatCompletion.Choice {
129
+ message: ParsedChatCompletionMessage<ParsedT>;
130
+ }
131
+ export interface ParsedChatCompletion<ParsedT> extends ChatCompletion {
132
+ choices: Array<ParsedChoice<ParsedT>>;
133
+ }
134
+ export type ChatCompletionParseParams = ChatCompletionCreateParamsNonStreaming;
135
+ export { ChatCompletionStreamingRunner } from "../../../lib/ChatCompletionStreamingRunner.mjs";
136
+ export { type RunnableFunctionWithParse, type RunnableFunctionWithoutParse, ParsingToolFunction, } from "../../../lib/RunnableFunction.mjs";
137
+ export { type ChatCompletionToolRunnerParams } from "../../../lib/ChatCompletionRunner.mjs";
138
+ export { type ChatCompletionStreamingToolRunnerParams } from "../../../lib/ChatCompletionStreamingRunner.mjs";
139
+ export { ChatCompletionStream, type ChatCompletionStreamParams } from "../../../lib/ChatCompletionStream.mjs";
140
+ export { ChatCompletionRunner } from "../../../lib/ChatCompletionRunner.mjs";
141
+ export type ChatCompletionsPage = CursorPage<ChatCompletion>;
142
+ export type ChatCompletionStoreMessagesPage = CursorPage<ChatCompletionStoreMessage>;
143
+ /**
144
+ * Represents a chat completion response returned by model, based on the provided
145
+ * input.
146
+ */
147
+ export interface ChatCompletion {
148
+ /**
149
+ * A unique identifier for the chat completion.
150
+ */
151
+ id: string;
152
+ /**
153
+ * A list of chat completion choices. Can be more than one if `n` is greater
154
+ * than 1.
155
+ */
156
+ choices: Array<ChatCompletion.Choice>;
157
+ /**
158
+ * The Unix timestamp (in seconds) of when the chat completion was created.
159
+ */
160
+ created: number;
161
+ /**
162
+ * The model used for the chat completion.
163
+ */
164
+ model: string;
165
+ /**
166
+ * The object type, which is always `chat.completion`.
167
+ */
168
+ object: 'chat.completion';
169
+ /**
170
+ * Specifies the processing type used for serving the request.
171
+ *
172
+ * - If set to 'auto', then the request will be processed with the service tier
173
+ * configured in the Project settings. Unless otherwise configured, the Project
174
+ * will use 'default'.
175
+ * - If set to 'default', then the request will be processed with the standard
176
+ * pricing and performance for the selected model.
177
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
178
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
179
+ * will be processed with the corresponding service tier.
180
+ * - When not set, the default behavior is 'auto'.
181
+ *
182
+ * When the `service_tier` parameter is set, the response body will include the
183
+ * `service_tier` value based on the processing mode actually used to serve the
184
+ * request. This response value may be different from the value set in the
185
+ * parameter.
186
+ */
187
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
188
+ /**
189
+ * @deprecated This fingerprint represents the backend configuration that the model
190
+ * runs with.
191
+ *
192
+ * Can be used in conjunction with the `seed` request parameter to understand when
193
+ * backend changes have been made that might impact determinism.
194
+ */
195
+ system_fingerprint?: string;
196
+ /**
197
+ * Usage statistics for the completion request.
198
+ */
199
+ usage?: CompletionsAPI.CompletionUsage;
200
+ }
201
+ export declare namespace ChatCompletion {
202
+ interface Choice {
203
+ /**
204
+ * The reason the model stopped generating tokens. This will be `stop` if the model
205
+ * hit a natural stop point or a provided stop sequence, `length` if the maximum
206
+ * number of tokens specified in the request was reached, `content_filter` if
207
+ * content was omitted due to a flag from our content filters, `tool_calls` if the
208
+ * model called a tool, or `function_call` (deprecated) if the model called a
209
+ * function.
210
+ */
211
+ finish_reason: 'stop' | 'length' | 'tool_calls' | 'content_filter' | 'function_call';
212
+ /**
213
+ * The index of the choice in the list of choices.
214
+ */
215
+ index: number;
216
+ /**
217
+ * Log probability information for the choice.
218
+ */
219
+ logprobs: Choice.Logprobs | null;
220
+ /**
221
+ * A chat completion message generated by the model.
222
+ */
223
+ message: CompletionsCompletionsAPI.ChatCompletionMessage;
224
+ }
225
+ namespace Choice {
226
+ /**
227
+ * Log probability information for the choice.
228
+ */
229
+ interface Logprobs {
230
+ /**
231
+ * A list of message content tokens with log probability information.
232
+ */
233
+ content: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
234
+ /**
235
+ * A list of message refusal tokens with log probability information.
236
+ */
237
+ refusal: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
238
+ }
239
+ }
240
+ }
241
+ /**
242
+ * Constrains the tools available to the model to a pre-defined set.
243
+ */
244
+ export interface ChatCompletionAllowedToolChoice {
245
+ /**
246
+ * Constrains the tools available to the model to a pre-defined set.
247
+ */
248
+ allowed_tools: ChatCompletionAllowedTools;
249
+ /**
250
+ * Allowed tool configuration type. Always `allowed_tools`.
251
+ */
252
+ type: 'allowed_tools';
253
+ }
254
+ /**
255
+ * Messages sent by the model in response to user messages.
256
+ */
257
+ export interface ChatCompletionAssistantMessageParam {
258
+ /**
259
+ * The role of the messages author, in this case `assistant`.
260
+ */
261
+ role: 'assistant';
262
+ /**
263
+ * Data about a previous audio response from the model.
264
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
265
+ */
266
+ audio?: ChatCompletionAssistantMessageParam.Audio | null;
267
+ /**
268
+ * The contents of the assistant message. Required unless `tool_calls` or
269
+ * `function_call` is specified.
270
+ */
271
+ content?: string | Array<ChatCompletionContentPartText | ChatCompletionContentPartRefusal> | null;
272
+ /**
273
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
274
+ * function that should be called, as generated by the model.
275
+ */
276
+ function_call?: ChatCompletionAssistantMessageParam.FunctionCall | null;
277
+ /**
278
+ * An optional name for the participant. Provides the model information to
279
+ * differentiate between participants of the same role.
280
+ */
281
+ name?: string;
282
+ /**
283
+ * The refusal message by the assistant.
284
+ */
285
+ refusal?: string | null;
286
+ /**
287
+ * The tool calls generated by the model, such as function calls.
288
+ */
289
+ tool_calls?: Array<ChatCompletionMessageToolCall>;
290
+ }
291
+ export declare namespace ChatCompletionAssistantMessageParam {
292
+ /**
293
+ * Data about a previous audio response from the model.
294
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
295
+ */
296
+ interface Audio {
297
+ /**
298
+ * Unique identifier for a previous audio response from the model.
299
+ */
300
+ id: string;
301
+ }
302
+ /**
303
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
304
+ * function that should be called, as generated by the model.
305
+ */
306
+ interface FunctionCall {
307
+ /**
308
+ * The arguments to call the function with, as generated by the model in JSON
309
+ * format. Note that the model does not always generate valid JSON, and may
310
+ * hallucinate parameters not defined by your function schema. Validate the
311
+ * arguments in your code before calling your function.
312
+ */
313
+ arguments: string;
314
+ /**
315
+ * The name of the function to call.
316
+ */
317
+ name: string;
318
+ }
319
+ }
320
+ /**
321
+ * If the audio output modality is requested, this object contains data about the
322
+ * audio response from the model.
323
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
324
+ */
325
+ export interface ChatCompletionAudio {
326
+ /**
327
+ * Unique identifier for this audio response.
328
+ */
329
+ id: string;
330
+ /**
331
+ * Base64 encoded audio bytes generated by the model, in the format specified in
332
+ * the request.
333
+ */
334
+ data: string;
335
+ /**
336
+ * The Unix timestamp (in seconds) for when this audio response will no longer be
337
+ * accessible on the server for use in multi-turn conversations.
338
+ */
339
+ expires_at: number;
340
+ /**
341
+ * Transcript of the audio generated by the model.
342
+ */
343
+ transcript: string;
344
+ }
345
+ /**
346
+ * Parameters for audio output. Required when audio output is requested with
347
+ * `modalities: ["audio"]`.
348
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
349
+ */
350
+ export interface ChatCompletionAudioParam {
351
+ /**
352
+ * Specifies the output audio format. Must be one of `wav`, `mp3`, `flac`, `opus`,
353
+ * or `pcm16`.
354
+ */
355
+ format: 'wav' | 'aac' | 'mp3' | 'flac' | 'opus' | 'pcm16';
356
+ /**
357
+ * The voice the model uses to respond. Supported voices are `alloy`, `ash`,
358
+ * `ballad`, `coral`, `echo`, `fable`, `nova`, `onyx`, `sage`, and `shimmer`.
359
+ */
360
+ voice: (string & {}) | 'alloy' | 'ash' | 'ballad' | 'coral' | 'echo' | 'sage' | 'shimmer' | 'verse';
361
+ }
362
+ /**
363
+ * Represents a streamed chunk of a chat completion response returned by the model,
364
+ * based on the provided input.
365
+ * [Learn more](https://platform.openai.com/docs/guides/streaming-responses).
366
+ */
367
+ export interface ChatCompletionChunk {
368
+ /**
369
+ * A unique identifier for the chat completion. Each chunk has the same ID.
370
+ */
371
+ id: string;
372
+ /**
373
+ * A list of chat completion choices. Can contain more than one elements if `n` is
374
+ * greater than 1. Can also be empty for the last chunk if you set
375
+ * `stream_options: {"include_usage": true}`.
376
+ */
377
+ choices: Array<ChatCompletionChunk.Choice>;
378
+ /**
379
+ * The Unix timestamp (in seconds) of when the chat completion was created. Each
380
+ * chunk has the same timestamp.
381
+ */
382
+ created: number;
383
+ /**
384
+ * The model to generate the completion.
385
+ */
386
+ model: string;
387
+ /**
388
+ * The object type, which is always `chat.completion.chunk`.
389
+ */
390
+ object: 'chat.completion.chunk';
391
+ /**
392
+ * Specifies the processing type used for serving the request.
393
+ *
394
+ * - If set to 'auto', then the request will be processed with the service tier
395
+ * configured in the Project settings. Unless otherwise configured, the Project
396
+ * will use 'default'.
397
+ * - If set to 'default', then the request will be processed with the standard
398
+ * pricing and performance for the selected model.
399
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
400
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
401
+ * will be processed with the corresponding service tier.
402
+ * - When not set, the default behavior is 'auto'.
403
+ *
404
+ * When the `service_tier` parameter is set, the response body will include the
405
+ * `service_tier` value based on the processing mode actually used to serve the
406
+ * request. This response value may be different from the value set in the
407
+ * parameter.
408
+ */
409
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
410
+ /**
411
+ * @deprecated This fingerprint represents the backend configuration that the model
412
+ * runs with. Can be used in conjunction with the `seed` request parameter to
413
+ * understand when backend changes have been made that might impact determinism.
414
+ */
415
+ system_fingerprint?: string;
416
+ /**
417
+ * An optional field that will only be present when you set
418
+ * `stream_options: {"include_usage": true}` in your request. When present, it
419
+ * contains a null value **except for the last chunk** which contains the token
420
+ * usage statistics for the entire request.
421
+ *
422
+ * **NOTE:** If the stream is interrupted or cancelled, you may not receive the
423
+ * final usage chunk which contains the total token usage for the request.
424
+ */
425
+ usage?: CompletionsAPI.CompletionUsage | null;
426
+ }
427
+ export declare namespace ChatCompletionChunk {
428
+ interface Choice {
429
+ /**
430
+ * A chat completion delta generated by streamed model responses.
431
+ */
432
+ delta: Choice.Delta;
433
+ /**
434
+ * The reason the model stopped generating tokens. This will be `stop` if the model
435
+ * hit a natural stop point or a provided stop sequence, `length` if the maximum
436
+ * number of tokens specified in the request was reached, `content_filter` if
437
+ * content was omitted due to a flag from our content filters, `tool_calls` if the
438
+ * model called a tool, or `function_call` (deprecated) if the model called a
439
+ * function.
440
+ */
441
+ finish_reason: 'stop' | 'length' | 'tool_calls' | 'content_filter' | 'function_call' | null;
442
+ /**
443
+ * The index of the choice in the list of choices.
444
+ */
445
+ index: number;
446
+ /**
447
+ * Log probability information for the choice.
448
+ */
449
+ logprobs?: Choice.Logprobs | null;
450
+ }
451
+ namespace Choice {
452
+ /**
453
+ * A chat completion delta generated by streamed model responses.
454
+ */
455
+ interface Delta {
456
+ /**
457
+ * The contents of the chunk message.
458
+ */
459
+ content?: string | null;
460
+ /**
461
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
462
+ * function that should be called, as generated by the model.
463
+ */
464
+ function_call?: Delta.FunctionCall;
465
+ /**
466
+ * The refusal message generated by the model.
467
+ */
468
+ refusal?: string | null;
469
+ /**
470
+ * The role of the author of this message.
471
+ */
472
+ role?: 'developer' | 'system' | 'user' | 'assistant' | 'tool';
473
+ tool_calls?: Array<Delta.ToolCall>;
474
+ }
475
+ namespace Delta {
476
+ /**
477
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
478
+ * function that should be called, as generated by the model.
479
+ */
480
+ interface FunctionCall {
481
+ /**
482
+ * The arguments to call the function with, as generated by the model in JSON
483
+ * format. Note that the model does not always generate valid JSON, and may
484
+ * hallucinate parameters not defined by your function schema. Validate the
485
+ * arguments in your code before calling your function.
486
+ */
487
+ arguments?: string;
488
+ /**
489
+ * The name of the function to call.
490
+ */
491
+ name?: string;
492
+ }
493
+ interface ToolCall {
494
+ index: number;
495
+ /**
496
+ * The ID of the tool call.
497
+ */
498
+ id?: string;
499
+ function?: ToolCall.Function;
500
+ /**
501
+ * The type of the tool. Currently, only `function` is supported.
502
+ */
503
+ type?: 'function';
504
+ }
505
+ namespace ToolCall {
506
+ interface Function {
507
+ /**
508
+ * The arguments to call the function with, as generated by the model in JSON
509
+ * format. Note that the model does not always generate valid JSON, and may
510
+ * hallucinate parameters not defined by your function schema. Validate the
511
+ * arguments in your code before calling your function.
512
+ */
513
+ arguments?: string;
514
+ /**
515
+ * The name of the function to call.
516
+ */
517
+ name?: string;
518
+ }
519
+ }
520
+ }
521
+ /**
522
+ * Log probability information for the choice.
523
+ */
524
+ interface Logprobs {
525
+ /**
526
+ * A list of message content tokens with log probability information.
527
+ */
528
+ content: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
529
+ /**
530
+ * A list of message refusal tokens with log probability information.
531
+ */
532
+ refusal: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
533
+ }
534
+ }
535
+ }
536
+ /**
537
+ * Learn about
538
+ * [text inputs](https://platform.openai.com/docs/guides/text-generation).
539
+ */
540
+ export type ChatCompletionContentPart = ChatCompletionContentPartText | ChatCompletionContentPartImage | ChatCompletionContentPartInputAudio | ChatCompletionContentPart.File;
541
+ export declare namespace ChatCompletionContentPart {
542
+ /**
543
+ * Learn about [file inputs](https://platform.openai.com/docs/guides/text) for text
544
+ * generation.
545
+ */
546
+ interface File {
547
+ file: File.File;
548
+ /**
549
+ * The type of the content part. Always `file`.
550
+ */
551
+ type: 'file';
552
+ }
553
+ namespace File {
554
+ interface File {
555
+ /**
556
+ * The base64 encoded file data, used when passing the file to the model as a
557
+ * string.
558
+ */
559
+ file_data?: string;
560
+ /**
561
+ * The ID of an uploaded file to use as input.
562
+ */
563
+ file_id?: string;
564
+ /**
565
+ * The name of the file, used when passing the file to the model as a string.
566
+ */
567
+ filename?: string;
568
+ }
569
+ }
570
+ }
571
+ /**
572
+ * Learn about [image inputs](https://platform.openai.com/docs/guides/vision).
573
+ */
574
+ export interface ChatCompletionContentPartImage {
575
+ image_url: ChatCompletionContentPartImage.ImageURL;
576
+ /**
577
+ * The type of the content part.
578
+ */
579
+ type: 'image_url';
580
+ }
581
+ export declare namespace ChatCompletionContentPartImage {
582
+ interface ImageURL {
583
+ /**
584
+ * Either a URL of the image or the base64 encoded image data.
585
+ */
586
+ url: string;
587
+ /**
588
+ * Specifies the detail level of the image. Learn more in the
589
+ * [Vision guide](https://platform.openai.com/docs/guides/vision#low-or-high-fidelity-image-understanding).
590
+ */
591
+ detail?: 'auto' | 'low' | 'high';
592
+ }
593
+ }
594
+ /**
595
+ * Learn about [audio inputs](https://platform.openai.com/docs/guides/audio).
596
+ */
597
+ export interface ChatCompletionContentPartInputAudio {
598
+ input_audio: ChatCompletionContentPartInputAudio.InputAudio;
599
+ /**
600
+ * The type of the content part. Always `input_audio`.
601
+ */
602
+ type: 'input_audio';
603
+ }
604
+ export declare namespace ChatCompletionContentPartInputAudio {
605
+ interface InputAudio {
606
+ /**
607
+ * Base64 encoded audio data.
608
+ */
609
+ data: string;
610
+ /**
611
+ * The format of the encoded audio data. Currently supports "wav" and "mp3".
612
+ */
613
+ format: 'wav' | 'mp3';
614
+ }
615
+ }
616
+ export interface ChatCompletionContentPartRefusal {
617
+ /**
618
+ * The refusal message generated by the model.
619
+ */
620
+ refusal: string;
621
+ /**
622
+ * The type of the content part.
623
+ */
624
+ type: 'refusal';
625
+ }
626
+ /**
627
+ * Learn about
628
+ * [text inputs](https://platform.openai.com/docs/guides/text-generation).
629
+ */
630
+ export interface ChatCompletionContentPartText {
631
+ /**
632
+ * The text content.
633
+ */
634
+ text: string;
635
+ /**
636
+ * The type of the content part.
637
+ */
638
+ type: 'text';
639
+ }
640
+ /**
641
+ * A custom tool that processes input using a specified format.
642
+ */
643
+ export interface ChatCompletionCustomTool {
644
+ /**
645
+ * Properties of the custom tool.
646
+ */
647
+ custom: ChatCompletionCustomTool.Custom;
648
+ /**
649
+ * The type of the custom tool. Always `custom`.
650
+ */
651
+ type: 'custom';
652
+ }
653
+ export declare namespace ChatCompletionCustomTool {
654
+ /**
655
+ * Properties of the custom tool.
656
+ */
657
+ interface Custom {
658
+ /**
659
+ * The name of the custom tool, used to identify it in tool calls.
660
+ */
661
+ name: string;
662
+ /**
663
+ * Optional description of the custom tool, used to provide more context.
664
+ */
665
+ description?: string;
666
+ /**
667
+ * The input format for the custom tool. Default is unconstrained text.
668
+ */
669
+ format?: Custom.Text | Custom.Grammar;
670
+ }
671
+ namespace Custom {
672
+ /**
673
+ * Unconstrained free-form text.
674
+ */
675
+ interface Text {
676
+ /**
677
+ * Unconstrained text format. Always `text`.
678
+ */
679
+ type: 'text';
680
+ }
681
+ /**
682
+ * A grammar defined by the user.
683
+ */
684
+ interface Grammar {
685
+ /**
686
+ * Your chosen grammar.
687
+ */
688
+ grammar: Grammar.Grammar;
689
+ /**
690
+ * Grammar format. Always `grammar`.
691
+ */
692
+ type: 'grammar';
693
+ }
694
+ namespace Grammar {
695
+ /**
696
+ * Your chosen grammar.
697
+ */
698
+ interface Grammar {
699
+ /**
700
+ * The grammar definition.
701
+ */
702
+ definition: string;
703
+ /**
704
+ * The syntax of the grammar definition. One of `lark` or `regex`.
705
+ */
706
+ syntax: 'lark' | 'regex';
707
+ }
708
+ }
709
+ }
710
+ }
711
+ export interface ChatCompletionDeleted {
712
+ /**
713
+ * The ID of the chat completion that was deleted.
714
+ */
715
+ id: string;
716
+ /**
717
+ * Whether the chat completion was deleted.
718
+ */
719
+ deleted: boolean;
720
+ /**
721
+ * The type of object being deleted.
722
+ */
723
+ object: 'chat.completion.deleted';
724
+ }
725
+ /**
726
+ * Developer-provided instructions that the model should follow, regardless of
727
+ * messages sent by the user. With o1 models and newer, `developer` messages
728
+ * replace the previous `system` messages.
729
+ */
730
+ export interface ChatCompletionDeveloperMessageParam {
731
+ /**
732
+ * The contents of the developer message.
733
+ */
734
+ content: string | Array<ChatCompletionContentPartText>;
735
+ /**
736
+ * The role of the messages author, in this case `developer`.
737
+ */
738
+ role: 'developer';
739
+ /**
740
+ * An optional name for the participant. Provides the model information to
741
+ * differentiate between participants of the same role.
742
+ */
743
+ name?: string;
744
+ }
745
+ /**
746
+ * Specifying a particular function via `{"name": "my_function"}` forces the model
747
+ * to call that function.
748
+ */
749
+ export interface ChatCompletionFunctionCallOption {
750
+ /**
751
+ * The name of the function to call.
752
+ */
753
+ name: string;
754
+ }
755
+ /**
756
+ * @deprecated
757
+ */
758
+ export interface ChatCompletionFunctionMessageParam {
759
+ /**
760
+ * The contents of the function message.
761
+ */
762
+ content: string | null;
763
+ /**
764
+ * The name of the function to call.
765
+ */
766
+ name: string;
767
+ /**
768
+ * The role of the messages author, in this case `function`.
769
+ */
770
+ role: 'function';
771
+ }
772
+ /**
773
+ * A function tool that can be used to generate a response.
774
+ */
775
+ export interface ChatCompletionFunctionTool {
776
+ function: Shared.FunctionDefinition;
777
+ /**
778
+ * The type of the tool. Currently, only `function` is supported.
779
+ */
780
+ type: 'function';
781
+ }
782
+ /**
783
+ * A chat completion message generated by the model.
784
+ */
785
+ export interface ChatCompletionMessage {
786
+ /**
787
+ * The contents of the message.
788
+ */
789
+ content: string | null;
790
+ /**
791
+ * The refusal message generated by the model.
792
+ */
793
+ refusal: string | null;
794
+ /**
795
+ * The role of the author of this message.
796
+ */
797
+ role: 'assistant';
798
+ /**
799
+ * Annotations for the message, when applicable, as when using the
800
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
801
+ */
802
+ annotations?: Array<ChatCompletionMessage.Annotation>;
803
+ /**
804
+ * If the audio output modality is requested, this object contains data about the
805
+ * audio response from the model.
806
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
807
+ */
808
+ audio?: ChatCompletionAudio | null;
809
+ /**
810
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
811
+ * function that should be called, as generated by the model.
812
+ */
813
+ function_call?: ChatCompletionMessage.FunctionCall | null;
814
+ /**
815
+ * The tool calls generated by the model, such as function calls.
816
+ */
817
+ tool_calls?: Array<ChatCompletionMessageToolCall>;
818
+ }
819
+ export declare namespace ChatCompletionMessage {
820
+ /**
821
+ * A URL citation when using web search.
822
+ */
823
+ interface Annotation {
824
+ /**
825
+ * The type of the URL citation. Always `url_citation`.
826
+ */
827
+ type: 'url_citation';
828
+ /**
829
+ * A URL citation when using web search.
830
+ */
831
+ url_citation: Annotation.URLCitation;
832
+ }
833
+ namespace Annotation {
834
+ /**
835
+ * A URL citation when using web search.
836
+ */
837
+ interface URLCitation {
838
+ /**
839
+ * The index of the last character of the URL citation in the message.
840
+ */
841
+ end_index: number;
842
+ /**
843
+ * The index of the first character of the URL citation in the message.
844
+ */
845
+ start_index: number;
846
+ /**
847
+ * The title of the web resource.
848
+ */
849
+ title: string;
850
+ /**
851
+ * The URL of the web resource.
852
+ */
853
+ url: string;
854
+ }
855
+ }
856
+ /**
857
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
858
+ * function that should be called, as generated by the model.
859
+ */
860
+ interface FunctionCall {
861
+ /**
862
+ * The arguments to call the function with, as generated by the model in JSON
863
+ * format. Note that the model does not always generate valid JSON, and may
864
+ * hallucinate parameters not defined by your function schema. Validate the
865
+ * arguments in your code before calling your function.
866
+ */
867
+ arguments: string;
868
+ /**
869
+ * The name of the function to call.
870
+ */
871
+ name: string;
872
+ }
873
+ }
874
+ /**
875
+ * A call to a custom tool created by the model.
876
+ */
877
+ export interface ChatCompletionMessageCustomToolCall {
878
+ /**
879
+ * The ID of the tool call.
880
+ */
881
+ id: string;
882
+ /**
883
+ * The custom tool that the model called.
884
+ */
885
+ custom: ChatCompletionMessageCustomToolCall.Custom;
886
+ /**
887
+ * The type of the tool. Always `custom`.
888
+ */
889
+ type: 'custom';
890
+ }
891
+ export declare namespace ChatCompletionMessageCustomToolCall {
892
+ /**
893
+ * The custom tool that the model called.
894
+ */
895
+ interface Custom {
896
+ /**
897
+ * The input for the custom tool call generated by the model.
898
+ */
899
+ input: string;
900
+ /**
901
+ * The name of the custom tool to call.
902
+ */
903
+ name: string;
904
+ }
905
+ }
906
+ /**
907
+ * A call to a function tool created by the model.
908
+ */
909
+ export interface ChatCompletionMessageFunctionToolCall {
910
+ /**
911
+ * The ID of the tool call.
912
+ */
913
+ id: string;
914
+ /**
915
+ * The function that the model called.
916
+ */
917
+ function: ChatCompletionMessageFunctionToolCall.Function;
918
+ /**
919
+ * The type of the tool. Currently, only `function` is supported.
920
+ */
921
+ type: 'function';
922
+ }
923
+ export declare namespace ChatCompletionMessageFunctionToolCall {
924
+ /**
925
+ * The function that the model called.
926
+ */
927
+ interface Function {
928
+ /**
929
+ * The arguments to call the function with, as generated by the model in JSON
930
+ * format. Note that the model does not always generate valid JSON, and may
931
+ * hallucinate parameters not defined by your function schema. Validate the
932
+ * arguments in your code before calling your function.
933
+ */
934
+ arguments: string;
935
+ /**
936
+ * The name of the function to call.
937
+ */
938
+ name: string;
939
+ }
940
+ }
941
+ /**
942
+ * Developer-provided instructions that the model should follow, regardless of
943
+ * messages sent by the user. With o1 models and newer, `developer` messages
944
+ * replace the previous `system` messages.
945
+ */
946
+ export type ChatCompletionMessageParam = ChatCompletionDeveloperMessageParam | ChatCompletionSystemMessageParam | ChatCompletionUserMessageParam | ChatCompletionAssistantMessageParam | ChatCompletionToolMessageParam | ChatCompletionFunctionMessageParam;
947
+ /**
948
+ * A call to a function tool created by the model.
949
+ */
950
+ export type ChatCompletionMessageToolCall = ChatCompletionMessageFunctionToolCall | ChatCompletionMessageCustomToolCall;
951
+ export type ChatCompletionModality = 'text' | 'audio';
952
+ /**
953
+ * Specifies a tool the model should use. Use to force the model to call a specific
954
+ * function.
955
+ */
956
+ export interface ChatCompletionNamedToolChoice {
957
+ function: ChatCompletionNamedToolChoice.Function;
958
+ /**
959
+ * For function calling, the type is always `function`.
960
+ */
961
+ type: 'function';
962
+ }
963
+ export declare namespace ChatCompletionNamedToolChoice {
964
+ interface Function {
965
+ /**
966
+ * The name of the function to call.
967
+ */
968
+ name: string;
969
+ }
970
+ }
971
+ /**
972
+ * Specifies a tool the model should use. Use to force the model to call a specific
973
+ * custom tool.
974
+ */
975
+ export interface ChatCompletionNamedToolChoiceCustom {
976
+ custom: ChatCompletionNamedToolChoiceCustom.Custom;
977
+ /**
978
+ * For custom tool calling, the type is always `custom`.
979
+ */
980
+ type: 'custom';
981
+ }
982
+ export declare namespace ChatCompletionNamedToolChoiceCustom {
983
+ interface Custom {
984
+ /**
985
+ * The name of the custom tool to call.
986
+ */
987
+ name: string;
988
+ }
989
+ }
990
+ /**
991
+ * Static predicted output content, such as the content of a text file that is
992
+ * being regenerated.
993
+ */
994
+ export interface ChatCompletionPredictionContent {
995
+ /**
996
+ * The content that should be matched when generating a model response. If
997
+ * generated tokens would match this content, the entire model response can be
998
+ * returned much more quickly.
999
+ */
1000
+ content: string | Array<ChatCompletionContentPartText>;
1001
+ /**
1002
+ * The type of the predicted content you want to provide. This type is currently
1003
+ * always `content`.
1004
+ */
1005
+ type: 'content';
1006
+ }
1007
+ /**
1008
+ * The role of the author of a message
1009
+ */
1010
+ export type ChatCompletionRole = 'developer' | 'system' | 'user' | 'assistant' | 'tool' | 'function';
1011
+ /**
1012
+ * A chat completion message generated by the model.
1013
+ */
1014
+ export interface ChatCompletionStoreMessage extends ChatCompletionMessage {
1015
+ /**
1016
+ * The identifier of the chat message.
1017
+ */
1018
+ id: string;
1019
+ /**
1020
+ * If a content parts array was provided, this is an array of `text` and
1021
+ * `image_url` parts. Otherwise, null.
1022
+ */
1023
+ content_parts?: Array<ChatCompletionContentPartText | ChatCompletionContentPartImage> | null;
1024
+ }
1025
+ /**
1026
+ * Options for streaming response. Only set this when you set `stream: true`.
1027
+ */
1028
+ export interface ChatCompletionStreamOptions {
1029
+ /**
1030
+ * When true, stream obfuscation will be enabled. Stream obfuscation adds random
1031
+ * characters to an `obfuscation` field on streaming delta events to normalize
1032
+ * payload sizes as a mitigation to certain side-channel attacks. These obfuscation
1033
+ * fields are included by default, but add a small amount of overhead to the data
1034
+ * stream. You can set `include_obfuscation` to false to optimize for bandwidth if
1035
+ * you trust the network links between your application and the OpenAI API.
1036
+ */
1037
+ include_obfuscation?: boolean;
1038
+ /**
1039
+ * If set, an additional chunk will be streamed before the `data: [DONE]` message.
1040
+ * The `usage` field on this chunk shows the token usage statistics for the entire
1041
+ * request, and the `choices` field will always be an empty array.
1042
+ *
1043
+ * All other chunks will also include a `usage` field, but with a null value.
1044
+ * **NOTE:** If the stream is interrupted, you may not receive the final usage
1045
+ * chunk which contains the total token usage for the request.
1046
+ */
1047
+ include_usage?: boolean;
1048
+ }
1049
+ /**
1050
+ * Developer-provided instructions that the model should follow, regardless of
1051
+ * messages sent by the user. With o1 models and newer, use `developer` messages
1052
+ * for this purpose instead.
1053
+ */
1054
+ export interface ChatCompletionSystemMessageParam {
1055
+ /**
1056
+ * The contents of the system message.
1057
+ */
1058
+ content: string | Array<ChatCompletionContentPartText>;
1059
+ /**
1060
+ * The role of the messages author, in this case `system`.
1061
+ */
1062
+ role: 'system';
1063
+ /**
1064
+ * An optional name for the participant. Provides the model information to
1065
+ * differentiate between participants of the same role.
1066
+ */
1067
+ name?: string;
1068
+ }
1069
+ export interface ChatCompletionTokenLogprob {
1070
+ /**
1071
+ * The token.
1072
+ */
1073
+ token: string;
1074
+ /**
1075
+ * A list of integers representing the UTF-8 bytes representation of the token.
1076
+ * Useful in instances where characters are represented by multiple tokens and
1077
+ * their byte representations must be combined to generate the correct text
1078
+ * representation. Can be `null` if there is no bytes representation for the token.
1079
+ */
1080
+ bytes: Array<number> | null;
1081
+ /**
1082
+ * The log probability of this token, if it is within the top 20 most likely
1083
+ * tokens. Otherwise, the value `-9999.0` is used to signify that the token is very
1084
+ * unlikely.
1085
+ */
1086
+ logprob: number;
1087
+ /**
1088
+ * List of the most likely tokens and their log probability, at this token
1089
+ * position. In rare cases, there may be fewer than the number of requested
1090
+ * `top_logprobs` returned.
1091
+ */
1092
+ top_logprobs: Array<ChatCompletionTokenLogprob.TopLogprob>;
1093
+ }
1094
+ export declare namespace ChatCompletionTokenLogprob {
1095
+ interface TopLogprob {
1096
+ /**
1097
+ * The token.
1098
+ */
1099
+ token: string;
1100
+ /**
1101
+ * A list of integers representing the UTF-8 bytes representation of the token.
1102
+ * Useful in instances where characters are represented by multiple tokens and
1103
+ * their byte representations must be combined to generate the correct text
1104
+ * representation. Can be `null` if there is no bytes representation for the token.
1105
+ */
1106
+ bytes: Array<number> | null;
1107
+ /**
1108
+ * The log probability of this token, if it is within the top 20 most likely
1109
+ * tokens. Otherwise, the value `-9999.0` is used to signify that the token is very
1110
+ * unlikely.
1111
+ */
1112
+ logprob: number;
1113
+ }
1114
+ }
1115
+ /**
1116
+ * A function tool that can be used to generate a response.
1117
+ */
1118
+ export type ChatCompletionTool = ChatCompletionFunctionTool | ChatCompletionCustomTool;
1119
+ /**
1120
+ * Controls which (if any) tool is called by the model. `none` means the model will
1121
+ * not call any tool and instead generates a message. `auto` means the model can
1122
+ * pick between generating a message or calling one or more tools. `required` means
1123
+ * the model must call one or more tools. Specifying a particular tool via
1124
+ * `{"type": "function", "function": {"name": "my_function"}}` forces the model to
1125
+ * call that tool.
1126
+ *
1127
+ * `none` is the default when no tools are present. `auto` is the default if tools
1128
+ * are present.
1129
+ */
1130
+ export type ChatCompletionToolChoiceOption = 'none' | 'auto' | 'required' | ChatCompletionAllowedToolChoice | ChatCompletionNamedToolChoice | ChatCompletionNamedToolChoiceCustom;
1131
+ export interface ChatCompletionToolMessageParam {
1132
+ /**
1133
+ * The contents of the tool message.
1134
+ */
1135
+ content: string | Array<ChatCompletionContentPartText>;
1136
+ /**
1137
+ * The role of the messages author, in this case `tool`.
1138
+ */
1139
+ role: 'tool';
1140
+ /**
1141
+ * Tool call that this message is responding to.
1142
+ */
1143
+ tool_call_id: string;
1144
+ }
1145
+ /**
1146
+ * Messages sent by an end user, containing prompts or additional context
1147
+ * information.
1148
+ */
1149
+ export interface ChatCompletionUserMessageParam {
1150
+ /**
1151
+ * The contents of the user message.
1152
+ */
1153
+ content: string | Array<ChatCompletionContentPart>;
1154
+ /**
1155
+ * The role of the messages author, in this case `user`.
1156
+ */
1157
+ role: 'user';
1158
+ /**
1159
+ * An optional name for the participant. Provides the model information to
1160
+ * differentiate between participants of the same role.
1161
+ */
1162
+ name?: string;
1163
+ }
1164
+ /**
1165
+ * Constrains the tools available to the model to a pre-defined set.
1166
+ */
1167
+ export interface ChatCompletionAllowedTools {
1168
+ /**
1169
+ * Constrains the tools available to the model to a pre-defined set.
1170
+ *
1171
+ * `auto` allows the model to pick from among the allowed tools and generate a
1172
+ * message.
1173
+ *
1174
+ * `required` requires the model to call one or more of the allowed tools.
1175
+ */
1176
+ mode: 'auto' | 'required';
1177
+ /**
1178
+ * A list of tool definitions that the model should be allowed to call.
1179
+ *
1180
+ * For the Chat Completions API, the list of tool definitions might look like:
1181
+ *
1182
+ * ```json
1183
+ * [
1184
+ * { "type": "function", "function": { "name": "get_weather" } },
1185
+ * { "type": "function", "function": { "name": "get_time" } }
1186
+ * ]
1187
+ * ```
1188
+ */
1189
+ tools: Array<{
1190
+ [key: string]: unknown;
1191
+ }>;
1192
+ }
1193
+ export type ChatCompletionReasoningEffort = Shared.ReasoningEffort | null;
1194
+ export type ChatCompletionCreateParams = ChatCompletionCreateParamsNonStreaming | ChatCompletionCreateParamsStreaming;
1195
+ export interface ChatCompletionCreateParamsBase {
1196
+ /**
1197
+ * A list of messages comprising the conversation so far. Depending on the
1198
+ * [model](https://platform.openai.com/docs/models) you use, different message
1199
+ * types (modalities) are supported, like
1200
+ * [text](https://platform.openai.com/docs/guides/text-generation),
1201
+ * [images](https://platform.openai.com/docs/guides/vision), and
1202
+ * [audio](https://platform.openai.com/docs/guides/audio).
1203
+ */
1204
+ messages: Array<ChatCompletionMessageParam>;
1205
+ /**
1206
+ * Model ID used to generate the response, like `gpt-4o` or `o3`. OpenAI offers a
1207
+ * wide range of models with different capabilities, performance characteristics,
1208
+ * and price points. Refer to the
1209
+ * [model guide](https://platform.openai.com/docs/models) to browse and compare
1210
+ * available models.
1211
+ */
1212
+ model: (string & {}) | Shared.ChatModel;
1213
+ /**
1214
+ * Parameters for audio output. Required when audio output is requested with
1215
+ * `modalities: ["audio"]`.
1216
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
1217
+ */
1218
+ audio?: ChatCompletionAudioParam | null;
1219
+ /**
1220
+ * Number between -2.0 and 2.0. Positive values penalize new tokens based on their
1221
+ * existing frequency in the text so far, decreasing the model's likelihood to
1222
+ * repeat the same line verbatim.
1223
+ */
1224
+ frequency_penalty?: number | null;
1225
+ /**
1226
+ * @deprecated Deprecated in favor of `tool_choice`.
1227
+ *
1228
+ * Controls which (if any) function is called by the model.
1229
+ *
1230
+ * `none` means the model will not call a function and instead generates a message.
1231
+ *
1232
+ * `auto` means the model can pick between generating a message or calling a
1233
+ * function.
1234
+ *
1235
+ * Specifying a particular function via `{"name": "my_function"}` forces the model
1236
+ * to call that function.
1237
+ *
1238
+ * `none` is the default when no functions are present. `auto` is the default if
1239
+ * functions are present.
1240
+ */
1241
+ function_call?: 'none' | 'auto' | ChatCompletionFunctionCallOption;
1242
+ /**
1243
+ * @deprecated Deprecated in favor of `tools`.
1244
+ *
1245
+ * A list of functions the model may generate JSON inputs for.
1246
+ */
1247
+ functions?: Array<ChatCompletionCreateParams.Function>;
1248
+ /**
1249
+ * Modify the likelihood of specified tokens appearing in the completion.
1250
+ *
1251
+ * Accepts a JSON object that maps tokens (specified by their token ID in the
1252
+ * tokenizer) to an associated bias value from -100 to 100. Mathematically, the
1253
+ * bias is added to the logits generated by the model prior to sampling. The exact
1254
+ * effect will vary per model, but values between -1 and 1 should decrease or
1255
+ * increase likelihood of selection; values like -100 or 100 should result in a ban
1256
+ * or exclusive selection of the relevant token.
1257
+ */
1258
+ logit_bias?: {
1259
+ [key: string]: number;
1260
+ } | null;
1261
+ /**
1262
+ * Whether to return log probabilities of the output tokens or not. If true,
1263
+ * returns the log probabilities of each output token returned in the `content` of
1264
+ * `message`.
1265
+ */
1266
+ logprobs?: boolean | null;
1267
+ /**
1268
+ * An upper bound for the number of tokens that can be generated for a completion,
1269
+ * including visible output tokens and
1270
+ * [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
1271
+ */
1272
+ max_completion_tokens?: number | null;
1273
+ /**
1274
+ * @deprecated The maximum number of [tokens](/tokenizer) that can be generated in
1275
+ * the chat completion. This value can be used to control
1276
+ * [costs](https://openai.com/api/pricing/) for text generated via API.
1277
+ *
1278
+ * This value is now deprecated in favor of `max_completion_tokens`, and is not
1279
+ * compatible with
1280
+ * [o-series models](https://platform.openai.com/docs/guides/reasoning).
1281
+ */
1282
+ max_tokens?: number | null;
1283
+ /**
1284
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1285
+ * for storing additional information about the object in a structured format, and
1286
+ * querying for objects via API or the dashboard.
1287
+ *
1288
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1289
+ * a maximum length of 512 characters.
1290
+ */
1291
+ metadata?: Shared.Metadata | null;
1292
+ /**
1293
+ * Output types that you would like the model to generate. Most models are capable
1294
+ * of generating text, which is the default:
1295
+ *
1296
+ * `["text"]`
1297
+ *
1298
+ * The `gpt-4o-audio-preview` model can also be used to
1299
+ * [generate audio](https://platform.openai.com/docs/guides/audio). To request that
1300
+ * this model generate both text and audio responses, you can use:
1301
+ *
1302
+ * `["text", "audio"]`
1303
+ */
1304
+ modalities?: Array<'text' | 'audio'> | null;
1305
+ /**
1306
+ * How many chat completion choices to generate for each input message. Note that
1307
+ * you will be charged based on the number of generated tokens across all of the
1308
+ * choices. Keep `n` as `1` to minimize costs.
1309
+ */
1310
+ n?: number | null;
1311
+ /**
1312
+ * Whether to enable
1313
+ * [parallel function calling](https://platform.openai.com/docs/guides/function-calling#configuring-parallel-function-calling)
1314
+ * during tool use.
1315
+ */
1316
+ parallel_tool_calls?: boolean;
1317
+ /**
1318
+ * Static predicted output content, such as the content of a text file that is
1319
+ * being regenerated.
1320
+ */
1321
+ prediction?: ChatCompletionPredictionContent | null;
1322
+ /**
1323
+ * Number between -2.0 and 2.0. Positive values penalize new tokens based on
1324
+ * whether they appear in the text so far, increasing the model's likelihood to
1325
+ * talk about new topics.
1326
+ */
1327
+ presence_penalty?: number | null;
1328
+ /**
1329
+ * Used by OpenAI to cache responses for similar requests to optimize your cache
1330
+ * hit rates. Replaces the `user` field.
1331
+ * [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
1332
+ */
1333
+ prompt_cache_key?: string;
1334
+ /**
1335
+ * Constrains effort on reasoning for
1336
+ * [reasoning models](https://platform.openai.com/docs/guides/reasoning). Currently
1337
+ * supported values are `minimal`, `low`, `medium`, and `high`. Reducing reasoning
1338
+ * effort can result in faster responses and fewer tokens used on reasoning in a
1339
+ * response.
1340
+ */
1341
+ reasoning_effort?: Shared.ReasoningEffort | null;
1342
+ /**
1343
+ * An object specifying the format that the model must output.
1344
+ *
1345
+ * Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured
1346
+ * Outputs which ensures the model will match your supplied JSON schema. Learn more
1347
+ * in the
1348
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
1349
+ *
1350
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
1351
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
1352
+ * preferred for models that support it.
1353
+ */
1354
+ response_format?: Shared.ResponseFormatText | Shared.ResponseFormatJSONSchema | Shared.ResponseFormatJSONObject;
1355
+ /**
1356
+ * A stable identifier used to help detect users of your application that may be
1357
+ * violating OpenAI's usage policies. The IDs should be a string that uniquely
1358
+ * identifies each user. We recommend hashing their username or email address, in
1359
+ * order to avoid sending us any identifying information.
1360
+ * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
1361
+ */
1362
+ safety_identifier?: string;
1363
+ /**
1364
+ * @deprecated This feature is in Beta. If specified, our system will make a best
1365
+ * effort to sample deterministically, such that repeated requests with the same
1366
+ * `seed` and parameters should return the same result. Determinism is not
1367
+ * guaranteed, and you should refer to the `system_fingerprint` response parameter
1368
+ * to monitor changes in the backend.
1369
+ */
1370
+ seed?: number | null;
1371
+ /**
1372
+ * Specifies the processing type used for serving the request.
1373
+ *
1374
+ * - If set to 'auto', then the request will be processed with the service tier
1375
+ * configured in the Project settings. Unless otherwise configured, the Project
1376
+ * will use 'default'.
1377
+ * - If set to 'default', then the request will be processed with the standard
1378
+ * pricing and performance for the selected model.
1379
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
1380
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
1381
+ * will be processed with the corresponding service tier.
1382
+ * - When not set, the default behavior is 'auto'.
1383
+ *
1384
+ * When the `service_tier` parameter is set, the response body will include the
1385
+ * `service_tier` value based on the processing mode actually used to serve the
1386
+ * request. This response value may be different from the value set in the
1387
+ * parameter.
1388
+ */
1389
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
1390
+ /**
1391
+ * Not supported with latest reasoning models `o3` and `o4-mini`.
1392
+ *
1393
+ * Up to 4 sequences where the API will stop generating further tokens. The
1394
+ * returned text will not contain the stop sequence.
1395
+ */
1396
+ stop?: string | null | Array<string>;
1397
+ /**
1398
+ * Whether or not to store the output of this chat completion request for use in
1399
+ * our [model distillation](https://platform.openai.com/docs/guides/distillation)
1400
+ * or [evals](https://platform.openai.com/docs/guides/evals) products.
1401
+ *
1402
+ * Supports text and image inputs. Note: image inputs over 8MB will be dropped.
1403
+ */
1404
+ store?: boolean | null;
1405
+ /**
1406
+ * If set to true, the model response data will be streamed to the client as it is
1407
+ * generated using
1408
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1409
+ * See the
1410
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1411
+ * for more information, along with the
1412
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1413
+ * guide for more information on how to handle the streaming events.
1414
+ */
1415
+ stream?: boolean | null;
1416
+ /**
1417
+ * Options for streaming response. Only set this when you set `stream: true`.
1418
+ */
1419
+ stream_options?: ChatCompletionStreamOptions | null;
1420
+ /**
1421
+ * What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
1422
+ * make the output more random, while lower values like 0.2 will make it more
1423
+ * focused and deterministic. We generally recommend altering this or `top_p` but
1424
+ * not both.
1425
+ */
1426
+ temperature?: number | null;
1427
+ /**
1428
+ * Controls which (if any) tool is called by the model. `none` means the model will
1429
+ * not call any tool and instead generates a message. `auto` means the model can
1430
+ * pick between generating a message or calling one or more tools. `required` means
1431
+ * the model must call one or more tools. Specifying a particular tool via
1432
+ * `{"type": "function", "function": {"name": "my_function"}}` forces the model to
1433
+ * call that tool.
1434
+ *
1435
+ * `none` is the default when no tools are present. `auto` is the default if tools
1436
+ * are present.
1437
+ */
1438
+ tool_choice?: ChatCompletionToolChoiceOption;
1439
+ /**
1440
+ * A list of tools the model may call. You can provide either
1441
+ * [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools)
1442
+ * or [function tools](https://platform.openai.com/docs/guides/function-calling).
1443
+ */
1444
+ tools?: Array<ChatCompletionTool>;
1445
+ /**
1446
+ * An integer between 0 and 20 specifying the number of most likely tokens to
1447
+ * return at each token position, each with an associated log probability.
1448
+ * `logprobs` must be set to `true` if this parameter is used.
1449
+ */
1450
+ top_logprobs?: number | null;
1451
+ /**
1452
+ * An alternative to sampling with temperature, called nucleus sampling, where the
1453
+ * model considers the results of the tokens with top_p probability mass. So 0.1
1454
+ * means only the tokens comprising the top 10% probability mass are considered.
1455
+ *
1456
+ * We generally recommend altering this or `temperature` but not both.
1457
+ */
1458
+ top_p?: number | null;
1459
+ /**
1460
+ * @deprecated This field is being replaced by `safety_identifier` and
1461
+ * `prompt_cache_key`. Use `prompt_cache_key` instead to maintain caching
1462
+ * optimizations. A stable identifier for your end-users. Used to boost cache hit
1463
+ * rates by better bucketing similar requests and to help OpenAI detect and prevent
1464
+ * abuse.
1465
+ * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
1466
+ */
1467
+ user?: string;
1468
+ /**
1469
+ * Constrains the verbosity of the model's response. Lower values will result in
1470
+ * more concise responses, while higher values will result in more verbose
1471
+ * responses. Currently supported values are `low`, `medium`, and `high`.
1472
+ */
1473
+ verbosity?: 'low' | 'medium' | 'high' | null;
1474
+ /**
1475
+ * This tool searches the web for relevant results to use in a response. Learn more
1476
+ * about the
1477
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
1478
+ */
1479
+ web_search_options?: ChatCompletionCreateParams.WebSearchOptions;
1480
+ }
1481
+ export declare namespace ChatCompletionCreateParams {
1482
+ /**
1483
+ * @deprecated
1484
+ */
1485
+ interface Function {
1486
+ /**
1487
+ * The name of the function to be called. Must be a-z, A-Z, 0-9, or contain
1488
+ * underscores and dashes, with a maximum length of 64.
1489
+ */
1490
+ name: string;
1491
+ /**
1492
+ * A description of what the function does, used by the model to choose when and
1493
+ * how to call the function.
1494
+ */
1495
+ description?: string;
1496
+ /**
1497
+ * The parameters the functions accepts, described as a JSON Schema object. See the
1498
+ * [guide](https://platform.openai.com/docs/guides/function-calling) for examples,
1499
+ * and the
1500
+ * [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for
1501
+ * documentation about the format.
1502
+ *
1503
+ * Omitting `parameters` defines a function with an empty parameter list.
1504
+ */
1505
+ parameters?: Shared.FunctionParameters;
1506
+ }
1507
+ /**
1508
+ * This tool searches the web for relevant results to use in a response. Learn more
1509
+ * about the
1510
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
1511
+ */
1512
+ interface WebSearchOptions {
1513
+ /**
1514
+ * High level guidance for the amount of context window space to use for the
1515
+ * search. One of `low`, `medium`, or `high`. `medium` is the default.
1516
+ */
1517
+ search_context_size?: 'low' | 'medium' | 'high';
1518
+ /**
1519
+ * Approximate location parameters for the search.
1520
+ */
1521
+ user_location?: WebSearchOptions.UserLocation | null;
1522
+ }
1523
+ namespace WebSearchOptions {
1524
+ /**
1525
+ * Approximate location parameters for the search.
1526
+ */
1527
+ interface UserLocation {
1528
+ /**
1529
+ * Approximate location parameters for the search.
1530
+ */
1531
+ approximate: UserLocation.Approximate;
1532
+ /**
1533
+ * The type of location approximation. Always `approximate`.
1534
+ */
1535
+ type: 'approximate';
1536
+ }
1537
+ namespace UserLocation {
1538
+ /**
1539
+ * Approximate location parameters for the search.
1540
+ */
1541
+ interface Approximate {
1542
+ /**
1543
+ * Free text input for the city of the user, e.g. `San Francisco`.
1544
+ */
1545
+ city?: string;
1546
+ /**
1547
+ * The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of
1548
+ * the user, e.g. `US`.
1549
+ */
1550
+ country?: string;
1551
+ /**
1552
+ * Free text input for the region of the user, e.g. `California`.
1553
+ */
1554
+ region?: string;
1555
+ /**
1556
+ * The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the
1557
+ * user, e.g. `America/Los_Angeles`.
1558
+ */
1559
+ timezone?: string;
1560
+ }
1561
+ }
1562
+ }
1563
+ type ChatCompletionCreateParamsNonStreaming = CompletionsCompletionsAPI.ChatCompletionCreateParamsNonStreaming;
1564
+ type ChatCompletionCreateParamsStreaming = CompletionsCompletionsAPI.ChatCompletionCreateParamsStreaming;
1565
+ }
1566
+ export interface ChatCompletionCreateParamsNonStreaming extends ChatCompletionCreateParamsBase {
1567
+ /**
1568
+ * If set to true, the model response data will be streamed to the client as it is
1569
+ * generated using
1570
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1571
+ * See the
1572
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1573
+ * for more information, along with the
1574
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1575
+ * guide for more information on how to handle the streaming events.
1576
+ */
1577
+ stream?: false | null;
1578
+ }
1579
+ export interface ChatCompletionCreateParamsStreaming extends ChatCompletionCreateParamsBase {
1580
+ /**
1581
+ * If set to true, the model response data will be streamed to the client as it is
1582
+ * generated using
1583
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1584
+ * See the
1585
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1586
+ * for more information, along with the
1587
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1588
+ * guide for more information on how to handle the streaming events.
1589
+ */
1590
+ stream: true;
1591
+ }
1592
+ export interface ChatCompletionUpdateParams {
1593
+ /**
1594
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1595
+ * for storing additional information about the object in a structured format, and
1596
+ * querying for objects via API or the dashboard.
1597
+ *
1598
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1599
+ * a maximum length of 512 characters.
1600
+ */
1601
+ metadata: Shared.Metadata | null;
1602
+ }
1603
+ export interface ChatCompletionListParams extends CursorPageParams {
1604
+ /**
1605
+ * A list of metadata keys to filter the Chat Completions by. Example:
1606
+ *
1607
+ * `metadata[key1]=value1&metadata[key2]=value2`
1608
+ */
1609
+ metadata?: Shared.Metadata | null;
1610
+ /**
1611
+ * The model used to generate the Chat Completions.
1612
+ */
1613
+ model?: string;
1614
+ /**
1615
+ * Sort order for Chat Completions by timestamp. Use `asc` for ascending order or
1616
+ * `desc` for descending order. Defaults to `asc`.
1617
+ */
1618
+ order?: 'asc' | 'desc';
1619
+ }
1620
+ export declare namespace Completions {
1621
+ export { type ChatCompletion as ChatCompletion, type ChatCompletionAllowedToolChoice as ChatCompletionAllowedToolChoice, type ChatCompletionAssistantMessageParam as ChatCompletionAssistantMessageParam, type ChatCompletionAudio as ChatCompletionAudio, type ChatCompletionAudioParam as ChatCompletionAudioParam, type ChatCompletionChunk as ChatCompletionChunk, type ChatCompletionContentPart as ChatCompletionContentPart, type ChatCompletionContentPartImage as ChatCompletionContentPartImage, type ChatCompletionContentPartInputAudio as ChatCompletionContentPartInputAudio, type ChatCompletionContentPartRefusal as ChatCompletionContentPartRefusal, type ChatCompletionContentPartText as ChatCompletionContentPartText, type ChatCompletionCustomTool as ChatCompletionCustomTool, type ChatCompletionDeleted as ChatCompletionDeleted, type ChatCompletionDeveloperMessageParam as ChatCompletionDeveloperMessageParam, type ChatCompletionFunctionCallOption as ChatCompletionFunctionCallOption, type ChatCompletionFunctionMessageParam as ChatCompletionFunctionMessageParam, type ChatCompletionFunctionTool as ChatCompletionFunctionTool, type ChatCompletionMessage as ChatCompletionMessage, type ChatCompletionMessageCustomToolCall as ChatCompletionMessageCustomToolCall, type ChatCompletionMessageFunctionToolCall as ChatCompletionMessageFunctionToolCall, type ChatCompletionMessageParam as ChatCompletionMessageParam, type ChatCompletionMessageToolCall as ChatCompletionMessageToolCall, type ChatCompletionModality as ChatCompletionModality, type ChatCompletionNamedToolChoice as ChatCompletionNamedToolChoice, type ChatCompletionNamedToolChoiceCustom as ChatCompletionNamedToolChoiceCustom, type ChatCompletionPredictionContent as ChatCompletionPredictionContent, type ChatCompletionRole as ChatCompletionRole, type ChatCompletionStoreMessage as ChatCompletionStoreMessage, type ChatCompletionStreamOptions as ChatCompletionStreamOptions, type ChatCompletionSystemMessageParam as ChatCompletionSystemMessageParam, type ChatCompletionTokenLogprob as ChatCompletionTokenLogprob, type ChatCompletionTool as ChatCompletionTool, type ChatCompletionToolChoiceOption as ChatCompletionToolChoiceOption, type ChatCompletionToolMessageParam as ChatCompletionToolMessageParam, type ChatCompletionUserMessageParam as ChatCompletionUserMessageParam, type ChatCompletionAllowedTools as ChatCompletionAllowedTools, type ChatCompletionReasoningEffort as ChatCompletionReasoningEffort, type ChatCompletionsPage as ChatCompletionsPage, type ChatCompletionCreateParams as ChatCompletionCreateParams, type ChatCompletionCreateParamsNonStreaming as ChatCompletionCreateParamsNonStreaming, type ChatCompletionCreateParamsStreaming as ChatCompletionCreateParamsStreaming, type ChatCompletionUpdateParams as ChatCompletionUpdateParams, type ChatCompletionListParams as ChatCompletionListParams, };
1622
+ export { Messages as Messages, type MessageListParams as MessageListParams };
1623
+ }
1624
+ //# sourceMappingURL=completions.d.mts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/completions.d.ts ADDED
@@ -0,0 +1,1624 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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/resource.js";
2
+ import * as CompletionsCompletionsAPI from "./completions.js";
3
+ import * as CompletionsAPI from "../../completions.js";
4
+ import * as Shared from "../../shared.js";
5
+ import * as MessagesAPI from "./messages.js";
6
+ import { MessageListParams, Messages } from "./messages.js";
7
+ import { APIPromise } from "../../../core/api-promise.js";
8
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.js";
9
+ import { Stream } from "../../../core/streaming.js";
10
+ import { RequestOptions } from "../../../internal/request-options.js";
11
+ import { ChatCompletionRunner } from "../../../lib/ChatCompletionRunner.js";
12
+ import { ChatCompletionStreamingRunner } from "../../../lib/ChatCompletionStreamingRunner.js";
13
+ import { RunnerOptions } from "../../../lib/AbstractChatCompletionRunner.js";
14
+ import { ChatCompletionToolRunnerParams } from "../../../lib/ChatCompletionRunner.js";
15
+ import { ChatCompletionStreamingToolRunnerParams } from "../../../lib/ChatCompletionStreamingRunner.js";
16
+ import { ChatCompletionStream, type ChatCompletionStreamParams } from "../../../lib/ChatCompletionStream.js";
17
+ import { ExtractParsedContentFromParams } from "../../../lib/parser.js";
18
+ export declare class Completions extends APIResource {
19
+ messages: MessagesAPI.Messages;
20
+ /**
21
+ * **Starting a new project?** We recommend trying
22
+ * [Responses](https://platform.openai.com/docs/api-reference/responses) to take
23
+ * advantage of the latest OpenAI platform features. Compare
24
+ * [Chat Completions with Responses](https://platform.openai.com/docs/guides/responses-vs-chat-completions?api-mode=responses).
25
+ *
26
+ * ---
27
+ *
28
+ * Creates a model response for the given chat conversation. Learn more in the
29
+ * [text generation](https://platform.openai.com/docs/guides/text-generation),
30
+ * [vision](https://platform.openai.com/docs/guides/vision), and
31
+ * [audio](https://platform.openai.com/docs/guides/audio) guides.
32
+ *
33
+ * Parameter support can differ depending on the model used to generate the
34
+ * response, particularly for newer reasoning models. Parameters that are only
35
+ * supported for reasoning models are noted below. For the current state of
36
+ * unsupported parameters in reasoning models,
37
+ * [refer to the reasoning guide](https://platform.openai.com/docs/guides/reasoning).
38
+ *
39
+ * @example
40
+ * ```ts
41
+ * const chatCompletion = await client.chat.completions.create(
42
+ * {
43
+ * messages: [{ content: 'string', role: 'developer' }],
44
+ * model: 'gpt-4o',
45
+ * },
46
+ * );
47
+ * ```
48
+ */
49
+ create(body: ChatCompletionCreateParamsNonStreaming, options?: RequestOptions): APIPromise<ChatCompletion>;
50
+ create(body: ChatCompletionCreateParamsStreaming, options?: RequestOptions): APIPromise<Stream<ChatCompletionChunk>>;
51
+ create(body: ChatCompletionCreateParamsBase, options?: RequestOptions): APIPromise<Stream<ChatCompletionChunk> | ChatCompletion>;
52
+ /**
53
+ * Get a stored chat completion. Only Chat Completions that have been created with
54
+ * the `store` parameter set to `true` will be returned.
55
+ *
56
+ * @example
57
+ * ```ts
58
+ * const chatCompletion =
59
+ * await client.chat.completions.retrieve('completion_id');
60
+ * ```
61
+ */
62
+ retrieve(completionID: string, options?: RequestOptions): APIPromise<ChatCompletion>;
63
+ /**
64
+ * Modify a stored chat completion. Only Chat Completions that have been created
65
+ * with the `store` parameter set to `true` can be modified. Currently, the only
66
+ * supported modification is to update the `metadata` field.
67
+ *
68
+ * @example
69
+ * ```ts
70
+ * const chatCompletion = await client.chat.completions.update(
71
+ * 'completion_id',
72
+ * { metadata: { foo: 'string' } },
73
+ * );
74
+ * ```
75
+ */
76
+ update(completionID: string, body: ChatCompletionUpdateParams, options?: RequestOptions): APIPromise<ChatCompletion>;
77
+ /**
78
+ * List stored Chat Completions. Only Chat Completions that have been stored with
79
+ * the `store` parameter set to `true` will be returned.
80
+ *
81
+ * @example
82
+ * ```ts
83
+ * // Automatically fetches more pages as needed.
84
+ * for await (const chatCompletion of client.chat.completions.list()) {
85
+ * // ...
86
+ * }
87
+ * ```
88
+ */
89
+ list(query?: ChatCompletionListParams | null | undefined, options?: RequestOptions): PagePromise<ChatCompletionsPage, ChatCompletion>;
90
+ /**
91
+ * Delete a stored chat completion. Only Chat Completions that have been created
92
+ * with the `store` parameter set to `true` can be deleted.
93
+ *
94
+ * @example
95
+ * ```ts
96
+ * const chatCompletionDeleted =
97
+ * await client.chat.completions.delete('completion_id');
98
+ * ```
99
+ */
100
+ delete(completionID: string, options?: RequestOptions): APIPromise<ChatCompletionDeleted>;
101
+ parse<Params extends ChatCompletionParseParams, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RequestOptions): APIPromise<ParsedChatCompletion<ParsedT>>;
102
+ /**
103
+ * A convenience helper for using tool calls with the /chat/completions endpoint
104
+ * which automatically calls the JavaScript functions you provide and sends their
105
+ * results back to the /chat/completions endpoint, looping as long as the model
106
+ * requests function calls.
107
+ *
108
+ * For more details and examples, see
109
+ * [the docs](https://github.com/openai/openai-node#automated-function-calls)
110
+ */
111
+ runTools<Params extends ChatCompletionToolRunnerParams<any>, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RunnerOptions): ChatCompletionRunner<ParsedT>;
112
+ runTools<Params extends ChatCompletionStreamingToolRunnerParams<any>, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RunnerOptions): ChatCompletionStreamingRunner<ParsedT>;
113
+ /**
114
+ * Creates a chat completion stream
115
+ */
116
+ stream<Params extends ChatCompletionStreamParams, ParsedT = ExtractParsedContentFromParams<Params>>(body: Params, options?: RequestOptions): ChatCompletionStream<ParsedT>;
117
+ }
118
+ export interface ParsedFunction extends ChatCompletionMessageFunctionToolCall.Function {
119
+ parsed_arguments?: unknown;
120
+ }
121
+ export interface ParsedFunctionToolCall extends ChatCompletionMessageFunctionToolCall {
122
+ function: ParsedFunction;
123
+ }
124
+ export interface ParsedChatCompletionMessage<ParsedT> extends ChatCompletionMessage {
125
+ parsed: ParsedT | null;
126
+ tool_calls?: Array<ParsedFunctionToolCall>;
127
+ }
128
+ export interface ParsedChoice<ParsedT> extends ChatCompletion.Choice {
129
+ message: ParsedChatCompletionMessage<ParsedT>;
130
+ }
131
+ export interface ParsedChatCompletion<ParsedT> extends ChatCompletion {
132
+ choices: Array<ParsedChoice<ParsedT>>;
133
+ }
134
+ export type ChatCompletionParseParams = ChatCompletionCreateParamsNonStreaming;
135
+ export { ChatCompletionStreamingRunner } from "../../../lib/ChatCompletionStreamingRunner.js";
136
+ export { type RunnableFunctionWithParse, type RunnableFunctionWithoutParse, ParsingToolFunction, } from "../../../lib/RunnableFunction.js";
137
+ export { type ChatCompletionToolRunnerParams } from "../../../lib/ChatCompletionRunner.js";
138
+ export { type ChatCompletionStreamingToolRunnerParams } from "../../../lib/ChatCompletionStreamingRunner.js";
139
+ export { ChatCompletionStream, type ChatCompletionStreamParams } from "../../../lib/ChatCompletionStream.js";
140
+ export { ChatCompletionRunner } from "../../../lib/ChatCompletionRunner.js";
141
+ export type ChatCompletionsPage = CursorPage<ChatCompletion>;
142
+ export type ChatCompletionStoreMessagesPage = CursorPage<ChatCompletionStoreMessage>;
143
+ /**
144
+ * Represents a chat completion response returned by model, based on the provided
145
+ * input.
146
+ */
147
+ export interface ChatCompletion {
148
+ /**
149
+ * A unique identifier for the chat completion.
150
+ */
151
+ id: string;
152
+ /**
153
+ * A list of chat completion choices. Can be more than one if `n` is greater
154
+ * than 1.
155
+ */
156
+ choices: Array<ChatCompletion.Choice>;
157
+ /**
158
+ * The Unix timestamp (in seconds) of when the chat completion was created.
159
+ */
160
+ created: number;
161
+ /**
162
+ * The model used for the chat completion.
163
+ */
164
+ model: string;
165
+ /**
166
+ * The object type, which is always `chat.completion`.
167
+ */
168
+ object: 'chat.completion';
169
+ /**
170
+ * Specifies the processing type used for serving the request.
171
+ *
172
+ * - If set to 'auto', then the request will be processed with the service tier
173
+ * configured in the Project settings. Unless otherwise configured, the Project
174
+ * will use 'default'.
175
+ * - If set to 'default', then the request will be processed with the standard
176
+ * pricing and performance for the selected model.
177
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
178
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
179
+ * will be processed with the corresponding service tier.
180
+ * - When not set, the default behavior is 'auto'.
181
+ *
182
+ * When the `service_tier` parameter is set, the response body will include the
183
+ * `service_tier` value based on the processing mode actually used to serve the
184
+ * request. This response value may be different from the value set in the
185
+ * parameter.
186
+ */
187
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
188
+ /**
189
+ * @deprecated This fingerprint represents the backend configuration that the model
190
+ * runs with.
191
+ *
192
+ * Can be used in conjunction with the `seed` request parameter to understand when
193
+ * backend changes have been made that might impact determinism.
194
+ */
195
+ system_fingerprint?: string;
196
+ /**
197
+ * Usage statistics for the completion request.
198
+ */
199
+ usage?: CompletionsAPI.CompletionUsage;
200
+ }
201
+ export declare namespace ChatCompletion {
202
+ interface Choice {
203
+ /**
204
+ * The reason the model stopped generating tokens. This will be `stop` if the model
205
+ * hit a natural stop point or a provided stop sequence, `length` if the maximum
206
+ * number of tokens specified in the request was reached, `content_filter` if
207
+ * content was omitted due to a flag from our content filters, `tool_calls` if the
208
+ * model called a tool, or `function_call` (deprecated) if the model called a
209
+ * function.
210
+ */
211
+ finish_reason: 'stop' | 'length' | 'tool_calls' | 'content_filter' | 'function_call';
212
+ /**
213
+ * The index of the choice in the list of choices.
214
+ */
215
+ index: number;
216
+ /**
217
+ * Log probability information for the choice.
218
+ */
219
+ logprobs: Choice.Logprobs | null;
220
+ /**
221
+ * A chat completion message generated by the model.
222
+ */
223
+ message: CompletionsCompletionsAPI.ChatCompletionMessage;
224
+ }
225
+ namespace Choice {
226
+ /**
227
+ * Log probability information for the choice.
228
+ */
229
+ interface Logprobs {
230
+ /**
231
+ * A list of message content tokens with log probability information.
232
+ */
233
+ content: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
234
+ /**
235
+ * A list of message refusal tokens with log probability information.
236
+ */
237
+ refusal: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
238
+ }
239
+ }
240
+ }
241
+ /**
242
+ * Constrains the tools available to the model to a pre-defined set.
243
+ */
244
+ export interface ChatCompletionAllowedToolChoice {
245
+ /**
246
+ * Constrains the tools available to the model to a pre-defined set.
247
+ */
248
+ allowed_tools: ChatCompletionAllowedTools;
249
+ /**
250
+ * Allowed tool configuration type. Always `allowed_tools`.
251
+ */
252
+ type: 'allowed_tools';
253
+ }
254
+ /**
255
+ * Messages sent by the model in response to user messages.
256
+ */
257
+ export interface ChatCompletionAssistantMessageParam {
258
+ /**
259
+ * The role of the messages author, in this case `assistant`.
260
+ */
261
+ role: 'assistant';
262
+ /**
263
+ * Data about a previous audio response from the model.
264
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
265
+ */
266
+ audio?: ChatCompletionAssistantMessageParam.Audio | null;
267
+ /**
268
+ * The contents of the assistant message. Required unless `tool_calls` or
269
+ * `function_call` is specified.
270
+ */
271
+ content?: string | Array<ChatCompletionContentPartText | ChatCompletionContentPartRefusal> | null;
272
+ /**
273
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
274
+ * function that should be called, as generated by the model.
275
+ */
276
+ function_call?: ChatCompletionAssistantMessageParam.FunctionCall | null;
277
+ /**
278
+ * An optional name for the participant. Provides the model information to
279
+ * differentiate between participants of the same role.
280
+ */
281
+ name?: string;
282
+ /**
283
+ * The refusal message by the assistant.
284
+ */
285
+ refusal?: string | null;
286
+ /**
287
+ * The tool calls generated by the model, such as function calls.
288
+ */
289
+ tool_calls?: Array<ChatCompletionMessageToolCall>;
290
+ }
291
+ export declare namespace ChatCompletionAssistantMessageParam {
292
+ /**
293
+ * Data about a previous audio response from the model.
294
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
295
+ */
296
+ interface Audio {
297
+ /**
298
+ * Unique identifier for a previous audio response from the model.
299
+ */
300
+ id: string;
301
+ }
302
+ /**
303
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
304
+ * function that should be called, as generated by the model.
305
+ */
306
+ interface FunctionCall {
307
+ /**
308
+ * The arguments to call the function with, as generated by the model in JSON
309
+ * format. Note that the model does not always generate valid JSON, and may
310
+ * hallucinate parameters not defined by your function schema. Validate the
311
+ * arguments in your code before calling your function.
312
+ */
313
+ arguments: string;
314
+ /**
315
+ * The name of the function to call.
316
+ */
317
+ name: string;
318
+ }
319
+ }
320
+ /**
321
+ * If the audio output modality is requested, this object contains data about the
322
+ * audio response from the model.
323
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
324
+ */
325
+ export interface ChatCompletionAudio {
326
+ /**
327
+ * Unique identifier for this audio response.
328
+ */
329
+ id: string;
330
+ /**
331
+ * Base64 encoded audio bytes generated by the model, in the format specified in
332
+ * the request.
333
+ */
334
+ data: string;
335
+ /**
336
+ * The Unix timestamp (in seconds) for when this audio response will no longer be
337
+ * accessible on the server for use in multi-turn conversations.
338
+ */
339
+ expires_at: number;
340
+ /**
341
+ * Transcript of the audio generated by the model.
342
+ */
343
+ transcript: string;
344
+ }
345
+ /**
346
+ * Parameters for audio output. Required when audio output is requested with
347
+ * `modalities: ["audio"]`.
348
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
349
+ */
350
+ export interface ChatCompletionAudioParam {
351
+ /**
352
+ * Specifies the output audio format. Must be one of `wav`, `mp3`, `flac`, `opus`,
353
+ * or `pcm16`.
354
+ */
355
+ format: 'wav' | 'aac' | 'mp3' | 'flac' | 'opus' | 'pcm16';
356
+ /**
357
+ * The voice the model uses to respond. Supported voices are `alloy`, `ash`,
358
+ * `ballad`, `coral`, `echo`, `fable`, `nova`, `onyx`, `sage`, and `shimmer`.
359
+ */
360
+ voice: (string & {}) | 'alloy' | 'ash' | 'ballad' | 'coral' | 'echo' | 'sage' | 'shimmer' | 'verse';
361
+ }
362
+ /**
363
+ * Represents a streamed chunk of a chat completion response returned by the model,
364
+ * based on the provided input.
365
+ * [Learn more](https://platform.openai.com/docs/guides/streaming-responses).
366
+ */
367
+ export interface ChatCompletionChunk {
368
+ /**
369
+ * A unique identifier for the chat completion. Each chunk has the same ID.
370
+ */
371
+ id: string;
372
+ /**
373
+ * A list of chat completion choices. Can contain more than one elements if `n` is
374
+ * greater than 1. Can also be empty for the last chunk if you set
375
+ * `stream_options: {"include_usage": true}`.
376
+ */
377
+ choices: Array<ChatCompletionChunk.Choice>;
378
+ /**
379
+ * The Unix timestamp (in seconds) of when the chat completion was created. Each
380
+ * chunk has the same timestamp.
381
+ */
382
+ created: number;
383
+ /**
384
+ * The model to generate the completion.
385
+ */
386
+ model: string;
387
+ /**
388
+ * The object type, which is always `chat.completion.chunk`.
389
+ */
390
+ object: 'chat.completion.chunk';
391
+ /**
392
+ * Specifies the processing type used for serving the request.
393
+ *
394
+ * - If set to 'auto', then the request will be processed with the service tier
395
+ * configured in the Project settings. Unless otherwise configured, the Project
396
+ * will use 'default'.
397
+ * - If set to 'default', then the request will be processed with the standard
398
+ * pricing and performance for the selected model.
399
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
400
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
401
+ * will be processed with the corresponding service tier.
402
+ * - When not set, the default behavior is 'auto'.
403
+ *
404
+ * When the `service_tier` parameter is set, the response body will include the
405
+ * `service_tier` value based on the processing mode actually used to serve the
406
+ * request. This response value may be different from the value set in the
407
+ * parameter.
408
+ */
409
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
410
+ /**
411
+ * @deprecated This fingerprint represents the backend configuration that the model
412
+ * runs with. Can be used in conjunction with the `seed` request parameter to
413
+ * understand when backend changes have been made that might impact determinism.
414
+ */
415
+ system_fingerprint?: string;
416
+ /**
417
+ * An optional field that will only be present when you set
418
+ * `stream_options: {"include_usage": true}` in your request. When present, it
419
+ * contains a null value **except for the last chunk** which contains the token
420
+ * usage statistics for the entire request.
421
+ *
422
+ * **NOTE:** If the stream is interrupted or cancelled, you may not receive the
423
+ * final usage chunk which contains the total token usage for the request.
424
+ */
425
+ usage?: CompletionsAPI.CompletionUsage | null;
426
+ }
427
+ export declare namespace ChatCompletionChunk {
428
+ interface Choice {
429
+ /**
430
+ * A chat completion delta generated by streamed model responses.
431
+ */
432
+ delta: Choice.Delta;
433
+ /**
434
+ * The reason the model stopped generating tokens. This will be `stop` if the model
435
+ * hit a natural stop point or a provided stop sequence, `length` if the maximum
436
+ * number of tokens specified in the request was reached, `content_filter` if
437
+ * content was omitted due to a flag from our content filters, `tool_calls` if the
438
+ * model called a tool, or `function_call` (deprecated) if the model called a
439
+ * function.
440
+ */
441
+ finish_reason: 'stop' | 'length' | 'tool_calls' | 'content_filter' | 'function_call' | null;
442
+ /**
443
+ * The index of the choice in the list of choices.
444
+ */
445
+ index: number;
446
+ /**
447
+ * Log probability information for the choice.
448
+ */
449
+ logprobs?: Choice.Logprobs | null;
450
+ }
451
+ namespace Choice {
452
+ /**
453
+ * A chat completion delta generated by streamed model responses.
454
+ */
455
+ interface Delta {
456
+ /**
457
+ * The contents of the chunk message.
458
+ */
459
+ content?: string | null;
460
+ /**
461
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
462
+ * function that should be called, as generated by the model.
463
+ */
464
+ function_call?: Delta.FunctionCall;
465
+ /**
466
+ * The refusal message generated by the model.
467
+ */
468
+ refusal?: string | null;
469
+ /**
470
+ * The role of the author of this message.
471
+ */
472
+ role?: 'developer' | 'system' | 'user' | 'assistant' | 'tool';
473
+ tool_calls?: Array<Delta.ToolCall>;
474
+ }
475
+ namespace Delta {
476
+ /**
477
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
478
+ * function that should be called, as generated by the model.
479
+ */
480
+ interface FunctionCall {
481
+ /**
482
+ * The arguments to call the function with, as generated by the model in JSON
483
+ * format. Note that the model does not always generate valid JSON, and may
484
+ * hallucinate parameters not defined by your function schema. Validate the
485
+ * arguments in your code before calling your function.
486
+ */
487
+ arguments?: string;
488
+ /**
489
+ * The name of the function to call.
490
+ */
491
+ name?: string;
492
+ }
493
+ interface ToolCall {
494
+ index: number;
495
+ /**
496
+ * The ID of the tool call.
497
+ */
498
+ id?: string;
499
+ function?: ToolCall.Function;
500
+ /**
501
+ * The type of the tool. Currently, only `function` is supported.
502
+ */
503
+ type?: 'function';
504
+ }
505
+ namespace ToolCall {
506
+ interface Function {
507
+ /**
508
+ * The arguments to call the function with, as generated by the model in JSON
509
+ * format. Note that the model does not always generate valid JSON, and may
510
+ * hallucinate parameters not defined by your function schema. Validate the
511
+ * arguments in your code before calling your function.
512
+ */
513
+ arguments?: string;
514
+ /**
515
+ * The name of the function to call.
516
+ */
517
+ name?: string;
518
+ }
519
+ }
520
+ }
521
+ /**
522
+ * Log probability information for the choice.
523
+ */
524
+ interface Logprobs {
525
+ /**
526
+ * A list of message content tokens with log probability information.
527
+ */
528
+ content: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
529
+ /**
530
+ * A list of message refusal tokens with log probability information.
531
+ */
532
+ refusal: Array<CompletionsCompletionsAPI.ChatCompletionTokenLogprob> | null;
533
+ }
534
+ }
535
+ }
536
+ /**
537
+ * Learn about
538
+ * [text inputs](https://platform.openai.com/docs/guides/text-generation).
539
+ */
540
+ export type ChatCompletionContentPart = ChatCompletionContentPartText | ChatCompletionContentPartImage | ChatCompletionContentPartInputAudio | ChatCompletionContentPart.File;
541
+ export declare namespace ChatCompletionContentPart {
542
+ /**
543
+ * Learn about [file inputs](https://platform.openai.com/docs/guides/text) for text
544
+ * generation.
545
+ */
546
+ interface File {
547
+ file: File.File;
548
+ /**
549
+ * The type of the content part. Always `file`.
550
+ */
551
+ type: 'file';
552
+ }
553
+ namespace File {
554
+ interface File {
555
+ /**
556
+ * The base64 encoded file data, used when passing the file to the model as a
557
+ * string.
558
+ */
559
+ file_data?: string;
560
+ /**
561
+ * The ID of an uploaded file to use as input.
562
+ */
563
+ file_id?: string;
564
+ /**
565
+ * The name of the file, used when passing the file to the model as a string.
566
+ */
567
+ filename?: string;
568
+ }
569
+ }
570
+ }
571
+ /**
572
+ * Learn about [image inputs](https://platform.openai.com/docs/guides/vision).
573
+ */
574
+ export interface ChatCompletionContentPartImage {
575
+ image_url: ChatCompletionContentPartImage.ImageURL;
576
+ /**
577
+ * The type of the content part.
578
+ */
579
+ type: 'image_url';
580
+ }
581
+ export declare namespace ChatCompletionContentPartImage {
582
+ interface ImageURL {
583
+ /**
584
+ * Either a URL of the image or the base64 encoded image data.
585
+ */
586
+ url: string;
587
+ /**
588
+ * Specifies the detail level of the image. Learn more in the
589
+ * [Vision guide](https://platform.openai.com/docs/guides/vision#low-or-high-fidelity-image-understanding).
590
+ */
591
+ detail?: 'auto' | 'low' | 'high';
592
+ }
593
+ }
594
+ /**
595
+ * Learn about [audio inputs](https://platform.openai.com/docs/guides/audio).
596
+ */
597
+ export interface ChatCompletionContentPartInputAudio {
598
+ input_audio: ChatCompletionContentPartInputAudio.InputAudio;
599
+ /**
600
+ * The type of the content part. Always `input_audio`.
601
+ */
602
+ type: 'input_audio';
603
+ }
604
+ export declare namespace ChatCompletionContentPartInputAudio {
605
+ interface InputAudio {
606
+ /**
607
+ * Base64 encoded audio data.
608
+ */
609
+ data: string;
610
+ /**
611
+ * The format of the encoded audio data. Currently supports "wav" and "mp3".
612
+ */
613
+ format: 'wav' | 'mp3';
614
+ }
615
+ }
616
+ export interface ChatCompletionContentPartRefusal {
617
+ /**
618
+ * The refusal message generated by the model.
619
+ */
620
+ refusal: string;
621
+ /**
622
+ * The type of the content part.
623
+ */
624
+ type: 'refusal';
625
+ }
626
+ /**
627
+ * Learn about
628
+ * [text inputs](https://platform.openai.com/docs/guides/text-generation).
629
+ */
630
+ export interface ChatCompletionContentPartText {
631
+ /**
632
+ * The text content.
633
+ */
634
+ text: string;
635
+ /**
636
+ * The type of the content part.
637
+ */
638
+ type: 'text';
639
+ }
640
+ /**
641
+ * A custom tool that processes input using a specified format.
642
+ */
643
+ export interface ChatCompletionCustomTool {
644
+ /**
645
+ * Properties of the custom tool.
646
+ */
647
+ custom: ChatCompletionCustomTool.Custom;
648
+ /**
649
+ * The type of the custom tool. Always `custom`.
650
+ */
651
+ type: 'custom';
652
+ }
653
+ export declare namespace ChatCompletionCustomTool {
654
+ /**
655
+ * Properties of the custom tool.
656
+ */
657
+ interface Custom {
658
+ /**
659
+ * The name of the custom tool, used to identify it in tool calls.
660
+ */
661
+ name: string;
662
+ /**
663
+ * Optional description of the custom tool, used to provide more context.
664
+ */
665
+ description?: string;
666
+ /**
667
+ * The input format for the custom tool. Default is unconstrained text.
668
+ */
669
+ format?: Custom.Text | Custom.Grammar;
670
+ }
671
+ namespace Custom {
672
+ /**
673
+ * Unconstrained free-form text.
674
+ */
675
+ interface Text {
676
+ /**
677
+ * Unconstrained text format. Always `text`.
678
+ */
679
+ type: 'text';
680
+ }
681
+ /**
682
+ * A grammar defined by the user.
683
+ */
684
+ interface Grammar {
685
+ /**
686
+ * Your chosen grammar.
687
+ */
688
+ grammar: Grammar.Grammar;
689
+ /**
690
+ * Grammar format. Always `grammar`.
691
+ */
692
+ type: 'grammar';
693
+ }
694
+ namespace Grammar {
695
+ /**
696
+ * Your chosen grammar.
697
+ */
698
+ interface Grammar {
699
+ /**
700
+ * The grammar definition.
701
+ */
702
+ definition: string;
703
+ /**
704
+ * The syntax of the grammar definition. One of `lark` or `regex`.
705
+ */
706
+ syntax: 'lark' | 'regex';
707
+ }
708
+ }
709
+ }
710
+ }
711
+ export interface ChatCompletionDeleted {
712
+ /**
713
+ * The ID of the chat completion that was deleted.
714
+ */
715
+ id: string;
716
+ /**
717
+ * Whether the chat completion was deleted.
718
+ */
719
+ deleted: boolean;
720
+ /**
721
+ * The type of object being deleted.
722
+ */
723
+ object: 'chat.completion.deleted';
724
+ }
725
+ /**
726
+ * Developer-provided instructions that the model should follow, regardless of
727
+ * messages sent by the user. With o1 models and newer, `developer` messages
728
+ * replace the previous `system` messages.
729
+ */
730
+ export interface ChatCompletionDeveloperMessageParam {
731
+ /**
732
+ * The contents of the developer message.
733
+ */
734
+ content: string | Array<ChatCompletionContentPartText>;
735
+ /**
736
+ * The role of the messages author, in this case `developer`.
737
+ */
738
+ role: 'developer';
739
+ /**
740
+ * An optional name for the participant. Provides the model information to
741
+ * differentiate between participants of the same role.
742
+ */
743
+ name?: string;
744
+ }
745
+ /**
746
+ * Specifying a particular function via `{"name": "my_function"}` forces the model
747
+ * to call that function.
748
+ */
749
+ export interface ChatCompletionFunctionCallOption {
750
+ /**
751
+ * The name of the function to call.
752
+ */
753
+ name: string;
754
+ }
755
+ /**
756
+ * @deprecated
757
+ */
758
+ export interface ChatCompletionFunctionMessageParam {
759
+ /**
760
+ * The contents of the function message.
761
+ */
762
+ content: string | null;
763
+ /**
764
+ * The name of the function to call.
765
+ */
766
+ name: string;
767
+ /**
768
+ * The role of the messages author, in this case `function`.
769
+ */
770
+ role: 'function';
771
+ }
772
+ /**
773
+ * A function tool that can be used to generate a response.
774
+ */
775
+ export interface ChatCompletionFunctionTool {
776
+ function: Shared.FunctionDefinition;
777
+ /**
778
+ * The type of the tool. Currently, only `function` is supported.
779
+ */
780
+ type: 'function';
781
+ }
782
+ /**
783
+ * A chat completion message generated by the model.
784
+ */
785
+ export interface ChatCompletionMessage {
786
+ /**
787
+ * The contents of the message.
788
+ */
789
+ content: string | null;
790
+ /**
791
+ * The refusal message generated by the model.
792
+ */
793
+ refusal: string | null;
794
+ /**
795
+ * The role of the author of this message.
796
+ */
797
+ role: 'assistant';
798
+ /**
799
+ * Annotations for the message, when applicable, as when using the
800
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
801
+ */
802
+ annotations?: Array<ChatCompletionMessage.Annotation>;
803
+ /**
804
+ * If the audio output modality is requested, this object contains data about the
805
+ * audio response from the model.
806
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
807
+ */
808
+ audio?: ChatCompletionAudio | null;
809
+ /**
810
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
811
+ * function that should be called, as generated by the model.
812
+ */
813
+ function_call?: ChatCompletionMessage.FunctionCall | null;
814
+ /**
815
+ * The tool calls generated by the model, such as function calls.
816
+ */
817
+ tool_calls?: Array<ChatCompletionMessageToolCall>;
818
+ }
819
+ export declare namespace ChatCompletionMessage {
820
+ /**
821
+ * A URL citation when using web search.
822
+ */
823
+ interface Annotation {
824
+ /**
825
+ * The type of the URL citation. Always `url_citation`.
826
+ */
827
+ type: 'url_citation';
828
+ /**
829
+ * A URL citation when using web search.
830
+ */
831
+ url_citation: Annotation.URLCitation;
832
+ }
833
+ namespace Annotation {
834
+ /**
835
+ * A URL citation when using web search.
836
+ */
837
+ interface URLCitation {
838
+ /**
839
+ * The index of the last character of the URL citation in the message.
840
+ */
841
+ end_index: number;
842
+ /**
843
+ * The index of the first character of the URL citation in the message.
844
+ */
845
+ start_index: number;
846
+ /**
847
+ * The title of the web resource.
848
+ */
849
+ title: string;
850
+ /**
851
+ * The URL of the web resource.
852
+ */
853
+ url: string;
854
+ }
855
+ }
856
+ /**
857
+ * @deprecated Deprecated and replaced by `tool_calls`. The name and arguments of a
858
+ * function that should be called, as generated by the model.
859
+ */
860
+ interface FunctionCall {
861
+ /**
862
+ * The arguments to call the function with, as generated by the model in JSON
863
+ * format. Note that the model does not always generate valid JSON, and may
864
+ * hallucinate parameters not defined by your function schema. Validate the
865
+ * arguments in your code before calling your function.
866
+ */
867
+ arguments: string;
868
+ /**
869
+ * The name of the function to call.
870
+ */
871
+ name: string;
872
+ }
873
+ }
874
+ /**
875
+ * A call to a custom tool created by the model.
876
+ */
877
+ export interface ChatCompletionMessageCustomToolCall {
878
+ /**
879
+ * The ID of the tool call.
880
+ */
881
+ id: string;
882
+ /**
883
+ * The custom tool that the model called.
884
+ */
885
+ custom: ChatCompletionMessageCustomToolCall.Custom;
886
+ /**
887
+ * The type of the tool. Always `custom`.
888
+ */
889
+ type: 'custom';
890
+ }
891
+ export declare namespace ChatCompletionMessageCustomToolCall {
892
+ /**
893
+ * The custom tool that the model called.
894
+ */
895
+ interface Custom {
896
+ /**
897
+ * The input for the custom tool call generated by the model.
898
+ */
899
+ input: string;
900
+ /**
901
+ * The name of the custom tool to call.
902
+ */
903
+ name: string;
904
+ }
905
+ }
906
+ /**
907
+ * A call to a function tool created by the model.
908
+ */
909
+ export interface ChatCompletionMessageFunctionToolCall {
910
+ /**
911
+ * The ID of the tool call.
912
+ */
913
+ id: string;
914
+ /**
915
+ * The function that the model called.
916
+ */
917
+ function: ChatCompletionMessageFunctionToolCall.Function;
918
+ /**
919
+ * The type of the tool. Currently, only `function` is supported.
920
+ */
921
+ type: 'function';
922
+ }
923
+ export declare namespace ChatCompletionMessageFunctionToolCall {
924
+ /**
925
+ * The function that the model called.
926
+ */
927
+ interface Function {
928
+ /**
929
+ * The arguments to call the function with, as generated by the model in JSON
930
+ * format. Note that the model does not always generate valid JSON, and may
931
+ * hallucinate parameters not defined by your function schema. Validate the
932
+ * arguments in your code before calling your function.
933
+ */
934
+ arguments: string;
935
+ /**
936
+ * The name of the function to call.
937
+ */
938
+ name: string;
939
+ }
940
+ }
941
+ /**
942
+ * Developer-provided instructions that the model should follow, regardless of
943
+ * messages sent by the user. With o1 models and newer, `developer` messages
944
+ * replace the previous `system` messages.
945
+ */
946
+ export type ChatCompletionMessageParam = ChatCompletionDeveloperMessageParam | ChatCompletionSystemMessageParam | ChatCompletionUserMessageParam | ChatCompletionAssistantMessageParam | ChatCompletionToolMessageParam | ChatCompletionFunctionMessageParam;
947
+ /**
948
+ * A call to a function tool created by the model.
949
+ */
950
+ export type ChatCompletionMessageToolCall = ChatCompletionMessageFunctionToolCall | ChatCompletionMessageCustomToolCall;
951
+ export type ChatCompletionModality = 'text' | 'audio';
952
+ /**
953
+ * Specifies a tool the model should use. Use to force the model to call a specific
954
+ * function.
955
+ */
956
+ export interface ChatCompletionNamedToolChoice {
957
+ function: ChatCompletionNamedToolChoice.Function;
958
+ /**
959
+ * For function calling, the type is always `function`.
960
+ */
961
+ type: 'function';
962
+ }
963
+ export declare namespace ChatCompletionNamedToolChoice {
964
+ interface Function {
965
+ /**
966
+ * The name of the function to call.
967
+ */
968
+ name: string;
969
+ }
970
+ }
971
+ /**
972
+ * Specifies a tool the model should use. Use to force the model to call a specific
973
+ * custom tool.
974
+ */
975
+ export interface ChatCompletionNamedToolChoiceCustom {
976
+ custom: ChatCompletionNamedToolChoiceCustom.Custom;
977
+ /**
978
+ * For custom tool calling, the type is always `custom`.
979
+ */
980
+ type: 'custom';
981
+ }
982
+ export declare namespace ChatCompletionNamedToolChoiceCustom {
983
+ interface Custom {
984
+ /**
985
+ * The name of the custom tool to call.
986
+ */
987
+ name: string;
988
+ }
989
+ }
990
+ /**
991
+ * Static predicted output content, such as the content of a text file that is
992
+ * being regenerated.
993
+ */
994
+ export interface ChatCompletionPredictionContent {
995
+ /**
996
+ * The content that should be matched when generating a model response. If
997
+ * generated tokens would match this content, the entire model response can be
998
+ * returned much more quickly.
999
+ */
1000
+ content: string | Array<ChatCompletionContentPartText>;
1001
+ /**
1002
+ * The type of the predicted content you want to provide. This type is currently
1003
+ * always `content`.
1004
+ */
1005
+ type: 'content';
1006
+ }
1007
+ /**
1008
+ * The role of the author of a message
1009
+ */
1010
+ export type ChatCompletionRole = 'developer' | 'system' | 'user' | 'assistant' | 'tool' | 'function';
1011
+ /**
1012
+ * A chat completion message generated by the model.
1013
+ */
1014
+ export interface ChatCompletionStoreMessage extends ChatCompletionMessage {
1015
+ /**
1016
+ * The identifier of the chat message.
1017
+ */
1018
+ id: string;
1019
+ /**
1020
+ * If a content parts array was provided, this is an array of `text` and
1021
+ * `image_url` parts. Otherwise, null.
1022
+ */
1023
+ content_parts?: Array<ChatCompletionContentPartText | ChatCompletionContentPartImage> | null;
1024
+ }
1025
+ /**
1026
+ * Options for streaming response. Only set this when you set `stream: true`.
1027
+ */
1028
+ export interface ChatCompletionStreamOptions {
1029
+ /**
1030
+ * When true, stream obfuscation will be enabled. Stream obfuscation adds random
1031
+ * characters to an `obfuscation` field on streaming delta events to normalize
1032
+ * payload sizes as a mitigation to certain side-channel attacks. These obfuscation
1033
+ * fields are included by default, but add a small amount of overhead to the data
1034
+ * stream. You can set `include_obfuscation` to false to optimize for bandwidth if
1035
+ * you trust the network links between your application and the OpenAI API.
1036
+ */
1037
+ include_obfuscation?: boolean;
1038
+ /**
1039
+ * If set, an additional chunk will be streamed before the `data: [DONE]` message.
1040
+ * The `usage` field on this chunk shows the token usage statistics for the entire
1041
+ * request, and the `choices` field will always be an empty array.
1042
+ *
1043
+ * All other chunks will also include a `usage` field, but with a null value.
1044
+ * **NOTE:** If the stream is interrupted, you may not receive the final usage
1045
+ * chunk which contains the total token usage for the request.
1046
+ */
1047
+ include_usage?: boolean;
1048
+ }
1049
+ /**
1050
+ * Developer-provided instructions that the model should follow, regardless of
1051
+ * messages sent by the user. With o1 models and newer, use `developer` messages
1052
+ * for this purpose instead.
1053
+ */
1054
+ export interface ChatCompletionSystemMessageParam {
1055
+ /**
1056
+ * The contents of the system message.
1057
+ */
1058
+ content: string | Array<ChatCompletionContentPartText>;
1059
+ /**
1060
+ * The role of the messages author, in this case `system`.
1061
+ */
1062
+ role: 'system';
1063
+ /**
1064
+ * An optional name for the participant. Provides the model information to
1065
+ * differentiate between participants of the same role.
1066
+ */
1067
+ name?: string;
1068
+ }
1069
+ export interface ChatCompletionTokenLogprob {
1070
+ /**
1071
+ * The token.
1072
+ */
1073
+ token: string;
1074
+ /**
1075
+ * A list of integers representing the UTF-8 bytes representation of the token.
1076
+ * Useful in instances where characters are represented by multiple tokens and
1077
+ * their byte representations must be combined to generate the correct text
1078
+ * representation. Can be `null` if there is no bytes representation for the token.
1079
+ */
1080
+ bytes: Array<number> | null;
1081
+ /**
1082
+ * The log probability of this token, if it is within the top 20 most likely
1083
+ * tokens. Otherwise, the value `-9999.0` is used to signify that the token is very
1084
+ * unlikely.
1085
+ */
1086
+ logprob: number;
1087
+ /**
1088
+ * List of the most likely tokens and their log probability, at this token
1089
+ * position. In rare cases, there may be fewer than the number of requested
1090
+ * `top_logprobs` returned.
1091
+ */
1092
+ top_logprobs: Array<ChatCompletionTokenLogprob.TopLogprob>;
1093
+ }
1094
+ export declare namespace ChatCompletionTokenLogprob {
1095
+ interface TopLogprob {
1096
+ /**
1097
+ * The token.
1098
+ */
1099
+ token: string;
1100
+ /**
1101
+ * A list of integers representing the UTF-8 bytes representation of the token.
1102
+ * Useful in instances where characters are represented by multiple tokens and
1103
+ * their byte representations must be combined to generate the correct text
1104
+ * representation. Can be `null` if there is no bytes representation for the token.
1105
+ */
1106
+ bytes: Array<number> | null;
1107
+ /**
1108
+ * The log probability of this token, if it is within the top 20 most likely
1109
+ * tokens. Otherwise, the value `-9999.0` is used to signify that the token is very
1110
+ * unlikely.
1111
+ */
1112
+ logprob: number;
1113
+ }
1114
+ }
1115
+ /**
1116
+ * A function tool that can be used to generate a response.
1117
+ */
1118
+ export type ChatCompletionTool = ChatCompletionFunctionTool | ChatCompletionCustomTool;
1119
+ /**
1120
+ * Controls which (if any) tool is called by the model. `none` means the model will
1121
+ * not call any tool and instead generates a message. `auto` means the model can
1122
+ * pick between generating a message or calling one or more tools. `required` means
1123
+ * the model must call one or more tools. Specifying a particular tool via
1124
+ * `{"type": "function", "function": {"name": "my_function"}}` forces the model to
1125
+ * call that tool.
1126
+ *
1127
+ * `none` is the default when no tools are present. `auto` is the default if tools
1128
+ * are present.
1129
+ */
1130
+ export type ChatCompletionToolChoiceOption = 'none' | 'auto' | 'required' | ChatCompletionAllowedToolChoice | ChatCompletionNamedToolChoice | ChatCompletionNamedToolChoiceCustom;
1131
+ export interface ChatCompletionToolMessageParam {
1132
+ /**
1133
+ * The contents of the tool message.
1134
+ */
1135
+ content: string | Array<ChatCompletionContentPartText>;
1136
+ /**
1137
+ * The role of the messages author, in this case `tool`.
1138
+ */
1139
+ role: 'tool';
1140
+ /**
1141
+ * Tool call that this message is responding to.
1142
+ */
1143
+ tool_call_id: string;
1144
+ }
1145
+ /**
1146
+ * Messages sent by an end user, containing prompts or additional context
1147
+ * information.
1148
+ */
1149
+ export interface ChatCompletionUserMessageParam {
1150
+ /**
1151
+ * The contents of the user message.
1152
+ */
1153
+ content: string | Array<ChatCompletionContentPart>;
1154
+ /**
1155
+ * The role of the messages author, in this case `user`.
1156
+ */
1157
+ role: 'user';
1158
+ /**
1159
+ * An optional name for the participant. Provides the model information to
1160
+ * differentiate between participants of the same role.
1161
+ */
1162
+ name?: string;
1163
+ }
1164
+ /**
1165
+ * Constrains the tools available to the model to a pre-defined set.
1166
+ */
1167
+ export interface ChatCompletionAllowedTools {
1168
+ /**
1169
+ * Constrains the tools available to the model to a pre-defined set.
1170
+ *
1171
+ * `auto` allows the model to pick from among the allowed tools and generate a
1172
+ * message.
1173
+ *
1174
+ * `required` requires the model to call one or more of the allowed tools.
1175
+ */
1176
+ mode: 'auto' | 'required';
1177
+ /**
1178
+ * A list of tool definitions that the model should be allowed to call.
1179
+ *
1180
+ * For the Chat Completions API, the list of tool definitions might look like:
1181
+ *
1182
+ * ```json
1183
+ * [
1184
+ * { "type": "function", "function": { "name": "get_weather" } },
1185
+ * { "type": "function", "function": { "name": "get_time" } }
1186
+ * ]
1187
+ * ```
1188
+ */
1189
+ tools: Array<{
1190
+ [key: string]: unknown;
1191
+ }>;
1192
+ }
1193
+ export type ChatCompletionReasoningEffort = Shared.ReasoningEffort | null;
1194
+ export type ChatCompletionCreateParams = ChatCompletionCreateParamsNonStreaming | ChatCompletionCreateParamsStreaming;
1195
+ export interface ChatCompletionCreateParamsBase {
1196
+ /**
1197
+ * A list of messages comprising the conversation so far. Depending on the
1198
+ * [model](https://platform.openai.com/docs/models) you use, different message
1199
+ * types (modalities) are supported, like
1200
+ * [text](https://platform.openai.com/docs/guides/text-generation),
1201
+ * [images](https://platform.openai.com/docs/guides/vision), and
1202
+ * [audio](https://platform.openai.com/docs/guides/audio).
1203
+ */
1204
+ messages: Array<ChatCompletionMessageParam>;
1205
+ /**
1206
+ * Model ID used to generate the response, like `gpt-4o` or `o3`. OpenAI offers a
1207
+ * wide range of models with different capabilities, performance characteristics,
1208
+ * and price points. Refer to the
1209
+ * [model guide](https://platform.openai.com/docs/models) to browse and compare
1210
+ * available models.
1211
+ */
1212
+ model: (string & {}) | Shared.ChatModel;
1213
+ /**
1214
+ * Parameters for audio output. Required when audio output is requested with
1215
+ * `modalities: ["audio"]`.
1216
+ * [Learn more](https://platform.openai.com/docs/guides/audio).
1217
+ */
1218
+ audio?: ChatCompletionAudioParam | null;
1219
+ /**
1220
+ * Number between -2.0 and 2.0. Positive values penalize new tokens based on their
1221
+ * existing frequency in the text so far, decreasing the model's likelihood to
1222
+ * repeat the same line verbatim.
1223
+ */
1224
+ frequency_penalty?: number | null;
1225
+ /**
1226
+ * @deprecated Deprecated in favor of `tool_choice`.
1227
+ *
1228
+ * Controls which (if any) function is called by the model.
1229
+ *
1230
+ * `none` means the model will not call a function and instead generates a message.
1231
+ *
1232
+ * `auto` means the model can pick between generating a message or calling a
1233
+ * function.
1234
+ *
1235
+ * Specifying a particular function via `{"name": "my_function"}` forces the model
1236
+ * to call that function.
1237
+ *
1238
+ * `none` is the default when no functions are present. `auto` is the default if
1239
+ * functions are present.
1240
+ */
1241
+ function_call?: 'none' | 'auto' | ChatCompletionFunctionCallOption;
1242
+ /**
1243
+ * @deprecated Deprecated in favor of `tools`.
1244
+ *
1245
+ * A list of functions the model may generate JSON inputs for.
1246
+ */
1247
+ functions?: Array<ChatCompletionCreateParams.Function>;
1248
+ /**
1249
+ * Modify the likelihood of specified tokens appearing in the completion.
1250
+ *
1251
+ * Accepts a JSON object that maps tokens (specified by their token ID in the
1252
+ * tokenizer) to an associated bias value from -100 to 100. Mathematically, the
1253
+ * bias is added to the logits generated by the model prior to sampling. The exact
1254
+ * effect will vary per model, but values between -1 and 1 should decrease or
1255
+ * increase likelihood of selection; values like -100 or 100 should result in a ban
1256
+ * or exclusive selection of the relevant token.
1257
+ */
1258
+ logit_bias?: {
1259
+ [key: string]: number;
1260
+ } | null;
1261
+ /**
1262
+ * Whether to return log probabilities of the output tokens or not. If true,
1263
+ * returns the log probabilities of each output token returned in the `content` of
1264
+ * `message`.
1265
+ */
1266
+ logprobs?: boolean | null;
1267
+ /**
1268
+ * An upper bound for the number of tokens that can be generated for a completion,
1269
+ * including visible output tokens and
1270
+ * [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
1271
+ */
1272
+ max_completion_tokens?: number | null;
1273
+ /**
1274
+ * @deprecated The maximum number of [tokens](/tokenizer) that can be generated in
1275
+ * the chat completion. This value can be used to control
1276
+ * [costs](https://openai.com/api/pricing/) for text generated via API.
1277
+ *
1278
+ * This value is now deprecated in favor of `max_completion_tokens`, and is not
1279
+ * compatible with
1280
+ * [o-series models](https://platform.openai.com/docs/guides/reasoning).
1281
+ */
1282
+ max_tokens?: number | null;
1283
+ /**
1284
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1285
+ * for storing additional information about the object in a structured format, and
1286
+ * querying for objects via API or the dashboard.
1287
+ *
1288
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1289
+ * a maximum length of 512 characters.
1290
+ */
1291
+ metadata?: Shared.Metadata | null;
1292
+ /**
1293
+ * Output types that you would like the model to generate. Most models are capable
1294
+ * of generating text, which is the default:
1295
+ *
1296
+ * `["text"]`
1297
+ *
1298
+ * The `gpt-4o-audio-preview` model can also be used to
1299
+ * [generate audio](https://platform.openai.com/docs/guides/audio). To request that
1300
+ * this model generate both text and audio responses, you can use:
1301
+ *
1302
+ * `["text", "audio"]`
1303
+ */
1304
+ modalities?: Array<'text' | 'audio'> | null;
1305
+ /**
1306
+ * How many chat completion choices to generate for each input message. Note that
1307
+ * you will be charged based on the number of generated tokens across all of the
1308
+ * choices. Keep `n` as `1` to minimize costs.
1309
+ */
1310
+ n?: number | null;
1311
+ /**
1312
+ * Whether to enable
1313
+ * [parallel function calling](https://platform.openai.com/docs/guides/function-calling#configuring-parallel-function-calling)
1314
+ * during tool use.
1315
+ */
1316
+ parallel_tool_calls?: boolean;
1317
+ /**
1318
+ * Static predicted output content, such as the content of a text file that is
1319
+ * being regenerated.
1320
+ */
1321
+ prediction?: ChatCompletionPredictionContent | null;
1322
+ /**
1323
+ * Number between -2.0 and 2.0. Positive values penalize new tokens based on
1324
+ * whether they appear in the text so far, increasing the model's likelihood to
1325
+ * talk about new topics.
1326
+ */
1327
+ presence_penalty?: number | null;
1328
+ /**
1329
+ * Used by OpenAI to cache responses for similar requests to optimize your cache
1330
+ * hit rates. Replaces the `user` field.
1331
+ * [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
1332
+ */
1333
+ prompt_cache_key?: string;
1334
+ /**
1335
+ * Constrains effort on reasoning for
1336
+ * [reasoning models](https://platform.openai.com/docs/guides/reasoning). Currently
1337
+ * supported values are `minimal`, `low`, `medium`, and `high`. Reducing reasoning
1338
+ * effort can result in faster responses and fewer tokens used on reasoning in a
1339
+ * response.
1340
+ */
1341
+ reasoning_effort?: Shared.ReasoningEffort | null;
1342
+ /**
1343
+ * An object specifying the format that the model must output.
1344
+ *
1345
+ * Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured
1346
+ * Outputs which ensures the model will match your supplied JSON schema. Learn more
1347
+ * in the
1348
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
1349
+ *
1350
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
1351
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
1352
+ * preferred for models that support it.
1353
+ */
1354
+ response_format?: Shared.ResponseFormatText | Shared.ResponseFormatJSONSchema | Shared.ResponseFormatJSONObject;
1355
+ /**
1356
+ * A stable identifier used to help detect users of your application that may be
1357
+ * violating OpenAI's usage policies. The IDs should be a string that uniquely
1358
+ * identifies each user. We recommend hashing their username or email address, in
1359
+ * order to avoid sending us any identifying information.
1360
+ * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
1361
+ */
1362
+ safety_identifier?: string;
1363
+ /**
1364
+ * @deprecated This feature is in Beta. If specified, our system will make a best
1365
+ * effort to sample deterministically, such that repeated requests with the same
1366
+ * `seed` and parameters should return the same result. Determinism is not
1367
+ * guaranteed, and you should refer to the `system_fingerprint` response parameter
1368
+ * to monitor changes in the backend.
1369
+ */
1370
+ seed?: number | null;
1371
+ /**
1372
+ * Specifies the processing type used for serving the request.
1373
+ *
1374
+ * - If set to 'auto', then the request will be processed with the service tier
1375
+ * configured in the Project settings. Unless otherwise configured, the Project
1376
+ * will use 'default'.
1377
+ * - If set to 'default', then the request will be processed with the standard
1378
+ * pricing and performance for the selected model.
1379
+ * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)' or
1380
+ * '[priority](https://openai.com/api-priority-processing/)', then the request
1381
+ * will be processed with the corresponding service tier.
1382
+ * - When not set, the default behavior is 'auto'.
1383
+ *
1384
+ * When the `service_tier` parameter is set, the response body will include the
1385
+ * `service_tier` value based on the processing mode actually used to serve the
1386
+ * request. This response value may be different from the value set in the
1387
+ * parameter.
1388
+ */
1389
+ service_tier?: 'auto' | 'default' | 'flex' | 'scale' | 'priority' | null;
1390
+ /**
1391
+ * Not supported with latest reasoning models `o3` and `o4-mini`.
1392
+ *
1393
+ * Up to 4 sequences where the API will stop generating further tokens. The
1394
+ * returned text will not contain the stop sequence.
1395
+ */
1396
+ stop?: string | null | Array<string>;
1397
+ /**
1398
+ * Whether or not to store the output of this chat completion request for use in
1399
+ * our [model distillation](https://platform.openai.com/docs/guides/distillation)
1400
+ * or [evals](https://platform.openai.com/docs/guides/evals) products.
1401
+ *
1402
+ * Supports text and image inputs. Note: image inputs over 8MB will be dropped.
1403
+ */
1404
+ store?: boolean | null;
1405
+ /**
1406
+ * If set to true, the model response data will be streamed to the client as it is
1407
+ * generated using
1408
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1409
+ * See the
1410
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1411
+ * for more information, along with the
1412
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1413
+ * guide for more information on how to handle the streaming events.
1414
+ */
1415
+ stream?: boolean | null;
1416
+ /**
1417
+ * Options for streaming response. Only set this when you set `stream: true`.
1418
+ */
1419
+ stream_options?: ChatCompletionStreamOptions | null;
1420
+ /**
1421
+ * What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
1422
+ * make the output more random, while lower values like 0.2 will make it more
1423
+ * focused and deterministic. We generally recommend altering this or `top_p` but
1424
+ * not both.
1425
+ */
1426
+ temperature?: number | null;
1427
+ /**
1428
+ * Controls which (if any) tool is called by the model. `none` means the model will
1429
+ * not call any tool and instead generates a message. `auto` means the model can
1430
+ * pick between generating a message or calling one or more tools. `required` means
1431
+ * the model must call one or more tools. Specifying a particular tool via
1432
+ * `{"type": "function", "function": {"name": "my_function"}}` forces the model to
1433
+ * call that tool.
1434
+ *
1435
+ * `none` is the default when no tools are present. `auto` is the default if tools
1436
+ * are present.
1437
+ */
1438
+ tool_choice?: ChatCompletionToolChoiceOption;
1439
+ /**
1440
+ * A list of tools the model may call. You can provide either
1441
+ * [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools)
1442
+ * or [function tools](https://platform.openai.com/docs/guides/function-calling).
1443
+ */
1444
+ tools?: Array<ChatCompletionTool>;
1445
+ /**
1446
+ * An integer between 0 and 20 specifying the number of most likely tokens to
1447
+ * return at each token position, each with an associated log probability.
1448
+ * `logprobs` must be set to `true` if this parameter is used.
1449
+ */
1450
+ top_logprobs?: number | null;
1451
+ /**
1452
+ * An alternative to sampling with temperature, called nucleus sampling, where the
1453
+ * model considers the results of the tokens with top_p probability mass. So 0.1
1454
+ * means only the tokens comprising the top 10% probability mass are considered.
1455
+ *
1456
+ * We generally recommend altering this or `temperature` but not both.
1457
+ */
1458
+ top_p?: number | null;
1459
+ /**
1460
+ * @deprecated This field is being replaced by `safety_identifier` and
1461
+ * `prompt_cache_key`. Use `prompt_cache_key` instead to maintain caching
1462
+ * optimizations. A stable identifier for your end-users. Used to boost cache hit
1463
+ * rates by better bucketing similar requests and to help OpenAI detect and prevent
1464
+ * abuse.
1465
+ * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
1466
+ */
1467
+ user?: string;
1468
+ /**
1469
+ * Constrains the verbosity of the model's response. Lower values will result in
1470
+ * more concise responses, while higher values will result in more verbose
1471
+ * responses. Currently supported values are `low`, `medium`, and `high`.
1472
+ */
1473
+ verbosity?: 'low' | 'medium' | 'high' | null;
1474
+ /**
1475
+ * This tool searches the web for relevant results to use in a response. Learn more
1476
+ * about the
1477
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
1478
+ */
1479
+ web_search_options?: ChatCompletionCreateParams.WebSearchOptions;
1480
+ }
1481
+ export declare namespace ChatCompletionCreateParams {
1482
+ /**
1483
+ * @deprecated
1484
+ */
1485
+ interface Function {
1486
+ /**
1487
+ * The name of the function to be called. Must be a-z, A-Z, 0-9, or contain
1488
+ * underscores and dashes, with a maximum length of 64.
1489
+ */
1490
+ name: string;
1491
+ /**
1492
+ * A description of what the function does, used by the model to choose when and
1493
+ * how to call the function.
1494
+ */
1495
+ description?: string;
1496
+ /**
1497
+ * The parameters the functions accepts, described as a JSON Schema object. See the
1498
+ * [guide](https://platform.openai.com/docs/guides/function-calling) for examples,
1499
+ * and the
1500
+ * [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for
1501
+ * documentation about the format.
1502
+ *
1503
+ * Omitting `parameters` defines a function with an empty parameter list.
1504
+ */
1505
+ parameters?: Shared.FunctionParameters;
1506
+ }
1507
+ /**
1508
+ * This tool searches the web for relevant results to use in a response. Learn more
1509
+ * about the
1510
+ * [web search tool](https://platform.openai.com/docs/guides/tools-web-search?api-mode=chat).
1511
+ */
1512
+ interface WebSearchOptions {
1513
+ /**
1514
+ * High level guidance for the amount of context window space to use for the
1515
+ * search. One of `low`, `medium`, or `high`. `medium` is the default.
1516
+ */
1517
+ search_context_size?: 'low' | 'medium' | 'high';
1518
+ /**
1519
+ * Approximate location parameters for the search.
1520
+ */
1521
+ user_location?: WebSearchOptions.UserLocation | null;
1522
+ }
1523
+ namespace WebSearchOptions {
1524
+ /**
1525
+ * Approximate location parameters for the search.
1526
+ */
1527
+ interface UserLocation {
1528
+ /**
1529
+ * Approximate location parameters for the search.
1530
+ */
1531
+ approximate: UserLocation.Approximate;
1532
+ /**
1533
+ * The type of location approximation. Always `approximate`.
1534
+ */
1535
+ type: 'approximate';
1536
+ }
1537
+ namespace UserLocation {
1538
+ /**
1539
+ * Approximate location parameters for the search.
1540
+ */
1541
+ interface Approximate {
1542
+ /**
1543
+ * Free text input for the city of the user, e.g. `San Francisco`.
1544
+ */
1545
+ city?: string;
1546
+ /**
1547
+ * The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of
1548
+ * the user, e.g. `US`.
1549
+ */
1550
+ country?: string;
1551
+ /**
1552
+ * Free text input for the region of the user, e.g. `California`.
1553
+ */
1554
+ region?: string;
1555
+ /**
1556
+ * The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the
1557
+ * user, e.g. `America/Los_Angeles`.
1558
+ */
1559
+ timezone?: string;
1560
+ }
1561
+ }
1562
+ }
1563
+ type ChatCompletionCreateParamsNonStreaming = CompletionsCompletionsAPI.ChatCompletionCreateParamsNonStreaming;
1564
+ type ChatCompletionCreateParamsStreaming = CompletionsCompletionsAPI.ChatCompletionCreateParamsStreaming;
1565
+ }
1566
+ export interface ChatCompletionCreateParamsNonStreaming extends ChatCompletionCreateParamsBase {
1567
+ /**
1568
+ * If set to true, the model response data will be streamed to the client as it is
1569
+ * generated using
1570
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1571
+ * See the
1572
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1573
+ * for more information, along with the
1574
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1575
+ * guide for more information on how to handle the streaming events.
1576
+ */
1577
+ stream?: false | null;
1578
+ }
1579
+ export interface ChatCompletionCreateParamsStreaming extends ChatCompletionCreateParamsBase {
1580
+ /**
1581
+ * If set to true, the model response data will be streamed to the client as it is
1582
+ * generated using
1583
+ * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
1584
+ * See the
1585
+ * [Streaming section below](https://platform.openai.com/docs/api-reference/chat/streaming)
1586
+ * for more information, along with the
1587
+ * [streaming responses](https://platform.openai.com/docs/guides/streaming-responses)
1588
+ * guide for more information on how to handle the streaming events.
1589
+ */
1590
+ stream: true;
1591
+ }
1592
+ export interface ChatCompletionUpdateParams {
1593
+ /**
1594
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1595
+ * for storing additional information about the object in a structured format, and
1596
+ * querying for objects via API or the dashboard.
1597
+ *
1598
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1599
+ * a maximum length of 512 characters.
1600
+ */
1601
+ metadata: Shared.Metadata | null;
1602
+ }
1603
+ export interface ChatCompletionListParams extends CursorPageParams {
1604
+ /**
1605
+ * A list of metadata keys to filter the Chat Completions by. Example:
1606
+ *
1607
+ * `metadata[key1]=value1&metadata[key2]=value2`
1608
+ */
1609
+ metadata?: Shared.Metadata | null;
1610
+ /**
1611
+ * The model used to generate the Chat Completions.
1612
+ */
1613
+ model?: string;
1614
+ /**
1615
+ * Sort order for Chat Completions by timestamp. Use `asc` for ascending order or
1616
+ * `desc` for descending order. Defaults to `asc`.
1617
+ */
1618
+ order?: 'asc' | 'desc';
1619
+ }
1620
+ export declare namespace Completions {
1621
+ export { type ChatCompletion as ChatCompletion, type ChatCompletionAllowedToolChoice as ChatCompletionAllowedToolChoice, type ChatCompletionAssistantMessageParam as ChatCompletionAssistantMessageParam, type ChatCompletionAudio as ChatCompletionAudio, type ChatCompletionAudioParam as ChatCompletionAudioParam, type ChatCompletionChunk as ChatCompletionChunk, type ChatCompletionContentPart as ChatCompletionContentPart, type ChatCompletionContentPartImage as ChatCompletionContentPartImage, type ChatCompletionContentPartInputAudio as ChatCompletionContentPartInputAudio, type ChatCompletionContentPartRefusal as ChatCompletionContentPartRefusal, type ChatCompletionContentPartText as ChatCompletionContentPartText, type ChatCompletionCustomTool as ChatCompletionCustomTool, type ChatCompletionDeleted as ChatCompletionDeleted, type ChatCompletionDeveloperMessageParam as ChatCompletionDeveloperMessageParam, type ChatCompletionFunctionCallOption as ChatCompletionFunctionCallOption, type ChatCompletionFunctionMessageParam as ChatCompletionFunctionMessageParam, type ChatCompletionFunctionTool as ChatCompletionFunctionTool, type ChatCompletionMessage as ChatCompletionMessage, type ChatCompletionMessageCustomToolCall as ChatCompletionMessageCustomToolCall, type ChatCompletionMessageFunctionToolCall as ChatCompletionMessageFunctionToolCall, type ChatCompletionMessageParam as ChatCompletionMessageParam, type ChatCompletionMessageToolCall as ChatCompletionMessageToolCall, type ChatCompletionModality as ChatCompletionModality, type ChatCompletionNamedToolChoice as ChatCompletionNamedToolChoice, type ChatCompletionNamedToolChoiceCustom as ChatCompletionNamedToolChoiceCustom, type ChatCompletionPredictionContent as ChatCompletionPredictionContent, type ChatCompletionRole as ChatCompletionRole, type ChatCompletionStoreMessage as ChatCompletionStoreMessage, type ChatCompletionStreamOptions as ChatCompletionStreamOptions, type ChatCompletionSystemMessageParam as ChatCompletionSystemMessageParam, type ChatCompletionTokenLogprob as ChatCompletionTokenLogprob, type ChatCompletionTool as ChatCompletionTool, type ChatCompletionToolChoiceOption as ChatCompletionToolChoiceOption, type ChatCompletionToolMessageParam as ChatCompletionToolMessageParam, type ChatCompletionUserMessageParam as ChatCompletionUserMessageParam, type ChatCompletionAllowedTools as ChatCompletionAllowedTools, type ChatCompletionReasoningEffort as ChatCompletionReasoningEffort, type ChatCompletionsPage as ChatCompletionsPage, type ChatCompletionCreateParams as ChatCompletionCreateParams, type ChatCompletionCreateParamsNonStreaming as ChatCompletionCreateParamsNonStreaming, type ChatCompletionCreateParamsStreaming as ChatCompletionCreateParamsStreaming, type ChatCompletionUpdateParams as ChatCompletionUpdateParams, type ChatCompletionListParams as ChatCompletionListParams, };
1622
+ export { Messages as Messages, type MessageListParams as MessageListParams };
1623
+ }
1624
+ //# sourceMappingURL=completions.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/index.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/chat/completions/index.ts"],"names":[],"mappings":"OAEO,EACL,WAAW,EACX,KAAK,cAAc,EACnB,KAAK,+BAA+B,EACpC,KAAK,mCAAmC,EACxC,KAAK,mBAAmB,EACxB,KAAK,wBAAwB,EAC7B,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,8BAA8B,EACnC,KAAK,mCAAmC,EACxC,KAAK,gCAAgC,EACrC,KAAK,6BAA6B,EAClC,KAAK,wBAAwB,EAC7B,KAAK,qBAAqB,EAC1B,KAAK,mCAAmC,EACxC,KAAK,gCAAgC,EACrC,KAAK,kCAAkC,EACvC,KAAK,0BAA0B,EAC/B,KAAK,qBAAqB,EAC1B,KAAK,mCAAmC,EACxC,KAAK,qCAAqC,EAC1C,KAAK,0BAA0B,EAC/B,KAAK,6BAA6B,EAClC,KAAK,sBAAsB,EAC3B,KAAK,6BAA6B,EAClC,KAAK,mCAAmC,EACxC,KAAK,+BAA+B,EACpC,KAAK,kBAAkB,EACvB,KAAK,0BAA0B,EAC/B,KAAK,2BAA2B,EAChC,KAAK,gCAAgC,EACrC,KAAK,0BAA0B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,8BAA8B,EACnC,KAAK,8BAA8B,EACnC,KAAK,8BAA8B,EACnC,KAAK,0BAA0B,EAC/B,KAAK,0BAA0B,EAC/B,KAAK,sCAAsC,EAC3C,KAAK,mCAAmC,EACxC,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,+BAA+B,EACpC,KAAK,mBAAmB,GACzB;;OAEM,EAAE,QAAQ,EAAE,KAAK,iBAAiB,EAAE"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/index.js ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Messages = exports.Completions = void 0;
5
+ const tslib_1 = require("../../../internal/tslib.js");
6
+ var completions_1 = require("./completions.js");
7
+ Object.defineProperty(exports, "Completions", { enumerable: true, get: function () { return completions_1.Completions; } });
8
+ tslib_1.__exportStar(require("./completions.js"), exports);
9
+ var messages_1 = require("./messages.js");
10
+ Object.defineProperty(exports, "Messages", { enumerable: true, get: function () { return messages_1.Messages; } });
11
+ //# sourceMappingURL=index.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.d.ts ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import * as CompletionsAPI from "./completions.js";
3
+ import { ChatCompletionStoreMessagesPage } from "./completions.js";
4
+ import { type CursorPageParams, PagePromise } from "../../../core/pagination.js";
5
+ import { RequestOptions } from "../../../internal/request-options.js";
6
+ export declare class Messages extends APIResource {
7
+ /**
8
+ * Get the messages in a stored chat completion. Only Chat Completions that have
9
+ * been created with the `store` parameter set to `true` will be returned.
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * // Automatically fetches more pages as needed.
14
+ * for await (const chatCompletionStoreMessage of client.chat.completions.messages.list(
15
+ * 'completion_id',
16
+ * )) {
17
+ * // ...
18
+ * }
19
+ * ```
20
+ */
21
+ list(completionID: string, query?: MessageListParams | null | undefined, options?: RequestOptions): PagePromise<ChatCompletionStoreMessagesPage, CompletionsAPI.ChatCompletionStoreMessage>;
22
+ }
23
+ export interface MessageListParams extends CursorPageParams {
24
+ /**
25
+ * Sort order for messages by timestamp. Use `asc` for ascending order or `desc`
26
+ * for descending order. Defaults to `asc`.
27
+ */
28
+ order?: 'asc' | 'desc';
29
+ }
30
+ export declare namespace Messages {
31
+ export { type MessageListParams as MessageListParams };
32
+ }
33
+ export { type ChatCompletionStoreMessagesPage };
34
+ //# sourceMappingURL=messages.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../../src/resources/chat/completions/messages.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,EAAE,+BAA+B,EAAE;OACnC,EAAc,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAClD,EAAE,cAAc,EAAE;AAGzB,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;;OAaG;IACH,IAAI,CACF,YAAY,EAAE,MAAM,EACpB,KAAK,GAAE,iBAAiB,GAAG,IAAI,GAAG,SAAc,EAChD,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,+BAA+B,EAAE,cAAc,CAAC,0BAA0B,CAAC;CAO3F;AAED,MAAM,WAAW,iBAAkB,SAAQ,gBAAgB;IACzD;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,GAAG,MAAM,CAAC;CACxB;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,CAAC;CACxD;AAED,OAAO,EAAE,KAAK,+BAA+B,EAAE,CAAC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/chat/completions/messages.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/resources/chat/completions/messages.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAGrD,4DAA0F;AAE1F,0DAAoD;AAEpD,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;;;;;;;;;;OAaG;IACH,IAAI,CACF,YAAoB,EACpB,QAA8C,EAAE,EAChD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAC5B,IAAA,WAAI,EAAA,qBAAqB,YAAY,WAAW,EAChD,CAAA,uBAAqD,CAAA,EACrD,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CACtB,CAAC;IACJ,CAAC;CACF;AA1BD,4BA0BC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/content.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"content.d.ts","sourceRoot":"","sources":["../../../src/resources/containers/files/content.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OAEd,EAAE,cAAc,EAAE;AAGzB,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,qBAAqB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,QAAQ,CAAC;CAQxG;AAED,MAAM,WAAW,qBAAqB;IACpC,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EAAE,KAAK,qBAAqB,IAAI,qBAAqB,EAAE,CAAC;CAChE"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/content.js ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Content = void 0;
5
+ const resource_1 = require("../../../core/resource.js");
6
+ const headers_1 = require("../../../internal/headers.js");
7
+ const path_1 = require("../../../internal/utils/path.js");
8
+ class Content extends resource_1.APIResource {
9
+ /**
10
+ * Retrieve Container File Content
11
+ */
12
+ retrieve(fileID, params, options) {
13
+ const { container_id } = params;
14
+ return this._client.get((0, path_1.path) `/containers/${container_id}/files/${fileID}/content`, {
15
+ ...options,
16
+ headers: (0, headers_1.buildHeaders)([{ Accept: 'application/binary' }, options?.headers]),
17
+ __binaryResponse: true,
18
+ });
19
+ }
20
+ }
21
+ exports.Content = Content;
22
+ //# sourceMappingURL=content.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.mts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"files.d.mts","sourceRoot":"","sources":["../../../src/resources/containers/files/files.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,EAAE,OAAO,EAAE,qBAAqB,EAAE;OAClC,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAClD,EAAE,KAAK,UAAU,EAAE;OAEnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,KAAM,SAAQ,WAAW;IACpC,OAAO,EAAE,UAAU,CAAC,OAAO,CAAwC;IAEnE;;;;;OAKG;IACH,MAAM,CACJ,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,gBAAgB,EACtB,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,kBAAkB,CAAC;IAOjC;;OAEG;IACH,QAAQ,CACN,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,kBAAkB,EAC1B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,oBAAoB,CAAC;IAKnC;;OAEG;IACH,IAAI,CACF,WAAW,EAAE,MAAM,EACnB,KAAK,GAAE,cAAc,GAAG,IAAI,GAAG,SAAc,EAC7C,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,qBAAqB,EAAE,gBAAgB,CAAC;IAOvD;;OAEG;IACH,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I,CAAC,EAAE,UAAU,CAAC;IAElB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,kBAAkB;IACjC,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,cAAe,SAAQ,gBAAgB;IACtD;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,GAAG,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,gBAAgB;IAC/B,YAAY,EAAE,MAAM,CAAC;CACtB;AAID,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,KAAK,qBAAqB,IAAI,qBAAqB,EAAE,CAAC;CACpF"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.ts ADDED
@@ -0,0 +1,148 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import * as ContentAPI from "./content.js";
3
+ import { Content, ContentRetrieveParams } from "./content.js";
4
+ import { APIPromise } from "../../../core/api-promise.js";
5
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.js";
6
+ import { type Uploadable } from "../../../core/uploads.js";
7
+ import { RequestOptions } from "../../../internal/request-options.js";
8
+ export declare class Files extends APIResource {
9
+ content: ContentAPI.Content;
10
+ /**
11
+ * Create a Container File
12
+ *
13
+ * You can send either a multipart/form-data request with the raw file content, or
14
+ * a JSON request with a file ID.
15
+ */
16
+ create(containerID: string, body: FileCreateParams, options?: RequestOptions): APIPromise<FileCreateResponse>;
17
+ /**
18
+ * Retrieve Container File
19
+ */
20
+ retrieve(fileID: string, params: FileRetrieveParams, options?: RequestOptions): APIPromise<FileRetrieveResponse>;
21
+ /**
22
+ * List Container files
23
+ */
24
+ list(containerID: string, query?: FileListParams | null | undefined, options?: RequestOptions): PagePromise<FileListResponsesPage, FileListResponse>;
25
+ /**
26
+ * Delete Container File
27
+ */
28
+ delete(fileID: string, params: FileDeleteParams, options?: RequestOptions): APIPromise<void>;
29
+ }
30
+ export type FileListResponsesPage = CursorPage<FileListResponse>;
31
+ export interface FileCreateResponse {
32
+ /**
33
+ * Unique identifier for the file.
34
+ */
35
+ id: string;
36
+ /**
37
+ * Size of the file in bytes.
38
+ */
39
+ bytes: number;
40
+ /**
41
+ * The container this file belongs to.
42
+ */
43
+ container_id: string;
44
+ /**
45
+ * Unix timestamp (in seconds) when the file was created.
46
+ */
47
+ created_at: number;
48
+ /**
49
+ * The type of this object (`container.file`).
50
+ */
51
+ object: 'container.file';
52
+ /**
53
+ * Path of the file in the container.
54
+ */
55
+ path: string;
56
+ /**
57
+ * Source of the file (e.g., `user`, `assistant`).
58
+ */
59
+ source: string;
60
+ }
61
+ export interface FileRetrieveResponse {
62
+ /**
63
+ * Unique identifier for the file.
64
+ */
65
+ id: string;
66
+ /**
67
+ * Size of the file in bytes.
68
+ */
69
+ bytes: number;
70
+ /**
71
+ * The container this file belongs to.
72
+ */
73
+ container_id: string;
74
+ /**
75
+ * Unix timestamp (in seconds) when the file was created.
76
+ */
77
+ created_at: number;
78
+ /**
79
+ * The type of this object (`container.file`).
80
+ */
81
+ object: 'container.file';
82
+ /**
83
+ * Path of the file in the container.
84
+ */
85
+ path: string;
86
+ /**
87
+ * Source of the file (e.g., `user`, `assistant`).
88
+ */
89
+ source: string;
90
+ }
91
+ export interface FileListResponse {
92
+ /**
93
+ * Unique identifier for the file.
94
+ */
95
+ id: string;
96
+ /**
97
+ * Size of the file in bytes.
98
+ */
99
+ bytes: number;
100
+ /**
101
+ * The container this file belongs to.
102
+ */
103
+ container_id: string;
104
+ /**
105
+ * Unix timestamp (in seconds) when the file was created.
106
+ */
107
+ created_at: number;
108
+ /**
109
+ * The type of this object (`container.file`).
110
+ */
111
+ object: 'container.file';
112
+ /**
113
+ * Path of the file in the container.
114
+ */
115
+ path: string;
116
+ /**
117
+ * Source of the file (e.g., `user`, `assistant`).
118
+ */
119
+ source: string;
120
+ }
121
+ export interface FileCreateParams {
122
+ /**
123
+ * The File object (not file name) to be uploaded.
124
+ */
125
+ file?: Uploadable;
126
+ /**
127
+ * Name of the file to create.
128
+ */
129
+ file_id?: string;
130
+ }
131
+ export interface FileRetrieveParams {
132
+ container_id: string;
133
+ }
134
+ export interface FileListParams extends CursorPageParams {
135
+ /**
136
+ * Sort order by the `created_at` timestamp of the objects. `asc` for ascending
137
+ * order and `desc` for descending order.
138
+ */
139
+ order?: 'asc' | 'desc';
140
+ }
141
+ export interface FileDeleteParams {
142
+ container_id: string;
143
+ }
144
+ export declare namespace Files {
145
+ export { type FileCreateResponse as FileCreateResponse, type FileRetrieveResponse as FileRetrieveResponse, type FileListResponse as FileListResponse, type FileListResponsesPage as FileListResponsesPage, type FileCreateParams as FileCreateParams, type FileRetrieveParams as FileRetrieveParams, type FileListParams as FileListParams, type FileDeleteParams as FileDeleteParams, };
146
+ export { Content as Content, type ContentRetrieveParams as ContentRetrieveParams };
147
+ }
148
+ //# sourceMappingURL=files.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"files.d.ts","sourceRoot":"","sources":["../../../src/resources/containers/files/files.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,EAAE,OAAO,EAAE,qBAAqB,EAAE;OAClC,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAClD,EAAE,KAAK,UAAU,EAAE;OAEnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,KAAM,SAAQ,WAAW;IACpC,OAAO,EAAE,UAAU,CAAC,OAAO,CAAwC;IAEnE;;;;;OAKG;IACH,MAAM,CACJ,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,gBAAgB,EACtB,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,kBAAkB,CAAC;IAOjC;;OAEG;IACH,QAAQ,CACN,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,kBAAkB,EAC1B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,oBAAoB,CAAC;IAKnC;;OAEG;IACH,IAAI,CACF,WAAW,EAAE,MAAM,EACnB,KAAK,GAAE,cAAc,GAAG,IAAI,GAAG,SAAc,EAC7C,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,qBAAqB,EAAE,gBAAgB,CAAC;IAOvD;;OAEG;IACH,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,gBAAgB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAO7F;AAED,MAAM,MAAM,qBAAqB,GAAG,UAAU,CAAC,gBAAgB,CAAC,CAAC;AAEjE,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,EAAE,EAAE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xB;AAED,MAAM,WAAW,gBAAgB;IAC/B,YAAY,EAAE,MAAM,CAAC;CACtB;AAID,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,KAAK,qBAAqB,IAAI,qBAAqB,EAAE,CAAC;CACpF"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.js ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Files = void 0;
5
+ const tslib_1 = require("../../../internal/tslib.js");
6
+ const resource_1 = require("../../../core/resource.js");
7
+ const ContentAPI = tslib_1.__importStar(require("./content.js"));
8
+ const content_1 = require("./content.js");
9
+ const pagination_1 = require("../../../core/pagination.js");
10
+ const headers_1 = require("../../../internal/headers.js");
11
+ const uploads_1 = require("../../../internal/uploads.js");
12
+ const path_1 = require("../../../internal/utils/path.js");
13
+ class Files extends resource_1.APIResource {
14
+ constructor() {
15
+ super(...arguments);
16
+ this.content = new ContentAPI.Content(this._client);
17
+ }
18
+ /**
19
+ * Create a Container File
20
+ *
21
+ * You can send either a multipart/form-data request with the raw file content, or
22
+ * a JSON request with a file ID.
23
+ */
24
+ create(containerID, body, options) {
25
+ return this._client.post((0, path_1.path) `/containers/${containerID}/files`, (0, uploads_1.multipartFormRequestOptions)({ body, ...options }, this._client));
26
+ }
27
+ /**
28
+ * Retrieve Container File
29
+ */
30
+ retrieve(fileID, params, options) {
31
+ const { container_id } = params;
32
+ return this._client.get((0, path_1.path) `/containers/${container_id}/files/${fileID}`, options);
33
+ }
34
+ /**
35
+ * List Container files
36
+ */
37
+ list(containerID, query = {}, options) {
38
+ return this._client.getAPIList((0, path_1.path) `/containers/${containerID}/files`, (pagination_1.CursorPage), {
39
+ query,
40
+ ...options,
41
+ });
42
+ }
43
+ /**
44
+ * Delete Container File
45
+ */
46
+ delete(fileID, params, options) {
47
+ const { container_id } = params;
48
+ return this._client.delete((0, path_1.path) `/containers/${container_id}/files/${fileID}`, {
49
+ ...options,
50
+ headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
51
+ });
52
+ }
53
+ }
54
+ exports.Files = Files;
55
+ Files.Content = content_1.Content;
56
+ //# sourceMappingURL=files.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"files.js","sourceRoot":"","sources":["../../../src/resources/containers/files/files.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AACrD,iEAAwC;AACxC,0CAA2D;AAE3D,4DAA0F;AAE1F,0DAAyD;AAEzD,0DAAwE;AACxE,0DAAoD;AAEpD,MAAa,KAAM,SAAQ,sBAAW;IAAtC;;QACE,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAuDrE,CAAC;IArDC;;;;;OAKG;IACH,MAAM,CACJ,WAAmB,EACnB,IAAsB,EACtB,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CACtB,IAAA,WAAI,EAAA,eAAe,WAAW,QAAQ,EACtC,IAAA,qCAA2B,EAAC,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,EAAE,IAAI,CAAC,OAAO,CAAC,CAChE,CAAC;IACJ,CAAC;IAED;;OAEG;IACH,QAAQ,CACN,MAAc,EACd,MAA0B,EAC1B,OAAwB;QAExB,MAAM,EAAE,YAAY,EAAE,GAAG,MAAM,CAAC;QAChC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,eAAe,YAAY,UAAU,MAAM,EAAE,EAAE,OAAO,CAAC,CAAC;IACtF,CAAC;IAED;;OAEG;IACH,IAAI,CACF,WAAmB,EACnB,QAA2C,EAAE,EAC7C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,IAAA,WAAI,EAAA,eAAe,WAAW,QAAQ,EAAE,CAAA,uBAA4B,CAAA,EAAE;YACnG,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,MAAc,EAAE,MAAwB,EAAE,OAAwB;QACvE,MAAM,EAAE,YAAY,EAAE,GAAG,MAAM,CAAC;QAChC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,eAAe,YAAY,UAAU,MAAM,EAAE,EAAE;YAC5E,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF;AAxDD,sBAwDC;AA+ID,KAAK,CAAC,OAAO,GAAG,iBAAO,CAAC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.mjs ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../../core/resource.mjs";
3
+ import * as ContentAPI from "./content.mjs";
4
+ import { Content } from "./content.mjs";
5
+ import { CursorPage } from "../../../core/pagination.mjs";
6
+ import { buildHeaders } from "../../../internal/headers.mjs";
7
+ import { multipartFormRequestOptions } from "../../../internal/uploads.mjs";
8
+ import { path } from "../../../internal/utils/path.mjs";
9
+ export class Files extends APIResource {
10
+ constructor() {
11
+ super(...arguments);
12
+ this.content = new ContentAPI.Content(this._client);
13
+ }
14
+ /**
15
+ * Create a Container File
16
+ *
17
+ * You can send either a multipart/form-data request with the raw file content, or
18
+ * a JSON request with a file ID.
19
+ */
20
+ create(containerID, body, options) {
21
+ return this._client.post(path `/containers/${containerID}/files`, multipartFormRequestOptions({ body, ...options }, this._client));
22
+ }
23
+ /**
24
+ * Retrieve Container File
25
+ */
26
+ retrieve(fileID, params, options) {
27
+ const { container_id } = params;
28
+ return this._client.get(path `/containers/${container_id}/files/${fileID}`, options);
29
+ }
30
+ /**
31
+ * List Container files
32
+ */
33
+ list(containerID, query = {}, options) {
34
+ return this._client.getAPIList(path `/containers/${containerID}/files`, (CursorPage), {
35
+ query,
36
+ ...options,
37
+ });
38
+ }
39
+ /**
40
+ * Delete Container File
41
+ */
42
+ delete(fileID, params, options) {
43
+ const { container_id } = params;
44
+ return this._client.delete(path `/containers/${container_id}/files/${fileID}`, {
45
+ ...options,
46
+ headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
47
+ });
48
+ }
49
+ }
50
+ Files.Content = Content;
51
+ //# sourceMappingURL=files.mjs.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/files.mjs.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"files.mjs","sourceRoot":"","sources":["../../../src/res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AAC,IAAI,CAAA,eAAe,YAAY,UAAU,MAAM,EAAE,EAAE;YAC5E,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF;AA+ID,KAAK,CAAC,OAAO,GAAG,OAAO,CAAC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.mts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export { Content, type ContentRetrieveParams } from "./content.mjs";
2
+ export { Files, type FileCreateResponse, type FileRetrieveResponse, type FileListResponse, type FileCreateParams, type FileRetrieveParams, type FileListParams, type FileDeleteParams, type FileListResponsesPage, } from "./files.mjs";
3
+ //# sourceMappingURL=index.d.mts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.mts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/containers/files/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE,KAAK,qBAAqB,EAAE;OACvC,EACL,KAAK,EACL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,GAC3B"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export { Content, type ContentRetrieveParams } from "./content.js";
2
+ export { Files, type FileCreateResponse, type FileRetrieveResponse, type FileListResponse, type FileCreateParams, type FileRetrieveParams, type FileListParams, type FileDeleteParams, type FileListResponsesPage, } from "./files.js";
3
+ //# sourceMappingURL=index.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/containers/files/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE,KAAK,qBAAqB,EAAE;OACvC,EACL,KAAK,EACL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,GAC3B"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Files = exports.Content = void 0;
5
+ var content_1 = require("./content.js");
6
+ Object.defineProperty(exports, "Content", { enumerable: true, get: function () { return content_1.Content; } });
7
+ var files_1 = require("./files.js");
8
+ Object.defineProperty(exports, "Files", { enumerable: true, get: function () { return files_1.Files; } });
9
+ //# sourceMappingURL=index.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/containers/files/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wCAAgE;AAAvD,kGAAA,OAAO,OAAA;AAChB,oCAUiB;AATf,8FAAA,KAAK,OAAA"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.mjs ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export { Content } from "./content.mjs";
3
+ export { Files, } from "./files.mjs";
4
+ //# sourceMappingURL=index.mjs.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/containers/files/index.mjs.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/containers/files/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,OAAO,EAA8B;OACvC,EACL,KAAK,GASN"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/index.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export { Evals, type EvalCustomDataSourceConfig, type EvalStoredCompletionsDataSourceConfig, type EvalCreateResponse, type EvalRetrieveResponse, type EvalUpdateResponse, type EvalListResponse, type EvalDeleteResponse, type EvalCreateParams, type EvalUpdateParams, type EvalListParams, type EvalListResponsesPage, } from "./evals.js";
2
+ export { Runs, type CreateEvalCompletionsRunDataSource, type CreateEvalJSONLRunDataSource, type EvalAPIError, type RunCreateResponse, type RunRetrieveResponse, type RunListResponse, type RunDeleteResponse, type RunCancelResponse, type RunCreateParams, type RunRetrieveParams, type RunListParams, type RunDeleteParams, type RunCancelParams, type RunListResponsesPage, } from "./runs/index.js";
3
+ //# sourceMappingURL=index.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"runs.d.ts","sourceRoot":"","sources":["../../src/resources/evals/runs.ts"],"names":[],"mappings":""}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.mts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/evals/runs/index.ts"],"names":[],"mappings":"OAEO,EACL,WAAW,EACX,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,2BAA2B,GACjC;OACM,EACL,IAAI,EACJ,KAAK,kCAAkC,EACvC,KAAK,4BAA4B,EACjC,KAAK,YAAY,EACjB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,eAAe,EACpB,KAAK,oBAAoB,GAC1B"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export { OutputItems, type OutputItemRetrieveResponse, type OutputItemListResponse, type OutputItemRetrieveParams, type OutputItemListParams, type OutputItemListResponsesPage, } from "./output-items.js";
2
+ export { Runs, type CreateEvalCompletionsRunDataSource, type CreateEvalJSONLRunDataSource, type EvalAPIError, type RunCreateResponse, type RunRetrieveResponse, type RunListResponse, type RunDeleteResponse, type RunCancelResponse, type RunCreateParams, type RunRetrieveParams, type RunListParams, type RunDeleteParams, type RunCancelParams, type RunListResponsesPage, } from "./runs.js";
3
+ //# sourceMappingURL=index.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.d.ts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/evals/runs/index.ts"],"names":[],"mappings":"OAEO,EACL,WAAW,EACX,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,2BAA2B,GACjC;OACM,EACL,IAAI,EACJ,KAAK,kCAAkC,EACvC,KAAK,4BAA4B,EACjC,KAAK,YAAY,EACjB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,eAAe,EACpB,KAAK,oBAAoB,GAC1B"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Runs = exports.OutputItems = void 0;
5
+ var output_items_1 = require("./output-items.js");
6
+ Object.defineProperty(exports, "OutputItems", { enumerable: true, get: function () { return output_items_1.OutputItems; } });
7
+ var runs_1 = require("./runs.js");
8
+ Object.defineProperty(exports, "Runs", { enumerable: true, get: function () { return runs_1.Runs; } });
9
+ //# sourceMappingURL=index.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/evals/runs/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAOwB;AANtB,2GAAA,WAAW,OAAA;AAOb,kCAgBgB;AAfd,4FAAA,IAAI,OAAA"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/index.mjs ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export { OutputItems, } from "./output-items.mjs";
3
+ export { Runs, } from "./runs.mjs";
4
+ //# sourceMappingURL=index.mjs.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.d.mts ADDED
@@ -0,0 +1,330 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import * as RunsAPI from "./runs.mjs";
3
+ import { APIPromise } from "../../../core/api-promise.mjs";
4
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.mjs";
5
+ import { RequestOptions } from "../../../internal/request-options.mjs";
6
+ export declare class OutputItems extends APIResource {
7
+ /**
8
+ * Get an evaluation run output item by ID.
9
+ */
10
+ retrieve(outputItemID: string, params: OutputItemRetrieveParams, options?: RequestOptions): APIPromise<OutputItemRetrieveResponse>;
11
+ /**
12
+ * Get a list of output items for an evaluation run.
13
+ */
14
+ list(runID: string, params: OutputItemListParams, options?: RequestOptions): PagePromise<OutputItemListResponsesPage, OutputItemListResponse>;
15
+ }
16
+ export type OutputItemListResponsesPage = CursorPage<OutputItemListResponse>;
17
+ /**
18
+ * A schema representing an evaluation run output item.
19
+ */
20
+ export interface OutputItemRetrieveResponse {
21
+ /**
22
+ * Unique identifier for the evaluation run output item.
23
+ */
24
+ id: string;
25
+ /**
26
+ * Unix timestamp (in seconds) when the evaluation run was created.
27
+ */
28
+ created_at: number;
29
+ /**
30
+ * Details of the input data source item.
31
+ */
32
+ datasource_item: {
33
+ [key: string]: unknown;
34
+ };
35
+ /**
36
+ * The identifier for the data source item.
37
+ */
38
+ datasource_item_id: number;
39
+ /**
40
+ * The identifier of the evaluation group.
41
+ */
42
+ eval_id: string;
43
+ /**
44
+ * The type of the object. Always "eval.run.output_item".
45
+ */
46
+ object: 'eval.run.output_item';
47
+ /**
48
+ * A list of results from the evaluation run.
49
+ */
50
+ results: Array<{
51
+ [key: string]: unknown;
52
+ }>;
53
+ /**
54
+ * The identifier of the evaluation run associated with this output item.
55
+ */
56
+ run_id: string;
57
+ /**
58
+ * A sample containing the input and output of the evaluation run.
59
+ */
60
+ sample: OutputItemRetrieveResponse.Sample;
61
+ /**
62
+ * The status of the evaluation run.
63
+ */
64
+ status: string;
65
+ }
66
+ export declare namespace OutputItemRetrieveResponse {
67
+ /**
68
+ * A sample containing the input and output of the evaluation run.
69
+ */
70
+ interface Sample {
71
+ /**
72
+ * An object representing an error response from the Eval API.
73
+ */
74
+ error: RunsAPI.EvalAPIError;
75
+ /**
76
+ * The reason why the sample generation was finished.
77
+ */
78
+ finish_reason: string;
79
+ /**
80
+ * An array of input messages.
81
+ */
82
+ input: Array<Sample.Input>;
83
+ /**
84
+ * The maximum number of tokens allowed for completion.
85
+ */
86
+ max_completion_tokens: number;
87
+ /**
88
+ * The model used for generating the sample.
89
+ */
90
+ model: string;
91
+ /**
92
+ * An array of output messages.
93
+ */
94
+ output: Array<Sample.Output>;
95
+ /**
96
+ * The seed used for generating the sample.
97
+ */
98
+ seed: number;
99
+ /**
100
+ * The sampling temperature used.
101
+ */
102
+ temperature: number;
103
+ /**
104
+ * The top_p value used for sampling.
105
+ */
106
+ top_p: number;
107
+ /**
108
+ * Token usage details for the sample.
109
+ */
110
+ usage: Sample.Usage;
111
+ }
112
+ namespace Sample {
113
+ /**
114
+ * An input message.
115
+ */
116
+ interface Input {
117
+ /**
118
+ * The content of the message.
119
+ */
120
+ content: string;
121
+ /**
122
+ * The role of the message sender (e.g., system, user, developer).
123
+ */
124
+ role: string;
125
+ }
126
+ interface Output {
127
+ /**
128
+ * The content of the message.
129
+ */
130
+ content?: string;
131
+ /**
132
+ * The role of the message (e.g. "system", "assistant", "user").
133
+ */
134
+ role?: string;
135
+ }
136
+ /**
137
+ * Token usage details for the sample.
138
+ */
139
+ interface Usage {
140
+ /**
141
+ * The number of tokens retrieved from cache.
142
+ */
143
+ cached_tokens: number;
144
+ /**
145
+ * The number of completion tokens generated.
146
+ */
147
+ completion_tokens: number;
148
+ /**
149
+ * The number of prompt tokens used.
150
+ */
151
+ prompt_tokens: number;
152
+ /**
153
+ * The total number of tokens used.
154
+ */
155
+ total_tokens: number;
156
+ }
157
+ }
158
+ }
159
+ /**
160
+ * A schema representing an evaluation run output item.
161
+ */
162
+ export interface OutputItemListResponse {
163
+ /**
164
+ * Unique identifier for the evaluation run output item.
165
+ */
166
+ id: string;
167
+ /**
168
+ * Unix timestamp (in seconds) when the evaluation run was created.
169
+ */
170
+ created_at: number;
171
+ /**
172
+ * Details of the input data source item.
173
+ */
174
+ datasource_item: {
175
+ [key: string]: unknown;
176
+ };
177
+ /**
178
+ * The identifier for the data source item.
179
+ */
180
+ datasource_item_id: number;
181
+ /**
182
+ * The identifier of the evaluation group.
183
+ */
184
+ eval_id: string;
185
+ /**
186
+ * The type of the object. Always "eval.run.output_item".
187
+ */
188
+ object: 'eval.run.output_item';
189
+ /**
190
+ * A list of results from the evaluation run.
191
+ */
192
+ results: Array<{
193
+ [key: string]: unknown;
194
+ }>;
195
+ /**
196
+ * The identifier of the evaluation run associated with this output item.
197
+ */
198
+ run_id: string;
199
+ /**
200
+ * A sample containing the input and output of the evaluation run.
201
+ */
202
+ sample: OutputItemListResponse.Sample;
203
+ /**
204
+ * The status of the evaluation run.
205
+ */
206
+ status: string;
207
+ }
208
+ export declare namespace OutputItemListResponse {
209
+ /**
210
+ * A sample containing the input and output of the evaluation run.
211
+ */
212
+ interface Sample {
213
+ /**
214
+ * An object representing an error response from the Eval API.
215
+ */
216
+ error: RunsAPI.EvalAPIError;
217
+ /**
218
+ * The reason why the sample generation was finished.
219
+ */
220
+ finish_reason: string;
221
+ /**
222
+ * An array of input messages.
223
+ */
224
+ input: Array<Sample.Input>;
225
+ /**
226
+ * The maximum number of tokens allowed for completion.
227
+ */
228
+ max_completion_tokens: number;
229
+ /**
230
+ * The model used for generating the sample.
231
+ */
232
+ model: string;
233
+ /**
234
+ * An array of output messages.
235
+ */
236
+ output: Array<Sample.Output>;
237
+ /**
238
+ * The seed used for generating the sample.
239
+ */
240
+ seed: number;
241
+ /**
242
+ * The sampling temperature used.
243
+ */
244
+ temperature: number;
245
+ /**
246
+ * The top_p value used for sampling.
247
+ */
248
+ top_p: number;
249
+ /**
250
+ * Token usage details for the sample.
251
+ */
252
+ usage: Sample.Usage;
253
+ }
254
+ namespace Sample {
255
+ /**
256
+ * An input message.
257
+ */
258
+ interface Input {
259
+ /**
260
+ * The content of the message.
261
+ */
262
+ content: string;
263
+ /**
264
+ * The role of the message sender (e.g., system, user, developer).
265
+ */
266
+ role: string;
267
+ }
268
+ interface Output {
269
+ /**
270
+ * The content of the message.
271
+ */
272
+ content?: string;
273
+ /**
274
+ * The role of the message (e.g. "system", "assistant", "user").
275
+ */
276
+ role?: string;
277
+ }
278
+ /**
279
+ * Token usage details for the sample.
280
+ */
281
+ interface Usage {
282
+ /**
283
+ * The number of tokens retrieved from cache.
284
+ */
285
+ cached_tokens: number;
286
+ /**
287
+ * The number of completion tokens generated.
288
+ */
289
+ completion_tokens: number;
290
+ /**
291
+ * The number of prompt tokens used.
292
+ */
293
+ prompt_tokens: number;
294
+ /**
295
+ * The total number of tokens used.
296
+ */
297
+ total_tokens: number;
298
+ }
299
+ }
300
+ }
301
+ export interface OutputItemRetrieveParams {
302
+ /**
303
+ * The ID of the evaluation to retrieve runs for.
304
+ */
305
+ eval_id: string;
306
+ /**
307
+ * The ID of the run to retrieve.
308
+ */
309
+ run_id: string;
310
+ }
311
+ export interface OutputItemListParams extends CursorPageParams {
312
+ /**
313
+ * Path param: The ID of the evaluation to retrieve runs for.
314
+ */
315
+ eval_id: string;
316
+ /**
317
+ * Query param: Sort order for output items by timestamp. Use `asc` for ascending
318
+ * order or `desc` for descending order. Defaults to `asc`.
319
+ */
320
+ order?: 'asc' | 'desc';
321
+ /**
322
+ * Query param: Filter output items by status. Use `failed` to filter by failed
323
+ * output items or `pass` to filter by passed output items.
324
+ */
325
+ status?: 'fail' | 'pass';
326
+ }
327
+ export declare namespace OutputItems {
328
+ export { type OutputItemRetrieveResponse as OutputItemRetrieveResponse, type OutputItemListResponse as OutputItemListResponse, type OutputItemListResponsesPage as OutputItemListResponsesPage, type OutputItemRetrieveParams as OutputItemRetrieveParams, type OutputItemListParams as OutputItemListParams, };
329
+ }
330
+ //# sourceMappingURL=output-items.d.mts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.d.ts ADDED
@@ -0,0 +1,330 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import * as RunsAPI from "./runs.js";
3
+ import { APIPromise } from "../../../core/api-promise.js";
4
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.js";
5
+ import { RequestOptions } from "../../../internal/request-options.js";
6
+ export declare class OutputItems extends APIResource {
7
+ /**
8
+ * Get an evaluation run output item by ID.
9
+ */
10
+ retrieve(outputItemID: string, params: OutputItemRetrieveParams, options?: RequestOptions): APIPromise<OutputItemRetrieveResponse>;
11
+ /**
12
+ * Get a list of output items for an evaluation run.
13
+ */
14
+ list(runID: string, params: OutputItemListParams, options?: RequestOptions): PagePromise<OutputItemListResponsesPage, OutputItemListResponse>;
15
+ }
16
+ export type OutputItemListResponsesPage = CursorPage<OutputItemListResponse>;
17
+ /**
18
+ * A schema representing an evaluation run output item.
19
+ */
20
+ export interface OutputItemRetrieveResponse {
21
+ /**
22
+ * Unique identifier for the evaluation run output item.
23
+ */
24
+ id: string;
25
+ /**
26
+ * Unix timestamp (in seconds) when the evaluation run was created.
27
+ */
28
+ created_at: number;
29
+ /**
30
+ * Details of the input data source item.
31
+ */
32
+ datasource_item: {
33
+ [key: string]: unknown;
34
+ };
35
+ /**
36
+ * The identifier for the data source item.
37
+ */
38
+ datasource_item_id: number;
39
+ /**
40
+ * The identifier of the evaluation group.
41
+ */
42
+ eval_id: string;
43
+ /**
44
+ * The type of the object. Always "eval.run.output_item".
45
+ */
46
+ object: 'eval.run.output_item';
47
+ /**
48
+ * A list of results from the evaluation run.
49
+ */
50
+ results: Array<{
51
+ [key: string]: unknown;
52
+ }>;
53
+ /**
54
+ * The identifier of the evaluation run associated with this output item.
55
+ */
56
+ run_id: string;
57
+ /**
58
+ * A sample containing the input and output of the evaluation run.
59
+ */
60
+ sample: OutputItemRetrieveResponse.Sample;
61
+ /**
62
+ * The status of the evaluation run.
63
+ */
64
+ status: string;
65
+ }
66
+ export declare namespace OutputItemRetrieveResponse {
67
+ /**
68
+ * A sample containing the input and output of the evaluation run.
69
+ */
70
+ interface Sample {
71
+ /**
72
+ * An object representing an error response from the Eval API.
73
+ */
74
+ error: RunsAPI.EvalAPIError;
75
+ /**
76
+ * The reason why the sample generation was finished.
77
+ */
78
+ finish_reason: string;
79
+ /**
80
+ * An array of input messages.
81
+ */
82
+ input: Array<Sample.Input>;
83
+ /**
84
+ * The maximum number of tokens allowed for completion.
85
+ */
86
+ max_completion_tokens: number;
87
+ /**
88
+ * The model used for generating the sample.
89
+ */
90
+ model: string;
91
+ /**
92
+ * An array of output messages.
93
+ */
94
+ output: Array<Sample.Output>;
95
+ /**
96
+ * The seed used for generating the sample.
97
+ */
98
+ seed: number;
99
+ /**
100
+ * The sampling temperature used.
101
+ */
102
+ temperature: number;
103
+ /**
104
+ * The top_p value used for sampling.
105
+ */
106
+ top_p: number;
107
+ /**
108
+ * Token usage details for the sample.
109
+ */
110
+ usage: Sample.Usage;
111
+ }
112
+ namespace Sample {
113
+ /**
114
+ * An input message.
115
+ */
116
+ interface Input {
117
+ /**
118
+ * The content of the message.
119
+ */
120
+ content: string;
121
+ /**
122
+ * The role of the message sender (e.g., system, user, developer).
123
+ */
124
+ role: string;
125
+ }
126
+ interface Output {
127
+ /**
128
+ * The content of the message.
129
+ */
130
+ content?: string;
131
+ /**
132
+ * The role of the message (e.g. "system", "assistant", "user").
133
+ */
134
+ role?: string;
135
+ }
136
+ /**
137
+ * Token usage details for the sample.
138
+ */
139
+ interface Usage {
140
+ /**
141
+ * The number of tokens retrieved from cache.
142
+ */
143
+ cached_tokens: number;
144
+ /**
145
+ * The number of completion tokens generated.
146
+ */
147
+ completion_tokens: number;
148
+ /**
149
+ * The number of prompt tokens used.
150
+ */
151
+ prompt_tokens: number;
152
+ /**
153
+ * The total number of tokens used.
154
+ */
155
+ total_tokens: number;
156
+ }
157
+ }
158
+ }
159
+ /**
160
+ * A schema representing an evaluation run output item.
161
+ */
162
+ export interface OutputItemListResponse {
163
+ /**
164
+ * Unique identifier for the evaluation run output item.
165
+ */
166
+ id: string;
167
+ /**
168
+ * Unix timestamp (in seconds) when the evaluation run was created.
169
+ */
170
+ created_at: number;
171
+ /**
172
+ * Details of the input data source item.
173
+ */
174
+ datasource_item: {
175
+ [key: string]: unknown;
176
+ };
177
+ /**
178
+ * The identifier for the data source item.
179
+ */
180
+ datasource_item_id: number;
181
+ /**
182
+ * The identifier of the evaluation group.
183
+ */
184
+ eval_id: string;
185
+ /**
186
+ * The type of the object. Always "eval.run.output_item".
187
+ */
188
+ object: 'eval.run.output_item';
189
+ /**
190
+ * A list of results from the evaluation run.
191
+ */
192
+ results: Array<{
193
+ [key: string]: unknown;
194
+ }>;
195
+ /**
196
+ * The identifier of the evaluation run associated with this output item.
197
+ */
198
+ run_id: string;
199
+ /**
200
+ * A sample containing the input and output of the evaluation run.
201
+ */
202
+ sample: OutputItemListResponse.Sample;
203
+ /**
204
+ * The status of the evaluation run.
205
+ */
206
+ status: string;
207
+ }
208
+ export declare namespace OutputItemListResponse {
209
+ /**
210
+ * A sample containing the input and output of the evaluation run.
211
+ */
212
+ interface Sample {
213
+ /**
214
+ * An object representing an error response from the Eval API.
215
+ */
216
+ error: RunsAPI.EvalAPIError;
217
+ /**
218
+ * The reason why the sample generation was finished.
219
+ */
220
+ finish_reason: string;
221
+ /**
222
+ * An array of input messages.
223
+ */
224
+ input: Array<Sample.Input>;
225
+ /**
226
+ * The maximum number of tokens allowed for completion.
227
+ */
228
+ max_completion_tokens: number;
229
+ /**
230
+ * The model used for generating the sample.
231
+ */
232
+ model: string;
233
+ /**
234
+ * An array of output messages.
235
+ */
236
+ output: Array<Sample.Output>;
237
+ /**
238
+ * The seed used for generating the sample.
239
+ */
240
+ seed: number;
241
+ /**
242
+ * The sampling temperature used.
243
+ */
244
+ temperature: number;
245
+ /**
246
+ * The top_p value used for sampling.
247
+ */
248
+ top_p: number;
249
+ /**
250
+ * Token usage details for the sample.
251
+ */
252
+ usage: Sample.Usage;
253
+ }
254
+ namespace Sample {
255
+ /**
256
+ * An input message.
257
+ */
258
+ interface Input {
259
+ /**
260
+ * The content of the message.
261
+ */
262
+ content: string;
263
+ /**
264
+ * The role of the message sender (e.g., system, user, developer).
265
+ */
266
+ role: string;
267
+ }
268
+ interface Output {
269
+ /**
270
+ * The content of the message.
271
+ */
272
+ content?: string;
273
+ /**
274
+ * The role of the message (e.g. "system", "assistant", "user").
275
+ */
276
+ role?: string;
277
+ }
278
+ /**
279
+ * Token usage details for the sample.
280
+ */
281
+ interface Usage {
282
+ /**
283
+ * The number of tokens retrieved from cache.
284
+ */
285
+ cached_tokens: number;
286
+ /**
287
+ * The number of completion tokens generated.
288
+ */
289
+ completion_tokens: number;
290
+ /**
291
+ * The number of prompt tokens used.
292
+ */
293
+ prompt_tokens: number;
294
+ /**
295
+ * The total number of tokens used.
296
+ */
297
+ total_tokens: number;
298
+ }
299
+ }
300
+ }
301
+ export interface OutputItemRetrieveParams {
302
+ /**
303
+ * The ID of the evaluation to retrieve runs for.
304
+ */
305
+ eval_id: string;
306
+ /**
307
+ * The ID of the run to retrieve.
308
+ */
309
+ run_id: string;
310
+ }
311
+ export interface OutputItemListParams extends CursorPageParams {
312
+ /**
313
+ * Path param: The ID of the evaluation to retrieve runs for.
314
+ */
315
+ eval_id: string;
316
+ /**
317
+ * Query param: Sort order for output items by timestamp. Use `asc` for ascending
318
+ * order or `desc` for descending order. Defaults to `asc`.
319
+ */
320
+ order?: 'asc' | 'desc';
321
+ /**
322
+ * Query param: Filter output items by status. Use `failed` to filter by failed
323
+ * output items or `pass` to filter by passed output items.
324
+ */
325
+ status?: 'fail' | 'pass';
326
+ }
327
+ export declare namespace OutputItems {
328
+ export { type OutputItemRetrieveResponse as OutputItemRetrieveResponse, type OutputItemListResponse as OutputItemListResponse, type OutputItemListResponsesPage as OutputItemListResponsesPage, type OutputItemRetrieveParams as OutputItemRetrieveParams, type OutputItemListParams as OutputItemListParams, };
329
+ }
330
+ //# sourceMappingURL=output-items.d.ts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.js ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.OutputItems = void 0;
5
+ const resource_1 = require("../../../core/resource.js");
6
+ const pagination_1 = require("../../../core/pagination.js");
7
+ const path_1 = require("../../../internal/utils/path.js");
8
+ class OutputItems extends resource_1.APIResource {
9
+ /**
10
+ * Get an evaluation run output item by ID.
11
+ */
12
+ retrieve(outputItemID, params, options) {
13
+ const { eval_id, run_id } = params;
14
+ return this._client.get((0, path_1.path) `/evals/${eval_id}/runs/${run_id}/output_items/${outputItemID}`, options);
15
+ }
16
+ /**
17
+ * Get a list of output items for an evaluation run.
18
+ */
19
+ list(runID, params, options) {
20
+ const { eval_id, ...query } = params;
21
+ return this._client.getAPIList((0, path_1.path) `/evals/${eval_id}/runs/${runID}/output_items`, (pagination_1.CursorPage), { query, ...options });
22
+ }
23
+ }
24
+ exports.OutputItems = OutputItems;
25
+ //# sourceMappingURL=output-items.js.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.js.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"output-items.js","sourceRoot":"","sources":["../../../src/resources/evals/runs/output-items.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAGrD,4DAA0F;AAE1F,0DAAoD;AAEpD,MAAa,WAAY,SAAQ,sBAAW;IAC1C;;OAEG;IACH,QAAQ,CACN,YAAoB,EACpB,MAAgC,EAChC,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC;QACnC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,UAAU,OAAO,SAAS,MAAM,iBAAiB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IACxG,CAAC;IAED;;OAEG;IACH,IAAI,CACF,KAAa,EACb,MAA4B,EAC5B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QACrC,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAC5B,IAAA,WAAI,EAAA,UAAU,OAAO,SAAS,KAAK,eAAe,EAClD,CAAA,uBAAkC,CAAA,EAClC,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CACtB,CAAC;IACJ,CAAC;CACF;AA5BD,kCA4BC"}
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.mjs ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../../core/resource.mjs";
3
+ import { CursorPage } from "../../../core/pagination.mjs";
4
+ import { path } from "../../../internal/utils/path.mjs";
5
+ export class OutputItems extends APIResource {
6
+ /**
7
+ * Get an evaluation run output item by ID.
8
+ */
9
+ retrieve(outputItemID, params, options) {
10
+ const { eval_id, run_id } = params;
11
+ return this._client.get(path `/evals/${eval_id}/runs/${run_id}/output_items/${outputItemID}`, options);
12
+ }
13
+ /**
14
+ * Get a list of output items for an evaluation run.
15
+ */
16
+ list(runID, params, options) {
17
+ const { eval_id, ...query } = params;
18
+ return this._client.getAPIList(path `/evals/${eval_id}/runs/${runID}/output_items`, (CursorPage), { query, ...options });
19
+ }
20
+ }
21
+ //# sourceMappingURL=output-items.mjs.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/output-items.mjs.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"output-items.mjs","sourceRoot":"","sources":["../../../src/resources/evals/runs/output-items.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,UAAU,EAAsC;OAElD,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,WAAY,SAAQ,WAAW;IAC1C;;OAEG;IACH,QAAQ,CACN,YAAoB,EACpB,MAAgC,EAChC,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC;QACnC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,UAAU,OAAO,SAAS,MAAM,iBAAiB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IACxG,CAAC;IAED;;OAEG;IACH,IAAI,CACF,KAAa,EACb,MAA4B,EAC5B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QACrC,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAC5B,IAAI,CAAA,UAAU,OAAO,SAAS,KAAK,eAAe,EAClD,CAAA,UAAkC,CAAA,EAClC,EA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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import * as Shared from "../../shared.mjs";
3
+ import * as ResponsesAPI from "../../responses/responses.mjs";
4
+ import * as CompletionsAPI from "../../chat/completions/completions.mjs";
5
+ import * as OutputItemsAPI from "./output-items.mjs";
6
+ import { OutputItemListParams, OutputItemListResponse, OutputItemListResponsesPage, OutputItemRetrieveParams, OutputItemRetrieveResponse, OutputItems } from "./output-items.mjs";
7
+ import { APIPromise } from "../../../core/api-promise.mjs";
8
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../../core/pagination.mjs";
9
+ import { RequestOptions } from "../../../internal/request-options.mjs";
10
+ export declare class Runs extends APIResource {
11
+ outputItems: OutputItemsAPI.OutputItems;
12
+ /**
13
+ * Kicks off a new run for a given evaluation, specifying the data source, and what
14
+ * model configuration to use to test. The datasource will be validated against the
15
+ * schema specified in the config of the evaluation.
16
+ */
17
+ create(evalID: string, body: RunCreateParams, options?: RequestOptions): APIPromise<RunCreateResponse>;
18
+ /**
19
+ * Get an evaluation run by ID.
20
+ */
21
+ retrieve(runID: string, params: RunRetrieveParams, options?: RequestOptions): APIPromise<RunRetrieveResponse>;
22
+ /**
23
+ * Get a list of runs for an evaluation.
24
+ */
25
+ list(evalID: string, query?: RunListParams | null | undefined, options?: RequestOptions): PagePromise<RunListResponsesPage, RunListResponse>;
26
+ /**
27
+ * Delete an eval run.
28
+ */
29
+ delete(runID: string, params: RunDeleteParams, options?: RequestOptions): APIPromise<RunDeleteResponse>;
30
+ /**
31
+ * Cancel an ongoing evaluation run.
32
+ */
33
+ cancel(runID: string, params: RunCancelParams, options?: RequestOptions): APIPromise<RunCancelResponse>;
34
+ }
35
+ export type RunListResponsesPage = CursorPage<RunListResponse>;
36
+ /**
37
+ * A CompletionsRunDataSource object describing a model sampling configuration.
38
+ */
39
+ export interface CreateEvalCompletionsRunDataSource {
40
+ /**
41
+ * Determines what populates the `item` namespace in this run's data source.
42
+ */
43
+ source: CreateEvalCompletionsRunDataSource.FileContent | CreateEvalCompletionsRunDataSource.FileID | CreateEvalCompletionsRunDataSource.StoredCompletions;
44
+ /**
45
+ * The type of run data source. Always `completions`.
46
+ */
47
+ type: 'completions';
48
+ /**
49
+ * Used when sampling from a model. Dictates the structure of the messages passed
50
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
51
+ * `item.input_trajectory`), or a template with variable references to the `item`
52
+ * namespace.
53
+ */
54
+ input_messages?: CreateEvalCompletionsRunDataSource.Template | CreateEvalCompletionsRunDataSource.ItemReference;
55
+ /**
56
+ * The name of the model to use for generating completions (e.g. "o3-mini").
57
+ */
58
+ model?: string;
59
+ sampling_params?: CreateEvalCompletionsRunDataSource.SamplingParams;
60
+ }
61
+ export declare namespace CreateEvalCompletionsRunDataSource {
62
+ interface FileContent {
63
+ /**
64
+ * The content of the jsonl file.
65
+ */
66
+ content: Array<FileContent.Content>;
67
+ /**
68
+ * The type of jsonl source. Always `file_content`.
69
+ */
70
+ type: 'file_content';
71
+ }
72
+ namespace FileContent {
73
+ interface Content {
74
+ item: {
75
+ [key: string]: unknown;
76
+ };
77
+ sample?: {
78
+ [key: string]: unknown;
79
+ };
80
+ }
81
+ }
82
+ interface FileID {
83
+ /**
84
+ * The identifier of the file.
85
+ */
86
+ id: string;
87
+ /**
88
+ * The type of jsonl source. Always `file_id`.
89
+ */
90
+ type: 'file_id';
91
+ }
92
+ /**
93
+ * A StoredCompletionsRunDataSource configuration describing a set of filters
94
+ */
95
+ interface StoredCompletions {
96
+ /**
97
+ * The type of source. Always `stored_completions`.
98
+ */
99
+ type: 'stored_completions';
100
+ /**
101
+ * An optional Unix timestamp to filter items created after this time.
102
+ */
103
+ created_after?: number | null;
104
+ /**
105
+ * An optional Unix timestamp to filter items created before this time.
106
+ */
107
+ created_before?: number | null;
108
+ /**
109
+ * An optional maximum number of items to return.
110
+ */
111
+ limit?: number | null;
112
+ /**
113
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
114
+ * for storing additional information about the object in a structured format, and
115
+ * querying for objects via API or the dashboard.
116
+ *
117
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
118
+ * a maximum length of 512 characters.
119
+ */
120
+ metadata?: Shared.Metadata | null;
121
+ /**
122
+ * An optional model to filter by (e.g., 'gpt-4o').
123
+ */
124
+ model?: string | null;
125
+ }
126
+ interface Template {
127
+ /**
128
+ * A list of chat messages forming the prompt or context. May include variable
129
+ * references to the `item` namespace, ie {{item.name}}.
130
+ */
131
+ template: Array<ResponsesAPI.EasyInputMessage | Template.EvalItem>;
132
+ /**
133
+ * The type of input messages. Always `template`.
134
+ */
135
+ type: 'template';
136
+ }
137
+ namespace Template {
138
+ /**
139
+ * A message input to the model with a role indicating instruction following
140
+ * hierarchy. Instructions given with the `developer` or `system` role take
141
+ * precedence over instructions given with the `user` role. Messages with the
142
+ * `assistant` role are presumed to have been generated by the model in previous
143
+ * interactions.
144
+ */
145
+ interface EvalItem {
146
+ /**
147
+ * Inputs to the model - can contain template strings.
148
+ */
149
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
150
+ /**
151
+ * The role of the message input. One of `user`, `assistant`, `system`, or
152
+ * `developer`.
153
+ */
154
+ role: 'user' | 'assistant' | 'system' | 'developer';
155
+ /**
156
+ * The type of the message input. Always `message`.
157
+ */
158
+ type?: 'message';
159
+ }
160
+ namespace EvalItem {
161
+ /**
162
+ * A text output from the model.
163
+ */
164
+ interface OutputText {
165
+ /**
166
+ * The text output from the model.
167
+ */
168
+ text: string;
169
+ /**
170
+ * The type of the output text. Always `output_text`.
171
+ */
172
+ type: 'output_text';
173
+ }
174
+ /**
175
+ * An image input to the model.
176
+ */
177
+ interface InputImage {
178
+ /**
179
+ * The URL of the image input.
180
+ */
181
+ image_url: string;
182
+ /**
183
+ * The type of the image input. Always `input_image`.
184
+ */
185
+ type: 'input_image';
186
+ /**
187
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
188
+ * `auto`. Defaults to `auto`.
189
+ */
190
+ detail?: string;
191
+ }
192
+ }
193
+ }
194
+ interface ItemReference {
195
+ /**
196
+ * A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"
197
+ */
198
+ item_reference: string;
199
+ /**
200
+ * The type of input messages. Always `item_reference`.
201
+ */
202
+ type: 'item_reference';
203
+ }
204
+ interface SamplingParams {
205
+ /**
206
+ * The maximum number of tokens in the generated output.
207
+ */
208
+ max_completion_tokens?: number;
209
+ /**
210
+ * An object specifying the format that the model must output.
211
+ *
212
+ * Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured
213
+ * Outputs which ensures the model will match your supplied JSON schema. Learn more
214
+ * in the
215
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
216
+ *
217
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
218
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
219
+ * preferred for models that support it.
220
+ */
221
+ response_format?: Shared.ResponseFormatText | Shared.ResponseFormatJSONSchema | Shared.ResponseFormatJSONObject;
222
+ /**
223
+ * A seed value to initialize the randomness, during sampling.
224
+ */
225
+ seed?: number;
226
+ /**
227
+ * A higher temperature increases randomness in the outputs.
228
+ */
229
+ temperature?: number;
230
+ /**
231
+ * A list of tools the model may call. Currently, only functions are supported as a
232
+ * tool. Use this to provide a list of functions the model may generate JSON inputs
233
+ * for. A max of 128 functions are supported.
234
+ */
235
+ tools?: Array<CompletionsAPI.ChatCompletionFunctionTool>;
236
+ /**
237
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
238
+ */
239
+ top_p?: number;
240
+ }
241
+ }
242
+ /**
243
+ * A JsonlRunDataSource object with that specifies a JSONL file that matches the
244
+ * eval
245
+ */
246
+ export interface CreateEvalJSONLRunDataSource {
247
+ /**
248
+ * Determines what populates the `item` namespace in the data source.
249
+ */
250
+ source: CreateEvalJSONLRunDataSource.FileContent | CreateEvalJSONLRunDataSource.FileID;
251
+ /**
252
+ * The type of data source. Always `jsonl`.
253
+ */
254
+ type: 'jsonl';
255
+ }
256
+ export declare namespace CreateEvalJSONLRunDataSource {
257
+ interface FileContent {
258
+ /**
259
+ * The content of the jsonl file.
260
+ */
261
+ content: Array<FileContent.Content>;
262
+ /**
263
+ * The type of jsonl source. Always `file_content`.
264
+ */
265
+ type: 'file_content';
266
+ }
267
+ namespace FileContent {
268
+ interface Content {
269
+ item: {
270
+ [key: string]: unknown;
271
+ };
272
+ sample?: {
273
+ [key: string]: unknown;
274
+ };
275
+ }
276
+ }
277
+ interface FileID {
278
+ /**
279
+ * The identifier of the file.
280
+ */
281
+ id: string;
282
+ /**
283
+ * The type of jsonl source. Always `file_id`.
284
+ */
285
+ type: 'file_id';
286
+ }
287
+ }
288
+ /**
289
+ * An object representing an error response from the Eval API.
290
+ */
291
+ export interface EvalAPIError {
292
+ /**
293
+ * The error code.
294
+ */
295
+ code: string;
296
+ /**
297
+ * The error message.
298
+ */
299
+ message: string;
300
+ }
301
+ /**
302
+ * A schema representing an evaluation run.
303
+ */
304
+ export interface RunCreateResponse {
305
+ /**
306
+ * Unique identifier for the evaluation run.
307
+ */
308
+ id: string;
309
+ /**
310
+ * Unix timestamp (in seconds) when the evaluation run was created.
311
+ */
312
+ created_at: number;
313
+ /**
314
+ * Information about the run's data source.
315
+ */
316
+ data_source: CreateEvalJSONLRunDataSource | CreateEvalCompletionsRunDataSource | RunCreateResponse.Responses;
317
+ /**
318
+ * An object representing an error response from the Eval API.
319
+ */
320
+ error: EvalAPIError;
321
+ /**
322
+ * The identifier of the associated evaluation.
323
+ */
324
+ eval_id: string;
325
+ /**
326
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
327
+ * for storing additional information about the object in a structured format, and
328
+ * querying for objects via API or the dashboard.
329
+ *
330
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
331
+ * a maximum length of 512 characters.
332
+ */
333
+ metadata: Shared.Metadata | null;
334
+ /**
335
+ * The model that is evaluated, if applicable.
336
+ */
337
+ model: string;
338
+ /**
339
+ * The name of the evaluation run.
340
+ */
341
+ name: string;
342
+ /**
343
+ * The type of the object. Always "eval.run".
344
+ */
345
+ object: 'eval.run';
346
+ /**
347
+ * Usage statistics for each model during the evaluation run.
348
+ */
349
+ per_model_usage: Array<RunCreateResponse.PerModelUsage>;
350
+ /**
351
+ * Results per testing criteria applied during the evaluation run.
352
+ */
353
+ per_testing_criteria_results: Array<RunCreateResponse.PerTestingCriteriaResult>;
354
+ /**
355
+ * The URL to the rendered evaluation run report on the UI dashboard.
356
+ */
357
+ report_url: string;
358
+ /**
359
+ * Counters summarizing the outcomes of the evaluation run.
360
+ */
361
+ result_counts: RunCreateResponse.ResultCounts;
362
+ /**
363
+ * The status of the evaluation run.
364
+ */
365
+ status: string;
366
+ }
367
+ export declare namespace RunCreateResponse {
368
+ /**
369
+ * A ResponsesRunDataSource object describing a model sampling configuration.
370
+ */
371
+ interface Responses {
372
+ /**
373
+ * Determines what populates the `item` namespace in this run's data source.
374
+ */
375
+ source: Responses.FileContent | Responses.FileID | Responses.Responses;
376
+ /**
377
+ * The type of run data source. Always `responses`.
378
+ */
379
+ type: 'responses';
380
+ /**
381
+ * Used when sampling from a model. Dictates the structure of the messages passed
382
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
383
+ * `item.input_trajectory`), or a template with variable references to the `item`
384
+ * namespace.
385
+ */
386
+ input_messages?: Responses.Template | Responses.ItemReference;
387
+ /**
388
+ * The name of the model to use for generating completions (e.g. "o3-mini").
389
+ */
390
+ model?: string;
391
+ sampling_params?: Responses.SamplingParams;
392
+ }
393
+ namespace Responses {
394
+ interface FileContent {
395
+ /**
396
+ * The content of the jsonl file.
397
+ */
398
+ content: Array<FileContent.Content>;
399
+ /**
400
+ * The type of jsonl source. Always `file_content`.
401
+ */
402
+ type: 'file_content';
403
+ }
404
+ namespace FileContent {
405
+ interface Content {
406
+ item: {
407
+ [key: string]: unknown;
408
+ };
409
+ sample?: {
410
+ [key: string]: unknown;
411
+ };
412
+ }
413
+ }
414
+ interface FileID {
415
+ /**
416
+ * The identifier of the file.
417
+ */
418
+ id: string;
419
+ /**
420
+ * The type of jsonl source. Always `file_id`.
421
+ */
422
+ type: 'file_id';
423
+ }
424
+ /**
425
+ * A EvalResponsesSource object describing a run data source configuration.
426
+ */
427
+ interface Responses {
428
+ /**
429
+ * The type of run data source. Always `responses`.
430
+ */
431
+ type: 'responses';
432
+ /**
433
+ * Only include items created after this timestamp (inclusive). This is a query
434
+ * parameter used to select responses.
435
+ */
436
+ created_after?: number | null;
437
+ /**
438
+ * Only include items created before this timestamp (inclusive). This is a query
439
+ * parameter used to select responses.
440
+ */
441
+ created_before?: number | null;
442
+ /**
443
+ * Optional string to search the 'instructions' field. This is a query parameter
444
+ * used to select responses.
445
+ */
446
+ instructions_search?: string | null;
447
+ /**
448
+ * Metadata filter for the responses. This is a query parameter used to select
449
+ * responses.
450
+ */
451
+ metadata?: unknown | null;
452
+ /**
453
+ * The name of the model to find responses for. This is a query parameter used to
454
+ * select responses.
455
+ */
456
+ model?: string | null;
457
+ /**
458
+ * Optional reasoning effort parameter. This is a query parameter used to select
459
+ * responses.
460
+ */
461
+ reasoning_effort?: Shared.ReasoningEffort | null;
462
+ /**
463
+ * Sampling temperature. This is a query parameter used to select responses.
464
+ */
465
+ temperature?: number | null;
466
+ /**
467
+ * List of tool names. This is a query parameter used to select responses.
468
+ */
469
+ tools?: Array<string> | null;
470
+ /**
471
+ * Nucleus sampling parameter. This is a query parameter used to select responses.
472
+ */
473
+ top_p?: number | null;
474
+ /**
475
+ * List of user identifiers. This is a query parameter used to select responses.
476
+ */
477
+ users?: Array<string> | null;
478
+ }
479
+ interface Template {
480
+ /**
481
+ * A list of chat messages forming the prompt or context. May include variable
482
+ * references to the `item` namespace, ie {{item.name}}.
483
+ */
484
+ template: Array<Template.ChatMessage | Template.EvalItem>;
485
+ /**
486
+ * The type of input messages. Always `template`.
487
+ */
488
+ type: 'template';
489
+ }
490
+ namespace Template {
491
+ interface ChatMessage {
492
+ /**
493
+ * The content of the message.
494
+ */
495
+ content: string;
496
+ /**
497
+ * The role of the message (e.g. "system", "assistant", "user").
498
+ */
499
+ role: string;
500
+ }
501
+ /**
502
+ * A message input to the model with a role indicating instruction following
503
+ * hierarchy. Instructions given with the `developer` or `system` role take
504
+ * precedence over instructions given with the `user` role. Messages with the
505
+ * `assistant` role are presumed to have been generated by the model in previous
506
+ * interactions.
507
+ */
508
+ interface EvalItem {
509
+ /**
510
+ * Inputs to the model - can contain template strings.
511
+ */
512
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
513
+ /**
514
+ * The role of the message input. One of `user`, `assistant`, `system`, or
515
+ * `developer`.
516
+ */
517
+ role: 'user' | 'assistant' | 'system' | 'developer';
518
+ /**
519
+ * The type of the message input. Always `message`.
520
+ */
521
+ type?: 'message';
522
+ }
523
+ namespace EvalItem {
524
+ /**
525
+ * A text output from the model.
526
+ */
527
+ interface OutputText {
528
+ /**
529
+ * The text output from the model.
530
+ */
531
+ text: string;
532
+ /**
533
+ * The type of the output text. Always `output_text`.
534
+ */
535
+ type: 'output_text';
536
+ }
537
+ /**
538
+ * An image input to the model.
539
+ */
540
+ interface InputImage {
541
+ /**
542
+ * The URL of the image input.
543
+ */
544
+ image_url: string;
545
+ /**
546
+ * The type of the image input. Always `input_image`.
547
+ */
548
+ type: 'input_image';
549
+ /**
550
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
551
+ * `auto`. Defaults to `auto`.
552
+ */
553
+ detail?: string;
554
+ }
555
+ }
556
+ }
557
+ interface ItemReference {
558
+ /**
559
+ * A reference to a variable in the `item` namespace. Ie, "item.name"
560
+ */
561
+ item_reference: string;
562
+ /**
563
+ * The type of input messages. Always `item_reference`.
564
+ */
565
+ type: 'item_reference';
566
+ }
567
+ interface SamplingParams {
568
+ /**
569
+ * The maximum number of tokens in the generated output.
570
+ */
571
+ max_completion_tokens?: number;
572
+ /**
573
+ * A seed value to initialize the randomness, during sampling.
574
+ */
575
+ seed?: number;
576
+ /**
577
+ * A higher temperature increases randomness in the outputs.
578
+ */
579
+ temperature?: number;
580
+ /**
581
+ * Configuration options for a text response from the model. Can be plain text or
582
+ * structured JSON data. Learn more:
583
+ *
584
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
585
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
586
+ */
587
+ text?: SamplingParams.Text;
588
+ /**
589
+ * An array of tools the model may call while generating a response. You can
590
+ * specify which tool to use by setting the `tool_choice` parameter.
591
+ *
592
+ * The two categories of tools you can provide the model are:
593
+ *
594
+ * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
595
+ * capabilities, like
596
+ * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
597
+ * [file search](https://platform.openai.com/docs/guides/tools-file-search).
598
+ * Learn more about
599
+ * [built-in tools](https://platform.openai.com/docs/guides/tools).
600
+ * - **Function calls (custom tools)**: Functions that are defined by you, enabling
601
+ * the model to call your own code. Learn more about
602
+ * [function calling](https://platform.openai.com/docs/guides/function-calling).
603
+ */
604
+ tools?: Array<ResponsesAPI.Tool>;
605
+ /**
606
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
607
+ */
608
+ top_p?: number;
609
+ }
610
+ namespace SamplingParams {
611
+ /**
612
+ * Configuration options for a text response from the model. Can be plain text or
613
+ * structured JSON data. Learn more:
614
+ *
615
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
616
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
617
+ */
618
+ interface Text {
619
+ /**
620
+ * An object specifying the format that the model must output.
621
+ *
622
+ * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
623
+ * ensures the model will match your supplied JSON schema. Learn more in the
624
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
625
+ *
626
+ * The default format is `{ "type": "text" }` with no additional options.
627
+ *
628
+ * **Not recommended for gpt-4o and newer models:**
629
+ *
630
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
631
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
632
+ * preferred for models that support it.
633
+ */
634
+ format?: ResponsesAPI.ResponseFormatTextConfig;
635
+ }
636
+ }
637
+ }
638
+ interface PerModelUsage {
639
+ /**
640
+ * The number of tokens retrieved from cache.
641
+ */
642
+ cached_tokens: number;
643
+ /**
644
+ * The number of completion tokens generated.
645
+ */
646
+ completion_tokens: number;
647
+ /**
648
+ * The number of invocations.
649
+ */
650
+ invocation_count: number;
651
+ /**
652
+ * The name of the model.
653
+ */
654
+ model_name: string;
655
+ /**
656
+ * The number of prompt tokens used.
657
+ */
658
+ prompt_tokens: number;
659
+ /**
660
+ * The total number of tokens used.
661
+ */
662
+ total_tokens: number;
663
+ }
664
+ interface PerTestingCriteriaResult {
665
+ /**
666
+ * Number of tests failed for this criteria.
667
+ */
668
+ failed: number;
669
+ /**
670
+ * Number of tests passed for this criteria.
671
+ */
672
+ passed: number;
673
+ /**
674
+ * A description of the testing criteria.
675
+ */
676
+ testing_criteria: string;
677
+ }
678
+ /**
679
+ * Counters summarizing the outcomes of the evaluation run.
680
+ */
681
+ interface ResultCounts {
682
+ /**
683
+ * Number of output items that resulted in an error.
684
+ */
685
+ errored: number;
686
+ /**
687
+ * Number of output items that failed to pass the evaluation.
688
+ */
689
+ failed: number;
690
+ /**
691
+ * Number of output items that passed the evaluation.
692
+ */
693
+ passed: number;
694
+ /**
695
+ * Total number of executed output items.
696
+ */
697
+ total: number;
698
+ }
699
+ }
700
+ /**
701
+ * A schema representing an evaluation run.
702
+ */
703
+ export interface RunRetrieveResponse {
704
+ /**
705
+ * Unique identifier for the evaluation run.
706
+ */
707
+ id: string;
708
+ /**
709
+ * Unix timestamp (in seconds) when the evaluation run was created.
710
+ */
711
+ created_at: number;
712
+ /**
713
+ * Information about the run's data source.
714
+ */
715
+ data_source: CreateEvalJSONLRunDataSource | CreateEvalCompletionsRunDataSource | RunRetrieveResponse.Responses;
716
+ /**
717
+ * An object representing an error response from the Eval API.
718
+ */
719
+ error: EvalAPIError;
720
+ /**
721
+ * The identifier of the associated evaluation.
722
+ */
723
+ eval_id: string;
724
+ /**
725
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
726
+ * for storing additional information about the object in a structured format, and
727
+ * querying for objects via API or the dashboard.
728
+ *
729
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
730
+ * a maximum length of 512 characters.
731
+ */
732
+ metadata: Shared.Metadata | null;
733
+ /**
734
+ * The model that is evaluated, if applicable.
735
+ */
736
+ model: string;
737
+ /**
738
+ * The name of the evaluation run.
739
+ */
740
+ name: string;
741
+ /**
742
+ * The type of the object. Always "eval.run".
743
+ */
744
+ object: 'eval.run';
745
+ /**
746
+ * Usage statistics for each model during the evaluation run.
747
+ */
748
+ per_model_usage: Array<RunRetrieveResponse.PerModelUsage>;
749
+ /**
750
+ * Results per testing criteria applied during the evaluation run.
751
+ */
752
+ per_testing_criteria_results: Array<RunRetrieveResponse.PerTestingCriteriaResult>;
753
+ /**
754
+ * The URL to the rendered evaluation run report on the UI dashboard.
755
+ */
756
+ report_url: string;
757
+ /**
758
+ * Counters summarizing the outcomes of the evaluation run.
759
+ */
760
+ result_counts: RunRetrieveResponse.ResultCounts;
761
+ /**
762
+ * The status of the evaluation run.
763
+ */
764
+ status: string;
765
+ }
766
+ export declare namespace RunRetrieveResponse {
767
+ /**
768
+ * A ResponsesRunDataSource object describing a model sampling configuration.
769
+ */
770
+ interface Responses {
771
+ /**
772
+ * Determines what populates the `item` namespace in this run's data source.
773
+ */
774
+ source: Responses.FileContent | Responses.FileID | Responses.Responses;
775
+ /**
776
+ * The type of run data source. Always `responses`.
777
+ */
778
+ type: 'responses';
779
+ /**
780
+ * Used when sampling from a model. Dictates the structure of the messages passed
781
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
782
+ * `item.input_trajectory`), or a template with variable references to the `item`
783
+ * namespace.
784
+ */
785
+ input_messages?: Responses.Template | Responses.ItemReference;
786
+ /**
787
+ * The name of the model to use for generating completions (e.g. "o3-mini").
788
+ */
789
+ model?: string;
790
+ sampling_params?: Responses.SamplingParams;
791
+ }
792
+ namespace Responses {
793
+ interface FileContent {
794
+ /**
795
+ * The content of the jsonl file.
796
+ */
797
+ content: Array<FileContent.Content>;
798
+ /**
799
+ * The type of jsonl source. Always `file_content`.
800
+ */
801
+ type: 'file_content';
802
+ }
803
+ namespace FileContent {
804
+ interface Content {
805
+ item: {
806
+ [key: string]: unknown;
807
+ };
808
+ sample?: {
809
+ [key: string]: unknown;
810
+ };
811
+ }
812
+ }
813
+ interface FileID {
814
+ /**
815
+ * The identifier of the file.
816
+ */
817
+ id: string;
818
+ /**
819
+ * The type of jsonl source. Always `file_id`.
820
+ */
821
+ type: 'file_id';
822
+ }
823
+ /**
824
+ * A EvalResponsesSource object describing a run data source configuration.
825
+ */
826
+ interface Responses {
827
+ /**
828
+ * The type of run data source. Always `responses`.
829
+ */
830
+ type: 'responses';
831
+ /**
832
+ * Only include items created after this timestamp (inclusive). This is a query
833
+ * parameter used to select responses.
834
+ */
835
+ created_after?: number | null;
836
+ /**
837
+ * Only include items created before this timestamp (inclusive). This is a query
838
+ * parameter used to select responses.
839
+ */
840
+ created_before?: number | null;
841
+ /**
842
+ * Optional string to search the 'instructions' field. This is a query parameter
843
+ * used to select responses.
844
+ */
845
+ instructions_search?: string | null;
846
+ /**
847
+ * Metadata filter for the responses. This is a query parameter used to select
848
+ * responses.
849
+ */
850
+ metadata?: unknown | null;
851
+ /**
852
+ * The name of the model to find responses for. This is a query parameter used to
853
+ * select responses.
854
+ */
855
+ model?: string | null;
856
+ /**
857
+ * Optional reasoning effort parameter. This is a query parameter used to select
858
+ * responses.
859
+ */
860
+ reasoning_effort?: Shared.ReasoningEffort | null;
861
+ /**
862
+ * Sampling temperature. This is a query parameter used to select responses.
863
+ */
864
+ temperature?: number | null;
865
+ /**
866
+ * List of tool names. This is a query parameter used to select responses.
867
+ */
868
+ tools?: Array<string> | null;
869
+ /**
870
+ * Nucleus sampling parameter. This is a query parameter used to select responses.
871
+ */
872
+ top_p?: number | null;
873
+ /**
874
+ * List of user identifiers. This is a query parameter used to select responses.
875
+ */
876
+ users?: Array<string> | null;
877
+ }
878
+ interface Template {
879
+ /**
880
+ * A list of chat messages forming the prompt or context. May include variable
881
+ * references to the `item` namespace, ie {{item.name}}.
882
+ */
883
+ template: Array<Template.ChatMessage | Template.EvalItem>;
884
+ /**
885
+ * The type of input messages. Always `template`.
886
+ */
887
+ type: 'template';
888
+ }
889
+ namespace Template {
890
+ interface ChatMessage {
891
+ /**
892
+ * The content of the message.
893
+ */
894
+ content: string;
895
+ /**
896
+ * The role of the message (e.g. "system", "assistant", "user").
897
+ */
898
+ role: string;
899
+ }
900
+ /**
901
+ * A message input to the model with a role indicating instruction following
902
+ * hierarchy. Instructions given with the `developer` or `system` role take
903
+ * precedence over instructions given with the `user` role. Messages with the
904
+ * `assistant` role are presumed to have been generated by the model in previous
905
+ * interactions.
906
+ */
907
+ interface EvalItem {
908
+ /**
909
+ * Inputs to the model - can contain template strings.
910
+ */
911
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
912
+ /**
913
+ * The role of the message input. One of `user`, `assistant`, `system`, or
914
+ * `developer`.
915
+ */
916
+ role: 'user' | 'assistant' | 'system' | 'developer';
917
+ /**
918
+ * The type of the message input. Always `message`.
919
+ */
920
+ type?: 'message';
921
+ }
922
+ namespace EvalItem {
923
+ /**
924
+ * A text output from the model.
925
+ */
926
+ interface OutputText {
927
+ /**
928
+ * The text output from the model.
929
+ */
930
+ text: string;
931
+ /**
932
+ * The type of the output text. Always `output_text`.
933
+ */
934
+ type: 'output_text';
935
+ }
936
+ /**
937
+ * An image input to the model.
938
+ */
939
+ interface InputImage {
940
+ /**
941
+ * The URL of the image input.
942
+ */
943
+ image_url: string;
944
+ /**
945
+ * The type of the image input. Always `input_image`.
946
+ */
947
+ type: 'input_image';
948
+ /**
949
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
950
+ * `auto`. Defaults to `auto`.
951
+ */
952
+ detail?: string;
953
+ }
954
+ }
955
+ }
956
+ interface ItemReference {
957
+ /**
958
+ * A reference to a variable in the `item` namespace. Ie, "item.name"
959
+ */
960
+ item_reference: string;
961
+ /**
962
+ * The type of input messages. Always `item_reference`.
963
+ */
964
+ type: 'item_reference';
965
+ }
966
+ interface SamplingParams {
967
+ /**
968
+ * The maximum number of tokens in the generated output.
969
+ */
970
+ max_completion_tokens?: number;
971
+ /**
972
+ * A seed value to initialize the randomness, during sampling.
973
+ */
974
+ seed?: number;
975
+ /**
976
+ * A higher temperature increases randomness in the outputs.
977
+ */
978
+ temperature?: number;
979
+ /**
980
+ * Configuration options for a text response from the model. Can be plain text or
981
+ * structured JSON data. Learn more:
982
+ *
983
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
984
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
985
+ */
986
+ text?: SamplingParams.Text;
987
+ /**
988
+ * An array of tools the model may call while generating a response. You can
989
+ * specify which tool to use by setting the `tool_choice` parameter.
990
+ *
991
+ * The two categories of tools you can provide the model are:
992
+ *
993
+ * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
994
+ * capabilities, like
995
+ * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
996
+ * [file search](https://platform.openai.com/docs/guides/tools-file-search).
997
+ * Learn more about
998
+ * [built-in tools](https://platform.openai.com/docs/guides/tools).
999
+ * - **Function calls (custom tools)**: Functions that are defined by you, enabling
1000
+ * the model to call your own code. Learn more about
1001
+ * [function calling](https://platform.openai.com/docs/guides/function-calling).
1002
+ */
1003
+ tools?: Array<ResponsesAPI.Tool>;
1004
+ /**
1005
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
1006
+ */
1007
+ top_p?: number;
1008
+ }
1009
+ namespace SamplingParams {
1010
+ /**
1011
+ * Configuration options for a text response from the model. Can be plain text or
1012
+ * structured JSON data. Learn more:
1013
+ *
1014
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
1015
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1016
+ */
1017
+ interface Text {
1018
+ /**
1019
+ * An object specifying the format that the model must output.
1020
+ *
1021
+ * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
1022
+ * ensures the model will match your supplied JSON schema. Learn more in the
1023
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
1024
+ *
1025
+ * The default format is `{ "type": "text" }` with no additional options.
1026
+ *
1027
+ * **Not recommended for gpt-4o and newer models:**
1028
+ *
1029
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
1030
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
1031
+ * preferred for models that support it.
1032
+ */
1033
+ format?: ResponsesAPI.ResponseFormatTextConfig;
1034
+ }
1035
+ }
1036
+ }
1037
+ interface PerModelUsage {
1038
+ /**
1039
+ * The number of tokens retrieved from cache.
1040
+ */
1041
+ cached_tokens: number;
1042
+ /**
1043
+ * The number of completion tokens generated.
1044
+ */
1045
+ completion_tokens: number;
1046
+ /**
1047
+ * The number of invocations.
1048
+ */
1049
+ invocation_count: number;
1050
+ /**
1051
+ * The name of the model.
1052
+ */
1053
+ model_name: string;
1054
+ /**
1055
+ * The number of prompt tokens used.
1056
+ */
1057
+ prompt_tokens: number;
1058
+ /**
1059
+ * The total number of tokens used.
1060
+ */
1061
+ total_tokens: number;
1062
+ }
1063
+ interface PerTestingCriteriaResult {
1064
+ /**
1065
+ * Number of tests failed for this criteria.
1066
+ */
1067
+ failed: number;
1068
+ /**
1069
+ * Number of tests passed for this criteria.
1070
+ */
1071
+ passed: number;
1072
+ /**
1073
+ * A description of the testing criteria.
1074
+ */
1075
+ testing_criteria: string;
1076
+ }
1077
+ /**
1078
+ * Counters summarizing the outcomes of the evaluation run.
1079
+ */
1080
+ interface ResultCounts {
1081
+ /**
1082
+ * Number of output items that resulted in an error.
1083
+ */
1084
+ errored: number;
1085
+ /**
1086
+ * Number of output items that failed to pass the evaluation.
1087
+ */
1088
+ failed: number;
1089
+ /**
1090
+ * Number of output items that passed the evaluation.
1091
+ */
1092
+ passed: number;
1093
+ /**
1094
+ * Total number of executed output items.
1095
+ */
1096
+ total: number;
1097
+ }
1098
+ }
1099
+ /**
1100
+ * A schema representing an evaluation run.
1101
+ */
1102
+ export interface RunListResponse {
1103
+ /**
1104
+ * Unique identifier for the evaluation run.
1105
+ */
1106
+ id: string;
1107
+ /**
1108
+ * Unix timestamp (in seconds) when the evaluation run was created.
1109
+ */
1110
+ created_at: number;
1111
+ /**
1112
+ * Information about the run's data source.
1113
+ */
1114
+ data_source: CreateEvalJSONLRunDataSource | CreateEvalCompletionsRunDataSource | RunListResponse.Responses;
1115
+ /**
1116
+ * An object representing an error response from the Eval API.
1117
+ */
1118
+ error: EvalAPIError;
1119
+ /**
1120
+ * The identifier of the associated evaluation.
1121
+ */
1122
+ eval_id: string;
1123
+ /**
1124
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1125
+ * for storing additional information about the object in a structured format, and
1126
+ * querying for objects via API or the dashboard.
1127
+ *
1128
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1129
+ * a maximum length of 512 characters.
1130
+ */
1131
+ metadata: Shared.Metadata | null;
1132
+ /**
1133
+ * The model that is evaluated, if applicable.
1134
+ */
1135
+ model: string;
1136
+ /**
1137
+ * The name of the evaluation run.
1138
+ */
1139
+ name: string;
1140
+ /**
1141
+ * The type of the object. Always "eval.run".
1142
+ */
1143
+ object: 'eval.run';
1144
+ /**
1145
+ * Usage statistics for each model during the evaluation run.
1146
+ */
1147
+ per_model_usage: Array<RunListResponse.PerModelUsage>;
1148
+ /**
1149
+ * Results per testing criteria applied during the evaluation run.
1150
+ */
1151
+ per_testing_criteria_results: Array<RunListResponse.PerTestingCriteriaResult>;
1152
+ /**
1153
+ * The URL to the rendered evaluation run report on the UI dashboard.
1154
+ */
1155
+ report_url: string;
1156
+ /**
1157
+ * Counters summarizing the outcomes of the evaluation run.
1158
+ */
1159
+ result_counts: RunListResponse.ResultCounts;
1160
+ /**
1161
+ * The status of the evaluation run.
1162
+ */
1163
+ status: string;
1164
+ }
1165
+ export declare namespace RunListResponse {
1166
+ /**
1167
+ * A ResponsesRunDataSource object describing a model sampling configuration.
1168
+ */
1169
+ interface Responses {
1170
+ /**
1171
+ * Determines what populates the `item` namespace in this run's data source.
1172
+ */
1173
+ source: Responses.FileContent | Responses.FileID | Responses.Responses;
1174
+ /**
1175
+ * The type of run data source. Always `responses`.
1176
+ */
1177
+ type: 'responses';
1178
+ /**
1179
+ * Used when sampling from a model. Dictates the structure of the messages passed
1180
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
1181
+ * `item.input_trajectory`), or a template with variable references to the `item`
1182
+ * namespace.
1183
+ */
1184
+ input_messages?: Responses.Template | Responses.ItemReference;
1185
+ /**
1186
+ * The name of the model to use for generating completions (e.g. "o3-mini").
1187
+ */
1188
+ model?: string;
1189
+ sampling_params?: Responses.SamplingParams;
1190
+ }
1191
+ namespace Responses {
1192
+ interface FileContent {
1193
+ /**
1194
+ * The content of the jsonl file.
1195
+ */
1196
+ content: Array<FileContent.Content>;
1197
+ /**
1198
+ * The type of jsonl source. Always `file_content`.
1199
+ */
1200
+ type: 'file_content';
1201
+ }
1202
+ namespace FileContent {
1203
+ interface Content {
1204
+ item: {
1205
+ [key: string]: unknown;
1206
+ };
1207
+ sample?: {
1208
+ [key: string]: unknown;
1209
+ };
1210
+ }
1211
+ }
1212
+ interface FileID {
1213
+ /**
1214
+ * The identifier of the file.
1215
+ */
1216
+ id: string;
1217
+ /**
1218
+ * The type of jsonl source. Always `file_id`.
1219
+ */
1220
+ type: 'file_id';
1221
+ }
1222
+ /**
1223
+ * A EvalResponsesSource object describing a run data source configuration.
1224
+ */
1225
+ interface Responses {
1226
+ /**
1227
+ * The type of run data source. Always `responses`.
1228
+ */
1229
+ type: 'responses';
1230
+ /**
1231
+ * Only include items created after this timestamp (inclusive). This is a query
1232
+ * parameter used to select responses.
1233
+ */
1234
+ created_after?: number | null;
1235
+ /**
1236
+ * Only include items created before this timestamp (inclusive). This is a query
1237
+ * parameter used to select responses.
1238
+ */
1239
+ created_before?: number | null;
1240
+ /**
1241
+ * Optional string to search the 'instructions' field. This is a query parameter
1242
+ * used to select responses.
1243
+ */
1244
+ instructions_search?: string | null;
1245
+ /**
1246
+ * Metadata filter for the responses. This is a query parameter used to select
1247
+ * responses.
1248
+ */
1249
+ metadata?: unknown | null;
1250
+ /**
1251
+ * The name of the model to find responses for. This is a query parameter used to
1252
+ * select responses.
1253
+ */
1254
+ model?: string | null;
1255
+ /**
1256
+ * Optional reasoning effort parameter. This is a query parameter used to select
1257
+ * responses.
1258
+ */
1259
+ reasoning_effort?: Shared.ReasoningEffort | null;
1260
+ /**
1261
+ * Sampling temperature. This is a query parameter used to select responses.
1262
+ */
1263
+ temperature?: number | null;
1264
+ /**
1265
+ * List of tool names. This is a query parameter used to select responses.
1266
+ */
1267
+ tools?: Array<string> | null;
1268
+ /**
1269
+ * Nucleus sampling parameter. This is a query parameter used to select responses.
1270
+ */
1271
+ top_p?: number | null;
1272
+ /**
1273
+ * List of user identifiers. This is a query parameter used to select responses.
1274
+ */
1275
+ users?: Array<string> | null;
1276
+ }
1277
+ interface Template {
1278
+ /**
1279
+ * A list of chat messages forming the prompt or context. May include variable
1280
+ * references to the `item` namespace, ie {{item.name}}.
1281
+ */
1282
+ template: Array<Template.ChatMessage | Template.EvalItem>;
1283
+ /**
1284
+ * The type of input messages. Always `template`.
1285
+ */
1286
+ type: 'template';
1287
+ }
1288
+ namespace Template {
1289
+ interface ChatMessage {
1290
+ /**
1291
+ * The content of the message.
1292
+ */
1293
+ content: string;
1294
+ /**
1295
+ * The role of the message (e.g. "system", "assistant", "user").
1296
+ */
1297
+ role: string;
1298
+ }
1299
+ /**
1300
+ * A message input to the model with a role indicating instruction following
1301
+ * hierarchy. Instructions given with the `developer` or `system` role take
1302
+ * precedence over instructions given with the `user` role. Messages with the
1303
+ * `assistant` role are presumed to have been generated by the model in previous
1304
+ * interactions.
1305
+ */
1306
+ interface EvalItem {
1307
+ /**
1308
+ * Inputs to the model - can contain template strings.
1309
+ */
1310
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
1311
+ /**
1312
+ * The role of the message input. One of `user`, `assistant`, `system`, or
1313
+ * `developer`.
1314
+ */
1315
+ role: 'user' | 'assistant' | 'system' | 'developer';
1316
+ /**
1317
+ * The type of the message input. Always `message`.
1318
+ */
1319
+ type?: 'message';
1320
+ }
1321
+ namespace EvalItem {
1322
+ /**
1323
+ * A text output from the model.
1324
+ */
1325
+ interface OutputText {
1326
+ /**
1327
+ * The text output from the model.
1328
+ */
1329
+ text: string;
1330
+ /**
1331
+ * The type of the output text. Always `output_text`.
1332
+ */
1333
+ type: 'output_text';
1334
+ }
1335
+ /**
1336
+ * An image input to the model.
1337
+ */
1338
+ interface InputImage {
1339
+ /**
1340
+ * The URL of the image input.
1341
+ */
1342
+ image_url: string;
1343
+ /**
1344
+ * The type of the image input. Always `input_image`.
1345
+ */
1346
+ type: 'input_image';
1347
+ /**
1348
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
1349
+ * `auto`. Defaults to `auto`.
1350
+ */
1351
+ detail?: string;
1352
+ }
1353
+ }
1354
+ }
1355
+ interface ItemReference {
1356
+ /**
1357
+ * A reference to a variable in the `item` namespace. Ie, "item.name"
1358
+ */
1359
+ item_reference: string;
1360
+ /**
1361
+ * The type of input messages. Always `item_reference`.
1362
+ */
1363
+ type: 'item_reference';
1364
+ }
1365
+ interface SamplingParams {
1366
+ /**
1367
+ * The maximum number of tokens in the generated output.
1368
+ */
1369
+ max_completion_tokens?: number;
1370
+ /**
1371
+ * A seed value to initialize the randomness, during sampling.
1372
+ */
1373
+ seed?: number;
1374
+ /**
1375
+ * A higher temperature increases randomness in the outputs.
1376
+ */
1377
+ temperature?: number;
1378
+ /**
1379
+ * Configuration options for a text response from the model. Can be plain text or
1380
+ * structured JSON data. Learn more:
1381
+ *
1382
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
1383
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1384
+ */
1385
+ text?: SamplingParams.Text;
1386
+ /**
1387
+ * An array of tools the model may call while generating a response. You can
1388
+ * specify which tool to use by setting the `tool_choice` parameter.
1389
+ *
1390
+ * The two categories of tools you can provide the model are:
1391
+ *
1392
+ * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
1393
+ * capabilities, like
1394
+ * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
1395
+ * [file search](https://platform.openai.com/docs/guides/tools-file-search).
1396
+ * Learn more about
1397
+ * [built-in tools](https://platform.openai.com/docs/guides/tools).
1398
+ * - **Function calls (custom tools)**: Functions that are defined by you, enabling
1399
+ * the model to call your own code. Learn more about
1400
+ * [function calling](https://platform.openai.com/docs/guides/function-calling).
1401
+ */
1402
+ tools?: Array<ResponsesAPI.Tool>;
1403
+ /**
1404
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
1405
+ */
1406
+ top_p?: number;
1407
+ }
1408
+ namespace SamplingParams {
1409
+ /**
1410
+ * Configuration options for a text response from the model. Can be plain text or
1411
+ * structured JSON data. Learn more:
1412
+ *
1413
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
1414
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1415
+ */
1416
+ interface Text {
1417
+ /**
1418
+ * An object specifying the format that the model must output.
1419
+ *
1420
+ * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
1421
+ * ensures the model will match your supplied JSON schema. Learn more in the
1422
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
1423
+ *
1424
+ * The default format is `{ "type": "text" }` with no additional options.
1425
+ *
1426
+ * **Not recommended for gpt-4o and newer models:**
1427
+ *
1428
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
1429
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
1430
+ * preferred for models that support it.
1431
+ */
1432
+ format?: ResponsesAPI.ResponseFormatTextConfig;
1433
+ }
1434
+ }
1435
+ }
1436
+ interface PerModelUsage {
1437
+ /**
1438
+ * The number of tokens retrieved from cache.
1439
+ */
1440
+ cached_tokens: number;
1441
+ /**
1442
+ * The number of completion tokens generated.
1443
+ */
1444
+ completion_tokens: number;
1445
+ /**
1446
+ * The number of invocations.
1447
+ */
1448
+ invocation_count: number;
1449
+ /**
1450
+ * The name of the model.
1451
+ */
1452
+ model_name: string;
1453
+ /**
1454
+ * The number of prompt tokens used.
1455
+ */
1456
+ prompt_tokens: number;
1457
+ /**
1458
+ * The total number of tokens used.
1459
+ */
1460
+ total_tokens: number;
1461
+ }
1462
+ interface PerTestingCriteriaResult {
1463
+ /**
1464
+ * Number of tests failed for this criteria.
1465
+ */
1466
+ failed: number;
1467
+ /**
1468
+ * Number of tests passed for this criteria.
1469
+ */
1470
+ passed: number;
1471
+ /**
1472
+ * A description of the testing criteria.
1473
+ */
1474
+ testing_criteria: string;
1475
+ }
1476
+ /**
1477
+ * Counters summarizing the outcomes of the evaluation run.
1478
+ */
1479
+ interface ResultCounts {
1480
+ /**
1481
+ * Number of output items that resulted in an error.
1482
+ */
1483
+ errored: number;
1484
+ /**
1485
+ * Number of output items that failed to pass the evaluation.
1486
+ */
1487
+ failed: number;
1488
+ /**
1489
+ * Number of output items that passed the evaluation.
1490
+ */
1491
+ passed: number;
1492
+ /**
1493
+ * Total number of executed output items.
1494
+ */
1495
+ total: number;
1496
+ }
1497
+ }
1498
+ export interface RunDeleteResponse {
1499
+ deleted?: boolean;
1500
+ object?: string;
1501
+ run_id?: string;
1502
+ }
1503
+ /**
1504
+ * A schema representing an evaluation run.
1505
+ */
1506
+ export interface RunCancelResponse {
1507
+ /**
1508
+ * Unique identifier for the evaluation run.
1509
+ */
1510
+ id: string;
1511
+ /**
1512
+ * Unix timestamp (in seconds) when the evaluation run was created.
1513
+ */
1514
+ created_at: number;
1515
+ /**
1516
+ * Information about the run's data source.
1517
+ */
1518
+ data_source: CreateEvalJSONLRunDataSource | CreateEvalCompletionsRunDataSource | RunCancelResponse.Responses;
1519
+ /**
1520
+ * An object representing an error response from the Eval API.
1521
+ */
1522
+ error: EvalAPIError;
1523
+ /**
1524
+ * The identifier of the associated evaluation.
1525
+ */
1526
+ eval_id: string;
1527
+ /**
1528
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1529
+ * for storing additional information about the object in a structured format, and
1530
+ * querying for objects via API or the dashboard.
1531
+ *
1532
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1533
+ * a maximum length of 512 characters.
1534
+ */
1535
+ metadata: Shared.Metadata | null;
1536
+ /**
1537
+ * The model that is evaluated, if applicable.
1538
+ */
1539
+ model: string;
1540
+ /**
1541
+ * The name of the evaluation run.
1542
+ */
1543
+ name: string;
1544
+ /**
1545
+ * The type of the object. Always "eval.run".
1546
+ */
1547
+ object: 'eval.run';
1548
+ /**
1549
+ * Usage statistics for each model during the evaluation run.
1550
+ */
1551
+ per_model_usage: Array<RunCancelResponse.PerModelUsage>;
1552
+ /**
1553
+ * Results per testing criteria applied during the evaluation run.
1554
+ */
1555
+ per_testing_criteria_results: Array<RunCancelResponse.PerTestingCriteriaResult>;
1556
+ /**
1557
+ * The URL to the rendered evaluation run report on the UI dashboard.
1558
+ */
1559
+ report_url: string;
1560
+ /**
1561
+ * Counters summarizing the outcomes of the evaluation run.
1562
+ */
1563
+ result_counts: RunCancelResponse.ResultCounts;
1564
+ /**
1565
+ * The status of the evaluation run.
1566
+ */
1567
+ status: string;
1568
+ }
1569
+ export declare namespace RunCancelResponse {
1570
+ /**
1571
+ * A ResponsesRunDataSource object describing a model sampling configuration.
1572
+ */
1573
+ interface Responses {
1574
+ /**
1575
+ * Determines what populates the `item` namespace in this run's data source.
1576
+ */
1577
+ source: Responses.FileContent | Responses.FileID | Responses.Responses;
1578
+ /**
1579
+ * The type of run data source. Always `responses`.
1580
+ */
1581
+ type: 'responses';
1582
+ /**
1583
+ * Used when sampling from a model. Dictates the structure of the messages passed
1584
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
1585
+ * `item.input_trajectory`), or a template with variable references to the `item`
1586
+ * namespace.
1587
+ */
1588
+ input_messages?: Responses.Template | Responses.ItemReference;
1589
+ /**
1590
+ * The name of the model to use for generating completions (e.g. "o3-mini").
1591
+ */
1592
+ model?: string;
1593
+ sampling_params?: Responses.SamplingParams;
1594
+ }
1595
+ namespace Responses {
1596
+ interface FileContent {
1597
+ /**
1598
+ * The content of the jsonl file.
1599
+ */
1600
+ content: Array<FileContent.Content>;
1601
+ /**
1602
+ * The type of jsonl source. Always `file_content`.
1603
+ */
1604
+ type: 'file_content';
1605
+ }
1606
+ namespace FileContent {
1607
+ interface Content {
1608
+ item: {
1609
+ [key: string]: unknown;
1610
+ };
1611
+ sample?: {
1612
+ [key: string]: unknown;
1613
+ };
1614
+ }
1615
+ }
1616
+ interface FileID {
1617
+ /**
1618
+ * The identifier of the file.
1619
+ */
1620
+ id: string;
1621
+ /**
1622
+ * The type of jsonl source. Always `file_id`.
1623
+ */
1624
+ type: 'file_id';
1625
+ }
1626
+ /**
1627
+ * A EvalResponsesSource object describing a run data source configuration.
1628
+ */
1629
+ interface Responses {
1630
+ /**
1631
+ * The type of run data source. Always `responses`.
1632
+ */
1633
+ type: 'responses';
1634
+ /**
1635
+ * Only include items created after this timestamp (inclusive). This is a query
1636
+ * parameter used to select responses.
1637
+ */
1638
+ created_after?: number | null;
1639
+ /**
1640
+ * Only include items created before this timestamp (inclusive). This is a query
1641
+ * parameter used to select responses.
1642
+ */
1643
+ created_before?: number | null;
1644
+ /**
1645
+ * Optional string to search the 'instructions' field. This is a query parameter
1646
+ * used to select responses.
1647
+ */
1648
+ instructions_search?: string | null;
1649
+ /**
1650
+ * Metadata filter for the responses. This is a query parameter used to select
1651
+ * responses.
1652
+ */
1653
+ metadata?: unknown | null;
1654
+ /**
1655
+ * The name of the model to find responses for. This is a query parameter used to
1656
+ * select responses.
1657
+ */
1658
+ model?: string | null;
1659
+ /**
1660
+ * Optional reasoning effort parameter. This is a query parameter used to select
1661
+ * responses.
1662
+ */
1663
+ reasoning_effort?: Shared.ReasoningEffort | null;
1664
+ /**
1665
+ * Sampling temperature. This is a query parameter used to select responses.
1666
+ */
1667
+ temperature?: number | null;
1668
+ /**
1669
+ * List of tool names. This is a query parameter used to select responses.
1670
+ */
1671
+ tools?: Array<string> | null;
1672
+ /**
1673
+ * Nucleus sampling parameter. This is a query parameter used to select responses.
1674
+ */
1675
+ top_p?: number | null;
1676
+ /**
1677
+ * List of user identifiers. This is a query parameter used to select responses.
1678
+ */
1679
+ users?: Array<string> | null;
1680
+ }
1681
+ interface Template {
1682
+ /**
1683
+ * A list of chat messages forming the prompt or context. May include variable
1684
+ * references to the `item` namespace, ie {{item.name}}.
1685
+ */
1686
+ template: Array<Template.ChatMessage | Template.EvalItem>;
1687
+ /**
1688
+ * The type of input messages. Always `template`.
1689
+ */
1690
+ type: 'template';
1691
+ }
1692
+ namespace Template {
1693
+ interface ChatMessage {
1694
+ /**
1695
+ * The content of the message.
1696
+ */
1697
+ content: string;
1698
+ /**
1699
+ * The role of the message (e.g. "system", "assistant", "user").
1700
+ */
1701
+ role: string;
1702
+ }
1703
+ /**
1704
+ * A message input to the model with a role indicating instruction following
1705
+ * hierarchy. Instructions given with the `developer` or `system` role take
1706
+ * precedence over instructions given with the `user` role. Messages with the
1707
+ * `assistant` role are presumed to have been generated by the model in previous
1708
+ * interactions.
1709
+ */
1710
+ interface EvalItem {
1711
+ /**
1712
+ * Inputs to the model - can contain template strings.
1713
+ */
1714
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
1715
+ /**
1716
+ * The role of the message input. One of `user`, `assistant`, `system`, or
1717
+ * `developer`.
1718
+ */
1719
+ role: 'user' | 'assistant' | 'system' | 'developer';
1720
+ /**
1721
+ * The type of the message input. Always `message`.
1722
+ */
1723
+ type?: 'message';
1724
+ }
1725
+ namespace EvalItem {
1726
+ /**
1727
+ * A text output from the model.
1728
+ */
1729
+ interface OutputText {
1730
+ /**
1731
+ * The text output from the model.
1732
+ */
1733
+ text: string;
1734
+ /**
1735
+ * The type of the output text. Always `output_text`.
1736
+ */
1737
+ type: 'output_text';
1738
+ }
1739
+ /**
1740
+ * An image input to the model.
1741
+ */
1742
+ interface InputImage {
1743
+ /**
1744
+ * The URL of the image input.
1745
+ */
1746
+ image_url: string;
1747
+ /**
1748
+ * The type of the image input. Always `input_image`.
1749
+ */
1750
+ type: 'input_image';
1751
+ /**
1752
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
1753
+ * `auto`. Defaults to `auto`.
1754
+ */
1755
+ detail?: string;
1756
+ }
1757
+ }
1758
+ }
1759
+ interface ItemReference {
1760
+ /**
1761
+ * A reference to a variable in the `item` namespace. Ie, "item.name"
1762
+ */
1763
+ item_reference: string;
1764
+ /**
1765
+ * The type of input messages. Always `item_reference`.
1766
+ */
1767
+ type: 'item_reference';
1768
+ }
1769
+ interface SamplingParams {
1770
+ /**
1771
+ * The maximum number of tokens in the generated output.
1772
+ */
1773
+ max_completion_tokens?: number;
1774
+ /**
1775
+ * A seed value to initialize the randomness, during sampling.
1776
+ */
1777
+ seed?: number;
1778
+ /**
1779
+ * A higher temperature increases randomness in the outputs.
1780
+ */
1781
+ temperature?: number;
1782
+ /**
1783
+ * Configuration options for a text response from the model. Can be plain text or
1784
+ * structured JSON data. Learn more:
1785
+ *
1786
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
1787
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1788
+ */
1789
+ text?: SamplingParams.Text;
1790
+ /**
1791
+ * An array of tools the model may call while generating a response. You can
1792
+ * specify which tool to use by setting the `tool_choice` parameter.
1793
+ *
1794
+ * The two categories of tools you can provide the model are:
1795
+ *
1796
+ * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
1797
+ * capabilities, like
1798
+ * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
1799
+ * [file search](https://platform.openai.com/docs/guides/tools-file-search).
1800
+ * Learn more about
1801
+ * [built-in tools](https://platform.openai.com/docs/guides/tools).
1802
+ * - **Function calls (custom tools)**: Functions that are defined by you, enabling
1803
+ * the model to call your own code. Learn more about
1804
+ * [function calling](https://platform.openai.com/docs/guides/function-calling).
1805
+ */
1806
+ tools?: Array<ResponsesAPI.Tool>;
1807
+ /**
1808
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
1809
+ */
1810
+ top_p?: number;
1811
+ }
1812
+ namespace SamplingParams {
1813
+ /**
1814
+ * Configuration options for a text response from the model. Can be plain text or
1815
+ * structured JSON data. Learn more:
1816
+ *
1817
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
1818
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1819
+ */
1820
+ interface Text {
1821
+ /**
1822
+ * An object specifying the format that the model must output.
1823
+ *
1824
+ * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
1825
+ * ensures the model will match your supplied JSON schema. Learn more in the
1826
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
1827
+ *
1828
+ * The default format is `{ "type": "text" }` with no additional options.
1829
+ *
1830
+ * **Not recommended for gpt-4o and newer models:**
1831
+ *
1832
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
1833
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
1834
+ * preferred for models that support it.
1835
+ */
1836
+ format?: ResponsesAPI.ResponseFormatTextConfig;
1837
+ }
1838
+ }
1839
+ }
1840
+ interface PerModelUsage {
1841
+ /**
1842
+ * The number of tokens retrieved from cache.
1843
+ */
1844
+ cached_tokens: number;
1845
+ /**
1846
+ * The number of completion tokens generated.
1847
+ */
1848
+ completion_tokens: number;
1849
+ /**
1850
+ * The number of invocations.
1851
+ */
1852
+ invocation_count: number;
1853
+ /**
1854
+ * The name of the model.
1855
+ */
1856
+ model_name: string;
1857
+ /**
1858
+ * The number of prompt tokens used.
1859
+ */
1860
+ prompt_tokens: number;
1861
+ /**
1862
+ * The total number of tokens used.
1863
+ */
1864
+ total_tokens: number;
1865
+ }
1866
+ interface PerTestingCriteriaResult {
1867
+ /**
1868
+ * Number of tests failed for this criteria.
1869
+ */
1870
+ failed: number;
1871
+ /**
1872
+ * Number of tests passed for this criteria.
1873
+ */
1874
+ passed: number;
1875
+ /**
1876
+ * A description of the testing criteria.
1877
+ */
1878
+ testing_criteria: string;
1879
+ }
1880
+ /**
1881
+ * Counters summarizing the outcomes of the evaluation run.
1882
+ */
1883
+ interface ResultCounts {
1884
+ /**
1885
+ * Number of output items that resulted in an error.
1886
+ */
1887
+ errored: number;
1888
+ /**
1889
+ * Number of output items that failed to pass the evaluation.
1890
+ */
1891
+ failed: number;
1892
+ /**
1893
+ * Number of output items that passed the evaluation.
1894
+ */
1895
+ passed: number;
1896
+ /**
1897
+ * Total number of executed output items.
1898
+ */
1899
+ total: number;
1900
+ }
1901
+ }
1902
+ export interface RunCreateParams {
1903
+ /**
1904
+ * Details about the run's data source.
1905
+ */
1906
+ data_source: CreateEvalJSONLRunDataSource | CreateEvalCompletionsRunDataSource | RunCreateParams.CreateEvalResponsesRunDataSource;
1907
+ /**
1908
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful
1909
+ * for storing additional information about the object in a structured format, and
1910
+ * querying for objects via API or the dashboard.
1911
+ *
1912
+ * Keys are strings with a maximum length of 64 characters. Values are strings with
1913
+ * a maximum length of 512 characters.
1914
+ */
1915
+ metadata?: Shared.Metadata | null;
1916
+ /**
1917
+ * The name of the run.
1918
+ */
1919
+ name?: string;
1920
+ }
1921
+ export declare namespace RunCreateParams {
1922
+ /**
1923
+ * A ResponsesRunDataSource object describing a model sampling configuration.
1924
+ */
1925
+ interface CreateEvalResponsesRunDataSource {
1926
+ /**
1927
+ * Determines what populates the `item` namespace in this run's data source.
1928
+ */
1929
+ source: CreateEvalResponsesRunDataSource.FileContent | CreateEvalResponsesRunDataSource.FileID | CreateEvalResponsesRunDataSource.Responses;
1930
+ /**
1931
+ * The type of run data source. Always `responses`.
1932
+ */
1933
+ type: 'responses';
1934
+ /**
1935
+ * Used when sampling from a model. Dictates the structure of the messages passed
1936
+ * into the model. Can either be a reference to a prebuilt trajectory (ie,
1937
+ * `item.input_trajectory`), or a template with variable references to the `item`
1938
+ * namespace.
1939
+ */
1940
+ input_messages?: CreateEvalResponsesRunDataSource.Template | CreateEvalResponsesRunDataSource.ItemReference;
1941
+ /**
1942
+ * The name of the model to use for generating completions (e.g. "o3-mini").
1943
+ */
1944
+ model?: string;
1945
+ sampling_params?: CreateEvalResponsesRunDataSource.SamplingParams;
1946
+ }
1947
+ namespace CreateEvalResponsesRunDataSource {
1948
+ interface FileContent {
1949
+ /**
1950
+ * The content of the jsonl file.
1951
+ */
1952
+ content: Array<FileContent.Content>;
1953
+ /**
1954
+ * The type of jsonl source. Always `file_content`.
1955
+ */
1956
+ type: 'file_content';
1957
+ }
1958
+ namespace FileContent {
1959
+ interface Content {
1960
+ item: {
1961
+ [key: string]: unknown;
1962
+ };
1963
+ sample?: {
1964
+ [key: string]: unknown;
1965
+ };
1966
+ }
1967
+ }
1968
+ interface FileID {
1969
+ /**
1970
+ * The identifier of the file.
1971
+ */
1972
+ id: string;
1973
+ /**
1974
+ * The type of jsonl source. Always `file_id`.
1975
+ */
1976
+ type: 'file_id';
1977
+ }
1978
+ /**
1979
+ * A EvalResponsesSource object describing a run data source configuration.
1980
+ */
1981
+ interface Responses {
1982
+ /**
1983
+ * The type of run data source. Always `responses`.
1984
+ */
1985
+ type: 'responses';
1986
+ /**
1987
+ * Only include items created after this timestamp (inclusive). This is a query
1988
+ * parameter used to select responses.
1989
+ */
1990
+ created_after?: number | null;
1991
+ /**
1992
+ * Only include items created before this timestamp (inclusive). This is a query
1993
+ * parameter used to select responses.
1994
+ */
1995
+ created_before?: number | null;
1996
+ /**
1997
+ * Optional string to search the 'instructions' field. This is a query parameter
1998
+ * used to select responses.
1999
+ */
2000
+ instructions_search?: string | null;
2001
+ /**
2002
+ * Metadata filter for the responses. This is a query parameter used to select
2003
+ * responses.
2004
+ */
2005
+ metadata?: unknown | null;
2006
+ /**
2007
+ * The name of the model to find responses for. This is a query parameter used to
2008
+ * select responses.
2009
+ */
2010
+ model?: string | null;
2011
+ /**
2012
+ * Optional reasoning effort parameter. This is a query parameter used to select
2013
+ * responses.
2014
+ */
2015
+ reasoning_effort?: Shared.ReasoningEffort | null;
2016
+ /**
2017
+ * Sampling temperature. This is a query parameter used to select responses.
2018
+ */
2019
+ temperature?: number | null;
2020
+ /**
2021
+ * List of tool names. This is a query parameter used to select responses.
2022
+ */
2023
+ tools?: Array<string> | null;
2024
+ /**
2025
+ * Nucleus sampling parameter. This is a query parameter used to select responses.
2026
+ */
2027
+ top_p?: number | null;
2028
+ /**
2029
+ * List of user identifiers. This is a query parameter used to select responses.
2030
+ */
2031
+ users?: Array<string> | null;
2032
+ }
2033
+ interface Template {
2034
+ /**
2035
+ * A list of chat messages forming the prompt or context. May include variable
2036
+ * references to the `item` namespace, ie {{item.name}}.
2037
+ */
2038
+ template: Array<Template.ChatMessage | Template.EvalItem>;
2039
+ /**
2040
+ * The type of input messages. Always `template`.
2041
+ */
2042
+ type: 'template';
2043
+ }
2044
+ namespace Template {
2045
+ interface ChatMessage {
2046
+ /**
2047
+ * The content of the message.
2048
+ */
2049
+ content: string;
2050
+ /**
2051
+ * The role of the message (e.g. "system", "assistant", "user").
2052
+ */
2053
+ role: string;
2054
+ }
2055
+ /**
2056
+ * A message input to the model with a role indicating instruction following
2057
+ * hierarchy. Instructions given with the `developer` or `system` role take
2058
+ * precedence over instructions given with the `user` role. Messages with the
2059
+ * `assistant` role are presumed to have been generated by the model in previous
2060
+ * interactions.
2061
+ */
2062
+ interface EvalItem {
2063
+ /**
2064
+ * Inputs to the model - can contain template strings.
2065
+ */
2066
+ content: string | ResponsesAPI.ResponseInputText | EvalItem.OutputText | EvalItem.InputImage | Array<unknown>;
2067
+ /**
2068
+ * The role of the message input. One of `user`, `assistant`, `system`, or
2069
+ * `developer`.
2070
+ */
2071
+ role: 'user' | 'assistant' | 'system' | 'developer';
2072
+ /**
2073
+ * The type of the message input. Always `message`.
2074
+ */
2075
+ type?: 'message';
2076
+ }
2077
+ namespace EvalItem {
2078
+ /**
2079
+ * A text output from the model.
2080
+ */
2081
+ interface OutputText {
2082
+ /**
2083
+ * The text output from the model.
2084
+ */
2085
+ text: string;
2086
+ /**
2087
+ * The type of the output text. Always `output_text`.
2088
+ */
2089
+ type: 'output_text';
2090
+ }
2091
+ /**
2092
+ * An image input to the model.
2093
+ */
2094
+ interface InputImage {
2095
+ /**
2096
+ * The URL of the image input.
2097
+ */
2098
+ image_url: string;
2099
+ /**
2100
+ * The type of the image input. Always `input_image`.
2101
+ */
2102
+ type: 'input_image';
2103
+ /**
2104
+ * The detail level of the image to be sent to the model. One of `high`, `low`, or
2105
+ * `auto`. Defaults to `auto`.
2106
+ */
2107
+ detail?: string;
2108
+ }
2109
+ }
2110
+ }
2111
+ interface ItemReference {
2112
+ /**
2113
+ * A reference to a variable in the `item` namespace. Ie, "item.name"
2114
+ */
2115
+ item_reference: string;
2116
+ /**
2117
+ * The type of input messages. Always `item_reference`.
2118
+ */
2119
+ type: 'item_reference';
2120
+ }
2121
+ interface SamplingParams {
2122
+ /**
2123
+ * The maximum number of tokens in the generated output.
2124
+ */
2125
+ max_completion_tokens?: number;
2126
+ /**
2127
+ * A seed value to initialize the randomness, during sampling.
2128
+ */
2129
+ seed?: number;
2130
+ /**
2131
+ * A higher temperature increases randomness in the outputs.
2132
+ */
2133
+ temperature?: number;
2134
+ /**
2135
+ * Configuration options for a text response from the model. Can be plain text or
2136
+ * structured JSON data. Learn more:
2137
+ *
2138
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
2139
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
2140
+ */
2141
+ text?: SamplingParams.Text;
2142
+ /**
2143
+ * An array of tools the model may call while generating a response. You can
2144
+ * specify which tool to use by setting the `tool_choice` parameter.
2145
+ *
2146
+ * The two categories of tools you can provide the model are:
2147
+ *
2148
+ * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
2149
+ * capabilities, like
2150
+ * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
2151
+ * [file search](https://platform.openai.com/docs/guides/tools-file-search).
2152
+ * Learn more about
2153
+ * [built-in tools](https://platform.openai.com/docs/guides/tools).
2154
+ * - **Function calls (custom tools)**: Functions that are defined by you, enabling
2155
+ * the model to call your own code. Learn more about
2156
+ * [function calling](https://platform.openai.com/docs/guides/function-calling).
2157
+ */
2158
+ tools?: Array<ResponsesAPI.Tool>;
2159
+ /**
2160
+ * An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
2161
+ */
2162
+ top_p?: number;
2163
+ }
2164
+ namespace SamplingParams {
2165
+ /**
2166
+ * Configuration options for a text response from the model. Can be plain text or
2167
+ * structured JSON data. Learn more:
2168
+ *
2169
+ * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
2170
+ * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
2171
+ */
2172
+ interface Text {
2173
+ /**
2174
+ * An object specifying the format that the model must output.
2175
+ *
2176
+ * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
2177
+ * ensures the model will match your supplied JSON schema. Learn more in the
2178
+ * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
2179
+ *
2180
+ * The default format is `{ "type": "text" }` with no additional options.
2181
+ *
2182
+ * **Not recommended for gpt-4o and newer models:**
2183
+ *
2184
+ * Setting to `{ "type": "json_object" }` enables the older JSON mode, which
2185
+ * ensures the message the model generates is valid JSON. Using `json_schema` is
2186
+ * preferred for models that support it.
2187
+ */
2188
+ format?: ResponsesAPI.ResponseFormatTextConfig;
2189
+ }
2190
+ }
2191
+ }
2192
+ }
2193
+ export interface RunRetrieveParams {
2194
+ /**
2195
+ * The ID of the evaluation to retrieve runs for.
2196
+ */
2197
+ eval_id: string;
2198
+ }
2199
+ export interface RunListParams extends CursorPageParams {
2200
+ /**
2201
+ * Sort order for runs by timestamp. Use `asc` for ascending order or `desc` for
2202
+ * descending order. Defaults to `asc`.
2203
+ */
2204
+ order?: 'asc' | 'desc';
2205
+ /**
2206
+ * Filter runs by status. One of `queued` | `in_progress` | `failed` | `completed`
2207
+ * | `canceled`.
2208
+ */
2209
+ status?: 'queued' | 'in_progress' | 'completed' | 'canceled' | 'failed';
2210
+ }
2211
+ export interface RunDeleteParams {
2212
+ /**
2213
+ * The ID of the evaluation to delete the run from.
2214
+ */
2215
+ eval_id: string;
2216
+ }
2217
+ export interface RunCancelParams {
2218
+ /**
2219
+ * The ID of the evaluation whose run you want to cancel.
2220
+ */
2221
+ eval_id: string;
2222
+ }
2223
+ export declare namespace Runs {
2224
+ export { type CreateEvalCompletionsRunDataSource as CreateEvalCompletionsRunDataSource, type CreateEvalJSONLRunDataSource as CreateEvalJSONLRunDataSource, type EvalAPIError as EvalAPIError, type RunCreateResponse as RunCreateResponse, type RunRetrieveResponse as RunRetrieveResponse, type RunListResponse as RunListResponse, type RunDeleteResponse as RunDeleteResponse, type RunCancelResponse as RunCancelResponse, type RunListResponsesPage as RunListResponsesPage, type RunCreateParams as RunCreateParams, type RunRetrieveParams as RunRetrieveParams, type RunListParams as RunListParams, type RunDeleteParams as RunDeleteParams, type RunCancelParams as RunCancelParams, };
2225
+ export { OutputItems as OutputItems, type OutputItemRetrieveResponse as OutputItemRetrieveResponse, type OutputItemListResponse as OutputItemListResponse, type OutputItemListResponsesPage as OutputItemListResponsesPage, type OutputItemRetrieveParams as OutputItemRetrieveParams, type OutputItemListParams as OutputItemListParams, };
2226
+ }
2227
+ //# sourceMappingURL=runs.d.mts.map
platform/dbops/archive/databases_old/data/home/x/india-h200-1-workspace/claude-code-router/node_modules/openai/resources/evals/runs/runs.d.mts.map ADDED
@@ -0,0 +1 @@
 
 
1
+ {"version":3,"file":"runs.d.mts","sourceRoot":"","sources":["../../../src/resources/evals/runs/runs.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,KAAK,YAAY;OACjB,KAAK,cAAc;OACnB,KAAK,cAAc;OACnB,EACL,oBAAoB,EACpB,sBAAsB,EACtB,2BAA2B,EAC3B,wBAAwB,EACxB,0BAA0B,EAC1B,WAAW,EACZ;OACM,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAClD,EAAE,cAAc,EAAE;AAGzB,qBAAa,IAAK,SAAQ,WAAW;IACnC,WAAW,EAAE,cAAc,CAAC,WAAW,CAAgD;IAEvF;;;;OAIG;IACH,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,iBAAiB,CAAC;IA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