openai 7.10.0 → 7.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (605) hide show
  1. package/CHANGELOG.md +203 -0
  2. package/README.md +7 -5
  3. package/_vendor/partial-json-parser/parser.d.mts.map +1 -1
  4. package/_vendor/partial-json-parser/parser.d.ts.map +1 -1
  5. package/_vendor/partial-json-parser/parser.js +4 -3
  6. package/_vendor/partial-json-parser/parser.js.map +1 -1
  7. package/_vendor/partial-json-parser/parser.mjs +4 -3
  8. package/_vendor/partial-json-parser/parser.mjs.map +1 -1
  9. package/_vendor/zod-to-json-schema/parsers/string.js +1 -1
  10. package/_vendor/zod-to-json-schema/parsers/string.js.map +1 -1
  11. package/_vendor/zod-to-json-schema/parsers/string.mjs +1 -1
  12. package/_vendor/zod-to-json-schema/parsers/string.mjs.map +1 -1
  13. package/_vendor/zod-to-json-schema/parsers/tuple.d.mts.map +1 -1
  14. package/_vendor/zod-to-json-schema/parsers/tuple.d.ts.map +1 -1
  15. package/_vendor/zod-to-json-schema/parsers/tuple.js +19 -12
  16. package/_vendor/zod-to-json-schema/parsers/tuple.js.map +1 -1
  17. package/_vendor/zod-to-json-schema/parsers/tuple.mjs +19 -12
  18. package/_vendor/zod-to-json-schema/parsers/tuple.mjs.map +1 -1
  19. package/_vendor/zod-to-json-schema/zodToJsonSchema.d.mts.map +1 -1
  20. package/_vendor/zod-to-json-schema/zodToJsonSchema.d.ts.map +1 -1
  21. package/_vendor/zod-to-json-schema/zodToJsonSchema.js +6 -2
  22. package/_vendor/zod-to-json-schema/zodToJsonSchema.js.map +1 -1
  23. package/_vendor/zod-to-json-schema/zodToJsonSchema.mjs +6 -2
  24. package/_vendor/zod-to-json-schema/zodToJsonSchema.mjs.map +1 -1
  25. package/auth/subject-token-providers.d.mts.map +1 -1
  26. package/auth/subject-token-providers.d.ts.map +1 -1
  27. package/auth/subject-token-providers.js +10 -5
  28. package/auth/subject-token-providers.js.map +1 -1
  29. package/auth/subject-token-providers.mjs +10 -5
  30. package/auth/subject-token-providers.mjs.map +1 -1
  31. package/auth/workload-identity-auth.d.mts.map +1 -1
  32. package/auth/workload-identity-auth.d.ts.map +1 -1
  33. package/auth/workload-identity-auth.js +21 -11
  34. package/auth/workload-identity-auth.js.map +1 -1
  35. package/auth/workload-identity-auth.mjs +21 -11
  36. package/auth/workload-identity-auth.mjs.map +1 -1
  37. package/azure.d.mts.map +1 -1
  38. package/azure.d.ts.map +1 -1
  39. package/azure.js +31 -2
  40. package/azure.js.map +1 -1
  41. package/azure.mjs +32 -3
  42. package/azure.mjs.map +1 -1
  43. package/beta/realtime/internal-base.d.mts.map +1 -1
  44. package/beta/realtime/internal-base.d.ts.map +1 -1
  45. package/beta/realtime/internal-base.js +3 -2
  46. package/beta/realtime/internal-base.js.map +1 -1
  47. package/beta/realtime/internal-base.mjs +3 -2
  48. package/beta/realtime/internal-base.mjs.map +1 -1
  49. package/beta/realtime/websocket.d.mts +2 -0
  50. package/beta/realtime/websocket.d.mts.map +1 -1
  51. package/beta/realtime/websocket.d.ts +2 -0
  52. package/beta/realtime/websocket.d.ts.map +1 -1
  53. package/beta/realtime/websocket.js +12 -7
  54. package/beta/realtime/websocket.js.map +1 -1
  55. package/beta/realtime/websocket.mjs +12 -7
  56. package/beta/realtime/websocket.mjs.map +1 -1
  57. package/beta/realtime/ws.d.mts +2 -0
  58. package/beta/realtime/ws.d.mts.map +1 -1
  59. package/beta/realtime/ws.d.ts +2 -0
  60. package/beta/realtime/ws.d.ts.map +1 -1
  61. package/beta/realtime/ws.js +7 -5
  62. package/beta/realtime/ws.js.map +1 -1
  63. package/beta/realtime/ws.mjs +7 -5
  64. package/beta/realtime/ws.mjs.map +1 -1
  65. package/client.d.mts +9 -1
  66. package/client.d.mts.map +1 -1
  67. package/client.d.ts +9 -1
  68. package/client.d.ts.map +1 -1
  69. package/client.js +17 -4
  70. package/client.js.map +1 -1
  71. package/client.mjs +17 -4
  72. package/client.mjs.map +1 -1
  73. package/core/EventEmitter.d.mts +2 -1
  74. package/core/EventEmitter.d.mts.map +1 -1
  75. package/core/EventEmitter.d.ts +2 -1
  76. package/core/EventEmitter.d.ts.map +1 -1
  77. package/core/EventEmitter.js +2 -1
  78. package/core/EventEmitter.js.map +1 -1
  79. package/core/EventEmitter.mjs +2 -1
  80. package/core/EventEmitter.mjs.map +1 -1
  81. package/core/pagination.js +1 -1
  82. package/core/pagination.js.map +1 -1
  83. package/core/pagination.mjs +1 -1
  84. package/core/pagination.mjs.map +1 -1
  85. package/core/streaming.d.mts +8 -0
  86. package/core/streaming.d.mts.map +1 -1
  87. package/core/streaming.d.ts +8 -0
  88. package/core/streaming.d.ts.map +1 -1
  89. package/core/streaming.js +68 -15
  90. package/core/streaming.js.map +1 -1
  91. package/core/streaming.mjs +68 -15
  92. package/core/streaming.mjs.map +1 -1
  93. package/helpers/audio.d.mts +1 -1
  94. package/helpers/audio.d.mts.map +1 -1
  95. package/helpers/audio.d.ts +1 -1
  96. package/helpers/audio.d.ts.map +1 -1
  97. package/helpers/audio.js +25 -5
  98. package/helpers/audio.js.map +1 -1
  99. package/helpers/audio.mjs +25 -5
  100. package/helpers/audio.mjs.map +1 -1
  101. package/helpers/zod.d.mts +28 -15
  102. package/helpers/zod.d.mts.map +1 -1
  103. package/helpers/zod.d.ts +28 -15
  104. package/helpers/zod.d.ts.map +1 -1
  105. package/helpers/zod.js +30 -23
  106. package/helpers/zod.js.map +1 -1
  107. package/helpers/zod.mjs +30 -23
  108. package/helpers/zod.mjs.map +1 -1
  109. package/index.js +4 -5
  110. package/internal/bedrock.d.mts +11 -0
  111. package/internal/bedrock.d.mts.map +1 -1
  112. package/internal/bedrock.d.ts +11 -0
  113. package/internal/bedrock.d.ts.map +1 -1
  114. package/internal/bedrock.js +71 -55
  115. package/internal/bedrock.js.map +1 -1
  116. package/internal/bedrock.mjs +70 -55
  117. package/internal/bedrock.mjs.map +1 -1
  118. package/internal/detect-platform.js +2 -2
  119. package/internal/detect-platform.js.map +1 -1
  120. package/internal/detect-platform.mjs +2 -2
  121. package/internal/detect-platform.mjs.map +1 -1
  122. package/internal/errors.d.mts.map +1 -1
  123. package/internal/errors.d.ts.map +1 -1
  124. package/internal/errors.js +3 -2
  125. package/internal/errors.js.map +1 -1
  126. package/internal/errors.mjs +3 -2
  127. package/internal/errors.mjs.map +1 -1
  128. package/internal/headers.d.mts.map +1 -1
  129. package/internal/headers.d.ts.map +1 -1
  130. package/internal/headers.js +4 -5
  131. package/internal/headers.js.map +1 -1
  132. package/internal/headers.mjs +4 -5
  133. package/internal/headers.mjs.map +1 -1
  134. package/internal/parse.js +1 -1
  135. package/internal/parse.js.map +1 -1
  136. package/internal/parse.mjs +1 -1
  137. package/internal/parse.mjs.map +1 -1
  138. package/internal/realtime-credentials.d.mts +15 -0
  139. package/internal/realtime-credentials.d.mts.map +1 -0
  140. package/internal/realtime-credentials.d.ts +15 -0
  141. package/internal/realtime-credentials.d.ts.map +1 -0
  142. package/internal/realtime-credentials.js +23 -0
  143. package/internal/realtime-credentials.js.map +1 -0
  144. package/internal/realtime-credentials.mjs +19 -0
  145. package/internal/realtime-credentials.mjs.map +1 -0
  146. package/internal/responses/response-accumulator.d.mts.map +1 -1
  147. package/internal/responses/response-accumulator.d.ts.map +1 -1
  148. package/internal/responses/response-accumulator.js +2 -1
  149. package/internal/responses/response-accumulator.js.map +1 -1
  150. package/internal/responses/response-accumulator.mjs +2 -1
  151. package/internal/responses/response-accumulator.mjs.map +1 -1
  152. package/internal/to-file.d.mts +2 -1
  153. package/internal/to-file.d.mts.map +1 -1
  154. package/internal/to-file.d.ts +2 -1
  155. package/internal/to-file.d.ts.map +1 -1
  156. package/internal/to-file.js +5 -4
  157. package/internal/to-file.js.map +1 -1
  158. package/internal/to-file.mjs +6 -5
  159. package/internal/to-file.mjs.map +1 -1
  160. package/internal/types.d.mts +3 -3
  161. package/internal/types.d.mts.map +1 -1
  162. package/internal/types.d.ts +3 -3
  163. package/internal/types.d.ts.map +1 -1
  164. package/internal/uploads.d.mts +2 -0
  165. package/internal/uploads.d.mts.map +1 -1
  166. package/internal/uploads.d.ts +2 -0
  167. package/internal/uploads.d.ts.map +1 -1
  168. package/internal/uploads.js +12 -1
  169. package/internal/uploads.js.map +1 -1
  170. package/internal/uploads.mjs +11 -1
  171. package/internal/uploads.mjs.map +1 -1
  172. package/internal/utils/base64.d.mts.map +1 -1
  173. package/internal/utils/base64.d.ts.map +1 -1
  174. package/internal/utils/base64.js +3 -0
  175. package/internal/utils/base64.js.map +1 -1
  176. package/internal/utils/base64.mjs +3 -0
  177. package/internal/utils/base64.mjs.map +1 -1
  178. package/lib/AbstractChatCompletionRunner.d.mts +1 -1
  179. package/lib/AbstractChatCompletionRunner.d.mts.map +1 -1
  180. package/lib/AbstractChatCompletionRunner.d.ts +1 -1
  181. package/lib/AbstractChatCompletionRunner.d.ts.map +1 -1
  182. package/lib/AbstractChatCompletionRunner.js +31 -9
  183. package/lib/AbstractChatCompletionRunner.js.map +1 -1
  184. package/lib/AbstractChatCompletionRunner.mjs +31 -9
  185. package/lib/AbstractChatCompletionRunner.mjs.map +1 -1
  186. package/lib/AssistantStream.d.mts +4 -1
  187. package/lib/AssistantStream.d.mts.map +1 -1
  188. package/lib/AssistantStream.d.ts +4 -1
  189. package/lib/AssistantStream.d.ts.map +1 -1
  190. package/lib/AssistantStream.js +23 -8
  191. package/lib/AssistantStream.js.map +1 -1
  192. package/lib/AssistantStream.mjs +24 -9
  193. package/lib/AssistantStream.mjs.map +1 -1
  194. package/lib/ChatCompletionRunner.d.mts +6 -3
  195. package/lib/ChatCompletionRunner.d.mts.map +1 -1
  196. package/lib/ChatCompletionRunner.d.ts +6 -3
  197. package/lib/ChatCompletionRunner.d.ts.map +1 -1
  198. package/lib/ChatCompletionRunner.js +7 -4
  199. package/lib/ChatCompletionRunner.js.map +1 -1
  200. package/lib/ChatCompletionRunner.mjs +7 -4
  201. package/lib/ChatCompletionRunner.mjs.map +1 -1
  202. package/lib/ChatCompletionStream.d.mts.map +1 -1
  203. package/lib/ChatCompletionStream.d.ts.map +1 -1
  204. package/lib/ChatCompletionStream.js +6 -0
  205. package/lib/ChatCompletionStream.js.map +1 -1
  206. package/lib/ChatCompletionStream.mjs +7 -1
  207. package/lib/ChatCompletionStream.mjs.map +1 -1
  208. package/lib/ChatCompletionStreamingRunner.d.mts.map +1 -1
  209. package/lib/ChatCompletionStreamingRunner.d.ts.map +1 -1
  210. package/lib/ChatCompletionStreamingRunner.js +1 -0
  211. package/lib/ChatCompletionStreamingRunner.js.map +1 -1
  212. package/lib/ChatCompletionStreamingRunner.mjs +1 -0
  213. package/lib/ChatCompletionStreamingRunner.mjs.map +1 -1
  214. package/lib/EventEmitter.d.mts +3 -1
  215. package/lib/EventEmitter.d.mts.map +1 -1
  216. package/lib/EventEmitter.d.ts +3 -1
  217. package/lib/EventEmitter.d.ts.map +1 -1
  218. package/lib/EventEmitter.js +2 -1
  219. package/lib/EventEmitter.js.map +1 -1
  220. package/lib/EventEmitter.mjs +2 -1
  221. package/lib/EventEmitter.mjs.map +1 -1
  222. package/lib/EventStream.d.mts +2 -1
  223. package/lib/EventStream.d.mts.map +1 -1
  224. package/lib/EventStream.d.ts +2 -1
  225. package/lib/EventStream.d.ts.map +1 -1
  226. package/lib/EventStream.js +99 -46
  227. package/lib/EventStream.js.map +1 -1
  228. package/lib/EventStream.mjs +99 -46
  229. package/lib/EventStream.mjs.map +1 -1
  230. package/lib/ResponsesParser.d.mts +5 -4
  231. package/lib/ResponsesParser.d.mts.map +1 -1
  232. package/lib/ResponsesParser.d.ts +5 -4
  233. package/lib/ResponsesParser.d.ts.map +1 -1
  234. package/lib/ResponsesParser.js +21 -7
  235. package/lib/ResponsesParser.js.map +1 -1
  236. package/lib/ResponsesParser.mjs +21 -7
  237. package/lib/ResponsesParser.mjs.map +1 -1
  238. package/lib/RunnableFunction.d.mts +2 -2
  239. package/lib/RunnableFunction.d.mts.map +1 -1
  240. package/lib/RunnableFunction.d.ts +2 -2
  241. package/lib/RunnableFunction.d.ts.map +1 -1
  242. package/lib/embeddings.d.mts.map +1 -1
  243. package/lib/embeddings.d.ts.map +1 -1
  244. package/lib/embeddings.js +18 -12
  245. package/lib/embeddings.js.map +1 -1
  246. package/lib/embeddings.mjs +18 -12
  247. package/lib/embeddings.mjs.map +1 -1
  248. package/lib/file-processing.d.mts +3 -2
  249. package/lib/file-processing.d.mts.map +1 -1
  250. package/lib/file-processing.d.ts +3 -2
  251. package/lib/file-processing.d.ts.map +1 -1
  252. package/lib/file-processing.js +5 -4
  253. package/lib/file-processing.js.map +1 -1
  254. package/lib/file-processing.mjs +5 -4
  255. package/lib/file-processing.mjs.map +1 -1
  256. package/lib/parser.d.mts +16 -4
  257. package/lib/parser.d.mts.map +1 -1
  258. package/lib/parser.d.ts +16 -4
  259. package/lib/parser.d.ts.map +1 -1
  260. package/lib/parser.js +1 -1
  261. package/lib/parser.js.map +1 -1
  262. package/lib/parser.mjs +1 -1
  263. package/lib/parser.mjs.map +1 -1
  264. package/lib/polling.d.mts +2 -2
  265. package/lib/polling.d.mts.map +1 -1
  266. package/lib/polling.d.ts +2 -2
  267. package/lib/polling.d.ts.map +1 -1
  268. package/lib/polling.js +5 -4
  269. package/lib/polling.js.map +1 -1
  270. package/lib/polling.mjs +5 -4
  271. package/lib/polling.mjs.map +1 -1
  272. package/lib/responses/EventTypes.d.mts +2 -2
  273. package/lib/responses/EventTypes.d.mts.map +1 -1
  274. package/lib/responses/EventTypes.d.ts +2 -2
  275. package/lib/responses/EventTypes.d.ts.map +1 -1
  276. package/lib/responses/ResponseInputItems.d.mts +3 -2
  277. package/lib/responses/ResponseInputItems.d.mts.map +1 -1
  278. package/lib/responses/ResponseInputItems.d.ts +3 -2
  279. package/lib/responses/ResponseInputItems.d.ts.map +1 -1
  280. package/lib/responses/ResponseInputItems.js +27 -4
  281. package/lib/responses/ResponseInputItems.js.map +1 -1
  282. package/lib/responses/ResponseInputItems.mjs +27 -4
  283. package/lib/responses/ResponseInputItems.mjs.map +1 -1
  284. package/lib/transform.d.mts.map +1 -1
  285. package/lib/transform.d.ts.map +1 -1
  286. package/lib/transform.js +1 -0
  287. package/lib/transform.js.map +1 -1
  288. package/lib/transform.mjs +1 -0
  289. package/lib/transform.mjs.map +1 -1
  290. package/lib/vector-store-polling.d.mts +2 -2
  291. package/lib/vector-store-polling.d.ts +2 -2
  292. package/lib/vector-store-polling.js +3 -3
  293. package/lib/vector-store-polling.js.map +1 -1
  294. package/lib/vector-store-polling.mjs +3 -3
  295. package/lib/vector-store-polling.mjs.map +1 -1
  296. package/lib/vector-store-upload.d.mts +2 -1
  297. package/lib/vector-store-upload.d.mts.map +1 -1
  298. package/lib/vector-store-upload.d.ts +2 -1
  299. package/lib/vector-store-upload.d.ts.map +1 -1
  300. package/lib/vector-store-upload.js +5 -1
  301. package/lib/vector-store-upload.js.map +1 -1
  302. package/lib/vector-store-upload.mjs +5 -1
  303. package/lib/vector-store-upload.mjs.map +1 -1
  304. package/package.json +1 -1
  305. package/providers/bedrock/aws.d.mts.map +1 -1
  306. package/providers/bedrock/aws.d.ts.map +1 -1
  307. package/providers/bedrock/aws.js +14 -16
  308. package/providers/bedrock/aws.js.map +1 -1
  309. package/providers/bedrock/aws.mjs +15 -17
  310. package/providers/bedrock/aws.mjs.map +1 -1
  311. package/realtime/internal-base.d.mts.map +1 -1
  312. package/realtime/internal-base.d.ts.map +1 -1
  313. package/realtime/internal-base.js +3 -5
  314. package/realtime/internal-base.js.map +1 -1
  315. package/realtime/internal-base.mjs +3 -5
  316. package/realtime/internal-base.mjs.map +1 -1
  317. package/realtime/websocket.d.mts +2 -0
  318. package/realtime/websocket.d.mts.map +1 -1
  319. package/realtime/websocket.d.ts +2 -0
  320. package/realtime/websocket.d.ts.map +1 -1
  321. package/realtime/websocket.js +12 -6
  322. package/realtime/websocket.js.map +1 -1
  323. package/realtime/websocket.mjs +12 -6
  324. package/realtime/websocket.mjs.map +1 -1
  325. package/realtime/ws.d.mts +2 -0
  326. package/realtime/ws.d.mts.map +1 -1
  327. package/realtime/ws.d.ts +2 -0
  328. package/realtime/ws.d.ts.map +1 -1
  329. package/realtime/ws.js +7 -4
  330. package/realtime/ws.js.map +1 -1
  331. package/realtime/ws.mjs +7 -4
  332. package/realtime/ws.mjs.map +1 -1
  333. package/resources/admin/organization/audit-logs.d.mts +1 -1
  334. package/resources/admin/organization/audit-logs.d.ts +1 -1
  335. package/resources/admin/organization/projects/api-keys.d.mts +5 -0
  336. package/resources/admin/organization/projects/api-keys.d.mts.map +1 -1
  337. package/resources/admin/organization/projects/api-keys.d.ts +5 -0
  338. package/resources/admin/organization/projects/api-keys.d.ts.map +1 -1
  339. package/resources/admin/organization/projects/projects.d.mts +2 -2
  340. package/resources/admin/organization/projects/projects.d.ts +2 -2
  341. package/resources/admin/organization/projects/service-accounts/api-keys.d.mts +9 -0
  342. package/resources/admin/organization/projects/service-accounts/api-keys.d.mts.map +1 -1
  343. package/resources/admin/organization/projects/service-accounts/api-keys.d.ts +9 -0
  344. package/resources/admin/organization/projects/service-accounts/api-keys.d.ts.map +1 -1
  345. package/resources/admin/organization/projects/service-accounts/service-accounts.d.mts +13 -0
  346. package/resources/admin/organization/projects/service-accounts/service-accounts.d.mts.map +1 -1
  347. package/resources/admin/organization/projects/service-accounts/service-accounts.d.ts +13 -0
  348. package/resources/admin/organization/projects/service-accounts/service-accounts.d.ts.map +1 -1
  349. package/resources/admin/organization/projects/service-accounts/service-accounts.js.map +1 -1
  350. package/resources/admin/organization/projects/service-accounts/service-accounts.mjs.map +1 -1
  351. package/resources/audio/speech.d.mts +3 -2
  352. package/resources/audio/speech.d.mts.map +1 -1
  353. package/resources/audio/speech.d.ts +3 -2
  354. package/resources/audio/speech.d.ts.map +1 -1
  355. package/resources/audio/transcriptions.d.mts +10 -10
  356. package/resources/audio/transcriptions.d.ts +10 -10
  357. package/resources/audio/translations.d.mts +1 -1
  358. package/resources/audio/translations.d.ts +1 -1
  359. package/resources/batches.d.mts +6 -5
  360. package/resources/batches.d.mts.map +1 -1
  361. package/resources/batches.d.ts +6 -5
  362. package/resources/batches.d.ts.map +1 -1
  363. package/resources/beta/assistants.d.mts +143 -147
  364. package/resources/beta/assistants.d.mts.map +1 -1
  365. package/resources/beta/assistants.d.ts +143 -147
  366. package/resources/beta/assistants.d.ts.map +1 -1
  367. package/resources/beta/responses/input-tokens.d.mts +11 -11
  368. package/resources/beta/responses/input-tokens.d.ts +11 -11
  369. package/resources/beta/responses/responses.d.mts +284 -194
  370. package/resources/beta/responses/responses.d.mts.map +1 -1
  371. package/resources/beta/responses/responses.d.ts +284 -194
  372. package/resources/beta/responses/responses.d.ts.map +1 -1
  373. package/resources/beta/responses/responses.js +3 -3
  374. package/resources/beta/responses/responses.js.map +1 -1
  375. package/resources/beta/responses/responses.mjs +3 -3
  376. package/resources/beta/responses/responses.mjs.map +1 -1
  377. package/resources/beta/threads/messages.d.mts +29 -23
  378. package/resources/beta/threads/messages.d.mts.map +1 -1
  379. package/resources/beta/threads/messages.d.ts +29 -23
  380. package/resources/beta/threads/messages.d.ts.map +1 -1
  381. package/resources/beta/threads/runs/runs.d.mts +39 -35
  382. package/resources/beta/threads/runs/runs.d.mts.map +1 -1
  383. package/resources/beta/threads/runs/runs.d.ts +39 -35
  384. package/resources/beta/threads/runs/runs.d.ts.map +1 -1
  385. package/resources/beta/threads/runs/runs.js.map +1 -1
  386. package/resources/beta/threads/runs/runs.mjs.map +1 -1
  387. package/resources/beta/threads/runs/steps.d.mts +14 -15
  388. package/resources/beta/threads/runs/steps.d.mts.map +1 -1
  389. package/resources/beta/threads/runs/steps.d.ts +14 -15
  390. package/resources/beta/threads/runs/steps.d.ts.map +1 -1
  391. package/resources/beta/threads/threads.d.mts +53 -50
  392. package/resources/beta/threads/threads.d.mts.map +1 -1
  393. package/resources/beta/threads/threads.d.ts +53 -50
  394. package/resources/beta/threads/threads.d.ts.map +1 -1
  395. package/resources/beta/threads/threads.js.map +1 -1
  396. package/resources/beta/threads/threads.mjs.map +1 -1
  397. package/resources/chat/completions/completions.d.mts +89 -81
  398. package/resources/chat/completions/completions.d.mts.map +1 -1
  399. package/resources/chat/completions/completions.d.ts +89 -81
  400. package/resources/chat/completions/completions.d.ts.map +1 -1
  401. package/resources/chat/completions/completions.js.map +1 -1
  402. package/resources/chat/completions/completions.mjs.map +1 -1
  403. package/resources/completions.d.mts +15 -14
  404. package/resources/completions.d.mts.map +1 -1
  405. package/resources/completions.d.ts +15 -14
  406. package/resources/completions.d.ts.map +1 -1
  407. package/resources/content-provenance-checks.d.mts +1 -1
  408. package/resources/content-provenance-checks.d.ts +1 -1
  409. package/resources/content-provenance-checks.js +1 -1
  410. package/resources/content-provenance-checks.mjs +1 -1
  411. package/resources/conversations/items.d.mts +12 -3
  412. package/resources/conversations/items.d.mts.map +1 -1
  413. package/resources/conversations/items.d.ts +12 -3
  414. package/resources/conversations/items.d.ts.map +1 -1
  415. package/resources/embeddings.d.mts +6 -6
  416. package/resources/embeddings.d.ts +6 -6
  417. package/resources/evals/evals.d.mts +1 -1
  418. package/resources/evals/evals.d.ts +1 -1
  419. package/resources/evals/evals.js +1 -1
  420. package/resources/evals/evals.mjs +1 -1
  421. package/resources/evals/runs/runs.d.mts +62 -57
  422. package/resources/evals/runs/runs.d.mts.map +1 -1
  423. package/resources/evals/runs/runs.d.ts +62 -57
  424. package/resources/evals/runs/runs.d.ts.map +1 -1
  425. package/resources/evals/runs/runs.js.map +1 -1
  426. package/resources/evals/runs/runs.mjs.map +1 -1
  427. package/resources/files.d.mts +5 -5
  428. package/resources/files.d.ts +5 -5
  429. package/resources/files.js +5 -5
  430. package/resources/files.mjs +5 -5
  431. package/resources/fine-tuning/alpha/graders.d.mts +5 -4
  432. package/resources/fine-tuning/alpha/graders.d.mts.map +1 -1
  433. package/resources/fine-tuning/alpha/graders.d.ts +5 -4
  434. package/resources/fine-tuning/alpha/graders.d.ts.map +1 -1
  435. package/resources/fine-tuning/checkpoints/permissions.d.mts +8 -4
  436. package/resources/fine-tuning/checkpoints/permissions.d.mts.map +1 -1
  437. package/resources/fine-tuning/checkpoints/permissions.d.ts +8 -4
  438. package/resources/fine-tuning/checkpoints/permissions.d.ts.map +1 -1
  439. package/resources/fine-tuning/checkpoints/permissions.js +8 -4
  440. package/resources/fine-tuning/checkpoints/permissions.js.map +1 -1
  441. package/resources/fine-tuning/checkpoints/permissions.mjs +8 -4
  442. package/resources/fine-tuning/checkpoints/permissions.mjs.map +1 -1
  443. package/resources/fine-tuning/jobs/jobs.d.mts +13 -12
  444. package/resources/fine-tuning/jobs/jobs.d.mts.map +1 -1
  445. package/resources/fine-tuning/jobs/jobs.d.ts +13 -12
  446. package/resources/fine-tuning/jobs/jobs.d.ts.map +1 -1
  447. package/resources/fine-tuning/jobs/jobs.js +2 -2
  448. package/resources/fine-tuning/jobs/jobs.js.map +1 -1
  449. package/resources/fine-tuning/jobs/jobs.mjs +2 -2
  450. package/resources/fine-tuning/jobs/jobs.mjs.map +1 -1
  451. package/resources/graders/grader-models.d.mts +1 -1
  452. package/resources/graders/grader-models.d.ts +1 -1
  453. package/resources/images.d.mts +83 -68
  454. package/resources/images.d.mts.map +1 -1
  455. package/resources/images.d.ts +83 -68
  456. package/resources/images.d.ts.map +1 -1
  457. package/resources/images.js.map +1 -1
  458. package/resources/images.mjs.map +1 -1
  459. package/resources/moderations.d.mts +5 -4
  460. package/resources/moderations.d.mts.map +1 -1
  461. package/resources/moderations.d.ts +5 -4
  462. package/resources/moderations.d.ts.map +1 -1
  463. package/resources/moderations.js +2 -1
  464. package/resources/moderations.js.map +1 -1
  465. package/resources/moderations.mjs +2 -1
  466. package/resources/moderations.mjs.map +1 -1
  467. package/resources/realtime/calls.d.mts +1 -1
  468. package/resources/realtime/calls.d.ts +1 -1
  469. package/resources/realtime/client-secrets.d.mts +4 -4
  470. package/resources/realtime/client-secrets.d.ts +4 -4
  471. package/resources/realtime/client-secrets.js +1 -1
  472. package/resources/realtime/client-secrets.mjs +1 -1
  473. package/resources/realtime/realtime.d.mts +16 -16
  474. package/resources/realtime/realtime.d.ts +16 -16
  475. package/resources/responses/input-tokens.d.mts +9 -9
  476. package/resources/responses/input-tokens.d.ts +9 -9
  477. package/resources/responses/responses.d.mts +278 -187
  478. package/resources/responses/responses.d.mts.map +1 -1
  479. package/resources/responses/responses.d.ts +278 -187
  480. package/resources/responses/responses.d.ts.map +1 -1
  481. package/resources/responses/responses.js +3 -3
  482. package/resources/responses/responses.js.map +1 -1
  483. package/resources/responses/responses.mjs +3 -3
  484. package/resources/responses/responses.mjs.map +1 -1
  485. package/resources/shared.d.mts +12 -12
  486. package/resources/shared.d.ts +12 -12
  487. package/resources/uploads/parts.d.mts +5 -4
  488. package/resources/uploads/parts.d.mts.map +1 -1
  489. package/resources/uploads/parts.d.ts +5 -4
  490. package/resources/uploads/parts.d.ts.map +1 -1
  491. package/resources/uploads/parts.js +5 -4
  492. package/resources/uploads/parts.js.map +1 -1
  493. package/resources/uploads/parts.mjs +5 -4
  494. package/resources/uploads/parts.mjs.map +1 -1
  495. package/resources/uploads/uploads.d.mts +11 -11
  496. package/resources/uploads/uploads.d.ts +11 -11
  497. package/resources/uploads/uploads.js +9 -9
  498. package/resources/uploads/uploads.mjs +9 -9
  499. package/resources/vector-stores/file-batches.d.mts +11 -11
  500. package/resources/vector-stores/file-batches.d.ts +11 -11
  501. package/resources/vector-stores/files.d.mts +8 -8
  502. package/resources/vector-stores/files.d.ts +8 -8
  503. package/resources/vector-stores/files.js +3 -3
  504. package/resources/vector-stores/files.mjs +3 -3
  505. package/resources/vector-stores/vector-stores.d.mts +3 -3
  506. package/resources/vector-stores/vector-stores.d.ts +3 -3
  507. package/resources/webhooks/webhooks.d.mts +12 -6
  508. package/resources/webhooks/webhooks.d.mts.map +1 -1
  509. package/resources/webhooks/webhooks.d.ts +12 -6
  510. package/resources/webhooks/webhooks.d.ts.map +1 -1
  511. package/src/_vendor/partial-json-parser/parser.ts +4 -3
  512. package/src/_vendor/zod-to-json-schema/parsers/string.ts +1 -1
  513. package/src/_vendor/zod-to-json-schema/parsers/tuple.ts +23 -16
  514. package/src/_vendor/zod-to-json-schema/zodToJsonSchema.ts +11 -6
  515. package/src/auth/subject-token-providers.ts +12 -7
  516. package/src/auth/workload-identity-auth.ts +27 -12
  517. package/src/azure.ts +34 -3
  518. package/src/beta/realtime/internal-base.ts +3 -2
  519. package/src/beta/realtime/websocket.ts +17 -7
  520. package/src/beta/realtime/ws.ts +9 -5
  521. package/src/client.ts +19 -4
  522. package/src/core/EventEmitter.ts +5 -8
  523. package/src/core/pagination.ts +1 -1
  524. package/src/core/streaming.ts +69 -13
  525. package/src/helpers/audio.ts +27 -6
  526. package/src/helpers/zod.ts +78 -29
  527. package/src/internal/bedrock.ts +84 -58
  528. package/src/internal/detect-platform.ts +2 -2
  529. package/src/internal/errors.ts +3 -2
  530. package/src/internal/headers.ts +7 -5
  531. package/src/internal/parse.ts +1 -1
  532. package/src/internal/realtime-credentials.ts +27 -0
  533. package/src/internal/responses/response-accumulator.ts +1 -0
  534. package/src/internal/to-file.ts +6 -5
  535. package/src/internal/uploads.ts +12 -1
  536. package/src/internal/utils/base64.ts +3 -0
  537. package/src/lib/AbstractChatCompletionRunner.ts +31 -6
  538. package/src/lib/AssistantStream.ts +25 -11
  539. package/src/lib/ChatCompletionRunner.ts +8 -4
  540. package/src/lib/ChatCompletionStream.ts +8 -0
  541. package/src/lib/ChatCompletionStreamingRunner.ts +1 -0
  542. package/src/lib/EventEmitter.ts +17 -8
  543. package/src/lib/EventStream.ts +105 -52
  544. package/src/lib/ResponsesParser.ts +33 -12
  545. package/src/lib/RunnableFunction.ts +2 -2
  546. package/src/lib/embeddings.ts +18 -12
  547. package/src/lib/file-processing.ts +5 -4
  548. package/src/lib/parser.ts +35 -11
  549. package/src/lib/polling.ts +5 -4
  550. package/src/lib/responses/EventTypes.ts +3 -69
  551. package/src/lib/responses/ResponseInputItems.ts +29 -4
  552. package/src/lib/transform.ts +1 -0
  553. package/src/lib/vector-store-polling.ts +3 -3
  554. package/src/lib/vector-store-upload.ts +5 -1
  555. package/src/providers/bedrock/aws.ts +23 -24
  556. package/src/realtime/internal-base.ts +3 -5
  557. package/src/realtime/websocket.ts +14 -6
  558. package/src/realtime/ws.ts +9 -4
  559. package/src/resources/admin/organization/audit-logs.ts +1 -1
  560. package/src/resources/admin/organization/projects/api-keys.ts +6 -0
  561. package/src/resources/admin/organization/projects/projects.ts +2 -2
  562. package/src/resources/admin/organization/projects/service-accounts/api-keys.ts +11 -0
  563. package/src/resources/admin/organization/projects/service-accounts/service-accounts.ts +15 -0
  564. package/src/resources/audio/speech.ts +3 -2
  565. package/src/resources/audio/transcriptions.ts +10 -10
  566. package/src/resources/audio/translations.ts +1 -1
  567. package/src/resources/batches.ts +6 -5
  568. package/src/resources/beta/assistants.ts +143 -147
  569. package/src/resources/beta/responses/input-tokens.ts +11 -11
  570. package/src/resources/beta/responses/responses.ts +315 -192
  571. package/src/resources/beta/threads/messages.ts +29 -23
  572. package/src/resources/beta/threads/runs/runs.ts +39 -35
  573. package/src/resources/beta/threads/runs/steps.ts +14 -15
  574. package/src/resources/beta/threads/threads.ts +53 -50
  575. package/src/resources/chat/completions/completions.ts +89 -81
  576. package/src/resources/completions.ts +15 -14
  577. package/src/resources/content-provenance-checks.ts +1 -1
  578. package/src/resources/conversations/items.ts +14 -3
  579. package/src/resources/embeddings.ts +6 -6
  580. package/src/resources/evals/evals.ts +1 -1
  581. package/src/resources/evals/runs/runs.ts +62 -57
  582. package/src/resources/files.ts +5 -5
  583. package/src/resources/fine-tuning/alpha/graders.ts +5 -4
  584. package/src/resources/fine-tuning/checkpoints/permissions.ts +8 -4
  585. package/src/resources/fine-tuning/jobs/jobs.ts +13 -12
  586. package/src/resources/graders/grader-models.ts +1 -1
  587. package/src/resources/images.ts +86 -67
  588. package/src/resources/moderations.ts +5 -4
  589. package/src/resources/realtime/calls.ts +1 -1
  590. package/src/resources/realtime/client-secrets.ts +4 -4
  591. package/src/resources/realtime/realtime.ts +16 -16
  592. package/src/resources/responses/input-tokens.ts +9 -9
  593. package/src/resources/responses/responses.ts +309 -185
  594. package/src/resources/shared.ts +12 -12
  595. package/src/resources/uploads/parts.ts +5 -4
  596. package/src/resources/uploads/uploads.ts +11 -11
  597. package/src/resources/vector-stores/file-batches.ts +11 -11
  598. package/src/resources/vector-stores/files.ts +8 -8
  599. package/src/resources/vector-stores/vector-stores.ts +3 -3
  600. package/src/resources/webhooks/webhooks.ts +12 -6
  601. package/src/version.ts +1 -1
  602. package/version.d.mts +1 -1
  603. package/version.d.ts +1 -1
  604. package/version.js +1 -1
  605. package/version.mjs +1 -1
@@ -32,16 +32,16 @@ export declare class Responses extends APIResource {
32
32
  inputTokens: InputTokensAPI.InputTokens;
33
33
  /**
34
34
  * Creates a model response. Provide
35
- * [text](https://platform.openai.com/docs/guides/text) or
36
- * [image](https://platform.openai.com/docs/guides/images) inputs to generate
37
- * [text](https://platform.openai.com/docs/guides/text) or
38
- * [JSON](https://platform.openai.com/docs/guides/structured-outputs) outputs. Have
39
- * the model call your own
40
- * [custom code](https://platform.openai.com/docs/guides/function-calling) or use
41
- * built-in [tools](https://platform.openai.com/docs/guides/tools) like
42
- * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
43
- * [file search](https://platform.openai.com/docs/guides/tools-file-search) to use
44
- * your own data as input for the model's response.
35
+ * [text](https://developers.openai.com/api/docs/guides/text) or
36
+ * [image](https://developers.openai.com/api/docs/guides/images-vision) inputs to
37
+ * generate [text](https://developers.openai.com/api/docs/guides/text) or
38
+ * [JSON](https://developers.openai.com/api/docs/guides/structured-outputs)
39
+ * outputs. Have the model call your own
40
+ * [custom code](https://developers.openai.com/api/docs/guides/function-calling) or
41
+ * use built-in [tools](https://developers.openai.com/api/docs/guides/tools) like
42
+ * [web search](https://developers.openai.com/api/docs/guides/tools-web-search) or
43
+ * [file search](https://developers.openai.com/api/docs/guides/tools-file-search)
44
+ * to use your own data as input for the model's response.
45
45
  *
46
46
  * @example
47
47
  * ```ts
@@ -83,7 +83,7 @@ export declare class Responses extends APIResource {
83
83
  /**
84
84
  * Cancels a model response with the given ID. Only responses created with the
85
85
  * `background` parameter set to `true` can be cancelled.
86
- * [Learn more](https://platform.openai.com/docs/guides/background).
86
+ * [Learn more](https://developers.openai.com/api/docs/guides/background).
87
87
  *
88
88
  * @example
89
89
  * ```ts
@@ -97,9 +97,9 @@ export declare class Responses extends APIResource {
97
97
  * Compact a conversation. Returns a compacted response object.
98
98
  *
99
99
  * Learn when and how to compact long-running conversations in the
100
- * [conversation state guide](https://platform.openai.com/docs/guides/conversation-state#managing-the-context-window).
100
+ * [conversation state guide](https://developers.openai.com/api/docs/guides/conversation-state#managing-the-context-window).
101
101
  * For ZDR-compatible compaction details, see
102
- * [Compaction (advanced)](https://platform.openai.com/docs/guides/conversation-state#compaction-advanced).
102
+ * [Compaction (advanced)](https://developers.openai.com/api/docs/guides/conversation-state#compaction-advanced).
103
103
  *
104
104
  * @example
105
105
  * ```ts
@@ -351,7 +351,7 @@ export declare namespace ComputerAction {
351
351
  export type ComputerActionList = Array<ComputerAction>;
352
352
  /**
353
353
  * A tool that controls a virtual computer. Learn more about the
354
- * [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
354
+ * [computer tool](https://developers.openai.com/api/docs/guides/tools-computer-use).
355
355
  */
356
356
  export interface ComputerTool {
357
357
  /**
@@ -361,7 +361,7 @@ export interface ComputerTool {
361
361
  }
362
362
  /**
363
363
  * A tool that controls a virtual computer. Learn more about the
364
- * [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
364
+ * [computer tool](https://developers.openai.com/api/docs/guides/tools-computer-use).
365
365
  */
366
366
  export interface ComputerUsePreviewTool {
367
367
  /**
@@ -449,7 +449,7 @@ export interface ContainerReference {
449
449
  }
450
450
  /**
451
451
  * A custom tool that processes input using a specified format. Learn more about
452
- * [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools)
452
+ * [custom tools](https://developers.openai.com/api/docs/guides/function-calling#custom-tools)
453
453
  */
454
454
  export interface CustomTool {
455
455
  /**
@@ -515,7 +515,7 @@ export interface EasyInputMessage {
515
515
  /**
516
516
  * A tool that searches for relevant content from uploaded files. Learn more about
517
517
  * the
518
- * [file search tool](https://platform.openai.com/docs/guides/tools-file-search).
518
+ * [file search tool](https://developers.openai.com/api/docs/guides/tools-file-search).
519
519
  */
520
520
  export interface FileSearchTool {
521
521
  /**
@@ -595,7 +595,7 @@ export interface FunctionShellTool {
595
595
  /**
596
596
  * Defines a function in your own code the model can choose to call. Learn more
597
597
  * about
598
- * [function calling](https://platform.openai.com/docs/guides/function-calling).
598
+ * [function calling](https://developers.openai.com/api/docs/guides/function-calling).
599
599
  */
600
600
  export interface FunctionTool {
601
601
  /**
@@ -809,8 +809,8 @@ export interface Response {
809
809
  * Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
810
810
  * range of models with different capabilities, performance characteristics, and
811
811
  * price points. Refer to the
812
- * [model guide](https://platform.openai.com/docs/models) to browse and compare
813
- * available models.
812
+ * [model guide](https://developers.openai.com/api/docs/models) to browse and
813
+ * compare available models.
814
814
  */
815
815
  model: Shared.ResponsesModel;
816
816
  /**
@@ -852,17 +852,18 @@ export interface Response {
852
852
  *
853
853
  * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
854
854
  * capabilities, like
855
- * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
856
- * [file search](https://platform.openai.com/docs/guides/tools-file-search).
855
+ * [web search](https://developers.openai.com/api/docs/guides/tools-web-search)
856
+ * or
857
+ * [file search](https://developers.openai.com/api/docs/guides/tools-file-search).
857
858
  * Learn more about
858
- * [built-in tools](https://platform.openai.com/docs/guides/tools).
859
+ * [built-in tools](https://developers.openai.com/api/docs/guides/tools).
859
860
  * - **MCP Tools**: Integrations with third-party systems via custom MCP servers or
860
861
  * predefined connectors such as Google Drive and SharePoint. Learn more about
861
- * [MCP Tools](https://platform.openai.com/docs/guides/tools-connectors-mcp).
862
+ * [MCP Tools](https://developers.openai.com/api/docs/guides/tools-connectors-mcp).
862
863
  * - **Function calls (custom tools)**: Functions that are defined by you, enabling
863
864
  * the model to call your own code with strongly typed arguments and outputs.
864
865
  * Learn more about
865
- * [function calling](https://platform.openai.com/docs/guides/function-calling).
866
+ * [function calling](https://developers.openai.com/api/docs/guides/function-calling).
866
867
  * You can also use custom tools to call your own code.
867
868
  */
868
869
  tools: Array<Tool>;
@@ -876,7 +877,7 @@ export interface Response {
876
877
  top_p: number | null;
877
878
  /**
878
879
  * Whether to run the model response in the background.
879
- * [Learn more](https://platform.openai.com/docs/guides/background).
880
+ * [Learn more](https://developers.openai.com/api/docs/guides/background).
880
881
  */
881
882
  background?: boolean | null;
882
883
  /**
@@ -892,7 +893,7 @@ export interface Response {
892
893
  /**
893
894
  * An upper bound for the number of tokens that can be generated for a response,
894
895
  * including visible output tokens and
895
- * [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
896
+ * [reasoning tokens](https://developers.openai.com/api/docs/guides/reasoning).
896
897
  */
897
898
  max_output_tokens?: number | null;
898
899
  /**
@@ -903,19 +904,23 @@ export interface Response {
903
904
  /**
904
905
  * The unique ID of the previous response to the model. Use this to create
905
906
  * multi-turn conversations. Learn more about
906
- * [conversation state](https://platform.openai.com/docs/guides/conversation-state).
907
+ * [conversation state](https://developers.openai.com/api/docs/guides/conversation-state).
907
908
  * Cannot be used in conjunction with `conversation`.
908
909
  */
909
910
  previous_response_id?: string | null;
910
911
  /**
911
912
  * Reference to a prompt template and its variables.
912
- * [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
913
+ * [Learn more](https://developers.openai.com/api/docs/guides/text?api-mode=responses#version-prompts-in-code).
913
914
  */
914
915
  prompt?: ResponsePrompt | null;
916
+ /**
917
+ * Prompt cache diagnostics requested for this response.
918
+ */
919
+ prompt_cache_diagnostics?: Response.CacheMiss | Response.CacheHit | Response.ComparisonResponseNotFound | Response.Unavailable;
915
920
  /**
916
921
  * Used by OpenAI to cache responses for similar requests to optimize your cache
917
922
  * hit rates. Replaces the `user` field.
918
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
923
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching).
919
924
  */
920
925
  prompt_cache_key?: string | null;
921
926
  /**
@@ -929,7 +934,7 @@ export interface Response {
929
934
  * The retention policy for the prompt cache. Set to `24h` to enable extended
930
935
  * prompt caching, which keeps cached prefixes active for longer, up to a maximum
931
936
  * of 24 hours.
932
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
937
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching#prompt-cache-retention).
933
938
  * This field expresses a maximum retention policy, while
934
939
  * `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
935
940
  * are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
@@ -945,7 +950,7 @@ export interface Response {
945
950
  prompt_cache_retention?: 'in_memory' | '24h' | null;
946
951
  /**
947
952
  * Configuration options for
948
- * [reasoning models](https://platform.openai.com/docs/guides/reasoning).
953
+ * [reasoning models](https://developers.openai.com/api/docs/guides/reasoning).
949
954
  */
950
955
  reasoning?: Shared.Reasoning | null;
951
956
  /**
@@ -954,7 +959,7 @@ export interface Response {
954
959
  * identifies each user, with a maximum length of 64 characters. We recommend
955
960
  * hashing their username or email address, in order to avoid sending us any
956
961
  * identifying information.
957
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
962
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
958
963
  */
959
964
  safety_identifier?: string | null;
960
965
  /**
@@ -966,13 +971,15 @@ export interface Response {
966
971
  * will use 'default'.
967
972
  * - If set to 'default', then the request will be processed with the standard
968
973
  * pricing and performance for the selected model.
969
- * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
970
- * then the request will be processed with the Flex Processing service tier.
971
- * - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
972
- * include the `service_tier=fast` or `service_tier=priority` parameter for
973
- * Responses or Chat Completions. The response will show `service_tier=priority`
974
- * regardless of if you specify `service_tier=fast` or `priority` in your
975
- * request.
974
+ * - If set to
975
+ * '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
976
+ * the request will be processed with the Flex Processing service tier.
977
+ * - To opt-in to
978
+ * [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
979
+ * request level, include the `service_tier=fast` or `service_tier=priority`
980
+ * parameter for Responses or Chat Completions. The response will show
981
+ * `service_tier=priority` regardless of if you specify `service_tier=fast` or
982
+ * `priority` in your request.
976
983
  * - If set to 'ultrafast', then the request will be processed with the
977
984
  * access-controlled Ultrafast Processing service tier. This tier is currently
978
985
  * available for `gpt-5.6-sol`; a response served through it will show
@@ -992,8 +999,8 @@ export interface Response {
992
999
  * Configuration options for a text response from the model. Can be plain text or
993
1000
  * structured JSON data. Learn more:
994
1001
  *
995
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
996
- * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
1002
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
1003
+ * - [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs)
997
1004
  */
998
1005
  text?: ResponseTextConfig;
999
1006
  /**
@@ -1023,7 +1030,7 @@ export interface Response {
1023
1030
  * optimizations. A stable identifier for your end-users. Used to boost cache hit
1024
1031
  * rates by better bucketing similar requests and to help OpenAI detect and prevent
1025
1032
  * abuse.
1026
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
1033
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
1027
1034
  */
1028
1035
  user?: string;
1029
1036
  }
@@ -1179,6 +1186,31 @@ export declare namespace Response {
1179
1186
  type: 'error';
1180
1187
  }
1181
1188
  }
1189
+ interface CacheMiss {
1190
+ /**
1191
+ * The estimated number of input tokens affected after the first detected
1192
+ * divergence.
1193
+ */
1194
+ cache_missed_tokens: number;
1195
+ /**
1196
+ * The reason prompt cache reuse did not occur.
1197
+ */
1198
+ reason: 'model_changed' | 'prompt_cache_key_changed' | 'tools_changed' | 'text_format_changed' | 'reasoning_effort_changed' | 'verbosity_changed' | 'context_compacted' | 'input_changed' | 'service_tier_changed';
1199
+ type: 'cache_miss';
1200
+ /**
1201
+ * The raw token count of the reusable prefix in the compared response.
1202
+ */
1203
+ comparison_reusable_tokens?: number;
1204
+ }
1205
+ interface CacheHit {
1206
+ type: 'cache_hit';
1207
+ }
1208
+ interface ComparisonResponseNotFound {
1209
+ type: 'comparison_response_not_found';
1210
+ }
1211
+ interface Unavailable {
1212
+ type: 'unavailable';
1213
+ }
1182
1214
  /**
1183
1215
  * The prompt-caching options that were applied to the response. Supported for
1184
1216
  * `gpt-5.6` and later models.
@@ -1192,6 +1224,10 @@ export declare namespace Response {
1192
1224
  * The minimum lifetime applied to each cache breakpoint.
1193
1225
  */
1194
1226
  ttl: '30m';
1227
+ /**
1228
+ * The response ID supplied as the prompt cache diagnostics comparison.
1229
+ */
1230
+ comparison_response_id?: string | null;
1195
1231
  }
1196
1232
  }
1197
1233
  /**
@@ -1572,7 +1608,7 @@ export declare namespace ResponseCodeInterpreterToolCall {
1572
1608
  }
1573
1609
  /**
1574
1610
  * A compaction item generated by the
1575
- * [`v1/responses/compact` API](https://platform.openai.com/docs/api-reference/responses/compact).
1611
+ * [`v1/responses/compact` API](https://developers.openai.com/api/reference/resources/responses/methods/compact).
1576
1612
  */
1577
1613
  export interface ResponseCompactionItem {
1578
1614
  /**
@@ -1594,7 +1630,7 @@ export interface ResponseCompactionItem {
1594
1630
  }
1595
1631
  /**
1596
1632
  * A compaction item generated by the
1597
- * [`v1/responses/compact` API](https://platform.openai.com/docs/api-reference/responses/compact).
1633
+ * [`v1/responses/compact` API](https://developers.openai.com/api/reference/resources/responses/methods/compact).
1598
1634
  */
1599
1635
  export interface ResponseCompactionItemParam {
1600
1636
  /**
@@ -1629,7 +1665,7 @@ export interface ResponseCompletedEvent {
1629
1665
  }
1630
1666
  /**
1631
1667
  * A tool call to a computer use tool. See the
1632
- * [computer use guide](https://platform.openai.com/docs/guides/tools-computer-use)
1668
+ * [computer use guide](https://developers.openai.com/api/docs/guides/tools-computer-use)
1633
1669
  * for more information.
1634
1670
  */
1635
1671
  export interface ResponseComputerToolCall {
@@ -2473,7 +2509,7 @@ export interface ResponseFileSearchCallSearchingEvent {
2473
2509
  }
2474
2510
  /**
2475
2511
  * The results of a file search tool call. See the
2476
- * [file search guide](https://platform.openai.com/docs/guides/tools-file-search)
2512
+ * [file search guide](https://developers.openai.com/api/docs/guides/tools-file-search)
2477
2513
  * for more information.
2478
2514
  */
2479
2515
  export interface ResponseFileSearchToolCall {
@@ -2534,7 +2570,7 @@ export declare namespace ResponseFileSearchToolCall {
2534
2570
  *
2535
2571
  * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
2536
2572
  * ensures the model will match your supplied JSON schema. Learn more in the
2537
- * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
2573
+ * [Structured Outputs guide](https://developers.openai.com/api/docs/guides/structured-outputs).
2538
2574
  *
2539
2575
  * The default format is `{ "type": "text" }` with no additional options.
2540
2576
  *
@@ -2548,7 +2584,7 @@ export type ResponseFormatTextConfig = Shared.ResponseFormatText | ResponseForma
2548
2584
  /**
2549
2585
  * JSON Schema response format. Used to generate structured JSON responses. Learn
2550
2586
  * more about
2551
- * [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs).
2587
+ * [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs).
2552
2588
  */
2553
2589
  export interface ResponseFormatTextJSONSchemaConfig {
2554
2590
  /**
@@ -2577,7 +2613,7 @@ export interface ResponseFormatTextJSONSchemaConfig {
2577
2613
  * true, the model will always follow the exact schema defined in the `schema`
2578
2614
  * field. Only a subset of JSON Schema is supported when `strict` is `true`. To
2579
2615
  * learn more, read the
2580
- * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
2616
+ * [Structured Outputs guide](https://developers.openai.com/api/docs/guides/structured-outputs).
2581
2617
  */
2582
2618
  strict?: boolean | null;
2583
2619
  }
@@ -2618,10 +2654,6 @@ export interface ResponseFunctionCallArgumentsDoneEvent {
2618
2654
  * The ID of the item.
2619
2655
  */
2620
2656
  item_id: string;
2621
- /**
2622
- * The name of the function that was called.
2623
- */
2624
- name: string;
2625
2657
  /**
2626
2658
  * The index of the output item.
2627
2659
  */
@@ -2846,7 +2878,7 @@ export declare namespace ResponseFunctionShellToolCallOutput {
2846
2878
  }
2847
2879
  /**
2848
2880
  * A tool call to run a function. See the
2849
- * [function calling guide](https://platform.openai.com/docs/guides/function-calling)
2881
+ * [function calling guide](https://developers.openai.com/api/docs/guides/function-calling)
2850
2882
  * for more information.
2851
2883
  */
2852
2884
  export interface ResponseFunctionToolCall {
@@ -2902,7 +2934,7 @@ export declare namespace ResponseFunctionToolCall {
2902
2934
  }
2903
2935
  /**
2904
2936
  * A tool call to run a function. See the
2905
- * [function calling guide](https://platform.openai.com/docs/guides/function-calling)
2937
+ * [function calling guide](https://developers.openai.com/api/docs/guides/function-calling)
2906
2938
  * for more information.
2907
2939
  */
2908
2940
  export interface ResponseFunctionToolCallItem extends ResponseFunctionToolCall {
@@ -2980,8 +3012,8 @@ export declare namespace ResponseFunctionToolCallOutputItem {
2980
3012
  }
2981
3013
  /**
2982
3014
  * The results of a web search tool call. See the
2983
- * [web search guide](https://platform.openai.com/docs/guides/tools-web-search) for
2984
- * more information.
3015
+ * [web search guide](https://developers.openai.com/api/docs/guides/tools-web-search)
3016
+ * for more information.
2985
3017
  */
2986
3018
  export interface ResponseFunctionWebSearch {
2987
3019
  /**
@@ -2996,7 +3028,7 @@ export interface ResponseFunctionWebSearch {
2996
3028
  /**
2997
3029
  * The status of the web search tool call.
2998
3030
  */
2999
- status: 'in_progress' | 'searching' | 'completed' | 'failed';
3031
+ status: 'in_progress' | 'searching' | 'completed' | 'failed' | 'incomplete';
3000
3032
  /**
3001
3033
  * The type of the web search tool call. Always `web_search_call`.
3002
3034
  */
@@ -3382,7 +3414,7 @@ export declare namespace ResponseInputFileContent {
3382
3414
  }
3383
3415
  /**
3384
3416
  * An image input to the model. Learn about
3385
- * [image inputs](https://platform.openai.com/docs/guides/vision).
3417
+ * [image inputs](https://developers.openai.com/api/docs/guides/images-vision).
3386
3418
  */
3387
3419
  export interface ResponseInputImage {
3388
3420
  /**
@@ -3425,7 +3457,7 @@ export declare namespace ResponseInputImage {
3425
3457
  }
3426
3458
  /**
3427
3459
  * An image input to the model. Learn about
3428
- * [image inputs](https://platform.openai.com/docs/guides/vision)
3460
+ * [image inputs](https://developers.openai.com/api/docs/guides/images-vision)
3429
3461
  */
3430
3462
  export interface ResponseInputImageContent {
3431
3463
  /**
@@ -3671,6 +3703,15 @@ export declare namespace ResponseInputItem {
3671
3703
  * The type of the image generation call. Always `image_generation_call`.
3672
3704
  */
3673
3705
  type: 'image_generation_call';
3706
+ /**
3707
+ * The quality of the image generated by the image generation tool call. One of
3708
+ * `low`, `medium`, `high`, `xhigh`, `max`, or `auto`.
3709
+ */
3710
+ quality?: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'auto' | null;
3711
+ /**
3712
+ * The image dimensions as a `WIDTHxHEIGHT` string, for example `1536x864`.
3713
+ */
3714
+ size?: (string & {}) | '1024x1024' | '1024x1536' | '1536x1024' | null;
3674
3715
  }
3675
3716
  /**
3676
3717
  * A tool call to run a command on the local shell.
@@ -4411,6 +4452,15 @@ export declare namespace ResponseItem {
4411
4452
  * The type of the image generation call. Always `image_generation_call`.
4412
4453
  */
4413
4454
  type: 'image_generation_call';
4455
+ /**
4456
+ * The quality of the image generated by the image generation tool call. One of
4457
+ * `low`, `medium`, `high`, `xhigh`, `max`, or `auto`.
4458
+ */
4459
+ quality?: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'auto' | null;
4460
+ /**
4461
+ * The image dimensions as a `WIDTHxHEIGHT` string, for example `1536x864`.
4462
+ */
4463
+ size?: (string & {}) | '1024x1024' | '1024x1536' | '1536x1024' | null;
4414
4464
  }
4415
4465
  /**
4416
4466
  * A tool call to run a command on the local shell.
@@ -4926,6 +4976,15 @@ export declare namespace ResponseOutputItem {
4926
4976
  * The type of the image generation call. Always `image_generation_call`.
4927
4977
  */
4928
4978
  type: 'image_generation_call';
4979
+ /**
4980
+ * The quality of the image generated by the image generation tool call. One of
4981
+ * `low`, `medium`, `high`, `xhigh`, `max`, or `auto`.
4982
+ */
4983
+ quality?: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'auto' | null;
4984
+ /**
4985
+ * The image dimensions as a `WIDTHxHEIGHT` string, for example `1536x864`.
4986
+ */
4987
+ size?: (string & {}) | '1024x1024' | '1024x1536' | '1536x1024' | null;
4929
4988
  }
4930
4989
  /**
4931
4990
  * A tool call to run a command on the local shell.
@@ -5500,7 +5559,7 @@ export declare namespace ResponseOutputTextAnnotationAddedEvent {
5500
5559
  }
5501
5560
  /**
5502
5561
  * Reference to a prompt template and its variables.
5503
- * [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
5562
+ * [Learn more](https://developers.openai.com/api/docs/guides/text?api-mode=responses#version-prompts-in-code).
5504
5563
  */
5505
5564
  export interface ResponsePrompt {
5506
5565
  /**
@@ -5541,7 +5600,7 @@ export interface ResponseQueuedEvent {
5541
5600
  * A description of the chain of thought used by a reasoning model while generating
5542
5601
  * a response. Be sure to include these items in your `input` to the Responses API
5543
5602
  * for subsequent turns of a conversation if you are manually
5544
- * [managing context](https://platform.openai.com/docs/guides/conversation-state).
5603
+ * [managing context](https://developers.openai.com/api/docs/guides/conversation-state).
5545
5604
  */
5546
5605
  export interface ResponseReasoningItem {
5547
5606
  /**
@@ -6528,8 +6587,8 @@ export type ResponseStreamEvent = ResponseAudioDeltaEvent | ResponseAudioDoneEve
6528
6587
  * Configuration options for a text response from the model. Can be plain text or
6529
6588
  * structured JSON data. Learn more:
6530
6589
  *
6531
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
6532
- * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
6590
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
6591
+ * - [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs)
6533
6592
  */
6534
6593
  export interface ResponseTextConfig {
6535
6594
  /**
@@ -6537,7 +6596,7 @@ export interface ResponseTextConfig {
6537
6596
  *
6538
6597
  * Configuring `{ "type": "json_schema" }` enables Structured Outputs, which
6539
6598
  * ensures the model will match your supplied JSON schema. Learn more in the
6540
- * [Structured Outputs guide](https://platform.openai.com/docs/guides/structured-outputs).
6599
+ * [Structured Outputs guide](https://developers.openai.com/api/docs/guides/structured-outputs).
6541
6600
  *
6542
6601
  * The default format is `{ "type": "text" }` with no additional options.
6543
6602
  *
@@ -6811,7 +6870,7 @@ export declare namespace ResponseUsage {
6811
6870
  cache_write_tokens: number;
6812
6871
  /**
6813
6872
  * The number of tokens that were retrieved from the cache.
6814
- * [More on prompt caching](https://platform.openai.com/docs/guides/prompt-caching).
6873
+ * [More on prompt caching](https://developers.openai.com/api/docs/guides/prompt-caching).
6815
6874
  */
6816
6875
  cached_tokens: number;
6817
6876
  }
@@ -6923,7 +6982,7 @@ export declare namespace ResponsesClientEvent {
6923
6982
  type: 'response.create';
6924
6983
  /**
6925
6984
  * Whether to run the model response in the background.
6926
- * [Learn more](https://platform.openai.com/docs/guides/background).
6985
+ * [Learn more](https://developers.openai.com/api/docs/guides/background).
6927
6986
  */
6928
6987
  background?: boolean | null;
6929
6988
  /**
@@ -6963,11 +7022,11 @@ export declare namespace ResponsesClientEvent {
6963
7022
  *
6964
7023
  * Learn more:
6965
7024
  *
6966
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
6967
- * - [Image inputs](https://platform.openai.com/docs/guides/images)
6968
- * - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
6969
- * - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
6970
- * - [Function calling](https://platform.openai.com/docs/guides/function-calling)
7025
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
7026
+ * - [Image inputs](https://developers.openai.com/api/docs/guides/images-vision)
7027
+ * - [File inputs](https://developers.openai.com/api/docs/guides/file-inputs)
7028
+ * - [Conversation state](https://developers.openai.com/api/docs/guides/conversation-state)
7029
+ * - [Function calling](https://developers.openai.com/api/docs/guides/function-calling)
6971
7030
  */
6972
7031
  input?: string | ResponsesAPI.ResponseInput;
6973
7032
  /**
@@ -6981,7 +7040,7 @@ export declare namespace ResponsesClientEvent {
6981
7040
  /**
6982
7041
  * An upper bound for the number of tokens that can be generated for a response,
6983
7042
  * including visible output tokens and
6984
- * [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
7043
+ * [reasoning tokens](https://developers.openai.com/api/docs/guides/reasoning).
6985
7044
  */
6986
7045
  max_output_tokens?: number | null;
6987
7046
  /**
@@ -7004,8 +7063,8 @@ export declare namespace ResponsesClientEvent {
7004
7063
  * Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
7005
7064
  * range of models with different capabilities, performance characteristics, and
7006
7065
  * price points. Refer to the
7007
- * [model guide](https://platform.openai.com/docs/models) to browse and compare
7008
- * available models.
7066
+ * [model guide](https://developers.openai.com/api/docs/models) to browse and
7067
+ * compare available models.
7009
7068
  */
7010
7069
  model?: Shared.ResponsesModel;
7011
7070
  /**
@@ -7019,19 +7078,19 @@ export declare namespace ResponsesClientEvent {
7019
7078
  /**
7020
7079
  * The unique ID of the previous response to the model. Use this to create
7021
7080
  * multi-turn conversations. Learn more about
7022
- * [conversation state](https://platform.openai.com/docs/guides/conversation-state).
7081
+ * [conversation state](https://developers.openai.com/api/docs/guides/conversation-state).
7023
7082
  * Cannot be used in conjunction with `conversation`.
7024
7083
  */
7025
7084
  previous_response_id?: string | null;
7026
7085
  /**
7027
7086
  * Reference to a prompt template and its variables.
7028
- * [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
7087
+ * [Learn more](https://developers.openai.com/api/docs/guides/text?api-mode=responses#version-prompts-in-code).
7029
7088
  */
7030
7089
  prompt?: ResponsesAPI.ResponsePrompt | null;
7031
7090
  /**
7032
7091
  * Used by OpenAI to cache responses for similar requests to optimize your cache
7033
7092
  * hit rates. Replaces the `user` field.
7034
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
7093
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching).
7035
7094
  */
7036
7095
  prompt_cache_key?: string | null;
7037
7096
  /**
@@ -7042,7 +7101,7 @@ export declare namespace ResponsesClientEvent {
7042
7101
  * up to the latest 80 breakpoints in the conversation, without a content-block
7043
7102
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
7044
7103
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
7045
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
7104
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
7046
7105
  * for current details.
7047
7106
  */
7048
7107
  prompt_cache_options?: ResponseCreate.PromptCacheOptions;
@@ -7052,7 +7111,7 @@ export declare namespace ResponsesClientEvent {
7052
7111
  * The retention policy for the prompt cache. Set to `24h` to enable extended
7053
7112
  * prompt caching, which keeps cached prefixes active for longer, up to a maximum
7054
7113
  * of 24 hours.
7055
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
7114
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching#prompt-cache-retention).
7056
7115
  * This field expresses a maximum retention policy, while
7057
7116
  * `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
7058
7117
  * are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
@@ -7068,7 +7127,7 @@ export declare namespace ResponsesClientEvent {
7068
7127
  prompt_cache_retention?: 'in_memory' | '24h' | null;
7069
7128
  /**
7070
7129
  * Configuration options for
7071
- * [reasoning models](https://platform.openai.com/docs/guides/reasoning).
7130
+ * [reasoning models](https://developers.openai.com/api/docs/guides/reasoning).
7072
7131
  */
7073
7132
  reasoning?: Shared.Reasoning | null;
7074
7133
  /**
@@ -7077,7 +7136,7 @@ export declare namespace ResponsesClientEvent {
7077
7136
  * identifies each user, with a maximum length of 64 characters. We recommend
7078
7137
  * hashing their username or email address, in order to avoid sending us any
7079
7138
  * identifying information.
7080
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
7139
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
7081
7140
  */
7082
7141
  safety_identifier?: string | null;
7083
7142
  /**
@@ -7088,13 +7147,15 @@ export declare namespace ResponsesClientEvent {
7088
7147
  * will use 'default'.
7089
7148
  * - If set to 'default', then the request will be processed with the standard
7090
7149
  * pricing and performance for the selected model.
7091
- * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
7092
- * then the request will be processed with the Flex Processing service tier.
7093
- * - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
7094
- * include the `service_tier=fast` or `service_tier=priority` parameter for
7095
- * Responses or Chat Completions. The response will show `service_tier=priority`
7096
- * regardless of if you specify `service_tier=fast` or `priority` in your
7097
- * request.
7150
+ * - If set to
7151
+ * '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
7152
+ * the request will be processed with the Flex Processing service tier.
7153
+ * - To opt-in to
7154
+ * [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
7155
+ * request level, include the `service_tier=fast` or `service_tier=priority`
7156
+ * parameter for Responses or Chat Completions. The response will show
7157
+ * `service_tier=priority` regardless of if you specify `service_tier=fast` or
7158
+ * `priority` in your request.
7098
7159
  * - If set to 'ultrafast', then the request will be processed with the
7099
7160
  * access-controlled Ultrafast Processing service tier. This tier is currently
7100
7161
  * available for `gpt-5.6-sol`; a response served through it will show
@@ -7109,6 +7170,9 @@ export declare namespace ResponsesClientEvent {
7109
7170
  service_tier?: ResponsesAPI.ServiceTier | null;
7110
7171
  /**
7111
7172
  * Whether to store the generated model response for later retrieval via API.
7173
+ * Defaults to true when omitted. If set to true, response data will be stored for
7174
+ * at least 30 days, subject to the
7175
+ * [data retention exceptions](https://developers.openai.com/api/docs/guides/your-data#v1responses).
7112
7176
  */
7113
7177
  store?: boolean | null;
7114
7178
  /**
@@ -7116,7 +7180,7 @@ export declare namespace ResponsesClientEvent {
7116
7180
  * generated using
7117
7181
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
7118
7182
  * See the
7119
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
7183
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
7120
7184
  * for more information.
7121
7185
  */
7122
7186
  stream?: boolean | null;
@@ -7143,8 +7207,8 @@ export declare namespace ResponsesClientEvent {
7143
7207
  * Configuration options for a text response from the model. Can be plain text or
7144
7208
  * structured JSON data. Learn more:
7145
7209
  *
7146
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
7147
- * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
7210
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
7211
+ * - [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs)
7148
7212
  */
7149
7213
  text?: ResponsesAPI.ResponseTextConfig;
7150
7214
  /**
@@ -7161,17 +7225,18 @@ export declare namespace ResponsesClientEvent {
7161
7225
  *
7162
7226
  * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
7163
7227
  * capabilities, like
7164
- * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
7165
- * [file search](https://platform.openai.com/docs/guides/tools-file-search).
7228
+ * [web search](https://developers.openai.com/api/docs/guides/tools-web-search)
7229
+ * or
7230
+ * [file search](https://developers.openai.com/api/docs/guides/tools-file-search).
7166
7231
  * Learn more about
7167
- * [built-in tools](https://platform.openai.com/docs/guides/tools).
7232
+ * [built-in tools](https://developers.openai.com/api/docs/guides/tools).
7168
7233
  * - **MCP Tools**: Integrations with third-party systems via custom MCP servers or
7169
7234
  * predefined connectors such as Google Drive and SharePoint. Learn more about
7170
- * [MCP Tools](https://platform.openai.com/docs/guides/tools-connectors-mcp).
7235
+ * [MCP Tools](https://developers.openai.com/api/docs/guides/tools-connectors-mcp).
7171
7236
  * - **Function calls (custom tools)**: Functions that are defined by you, enabling
7172
7237
  * the model to call your own code with strongly typed arguments and outputs.
7173
7238
  * Learn more about
7174
- * [function calling](https://platform.openai.com/docs/guides/function-calling).
7239
+ * [function calling](https://developers.openai.com/api/docs/guides/function-calling).
7175
7240
  * You can also use custom tools to call your own code.
7176
7241
  */
7177
7242
  tools?: Array<ResponsesAPI.Tool>;
@@ -7205,7 +7270,7 @@ export declare namespace ResponsesClientEvent {
7205
7270
  * optimizations. A stable identifier for your end-users. Used to boost cache hit
7206
7271
  * rates by better bucketing similar requests and to help OpenAI detect and prevent
7207
7272
  * abuse.
7208
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
7273
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
7209
7274
  */
7210
7275
  user?: string;
7211
7276
  }
@@ -7271,10 +7336,15 @@ export declare namespace ResponsesClientEvent {
7271
7336
  * up to the latest 80 breakpoints in the conversation, without a content-block
7272
7337
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
7273
7338
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
7274
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
7339
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
7275
7340
  * for current details.
7276
7341
  */
7277
7342
  interface PromptCacheOptions {
7343
+ /**
7344
+ * The ID of a response to compare when diagnosing prompt cache reuse. Supplying
7345
+ * this field requests prompt cache diagnostics when the feature is enabled.
7346
+ */
7347
+ comparison_response_id?: string | null;
7278
7348
  /**
7279
7349
  * Controls whether OpenAI automatically creates an implicit cache breakpoint.
7280
7350
  * Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
@@ -7998,13 +8068,15 @@ export declare namespace ResponsesServerEvent {
7998
8068
  * will use 'default'.
7999
8069
  * - If set to 'default', then the request will be processed with the standard
8000
8070
  * pricing and performance for the selected model.
8001
- * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
8002
- * then the request will be processed with the Flex Processing service tier.
8003
- * - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
8004
- * include the `service_tier=fast` or `service_tier=priority` parameter for
8005
- * Responses or Chat Completions. The response will show `service_tier=priority`
8006
- * regardless of if you specify `service_tier=fast` or `priority` in your
8007
- * request.
8071
+ * - If set to
8072
+ * '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
8073
+ * the request will be processed with the Flex Processing service tier.
8074
+ * - To opt-in to
8075
+ * [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
8076
+ * request level, include the `service_tier=fast` or `service_tier=priority`
8077
+ * parameter for Responses or Chat Completions. The response will show
8078
+ * `service_tier=priority` regardless of if you specify `service_tier=fast` or
8079
+ * `priority` in your request.
8008
8080
  * - If set to 'ultrafast', then the request will be processed with the
8009
8081
  * access-controlled Ultrafast Processing service tier. This tier is currently
8010
8082
  * available for `gpt-5.6-sol`; a response served through it will show
@@ -8039,7 +8111,7 @@ export declare namespace Tool {
8039
8111
  /**
8040
8112
  * Give the model access to additional tools via remote Model Context Protocol
8041
8113
  * (MCP) servers.
8042
- * [Learn more about MCP](https://platform.openai.com/docs/guides/tools-remote-mcp).
8114
+ * [Learn more about MCP](https://developers.openai.com/api/docs/guides/tools-connectors-mcp).
8043
8115
  */
8044
8116
  interface Mcp {
8045
8117
  /**
@@ -8068,7 +8140,7 @@ export declare namespace Tool {
8068
8140
  * Identifier for service connectors, like those available in ChatGPT. One of
8069
8141
  * `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more about
8070
8142
  * service connectors
8071
- * [here](https://platform.openai.com/docs/guides/tools-remote-mcp#connectors).
8143
+ * [here](https://developers.openai.com/api/docs/guides/tools-connectors-mcp#connectors).
8072
8144
  *
8073
8145
  * Currently supported `connector_id` values are:
8074
8146
  *
@@ -8244,9 +8316,11 @@ export declare namespace Tool {
8244
8316
  * one of `transparent`, `opaque`, or `auto` (default value). When `auto` is used,
8245
8317
  * the model will automatically determine the best background for the image.
8246
8318
  *
8247
- * Transparent backgrounds are available for supported GPT Image models. For
8248
- * `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in preview. When
8249
- * using `transparent`, set the output format to `png` or `webp`.
8319
+ * `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including their `2026-09-08`
8320
+ * snapshots, support `opaque` and `transparent` backgrounds. Transparent
8321
+ * backgrounds are available for supported GPT Image models. For `gpt-image-2` and
8322
+ * `gpt-image-2-2026-04-21`, this support is in preview. When using `transparent`,
8323
+ * set the output format to `png` or `webp`.
8250
8324
  */
8251
8325
  background?: 'transparent' | 'opaque' | 'auto';
8252
8326
  /**
@@ -8263,10 +8337,12 @@ export declare namespace Tool {
8263
8337
  input_image_mask?: ImageGeneration.InputImageMask;
8264
8338
  /**
8265
8339
  * The image generation model to use. One of `gpt-image-1`, `gpt-image-1-mini`,
8266
- * `gpt-image-1.5`, `gpt-image-2`, `gpt-image-2-2026-04-21`, or
8340
+ * `gpt-image-1.5`, `gpt-image-2`, `gpt-image-2-2026-04-21`,
8341
+ * `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`,
8342
+ * `gpt-image-2.5-flare`, `gpt-image-2.5-flare-2026-09-08`, or
8267
8343
  * `chatgpt-image-latest`. Default: `gpt-image-1`.
8268
8344
  */
8269
- model?: (string & {}) | 'gpt-image-1' | 'gpt-image-1-mini' | 'gpt-image-2' | 'gpt-image-2-2026-04-21' | 'gpt-image-1.5' | 'chatgpt-image-latest';
8345
+ model?: (string & {}) | 'gpt-image-1' | 'gpt-image-1-mini' | 'gpt-image-2' | 'gpt-image-2-2026-04-21' | 'gpt-image-2.5-sunburst' | 'gpt-image-2.5-sunburst-2026-09-08' | 'gpt-image-2.5-flare' | 'gpt-image-2.5-flare-2026-09-08' | 'gpt-image-1.5' | 'chatgpt-image-latest';
8270
8346
  /**
8271
8347
  * Moderation level for the generated image. Default: `auto`.
8272
8348
  */
@@ -8286,22 +8362,25 @@ export declare namespace Tool {
8286
8362
  */
8287
8363
  partial_images?: number;
8288
8364
  /**
8289
- * The quality of the generated image. One of `low`, `medium`, `high`, or `auto`.
8290
- * Default: `auto`.
8291
- */
8292
- quality?: 'low' | 'medium' | 'high' | 'auto';
8293
- /**
8294
- * The size of the generated images. For `gpt-image-2` and
8295
- * `gpt-image-2-2026-04-21`, arbitrary resolutions are supported as `WIDTHxHEIGHT`
8296
- * strings, for example `1536x864`. Width and height must both be divisible by 16
8297
- * and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above
8298
- * `2560x1440` are experimental, and the maximum supported resolution is
8299
- * `3840x2160`. The requested size must also satisfy the model's current pixel and
8300
- * edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are
8301
- * supported by the GPT image models; `auto` is supported for models that allow
8302
- * automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or
8303
- * `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or
8304
- * `1024x1792`.
8365
+ * The quality of the generated image. The GPT image models support `low`,
8366
+ * `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,
8367
+ * including their `2026-09-08` snapshots, also support `xhigh` and `max`. Default:
8368
+ * `auto`.
8369
+ */
8370
+ quality?: 'low' | 'medium' | 'high' | 'xhigh' | 'max' | 'auto';
8371
+ /**
8372
+ * The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`,
8373
+ * `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`,
8374
+ * `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary
8375
+ * resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`.
8376
+ * Width and height must both be divisible by 16 and the requested aspect ratio
8377
+ * must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and
8378
+ * the maximum supported resolution is `3840x2160`. The requested size must also
8379
+ * satisfy the model's current pixel and edge limits. The standard sizes
8380
+ * `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models;
8381
+ * `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use
8382
+ * one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of
8383
+ * `1024x1024`, `1792x1024`, or `1024x1792`.
8305
8384
  */
8306
8385
  size?: (string & {}) | '1024x1024' | '1024x1536' | '1536x1024' | 'auto';
8307
8386
  }
@@ -8440,12 +8519,12 @@ export interface ToolChoiceShell {
8440
8519
  }
8441
8520
  /**
8442
8521
  * Indicates that the model should use a built-in tool to generate a response.
8443
- * [Learn more about built-in tools](https://platform.openai.com/docs/guides/tools).
8522
+ * [Learn more about built-in tools](https://developers.openai.com/api/docs/guides/tools).
8444
8523
  */
8445
8524
  export interface ToolChoiceTypes {
8446
8525
  /**
8447
8526
  * The type of hosted tool the model should to use. Learn more about
8448
- * [built-in tools](https://platform.openai.com/docs/guides/tools).
8527
+ * [built-in tools](https://developers.openai.com/api/docs/guides/tools).
8449
8528
  *
8450
8529
  * Allowed values are:
8451
8530
  *
@@ -8484,7 +8563,7 @@ export interface ToolSearchTool {
8484
8563
  /**
8485
8564
  * This tool searches the web for relevant results to use in a response. Learn more
8486
8565
  * about the
8487
- * [web search tool](https://platform.openai.com/docs/guides/tools-web-search).
8566
+ * [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).
8488
8567
  */
8489
8568
  export interface WebSearchPreviewTool {
8490
8569
  /**
@@ -8534,7 +8613,7 @@ export declare namespace WebSearchPreviewTool {
8534
8613
  }
8535
8614
  /**
8536
8615
  * Search the Internet for sources related to the prompt. Learn more about the
8537
- * [web search tool](https://platform.openai.com/docs/guides/tools-web-search).
8616
+ * [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).
8538
8617
  */
8539
8618
  export interface WebSearchTool {
8540
8619
  /**
@@ -8606,7 +8685,7 @@ export type ResponseCreateParams = ResponseCreateParamsNonStreaming | ResponseCr
8606
8685
  export interface ResponseCreateParamsBase {
8607
8686
  /**
8608
8687
  * Whether to run the model response in the background.
8609
- * [Learn more](https://platform.openai.com/docs/guides/background).
8688
+ * [Learn more](https://developers.openai.com/api/docs/guides/background).
8610
8689
  */
8611
8690
  background?: boolean | null;
8612
8691
  /**
@@ -8649,11 +8728,11 @@ export interface ResponseCreateParamsBase {
8649
8728
  *
8650
8729
  * Learn more:
8651
8730
  *
8652
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
8653
- * - [Image inputs](https://platform.openai.com/docs/guides/images)
8654
- * - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
8655
- * - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
8656
- * - [Function calling](https://platform.openai.com/docs/guides/function-calling)
8731
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
8732
+ * - [Image inputs](https://developers.openai.com/api/docs/guides/images-vision)
8733
+ * - [File inputs](https://developers.openai.com/api/docs/guides/file-inputs)
8734
+ * - [Conversation state](https://developers.openai.com/api/docs/guides/conversation-state)
8735
+ * - [Function calling](https://developers.openai.com/api/docs/guides/function-calling)
8657
8736
  */
8658
8737
  input?: string | ResponseInput;
8659
8738
  /**
@@ -8667,7 +8746,7 @@ export interface ResponseCreateParamsBase {
8667
8746
  /**
8668
8747
  * An upper bound for the number of tokens that can be generated for a response,
8669
8748
  * including visible output tokens and
8670
- * [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
8749
+ * [reasoning tokens](https://developers.openai.com/api/docs/guides/reasoning).
8671
8750
  */
8672
8751
  max_output_tokens?: number | null;
8673
8752
  /**
@@ -8683,8 +8762,8 @@ export interface ResponseCreateParamsBase {
8683
8762
  * Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
8684
8763
  * range of models with different capabilities, performance characteristics, and
8685
8764
  * price points. Refer to the
8686
- * [model guide](https://platform.openai.com/docs/models) to browse and compare
8687
- * available models.
8765
+ * [model guide](https://developers.openai.com/api/docs/models) to browse and
8766
+ * compare available models.
8688
8767
  */
8689
8768
  model?: Shared.ResponsesModel;
8690
8769
  /**
@@ -8698,19 +8777,19 @@ export interface ResponseCreateParamsBase {
8698
8777
  /**
8699
8778
  * The unique ID of the previous response to the model. Use this to create
8700
8779
  * multi-turn conversations. Learn more about
8701
- * [conversation state](https://platform.openai.com/docs/guides/conversation-state).
8780
+ * [conversation state](https://developers.openai.com/api/docs/guides/conversation-state).
8702
8781
  * Cannot be used in conjunction with `conversation`.
8703
8782
  */
8704
8783
  previous_response_id?: string | null;
8705
8784
  /**
8706
8785
  * Reference to a prompt template and its variables.
8707
- * [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
8786
+ * [Learn more](https://developers.openai.com/api/docs/guides/text?api-mode=responses#version-prompts-in-code).
8708
8787
  */
8709
8788
  prompt?: ResponsePrompt | null;
8710
8789
  /**
8711
8790
  * Used by OpenAI to cache responses for similar requests to optimize your cache
8712
8791
  * hit rates. Replaces the `user` field.
8713
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
8792
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching).
8714
8793
  */
8715
8794
  prompt_cache_key?: string | null;
8716
8795
  /**
@@ -8721,7 +8800,7 @@ export interface ResponseCreateParamsBase {
8721
8800
  * up to the latest 80 breakpoints in the conversation, without a content-block
8722
8801
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
8723
8802
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
8724
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
8803
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
8725
8804
  * for current details.
8726
8805
  */
8727
8806
  prompt_cache_options?: ResponseCreateParams.PromptCacheOptions;
@@ -8731,7 +8810,7 @@ export interface ResponseCreateParamsBase {
8731
8810
  * The retention policy for the prompt cache. Set to `24h` to enable extended
8732
8811
  * prompt caching, which keeps cached prefixes active for longer, up to a maximum
8733
8812
  * of 24 hours.
8734
- * [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
8813
+ * [Learn more](https://developers.openai.com/api/docs/guides/prompt-caching#prompt-cache-retention).
8735
8814
  * This field expresses a maximum retention policy, while
8736
8815
  * `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
8737
8816
  * are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
@@ -8747,7 +8826,7 @@ export interface ResponseCreateParamsBase {
8747
8826
  prompt_cache_retention?: 'in_memory' | '24h' | null;
8748
8827
  /**
8749
8828
  * Configuration options for
8750
- * [reasoning models](https://platform.openai.com/docs/guides/reasoning).
8829
+ * [reasoning models](https://developers.openai.com/api/docs/guides/reasoning).
8751
8830
  */
8752
8831
  reasoning?: Shared.Reasoning | null;
8753
8832
  /**
@@ -8756,7 +8835,7 @@ export interface ResponseCreateParamsBase {
8756
8835
  * identifies each user, with a maximum length of 64 characters. We recommend
8757
8836
  * hashing their username or email address, in order to avoid sending us any
8758
8837
  * identifying information.
8759
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
8838
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
8760
8839
  */
8761
8840
  safety_identifier?: string | null;
8762
8841
  /**
@@ -8768,13 +8847,15 @@ export interface ResponseCreateParamsBase {
8768
8847
  * will use 'default'.
8769
8848
  * - If set to 'default', then the request will be processed with the standard
8770
8849
  * pricing and performance for the selected model.
8771
- * - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
8772
- * then the request will be processed with the Flex Processing service tier.
8773
- * - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
8774
- * include the `service_tier=fast` or `service_tier=priority` parameter for
8775
- * Responses or Chat Completions. The response will show `service_tier=priority`
8776
- * regardless of if you specify `service_tier=fast` or `priority` in your
8777
- * request.
8850
+ * - If set to
8851
+ * '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
8852
+ * the request will be processed with the Flex Processing service tier.
8853
+ * - To opt-in to
8854
+ * [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
8855
+ * request level, include the `service_tier=fast` or `service_tier=priority`
8856
+ * parameter for Responses or Chat Completions. The response will show
8857
+ * `service_tier=priority` regardless of if you specify `service_tier=fast` or
8858
+ * `priority` in your request.
8778
8859
  * - If set to 'ultrafast', then the request will be processed with the
8779
8860
  * access-controlled Ultrafast Processing service tier. This tier is currently
8780
8861
  * available for `gpt-5.6-sol`; a response served through it will show
@@ -8787,6 +8868,9 @@ export interface ResponseCreateParamsBase {
8787
8868
  service_tier?: ServiceTier | null;
8788
8869
  /**
8789
8870
  * Whether to store the generated model response for later retrieval via API.
8871
+ * Defaults to true when omitted. If set to true, response data will be stored for
8872
+ * at least 30 days, subject to the
8873
+ * [data retention exceptions](https://developers.openai.com/api/docs/guides/your-data#v1responses).
8790
8874
  */
8791
8875
  store?: boolean | null;
8792
8876
  /**
@@ -8794,7 +8878,7 @@ export interface ResponseCreateParamsBase {
8794
8878
  * generated using
8795
8879
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
8796
8880
  * See the
8797
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
8881
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
8798
8882
  * for more information.
8799
8883
  */
8800
8884
  stream?: boolean | null;
@@ -8813,8 +8897,8 @@ export interface ResponseCreateParamsBase {
8813
8897
  * Configuration options for a text response from the model. Can be plain text or
8814
8898
  * structured JSON data. Learn more:
8815
8899
  *
8816
- * - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
8817
- * - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
8900
+ * - [Text inputs and outputs](https://developers.openai.com/api/docs/guides/text)
8901
+ * - [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs)
8818
8902
  */
8819
8903
  text?: ResponseTextConfig;
8820
8904
  /**
@@ -8831,17 +8915,18 @@ export interface ResponseCreateParamsBase {
8831
8915
  *
8832
8916
  * - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
8833
8917
  * capabilities, like
8834
- * [web search](https://platform.openai.com/docs/guides/tools-web-search) or
8835
- * [file search](https://platform.openai.com/docs/guides/tools-file-search).
8918
+ * [web search](https://developers.openai.com/api/docs/guides/tools-web-search)
8919
+ * or
8920
+ * [file search](https://developers.openai.com/api/docs/guides/tools-file-search).
8836
8921
  * Learn more about
8837
- * [built-in tools](https://platform.openai.com/docs/guides/tools).
8922
+ * [built-in tools](https://developers.openai.com/api/docs/guides/tools).
8838
8923
  * - **MCP Tools**: Integrations with third-party systems via custom MCP servers or
8839
8924
  * predefined connectors such as Google Drive and SharePoint. Learn more about
8840
- * [MCP Tools](https://platform.openai.com/docs/guides/tools-connectors-mcp).
8925
+ * [MCP Tools](https://developers.openai.com/api/docs/guides/tools-connectors-mcp).
8841
8926
  * - **Function calls (custom tools)**: Functions that are defined by you, enabling
8842
8927
  * the model to call your own code with strongly typed arguments and outputs.
8843
8928
  * Learn more about
8844
- * [function calling](https://platform.openai.com/docs/guides/function-calling).
8929
+ * [function calling](https://developers.openai.com/api/docs/guides/function-calling).
8845
8930
  * You can also use custom tools to call your own code.
8846
8931
  */
8847
8932
  tools?: Array<Tool>;
@@ -8875,7 +8960,7 @@ export interface ResponseCreateParamsBase {
8875
8960
  * optimizations. A stable identifier for your end-users. Used to boost cache hit
8876
8961
  * rates by better bucketing similar requests and to help OpenAI detect and prevent
8877
8962
  * abuse.
8878
- * [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
8963
+ * [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
8879
8964
  */
8880
8965
  user?: string;
8881
8966
  }
@@ -8941,10 +9026,15 @@ export declare namespace ResponseCreateParams {
8941
9026
  * up to the latest 80 breakpoints in the conversation, without a content-block
8942
9027
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
8943
9028
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
8944
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
9029
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
8945
9030
  * for current details.
8946
9031
  */
8947
9032
  interface PromptCacheOptions {
9033
+ /**
9034
+ * The ID of a response to compare when diagnosing prompt cache reuse. Supplying
9035
+ * this field requests prompt cache diagnostics when the feature is enabled.
9036
+ */
9037
+ comparison_response_id?: string | null;
8948
9038
  /**
8949
9039
  * Controls whether OpenAI automatically creates an implicit cache breakpoint.
8950
9040
  * Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
@@ -8990,7 +9080,7 @@ export interface ResponseCreateParamsNonStreaming extends ResponseCreateParamsBa
8990
9080
  * generated using
8991
9081
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
8992
9082
  * See the
8993
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
9083
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
8994
9084
  * for more information.
8995
9085
  */
8996
9086
  stream?: false | null;
@@ -9001,7 +9091,7 @@ export interface ResponseCreateParamsStreaming extends ResponseCreateParamsBase
9001
9091
  * generated using
9002
9092
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
9003
9093
  * See the
9004
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
9094
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
9005
9095
  * for more information.
9006
9096
  */
9007
9097
  stream: true;
@@ -9031,7 +9121,7 @@ export interface ResponseRetrieveParamsBase {
9031
9121
  * generated using
9032
9122
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
9033
9123
  * See the
9034
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
9124
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
9035
9125
  * for more information.
9036
9126
  */
9037
9127
  stream?: boolean;
@@ -9046,7 +9136,7 @@ export interface ResponseRetrieveParamsNonStreaming extends ResponseRetrievePara
9046
9136
  * generated using
9047
9137
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
9048
9138
  * See the
9049
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
9139
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
9050
9140
  * for more information.
9051
9141
  */
9052
9142
  stream?: false;
@@ -9057,7 +9147,7 @@ export interface ResponseRetrieveParamsStreaming extends ResponseRetrieveParamsB
9057
9147
  * generated using
9058
9148
  * [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
9059
9149
  * See the
9060
- * [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
9150
+ * [Streaming section below](https://developers.openai.com/api/reference/resources/responses/streaming-events)
9061
9151
  * for more information.
9062
9152
  */
9063
9153
  stream: true;
@@ -9067,8 +9157,8 @@ export interface ResponseCompactParams {
9067
9157
  * Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
9068
9158
  * range of models with different capabilities, performance characteristics, and
9069
9159
  * price points. Refer to the
9070
- * [model guide](https://platform.openai.com/docs/models) to browse and compare
9071
- * available models.
9160
+ * [model guide](https://developers.openai.com/api/docs/models) to browse and
9161
+ * compare available models.
9072
9162
  */
9073
9163
  model: 'gpt-6-astra' | 'gpt-5.6-sol' | 'gpt-5.6-terra' | 'gpt-5.6-luna' | 'gpt-5.5' | 'gpt-5.5-2026-04-23' | 'gpt-5.4' | 'gpt-5.4-mini' | 'gpt-5.4-nano' | 'gpt-5.4-mini-2026-03-17' | 'gpt-5.4-nano-2026-03-17' | 'gpt-5.3-chat-latest' | 'gpt-5.2' | 'gpt-5.2-2025-12-11' | 'gpt-5.2-chat-latest' | 'gpt-5.2-pro' | 'gpt-5.2-pro-2025-12-11' | 'gpt-5.1' | 'gpt-5.1-2025-11-13' | 'gpt-5.1-codex' | 'gpt-5.1-mini' | 'gpt-5.1-chat-latest' | 'gpt-5' | 'gpt-5-mini' | 'gpt-5-nano' | 'gpt-5-2025-08-07' | 'gpt-5-mini-2025-08-07' | 'gpt-5-nano-2025-08-07' | 'gpt-5-chat-latest' | 'gpt-4.1' | 'gpt-4.1-mini' | 'gpt-4.1-nano' | 'gpt-4.1-2025-04-14' | 'gpt-4.1-mini-2025-04-14' | 'gpt-4.1-nano-2025-04-14' | 'o4-mini' | 'o4-mini-2025-04-16' | 'o3' | 'o3-2025-04-16' | 'o3-mini' | 'o3-mini-2025-01-31' | 'o1' | 'o1-2024-12-17' | 'o1-preview' | 'o1-preview-2024-09-12' | 'o1-mini' | 'o1-mini-2024-09-12' | 'gpt-4o' | 'gpt-4o-2024-11-20' | 'gpt-4o-2024-08-06' | 'gpt-4o-2024-05-13' | 'gpt-4o-audio-preview' | 'gpt-4o-audio-preview-2024-10-01' | 'gpt-4o-audio-preview-2024-12-17' | 'gpt-4o-audio-preview-2025-06-03' | 'gpt-4o-mini-audio-preview' | 'gpt-4o-mini-audio-preview-2024-12-17' | 'gpt-4o-search-preview' | 'gpt-4o-mini-search-preview' | 'gpt-4o-search-preview-2025-03-11' | 'gpt-4o-mini-search-preview-2025-03-11' | 'chatgpt-4o-latest' | 'codex-mini-latest' | 'gpt-4o-mini' | 'gpt-4o-mini-2024-07-18' | 'gpt-4-turbo' | 'gpt-4-turbo-2024-04-09' | 'gpt-4-0125-preview' | 'gpt-4-turbo-preview' | 'gpt-4-1106-preview' | 'gpt-4-vision-preview' | 'gpt-4' | 'gpt-4-0314' | 'gpt-4-0613' | 'gpt-4-32k' | 'gpt-4-32k-0314' | 'gpt-4-32k-0613' | 'gpt-3.5-turbo' | 'gpt-3.5-turbo-16k' | 'gpt-3.5-turbo-0301' | 'gpt-3.5-turbo-0613' | 'gpt-3.5-turbo-1106' | 'gpt-3.5-turbo-0125' | 'gpt-3.5-turbo-16k-0613' | 'o1-pro' | 'o1-pro-2025-03-19' | 'o3-pro' | 'o3-pro-2025-06-10' | 'o3-deep-research' | 'o3-deep-research-2025-06-26' | 'o4-mini-deep-research' | 'o4-mini-deep-research-2025-06-26' | 'computer-use-preview' | 'computer-use-preview-2025-03-11' | 'gpt-5.5-pro' | 'gpt-5.5-pro-2026-04-23' | 'gpt-5-codex' | 'gpt-5-pro' | 'gpt-5-pro-2025-10-06' | 'gpt-5.1-codex-max' | 'gpt-daybreak-blue-latest' | 'gpt-daybreak-red-latest' | 'gpt-5.6-cyber' | (string & {}) | null;
9074
9164
  /**
@@ -9085,7 +9175,7 @@ export interface ResponseCompactParams {
9085
9175
  /**
9086
9176
  * The unique ID of the previous response to the model. Use this to create
9087
9177
  * multi-turn conversations. Learn more about
9088
- * [conversation state](https://platform.openai.com/docs/guides/conversation-state).
9178
+ * [conversation state](https://developers.openai.com/api/docs/guides/conversation-state).
9089
9179
  * Cannot be used in conjunction with `conversation`.
9090
9180
  */
9091
9181
  previous_response_id?: string | null;
@@ -9101,7 +9191,7 @@ export interface ResponseCompactParams {
9101
9191
  * up to the latest 80 breakpoints in the conversation, without a content-block
9102
9192
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
9103
9193
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
9104
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
9194
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
9105
9195
  * for current details.
9106
9196
  */
9107
9197
  prompt_cache_options?: ResponseCompactParams.PromptCacheOptions | null;
@@ -9115,16 +9205,17 @@ export interface ResponseCompactParams {
9115
9205
  * Project settings. Unless otherwise configured, the Project will use 'default'. -
9116
9206
  * If set to 'default', then the request will be processed with the standard
9117
9207
  * pricing and performance for the selected model. - If set to
9118
- * '[flex](https://platform.openai.com/docs/guides/flex-processing)', then the
9119
- * request will be processed with the Flex Processing service tier. - To opt-in to
9120
- * [Fast mode](/api/docs/guides/fast-mode) at the request level, include the
9121
- * `service_tier=fast` or `service_tier=priority` parameter for Responses or Chat
9122
- * Completions. The response will show `service_tier=priority` regardless of if you
9123
- * specify `service_tier=fast` or `priority` in your request. - When not set, the
9124
- * default behavior is 'auto'. When the `service_tier` parameter is set, the
9125
- * response body will include the `service_tier` value based on the processing mode
9126
- * actually used to serve the request. This response value may be different from
9127
- * the value set in the parameter.
9208
+ * '[flex](https://developers.openai.com/api/docs/guides/flex-processing)', then
9209
+ * the request will be processed with the Flex Processing service tier. - To opt-in
9210
+ * to [Fast mode](https://developers.openai.com/api/docs/guides/fast-mode) at the
9211
+ * request level, include the `service_tier=fast` or `service_tier=priority`
9212
+ * parameter for Responses or Chat Completions. For models with a dedicated Fast
9213
+ * tier, either value resolves to `service_tier=fast`; for other models, either
9214
+ * value resolves to `service_tier=priority`. - When not set, the default behavior
9215
+ * is 'auto'. When the `service_tier` parameter is set, the response body will
9216
+ * include the `service_tier` value based on the processing mode actually used to
9217
+ * serve the request. This response value may be different from the value set in
9218
+ * the parameter.
9128
9219
  */
9129
9220
  service_tier?: 'auto' | 'default' | 'fast' | 'flex' | 'priority' | null;
9130
9221
  }
@@ -9137,7 +9228,7 @@ export declare namespace ResponseCompactParams {
9137
9228
  * up to the latest 80 breakpoints in the conversation, without a content-block
9138
9229
  * lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
9139
9230
  * `ttl` defaults to `30m`, which is currently the only supported value. See the
9140
- * [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
9231
+ * [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
9141
9232
  * for current details.
9142
9233
  */
9143
9234
  interface PromptCacheOptions {