@openrouter/sdk 0.8.0 → 0.10.2

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 (360) hide show
  1. package/FUNCTIONS.md +2 -1
  2. package/_speakeasy/.github/action-inputs-config.json +4 -0
  3. package/esm/funcs/analyticsGetUserActivity.js +2 -1
  4. package/esm/funcs/apiKeysCreate.js +2 -1
  5. package/esm/funcs/apiKeysDelete.js +2 -1
  6. package/esm/funcs/apiKeysGet.js +2 -1
  7. package/esm/funcs/apiKeysGetCurrentKeyMetadata.js +2 -1
  8. package/esm/funcs/apiKeysList.js +2 -1
  9. package/esm/funcs/apiKeysUpdate.js +2 -1
  10. package/esm/funcs/betaResponsesSend.js +2 -1
  11. package/esm/funcs/call-model.d.ts +19 -70
  12. package/esm/funcs/call-model.js +29 -71
  13. package/esm/funcs/chatSend.d.ts +3 -3
  14. package/esm/funcs/chatSend.js +20 -3
  15. package/esm/funcs/creditsCreateCoinbaseCharge.js +2 -1
  16. package/esm/funcs/creditsGetCredits.js +2 -1
  17. package/esm/funcs/embeddingsGenerate.js +2 -1
  18. package/esm/funcs/embeddingsListModels.js +2 -1
  19. package/esm/funcs/endpointsList.js +2 -1
  20. package/esm/funcs/endpointsListZdrEndpoints.js +2 -1
  21. package/esm/funcs/generationsGetGeneration.js +2 -1
  22. package/esm/funcs/guardrailsBulkAssignKeys.js +2 -1
  23. package/esm/funcs/guardrailsBulkAssignMembers.js +2 -1
  24. package/esm/funcs/guardrailsBulkUnassignKeys.js +2 -1
  25. package/esm/funcs/guardrailsBulkUnassignMembers.js +2 -1
  26. package/esm/funcs/guardrailsCreate.js +2 -1
  27. package/esm/funcs/guardrailsDelete.js +2 -1
  28. package/esm/funcs/guardrailsGet.js +2 -1
  29. package/esm/funcs/guardrailsList.js +2 -1
  30. package/esm/funcs/guardrailsListGuardrailKeyAssignments.js +2 -1
  31. package/esm/funcs/guardrailsListGuardrailMemberAssignments.js +2 -1
  32. package/esm/funcs/guardrailsListKeyAssignments.js +2 -1
  33. package/esm/funcs/guardrailsListMemberAssignments.js +2 -1
  34. package/esm/funcs/guardrailsUpdate.js +2 -1
  35. package/esm/funcs/modelsCount.d.ts +1 -1
  36. package/esm/funcs/modelsCount.js +9 -4
  37. package/esm/funcs/modelsList.js +3 -1
  38. package/esm/funcs/modelsListForUser.js +2 -1
  39. package/esm/funcs/oAuthCreateAuthCode.d.ts +1 -1
  40. package/esm/funcs/oAuthCreateAuthCode.js +4 -3
  41. package/esm/funcs/oAuthExchangeAuthCodeForAPIKey.js +2 -1
  42. package/esm/funcs/providersList.js +2 -1
  43. package/esm/index.d.ts +22 -23
  44. package/esm/index.js +20 -17
  45. package/esm/lib/anthropic-compat.d.ts +2 -1
  46. package/esm/lib/anthropic-compat.js +1 -2
  47. package/esm/lib/async-params.d.ts +19 -5
  48. package/esm/lib/async-params.js +5 -1
  49. package/esm/lib/chat-compat.d.ts +1 -1
  50. package/esm/lib/chat-compat.js +1 -2
  51. package/esm/lib/claude-type-guards.d.ts +2 -2
  52. package/esm/lib/config.d.ts +8 -10
  53. package/esm/lib/config.js +2 -2
  54. package/esm/lib/conversation-state.d.ts +1 -1
  55. package/esm/lib/conversation-state.js +35 -32
  56. package/esm/lib/env.d.ts +6 -2
  57. package/esm/lib/env.js +7 -3
  58. package/esm/lib/model-result.d.ts +73 -17
  59. package/esm/lib/model-result.js +329 -125
  60. package/esm/lib/sdks.d.ts +1 -1
  61. package/esm/lib/sdks.js +8 -28
  62. package/esm/lib/stream-transformers.d.ts +5 -4
  63. package/esm/lib/stream-transformers.js +24 -29
  64. package/esm/lib/stream-type-guards.js +8 -32
  65. package/esm/lib/tool-context.d.ts +68 -0
  66. package/esm/lib/tool-context.js +175 -0
  67. package/esm/lib/tool-executor.d.ts +9 -5
  68. package/esm/lib/tool-executor.js +26 -16
  69. package/esm/lib/tool-orchestrator.d.ts +2 -2
  70. package/esm/lib/tool-types.d.ts +101 -14
  71. package/esm/lib/tool-types.js +17 -0
  72. package/esm/lib/tool.d.ts +49 -60
  73. package/esm/lib/tool.js +15 -19
  74. package/esm/lib/turn-context.d.ts +1 -1
  75. package/esm/models/assistantmessage.d.ts +53 -36
  76. package/esm/models/assistantmessage.js +38 -47
  77. package/esm/models/assistantmessageimages.d.ts +33 -0
  78. package/esm/models/assistantmessageimages.js +44 -0
  79. package/esm/models/chatcompletionaudiooutput.d.ts +38 -0
  80. package/esm/models/chatcompletionaudiooutput.js +36 -0
  81. package/esm/models/chatgenerationparams.d.ts +527 -131
  82. package/esm/models/chatgenerationparams.js +280 -97
  83. package/esm/models/chatgenerationtokenusage.d.ts +48 -0
  84. package/esm/models/chatmessagecontentitem.d.ts +16 -10
  85. package/esm/models/chatmessagecontentitem.js +28 -4
  86. package/esm/models/chatmessagecontentitemaudio.d.ts +20 -2
  87. package/esm/models/chatmessagecontentitemaudio.js +9 -2
  88. package/esm/models/chatmessagecontentitemcachecontrol.d.ts +19 -8
  89. package/esm/models/chatmessagecontentitemcachecontrol.js +14 -9
  90. package/esm/models/chatmessagecontentitemfile.d.ts +57 -0
  91. package/esm/models/chatmessagecontentitemfile.js +59 -0
  92. package/esm/models/chatmessagecontentitemimage.d.ts +26 -3
  93. package/esm/models/chatmessagecontentitemimage.js +12 -2
  94. package/esm/models/chatmessagecontentitemtext.d.ts +17 -2
  95. package/esm/models/chatmessagecontentitemtext.js +9 -2
  96. package/esm/models/chatmessagecontentitemvideo.d.ts +12 -55
  97. package/esm/models/chatmessagecontentitemvideo.js +5 -72
  98. package/esm/models/chatmessagecontentitemvideolegacy.d.ts +28 -0
  99. package/esm/models/chatmessagecontentitemvideolegacy.js +33 -0
  100. package/esm/models/chatmessagetokenlogprob.d.ts +15 -0
  101. package/esm/models/chatmessagetokenlogprobs.d.ts +10 -1
  102. package/esm/models/chatmessagetokenlogprobs.js +2 -1
  103. package/esm/models/chatmessagetoolcall.d.ts +23 -2
  104. package/esm/models/chatmessagetoolcall.js +9 -2
  105. package/esm/models/chatresponse.d.ts +30 -2
  106. package/esm/models/chatresponse.js +7 -2
  107. package/esm/models/chatresponsechoice.d.ts +13 -2
  108. package/esm/models/chatresponsechoice.js +1 -2
  109. package/esm/models/chatstreamingchoice.d.ts +13 -2
  110. package/esm/models/chatstreamingchoice.js +1 -2
  111. package/esm/models/chatstreamingmessagechunk.d.ts +31 -2
  112. package/esm/models/chatstreamingmessagechunk.js +7 -2
  113. package/esm/models/chatstreamingmessagetoolcall.d.ts +38 -1
  114. package/esm/models/chatstreamingmessagetoolcall.js +9 -1
  115. package/esm/models/chatstreamingresponsechunk.d.ts +46 -12
  116. package/esm/models/chatstreamingresponsechunk.js +12 -26
  117. package/esm/models/chatstreamoptions.d.ts +8 -0
  118. package/esm/models/compoundfilter.d.ts +36 -0
  119. package/esm/models/compoundfilter.js +32 -0
  120. package/esm/models/conflictresponseerrordata.d.ts +17 -0
  121. package/esm/models/conflictresponseerrordata.js +16 -0
  122. package/esm/models/contextcompressionengine.d.ts +15 -0
  123. package/esm/models/contextcompressionengine.js +14 -0
  124. package/esm/models/datetimeservertool.d.ts +30 -0
  125. package/esm/models/datetimeservertool.js +22 -0
  126. package/esm/models/debugoptions.d.ts +18 -0
  127. package/esm/models/debugoptions.js +18 -0
  128. package/esm/models/defaultparameters.d.ts +3 -0
  129. package/esm/models/defaultparameters.js +6 -0
  130. package/esm/models/developermessage.d.ts +12 -0
  131. package/esm/models/errors/conflictresponseerror.d.ts +33 -0
  132. package/esm/models/errors/{chaterror.js → conflictresponseerror.js} +17 -7
  133. package/esm/models/errors/index.d.ts +1 -1
  134. package/esm/models/errors/index.js +1 -1
  135. package/esm/models/index.d.ts +35 -12
  136. package/esm/models/index.js +35 -12
  137. package/esm/models/jsonschemaconfig.d.ts +17 -2
  138. package/esm/models/jsonschemaconfig.js +1 -1
  139. package/esm/models/message.d.ts +9 -2
  140. package/esm/models/message.js +1 -1
  141. package/esm/models/modelscountresponse.d.ts +4 -4
  142. package/esm/models/modelscountresponse.js +4 -4
  143. package/esm/models/namedtoolchoice.d.ts +15 -2
  144. package/esm/models/namedtoolchoice.js +6 -1
  145. package/esm/models/openairesponsesinputunion.d.ts +32 -1
  146. package/esm/models/openairesponsesinputunion.js +53 -1
  147. package/esm/models/openairesponsesreasoningconfig.d.ts +1 -1
  148. package/esm/models/openairesponsesreasoningconfig.js +1 -1
  149. package/esm/models/openresponsesapplypatchtool.d.ts +20 -0
  150. package/esm/models/openresponsesapplypatchtool.js +21 -0
  151. package/esm/models/openresponsescodeinterpretertool.d.ts +68 -0
  152. package/esm/models/openresponsescodeinterpretertool.js +85 -0
  153. package/esm/models/openresponsescomputertool.d.ts +39 -0
  154. package/esm/models/openresponsescomputertool.js +50 -0
  155. package/esm/models/openresponsescustomtool.d.ts +75 -0
  156. package/esm/models/openresponsescustomtool.js +95 -0
  157. package/esm/models/openresponseseasyinputmessage.d.ts +30 -4
  158. package/esm/models/openresponseseasyinputmessage.js +28 -2
  159. package/esm/models/openresponsesfilesearchtool.d.ts +111 -0
  160. package/esm/models/openresponsesfilesearchtool.js +180 -0
  161. package/esm/models/openresponsesfunctioncalloutput.d.ts +46 -7
  162. package/esm/models/openresponsesfunctioncalloutput.js +56 -4
  163. package/esm/models/openresponsesfunctionshelltool.d.ts +20 -0
  164. package/esm/models/openresponsesfunctionshelltool.js +21 -0
  165. package/esm/models/openresponsesimagegenerationtool.d.ts +125 -0
  166. package/esm/models/openresponsesimagegenerationtool.js +153 -0
  167. package/esm/models/openresponsesinputmessageitem.d.ts +2 -2
  168. package/esm/models/openresponsesinputmessageitem.js +2 -2
  169. package/esm/models/openresponsesinputunion.d.ts +207 -0
  170. package/esm/models/openresponsesinputunion.js +225 -0
  171. package/esm/models/openresponseslocalshelltool.d.ts +20 -0
  172. package/esm/models/openresponseslocalshelltool.js +21 -0
  173. package/esm/models/openresponsesmcptool.d.ts +128 -0
  174. package/esm/models/openresponsesmcptool.js +173 -0
  175. package/esm/models/openresponsesnonstreamingresponse.d.ts +15 -6
  176. package/esm/models/openresponsesnonstreamingresponse.js +30 -3
  177. package/esm/models/openresponsesreasoning.d.ts +2 -2
  178. package/esm/models/openresponsesreasoning.js +1 -1
  179. package/esm/models/openresponsesreasoningconfig.d.ts +2 -2
  180. package/esm/models/openresponsesreasoningconfig.js +1 -1
  181. package/esm/models/openresponsesrequest.d.ts +111 -39
  182. package/esm/models/openresponsesrequest.js +112 -38
  183. package/esm/models/openresponsesstreamevent.d.ts +52 -4
  184. package/esm/models/openresponsesstreamevent.js +54 -3
  185. package/esm/models/openresponseswebsearch20250826tool.d.ts +29 -0
  186. package/esm/models/openresponseswebsearch20250826tool.js +23 -0
  187. package/esm/models/openresponseswebsearchcallcompleted.d.ts +16 -0
  188. package/esm/models/openresponseswebsearchcallcompleted.js +24 -0
  189. package/esm/models/openresponseswebsearchcallinprogress.d.ts +16 -0
  190. package/esm/models/openresponseswebsearchcallinprogress.js +24 -0
  191. package/esm/models/openresponseswebsearchcallsearching.d.ts +16 -0
  192. package/esm/models/openresponseswebsearchcallsearching.js +24 -0
  193. package/esm/models/openresponseswebsearchpreview20250311tool.d.ts +44 -0
  194. package/esm/models/openresponseswebsearchpreview20250311tool.js +51 -0
  195. package/esm/models/openresponseswebsearchpreviewtool.d.ts +44 -0
  196. package/esm/models/openresponseswebsearchpreviewtool.js +47 -0
  197. package/esm/models/openresponseswebsearchtool.d.ts +29 -0
  198. package/esm/models/openresponseswebsearchtool.js +23 -0
  199. package/esm/models/operations/bulkassignkeystoguardrail.d.ts +16 -3
  200. package/esm/models/operations/bulkassignkeystoguardrail.js +2 -2
  201. package/esm/models/operations/bulkassignmemberstoguardrail.d.ts +16 -3
  202. package/esm/models/operations/bulkassignmemberstoguardrail.js +2 -2
  203. package/esm/models/operations/bulkunassignkeysfromguardrail.d.ts +16 -3
  204. package/esm/models/operations/bulkunassignkeysfromguardrail.js +2 -2
  205. package/esm/models/operations/bulkunassignmembersfromguardrail.d.ts +16 -3
  206. package/esm/models/operations/bulkunassignmembersfromguardrail.js +2 -2
  207. package/esm/models/operations/createauthkeyscode.d.ts +40 -3
  208. package/esm/models/operations/createauthkeyscode.js +16 -2
  209. package/esm/models/operations/createcoinbasecharge.d.ts +16 -3
  210. package/esm/models/operations/createcoinbasecharge.js +2 -2
  211. package/esm/models/operations/createembeddings.d.ts +16 -3
  212. package/esm/models/operations/createembeddings.js +2 -2
  213. package/esm/models/operations/createguardrail.d.ts +25 -3
  214. package/esm/models/operations/createguardrail.js +6 -2
  215. package/esm/models/operations/createkeys.d.ts +16 -3
  216. package/esm/models/operations/createkeys.js +2 -2
  217. package/esm/models/operations/createresponses.d.ts +16 -3
  218. package/esm/models/operations/createresponses.js +2 -2
  219. package/esm/models/operations/deleteguardrail.d.ts +16 -3
  220. package/esm/models/operations/deleteguardrail.js +2 -2
  221. package/esm/models/operations/deletekeys.d.ts +16 -3
  222. package/esm/models/operations/deletekeys.js +2 -2
  223. package/esm/models/operations/exchangeauthcodeforapikey.d.ts +16 -3
  224. package/esm/models/operations/exchangeauthcodeforapikey.js +2 -2
  225. package/esm/models/operations/getcredits.d.ts +16 -3
  226. package/esm/models/operations/getcredits.js +2 -2
  227. package/esm/models/operations/getcurrentkey.d.ts +16 -3
  228. package/esm/models/operations/getcurrentkey.js +2 -2
  229. package/esm/models/operations/getgeneration.d.ts +27 -3
  230. package/esm/models/operations/getgeneration.js +9 -2
  231. package/esm/models/operations/getguardrail.d.ts +20 -3
  232. package/esm/models/operations/getguardrail.js +4 -2
  233. package/esm/models/operations/getkey.d.ts +16 -3
  234. package/esm/models/operations/getkey.js +2 -2
  235. package/esm/models/operations/getmodels.d.ts +21 -3
  236. package/esm/models/operations/getmodels.js +4 -2
  237. package/esm/models/operations/getuseractivity.d.ts +16 -3
  238. package/esm/models/operations/getuseractivity.js +2 -2
  239. package/esm/models/operations/list.d.ts +16 -3
  240. package/esm/models/operations/list.js +2 -2
  241. package/esm/models/operations/listembeddingsmodels.d.ts +16 -3
  242. package/esm/models/operations/listembeddingsmodels.js +2 -2
  243. package/esm/models/operations/listendpoints.d.ts +16 -3
  244. package/esm/models/operations/listendpoints.js +2 -2
  245. package/esm/models/operations/listendpointszdr.d.ts +16 -3
  246. package/esm/models/operations/listendpointszdr.js +2 -2
  247. package/esm/models/operations/listguardrailkeyassignments.d.ts +16 -3
  248. package/esm/models/operations/listguardrailkeyassignments.js +2 -2
  249. package/esm/models/operations/listguardrailmemberassignments.d.ts +16 -3
  250. package/esm/models/operations/listguardrailmemberassignments.js +2 -2
  251. package/esm/models/operations/listguardrails.d.ts +20 -3
  252. package/esm/models/operations/listguardrails.js +4 -2
  253. package/esm/models/operations/listkeyassignments.d.ts +16 -3
  254. package/esm/models/operations/listkeyassignments.js +2 -2
  255. package/esm/models/operations/listmemberassignments.d.ts +16 -3
  256. package/esm/models/operations/listmemberassignments.js +2 -2
  257. package/esm/models/operations/listmodelscount.d.ts +21 -3
  258. package/esm/models/operations/listmodelscount.js +4 -2
  259. package/esm/models/operations/listmodelsuser.d.ts +16 -3
  260. package/esm/models/operations/listmodelsuser.js +2 -2
  261. package/esm/models/operations/listproviders.d.ts +16 -3
  262. package/esm/models/operations/listproviders.js +2 -2
  263. package/esm/models/operations/sendchatcompletionrequest.d.ts +27 -5
  264. package/esm/models/operations/sendchatcompletionrequest.js +22 -4
  265. package/esm/models/operations/updateguardrail.d.ts +25 -3
  266. package/esm/models/operations/updateguardrail.js +6 -2
  267. package/esm/models/operations/updatekeys.d.ts +16 -3
  268. package/esm/models/operations/updatekeys.js +2 -2
  269. package/esm/models/outputmessage.d.ts +23 -0
  270. package/esm/models/outputmessage.js +24 -0
  271. package/esm/models/outputmodality.d.ts +1 -0
  272. package/esm/models/outputmodality.js +1 -0
  273. package/esm/models/providername.d.ts +3 -0
  274. package/esm/models/providername.js +3 -0
  275. package/esm/models/providerpreferences.d.ts +49 -14
  276. package/esm/models/providerpreferences.js +33 -15
  277. package/esm/models/providersort.d.ts +7 -0
  278. package/esm/models/providersort.js +4 -0
  279. package/esm/models/providersortconfig.d.ts +31 -2
  280. package/esm/models/providersortconfig.js +16 -2
  281. package/esm/models/reasoningdetailencrypted.d.ts +42 -0
  282. package/esm/models/reasoningdetailencrypted.js +42 -0
  283. package/esm/models/reasoningdetailsummary.d.ts +42 -0
  284. package/esm/models/reasoningdetailsummary.js +42 -0
  285. package/esm/models/reasoningdetailtext.d.ts +44 -0
  286. package/esm/models/reasoningdetailtext.js +44 -0
  287. package/esm/models/reasoningdetailunion.d.ts +19 -0
  288. package/esm/models/reasoningdetailunion.js +28 -0
  289. package/esm/models/responseformatjsonobject.d.ts +20 -0
  290. package/esm/models/responseformatjsonobject.js +21 -0
  291. package/esm/models/responseformatjsonschema.d.ts +6 -0
  292. package/esm/models/responseformattext.d.ts +15 -0
  293. package/esm/models/responseformattext.js +13 -0
  294. package/esm/models/responseformattextconfig.d.ts +3 -3
  295. package/esm/models/responseformattextconfig.js +3 -3
  296. package/esm/models/responseformattextgrammar.d.ts +6 -0
  297. package/esm/models/responseformattextpython.d.ts +15 -0
  298. package/esm/models/responseformattextpython.js +13 -0
  299. package/esm/models/responseoutputtext.d.ts +8 -8
  300. package/esm/models/responseoutputtext.js +10 -9
  301. package/esm/models/responseserrorfield.d.ts +4 -4
  302. package/esm/models/responseserrorfield.js +4 -4
  303. package/esm/models/responsesoutputitem.d.ts +2 -13
  304. package/esm/models/responsesoutputitem.js +8 -6
  305. package/esm/models/responsesoutputitemreasoning.d.ts +3 -32
  306. package/esm/models/responsesoutputitemreasoning.js +3 -45
  307. package/esm/models/responsesoutputmessage.d.ts +24 -32
  308. package/esm/models/responsesoutputmessage.js +26 -47
  309. package/esm/models/responsesservertooloutput.d.ts +42 -0
  310. package/esm/models/responsesservertooloutput.js +44 -0
  311. package/esm/models/responseswebsearchcalloutput.d.ts +90 -5
  312. package/esm/models/responseswebsearchcalloutput.js +113 -5
  313. package/esm/models/responseswebsearchservertool.d.ts +35 -0
  314. package/esm/models/responseswebsearchservertool.js +28 -0
  315. package/esm/models/systemmessage.d.ts +12 -0
  316. package/esm/models/toolchoiceoption.d.ts +31 -0
  317. package/esm/models/toolchoiceoption.js +32 -0
  318. package/esm/models/tooldefinitionjson.d.ts +62 -10
  319. package/esm/models/tooldefinitionjson.js +29 -6
  320. package/esm/models/toolresponsemessage.d.ts +12 -0
  321. package/esm/models/usermessage.d.ts +12 -0
  322. package/esm/models/videoinput.d.ts +23 -0
  323. package/esm/models/videoinput.js +22 -0
  324. package/esm/models/websearchengine.d.ts +2 -0
  325. package/esm/models/websearchengine.js +2 -0
  326. package/esm/models/websearchservertool.d.ts +116 -0
  327. package/esm/models/websearchservertool.js +77 -0
  328. package/esm/models/websearchshorthand.d.ts +215 -0
  329. package/esm/models/websearchshorthand.js +138 -0
  330. package/esm/sdk/chat.d.ts +1 -1
  331. package/esm/sdk/sdk.d.ts +6 -3
  332. package/esm/sdk/sdk.js +3 -4
  333. package/esm/types/index.d.ts +0 -2
  334. package/esm/types/index.js +0 -1
  335. package/jsr.json +1 -1
  336. package/package.json +11 -6
  337. package/turbo.json +10 -0
  338. package/esm/models/chaterror.d.ts +0 -17
  339. package/esm/models/chaterror.js +0 -25
  340. package/esm/models/errors/chaterror.d.ts +0 -19
  341. package/esm/models/openresponsesinput.d.ts +0 -28
  342. package/esm/models/openresponsesinput.js +0 -54
  343. package/esm/models/openresponseslogprobs.d.ts +0 -16
  344. package/esm/models/openresponseslogprobs.js +0 -22
  345. package/esm/models/openresponsestoplogprobs.d.ts +0 -14
  346. package/esm/models/openresponsestoplogprobs.js +0 -15
  347. package/esm/models/providersortunion.d.ts +0 -10
  348. package/esm/models/providersortunion.js +0 -13
  349. package/esm/models/responsesformatjsonobject.d.ts +0 -20
  350. package/esm/models/responsesformatjsonobject.js +0 -21
  351. package/esm/models/schema10.d.ts +0 -33
  352. package/esm/models/schema10.js +0 -30
  353. package/esm/models/schema14.d.ts +0 -8
  354. package/esm/models/schema14.js +0 -12
  355. package/esm/models/schema17.d.ts +0 -102
  356. package/esm/models/schema17.js +0 -95
  357. package/esm/models/schema19.d.ts +0 -92
  358. package/esm/models/schema19.js +0 -109
  359. package/esm/models/schema5.d.ts +0 -86
  360. package/esm/models/schema5.js +0 -89
@@ -4,18 +4,21 @@
4
4
  */
5
5
  export * from "./activityitem.js";
6
6
  export * from "./assistantmessage.js";
7
+ export * from "./assistantmessageimages.js";
7
8
  export * from "./badgatewayresponseerrordata.js";
8
9
  export * from "./badrequestresponseerrordata.js";
10
+ export * from "./chatcompletionaudiooutput.js";
9
11
  export * from "./chatcompletionfinishreason.js";
10
- export * from "./chaterror.js";
11
12
  export * from "./chatgenerationparams.js";
12
13
  export * from "./chatgenerationtokenusage.js";
13
14
  export * from "./chatmessagecontentitem.js";
14
15
  export * from "./chatmessagecontentitemaudio.js";
15
16
  export * from "./chatmessagecontentitemcachecontrol.js";
17
+ export * from "./chatmessagecontentitemfile.js";
16
18
  export * from "./chatmessagecontentitemimage.js";
17
19
  export * from "./chatmessagecontentitemtext.js";
18
20
  export * from "./chatmessagecontentitemvideo.js";
21
+ export * from "./chatmessagecontentitemvideolegacy.js";
19
22
  export * from "./chatmessagetokenlogprob.js";
20
23
  export * from "./chatmessagetokenlogprobs.js";
21
24
  export * from "./chatmessagetoolcall.js";
@@ -26,8 +29,13 @@ export * from "./chatstreamingmessagechunk.js";
26
29
  export * from "./chatstreamingmessagetoolcall.js";
27
30
  export * from "./chatstreamingresponsechunk.js";
28
31
  export * from "./chatstreamoptions.js";
32
+ export * from "./compoundfilter.js";
33
+ export * from "./conflictresponseerrordata.js";
34
+ export * from "./contextcompressionengine.js";
29
35
  export * from "./createchargerequest.js";
30
36
  export * from "./datacollection.js";
37
+ export * from "./datetimeservertool.js";
38
+ export * from "./debugoptions.js";
31
39
  export * from "./defaultparameters.js";
32
40
  export * from "./developermessage.js";
33
41
  export * from "./edgenetworktimeoutresponseerrordata.js";
@@ -61,17 +69,25 @@ export * from "./openairesponsesresponsestatus.js";
61
69
  export * from "./openairesponsesservicetier.js";
62
70
  export * from "./openairesponsestoolchoiceunion.js";
63
71
  export * from "./openairesponsestruncation.js";
72
+ export * from "./openresponsesapplypatchtool.js";
73
+ export * from "./openresponsescodeinterpretertool.js";
74
+ export * from "./openresponsescomputertool.js";
75
+ export * from "./openresponsescustomtool.js";
64
76
  export * from "./openresponseseasyinputmessage.js";
65
77
  export * from "./openresponseserrorevent.js";
78
+ export * from "./openresponsesfilesearchtool.js";
66
79
  export * from "./openresponsesfunctioncalloutput.js";
80
+ export * from "./openresponsesfunctionshelltool.js";
67
81
  export * from "./openresponsesfunctiontoolcall.js";
68
82
  export * from "./openresponsesimagegencallcompleted.js";
69
83
  export * from "./openresponsesimagegencallgenerating.js";
70
84
  export * from "./openresponsesimagegencallinprogress.js";
71
85
  export * from "./openresponsesimagegencallpartialimage.js";
72
- export * from "./openresponsesinput.js";
86
+ export * from "./openresponsesimagegenerationtool.js";
73
87
  export * from "./openresponsesinputmessageitem.js";
74
- export * from "./openresponseslogprobs.js";
88
+ export * from "./openresponsesinputunion.js";
89
+ export * from "./openresponseslocalshelltool.js";
90
+ export * from "./openresponsesmcptool.js";
75
91
  export * from "./openresponsesnonstreamingresponse.js";
76
92
  export * from "./openresponsesreasoning.js";
77
93
  export * from "./openresponsesreasoningconfig.js";
@@ -83,9 +99,11 @@ export * from "./openresponsesreasoningsummarytextdoneevent.js";
83
99
  export * from "./openresponsesrequest.js";
84
100
  export * from "./openresponsesresponsetext.js";
85
101
  export * from "./openresponsesstreamevent.js";
86
- export * from "./openresponsestoplogprobs.js";
87
102
  export * from "./openresponsesusage.js";
88
103
  export * from "./openresponseswebsearch20250826tool.js";
104
+ export * from "./openresponseswebsearchcallcompleted.js";
105
+ export * from "./openresponseswebsearchcallinprogress.js";
106
+ export * from "./openresponseswebsearchcallsearching.js";
89
107
  export * from "./openresponseswebsearchpreview20250311tool.js";
90
108
  export * from "./openresponseswebsearchpreviewtool.js";
91
109
  export * from "./openresponseswebsearchtool.js";
@@ -108,17 +126,23 @@ export * from "./provideroverloadedresponseerrordata.js";
108
126
  export * from "./providerpreferences.js";
109
127
  export * from "./providersort.js";
110
128
  export * from "./providersortconfig.js";
111
- export * from "./providersortunion.js";
112
129
  export * from "./publicendpoint.js";
113
130
  export * from "./publicpricing.js";
114
131
  export * from "./quantization.js";
132
+ export * from "./reasoningdetailencrypted.js";
133
+ export * from "./reasoningdetailsummary.js";
134
+ export * from "./reasoningdetailtext.js";
135
+ export * from "./reasoningdetailunion.js";
115
136
  export * from "./reasoningsummarytext.js";
116
137
  export * from "./reasoningsummaryverbosity.js";
117
138
  export * from "./reasoningtextcontent.js";
118
139
  export * from "./requesttimeoutresponseerrordata.js";
140
+ export * from "./responseformatjsonobject.js";
119
141
  export * from "./responseformatjsonschema.js";
142
+ export * from "./responseformattext.js";
120
143
  export * from "./responseformattextconfig.js";
121
144
  export * from "./responseformattextgrammar.js";
145
+ export * from "./responseformattextpython.js";
122
146
  export * from "./responseinputaudio.js";
123
147
  export * from "./responseinputfile.js";
124
148
  export * from "./responseinputimage.js";
@@ -126,7 +150,6 @@ export * from "./responseinputtext.js";
126
150
  export * from "./responseinputvideo.js";
127
151
  export * from "./responseoutputtext.js";
128
152
  export * from "./responseserrorfield.js";
129
- export * from "./responsesformatjsonobject.js";
130
153
  export * from "./responsesformattext.js";
131
154
  export * from "./responsesformattextjsonschemaconfig.js";
132
155
  export * from "./responsesimagegenerationcall.js";
@@ -137,18 +160,16 @@ export * from "./responsesoutputitemreasoning.js";
137
160
  export * from "./responsesoutputmessage.js";
138
161
  export * from "./responsesoutputmodality.js";
139
162
  export * from "./responsessearchcontextsize.js";
163
+ export * from "./responsesservertooloutput.js";
140
164
  export * from "./responseswebsearchcalloutput.js";
165
+ export * from "./responseswebsearchservertool.js";
141
166
  export * from "./responseswebsearchuserlocation.js";
142
167
  export * from "./responsetextconfig.js";
143
- export * from "./schema10.js";
144
- export * from "./schema14.js";
145
- export * from "./schema17.js";
146
- export * from "./schema19.js";
147
- export * from "./schema5.js";
148
168
  export * from "./security.js";
149
169
  export * from "./serviceunavailableresponseerrordata.js";
150
170
  export * from "./systemmessage.js";
151
171
  export * from "./toolcallstatus.js";
172
+ export * from "./toolchoiceoption.js";
152
173
  export * from "./tooldefinitionjson.js";
153
174
  export * from "./toolresponsemessage.js";
154
175
  export * from "./toomanyrequestsresponseerrordata.js";
@@ -157,8 +178,10 @@ export * from "./unauthorizedresponseerrordata.js";
157
178
  export * from "./unprocessableentityresponseerrordata.js";
158
179
  export * from "./urlcitation.js";
159
180
  export * from "./usermessage.js";
181
+ export * from "./videoinput.js";
160
182
  export * from "./websearchengine.js";
161
183
  export * from "./websearchpreviewtooluserlocation.js";
184
+ export * from "./websearchservertool.js";
185
+ export * from "./websearchshorthand.js";
162
186
  export * from "./websearchstatus.js";
163
- export * from "./claude-message.js";
164
187
  //# sourceMappingURL=index.js.map
@@ -1,10 +1,25 @@
1
1
  import * as z from "zod/v4";
2
+ /**
3
+ * JSON Schema configuration object
4
+ */
2
5
  export type JSONSchemaConfig = {
6
+ /**
7
+ * Schema name (a-z, A-Z, 0-9, underscores, dashes, max 64 chars)
8
+ */
3
9
  name: string;
10
+ /**
11
+ * Schema description for the model
12
+ */
4
13
  description?: string | undefined;
14
+ /**
15
+ * JSON Schema object
16
+ */
5
17
  schema?: {
6
- [k: string]: any;
18
+ [k: string]: any | null;
7
19
  } | undefined;
20
+ /**
21
+ * Enable strict schema adherence
22
+ */
8
23
  strict?: boolean | null | undefined;
9
24
  };
10
25
  /** @internal */
@@ -12,7 +27,7 @@ export type JSONSchemaConfig$Outbound = {
12
27
  name: string;
13
28
  description?: string | undefined;
14
29
  schema?: {
15
- [k: string]: any;
30
+ [k: string]: any | null;
16
31
  } | undefined;
17
32
  strict?: boolean | null | undefined;
18
33
  };
@@ -7,7 +7,7 @@ import * as z from "zod/v4";
7
7
  export const JSONSchemaConfig$outboundSchema = z.object({
8
8
  name: z.string(),
9
9
  description: z.string().optional(),
10
- schema: z.record(z.string(), z.any()).optional(),
10
+ schema: z.record(z.string(), z.nullable(z.any())).optional(),
11
11
  strict: z.nullable(z.boolean()).optional(),
12
12
  });
13
13
  export function jsonSchemaConfigToJSON(jsonSchemaConfig) {
@@ -4,9 +4,16 @@ import { DeveloperMessage, DeveloperMessage$Outbound } from "./developermessage.
4
4
  import { SystemMessage, SystemMessage$Outbound } from "./systemmessage.js";
5
5
  import { ToolResponseMessage, ToolResponseMessage$Outbound } from "./toolresponsemessage.js";
6
6
  import { UserMessage, UserMessage$Outbound } from "./usermessage.js";
7
- export type Message = SystemMessage | UserMessage | DeveloperMessage | AssistantMessage | ToolResponseMessage;
7
+ /**
8
+ * Chat completion message with role-based discrimination
9
+ */
10
+ export type Message = SystemMessage | UserMessage | DeveloperMessage | (AssistantMessage & {
11
+ role: "assistant";
12
+ }) | ToolResponseMessage;
8
13
  /** @internal */
9
- export type Message$Outbound = SystemMessage$Outbound | UserMessage$Outbound | DeveloperMessage$Outbound | AssistantMessage$Outbound | ToolResponseMessage$Outbound;
14
+ export type Message$Outbound = SystemMessage$Outbound | UserMessage$Outbound | DeveloperMessage$Outbound | (AssistantMessage$Outbound & {
15
+ role: "assistant";
16
+ }) | ToolResponseMessage$Outbound;
10
17
  /** @internal */
11
18
  export declare const Message$outboundSchema: z.ZodType<Message$Outbound, Message>;
12
19
  export declare function messageToJSON(message: Message): string;
@@ -14,7 +14,7 @@ export const Message$outboundSchema = z
14
14
  SystemMessage$outboundSchema,
15
15
  UserMessage$outboundSchema,
16
16
  DeveloperMessage$outboundSchema,
17
- AssistantMessage$outboundSchema,
17
+ AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") })),
18
18
  ToolResponseMessage$outboundSchema,
19
19
  ]);
20
20
  export function messageToJSON(message) {
@@ -4,7 +4,7 @@ import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
4
  /**
5
5
  * Model count data
6
6
  */
7
- export type ModelsCountResponseData = {
7
+ export type Data = {
8
8
  /**
9
9
  * Total number of available models
10
10
  */
@@ -17,11 +17,11 @@ export type ModelsCountResponse = {
17
17
  /**
18
18
  * Model count data
19
19
  */
20
- data: ModelsCountResponseData;
20
+ data: Data;
21
21
  };
22
22
  /** @internal */
23
- export declare const ModelsCountResponseData$inboundSchema: z.ZodType<ModelsCountResponseData, unknown>;
24
- export declare function modelsCountResponseDataFromJSON(jsonString: string): SafeParseResult<ModelsCountResponseData, SDKValidationError>;
23
+ export declare const Data$inboundSchema: z.ZodType<Data, unknown>;
24
+ export declare function dataFromJSON(jsonString: string): SafeParseResult<Data, SDKValidationError>;
25
25
  /** @internal */
26
26
  export declare const ModelsCountResponse$inboundSchema: z.ZodType<ModelsCountResponse, unknown>;
27
27
  export declare function modelsCountResponseFromJSON(jsonString: string): SafeParseResult<ModelsCountResponse, SDKValidationError>;
@@ -5,15 +5,15 @@
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
7
  /** @internal */
8
- export const ModelsCountResponseData$inboundSchema = z.object({
8
+ export const Data$inboundSchema = z.object({
9
9
  count: z.number(),
10
10
  });
11
- export function modelsCountResponseDataFromJSON(jsonString) {
12
- return safeParse(jsonString, (x) => ModelsCountResponseData$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ModelsCountResponseData' from JSON`);
11
+ export function dataFromJSON(jsonString) {
12
+ return safeParse(jsonString, (x) => Data$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Data' from JSON`);
13
13
  }
14
14
  /** @internal */
15
15
  export const ModelsCountResponse$inboundSchema = z.object({
16
- data: z.lazy(() => ModelsCountResponseData$inboundSchema),
16
+ data: z.lazy(() => Data$inboundSchema),
17
17
  });
18
18
  export function modelsCountResponseFromJSON(jsonString) {
19
19
  return safeParse(jsonString, (x) => ModelsCountResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ModelsCountResponse' from JSON`);
@@ -1,12 +1,25 @@
1
1
  import * as z from "zod/v4";
2
+ import { ClosedEnum } from "../types/enums.js";
3
+ export declare const NamedToolChoiceType: {
4
+ readonly Function: "function";
5
+ };
6
+ export type NamedToolChoiceType = ClosedEnum<typeof NamedToolChoiceType>;
2
7
  export type NamedToolChoiceFunction = {
8
+ /**
9
+ * Function name to call
10
+ */
3
11
  name: string;
4
12
  };
13
+ /**
14
+ * Named tool choice for specific function
15
+ */
5
16
  export type NamedToolChoice = {
6
- type: "function";
17
+ type: NamedToolChoiceType;
7
18
  function: NamedToolChoiceFunction;
8
19
  };
9
20
  /** @internal */
21
+ export declare const NamedToolChoiceType$outboundSchema: z.ZodEnum<typeof NamedToolChoiceType>;
22
+ /** @internal */
10
23
  export type NamedToolChoiceFunction$Outbound = {
11
24
  name: string;
12
25
  };
@@ -15,7 +28,7 @@ export declare const NamedToolChoiceFunction$outboundSchema: z.ZodType<NamedTool
15
28
  export declare function namedToolChoiceFunctionToJSON(namedToolChoiceFunction: NamedToolChoiceFunction): string;
16
29
  /** @internal */
17
30
  export type NamedToolChoice$Outbound = {
18
- type: "function";
31
+ type: string;
19
32
  function: NamedToolChoiceFunction$Outbound;
20
33
  };
21
34
  /** @internal */
@@ -3,6 +3,11 @@
3
3
  * @generated-id: db68e36b6a77
4
4
  */
5
5
  import * as z from "zod/v4";
6
+ export const NamedToolChoiceType = {
7
+ Function: "function",
8
+ };
9
+ /** @internal */
10
+ export const NamedToolChoiceType$outboundSchema = z.enum(NamedToolChoiceType);
6
11
  /** @internal */
7
12
  export const NamedToolChoiceFunction$outboundSchema = z.object({
8
13
  name: z.string(),
@@ -12,7 +17,7 @@ export function namedToolChoiceFunctionToJSON(namedToolChoiceFunction) {
12
17
  }
13
18
  /** @internal */
14
19
  export const NamedToolChoice$outboundSchema = z.object({
15
- type: z.literal("function"),
20
+ type: NamedToolChoiceType$outboundSchema,
16
21
  function: z.lazy(() => NamedToolChoiceFunction$outboundSchema),
17
22
  });
18
23
  export function namedToolChoiceToJSON(namedToolChoice) {
@@ -25,11 +25,19 @@ export declare const OpenAIResponsesInputTypeFunctionCallOutput: {
25
25
  readonly FunctionCallOutput: "function_call_output";
26
26
  };
27
27
  export type OpenAIResponsesInputTypeFunctionCallOutput = ClosedEnum<typeof OpenAIResponsesInputTypeFunctionCallOutput>;
28
+ export type OpenAIResponsesInputOutput1 = ResponseInputText | (ResponseInputImage & {
29
+ type: "input_image";
30
+ }) | ResponseInputFile;
31
+ export type OpenAIResponsesInputOutput2 = string | Array<ResponseInputText | (ResponseInputImage & {
32
+ type: "input_image";
33
+ }) | ResponseInputFile>;
28
34
  export type OpenAIResponsesInputFunctionCallOutput = {
29
35
  type: OpenAIResponsesInputTypeFunctionCallOutput;
30
36
  id?: string | null | undefined;
31
37
  callId: string;
32
- output: string;
38
+ output: string | Array<ResponseInputText | (ResponseInputImage & {
39
+ type: "input_image";
40
+ }) | ResponseInputFile>;
33
41
  status?: ToolCallStatus | null | undefined;
34
42
  };
35
43
  export declare const OpenAIResponsesInputTypeMessage2: {
@@ -87,12 +95,22 @@ export type OpenAIResponsesInputContent1 = ResponseInputText | (ResponseInputIma
87
95
  export type OpenAIResponsesInputContent2 = Array<ResponseInputText | (ResponseInputImage & {
88
96
  type: "input_image";
89
97
  }) | ResponseInputFile | ResponseInputAudio> | string;
98
+ export declare const OpenAIResponsesInputPhaseFinalAnswer: {
99
+ readonly FinalAnswer: "final_answer";
100
+ };
101
+ export type OpenAIResponsesInputPhaseFinalAnswer = ClosedEnum<typeof OpenAIResponsesInputPhaseFinalAnswer>;
102
+ export declare const OpenAIResponsesInputPhaseCommentary: {
103
+ readonly Commentary: "commentary";
104
+ };
105
+ export type OpenAIResponsesInputPhaseCommentary = ClosedEnum<typeof OpenAIResponsesInputPhaseCommentary>;
106
+ export type OpenAIResponsesInputPhaseUnion = OpenAIResponsesInputPhaseCommentary | OpenAIResponsesInputPhaseFinalAnswer | any;
90
107
  export type OpenAIResponsesInputMessage1 = {
91
108
  type?: OpenAIResponsesInputTypeMessage1 | undefined;
92
109
  role: OpenAIResponsesInputRoleUser1 | OpenAIResponsesInputRoleSystem1 | OpenAIResponsesInputRoleAssistant | OpenAIResponsesInputRoleDeveloper1;
93
110
  content: Array<ResponseInputText | (ResponseInputImage & {
94
111
  type: "input_image";
95
112
  }) | ResponseInputFile | ResponseInputAudio> | string;
113
+ phase?: OpenAIResponsesInputPhaseCommentary | OpenAIResponsesInputPhaseFinalAnswer | any | null | undefined;
96
114
  };
97
115
  export type OpenAIResponsesInputUnion1 = OpenAIResponsesInputFunctionCall | OutputMessage | OpenAIResponsesInputMessage2 | OpenAIResponsesInputFunctionCallOutput | OutputItemImageGenerationCall | OpenAIResponsesInputMessage1;
98
116
  export type OpenAIResponsesInputUnion = string | Array<OpenAIResponsesInputFunctionCall | OutputMessage | OpenAIResponsesInputMessage2 | OpenAIResponsesInputFunctionCallOutput | OutputItemImageGenerationCall | OpenAIResponsesInputMessage1> | any;
@@ -104,6 +122,12 @@ export declare function openAIResponsesInputFunctionCallFromJSON(jsonString: str
104
122
  /** @internal */
105
123
  export declare const OpenAIResponsesInputTypeFunctionCallOutput$inboundSchema: z.ZodEnum<typeof OpenAIResponsesInputTypeFunctionCallOutput>;
106
124
  /** @internal */
125
+ export declare const OpenAIResponsesInputOutput1$inboundSchema: z.ZodType<OpenAIResponsesInputOutput1, unknown>;
126
+ export declare function openAIResponsesInputOutput1FromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputOutput1, SDKValidationError>;
127
+ /** @internal */
128
+ export declare const OpenAIResponsesInputOutput2$inboundSchema: z.ZodType<OpenAIResponsesInputOutput2, unknown>;
129
+ export declare function openAIResponsesInputOutput2FromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputOutput2, SDKValidationError>;
130
+ /** @internal */
107
131
  export declare const OpenAIResponsesInputFunctionCallOutput$inboundSchema: z.ZodType<OpenAIResponsesInputFunctionCallOutput, unknown>;
108
132
  export declare function openAIResponsesInputFunctionCallOutputFromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputFunctionCallOutput, SDKValidationError>;
109
133
  /** @internal */
@@ -143,6 +167,13 @@ export declare function openAIResponsesInputContent1FromJSON(jsonString: string)
143
167
  export declare const OpenAIResponsesInputContent2$inboundSchema: z.ZodType<OpenAIResponsesInputContent2, unknown>;
144
168
  export declare function openAIResponsesInputContent2FromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputContent2, SDKValidationError>;
145
169
  /** @internal */
170
+ export declare const OpenAIResponsesInputPhaseFinalAnswer$inboundSchema: z.ZodEnum<typeof OpenAIResponsesInputPhaseFinalAnswer>;
171
+ /** @internal */
172
+ export declare const OpenAIResponsesInputPhaseCommentary$inboundSchema: z.ZodEnum<typeof OpenAIResponsesInputPhaseCommentary>;
173
+ /** @internal */
174
+ export declare const OpenAIResponsesInputPhaseUnion$inboundSchema: z.ZodType<OpenAIResponsesInputPhaseUnion, unknown>;
175
+ export declare function openAIResponsesInputPhaseUnionFromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputPhaseUnion, SDKValidationError>;
176
+ /** @internal */
146
177
  export declare const OpenAIResponsesInputMessage1$inboundSchema: z.ZodType<OpenAIResponsesInputMessage1, unknown>;
147
178
  export declare function openAIResponsesInputMessage1FromJSON(jsonString: string): SafeParseResult<OpenAIResponsesInputMessage1, SDKValidationError>;
148
179
  /** @internal */
@@ -45,6 +45,12 @@ export const OpenAIResponsesInputRoleSystem1 = {
45
45
  export const OpenAIResponsesInputRoleUser1 = {
46
46
  User: "user",
47
47
  };
48
+ export const OpenAIResponsesInputPhaseFinalAnswer = {
49
+ FinalAnswer: "final_answer",
50
+ };
51
+ export const OpenAIResponsesInputPhaseCommentary = {
52
+ Commentary: "commentary",
53
+ };
48
54
  /** @internal */
49
55
  export const OpenAIResponsesInputTypeFunctionCall$inboundSchema = z.enum(OpenAIResponsesInputTypeFunctionCall);
50
56
  /** @internal */
@@ -66,11 +72,39 @@ export function openAIResponsesInputFunctionCallFromJSON(jsonString) {
66
72
  /** @internal */
67
73
  export const OpenAIResponsesInputTypeFunctionCallOutput$inboundSchema = z.enum(OpenAIResponsesInputTypeFunctionCallOutput);
68
74
  /** @internal */
75
+ export const OpenAIResponsesInputOutput1$inboundSchema = z.union([
76
+ ResponseInputText$inboundSchema,
77
+ ResponseInputImage$inboundSchema.and(z.object({ type: z.literal("input_image") })),
78
+ ResponseInputFile$inboundSchema,
79
+ ]);
80
+ export function openAIResponsesInputOutput1FromJSON(jsonString) {
81
+ return safeParse(jsonString, (x) => OpenAIResponsesInputOutput1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesInputOutput1' from JSON`);
82
+ }
83
+ /** @internal */
84
+ export const OpenAIResponsesInputOutput2$inboundSchema = z.union([
85
+ z.string(),
86
+ z.array(z.union([
87
+ ResponseInputText$inboundSchema,
88
+ ResponseInputImage$inboundSchema.and(z.object({ type: z.literal("input_image") })),
89
+ ResponseInputFile$inboundSchema,
90
+ ])),
91
+ ]);
92
+ export function openAIResponsesInputOutput2FromJSON(jsonString) {
93
+ return safeParse(jsonString, (x) => OpenAIResponsesInputOutput2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesInputOutput2' from JSON`);
94
+ }
95
+ /** @internal */
69
96
  export const OpenAIResponsesInputFunctionCallOutput$inboundSchema = z.object({
70
97
  type: OpenAIResponsesInputTypeFunctionCallOutput$inboundSchema,
71
98
  id: z.nullable(z.string()).optional(),
72
99
  call_id: z.string(),
73
- output: z.string(),
100
+ output: z.union([
101
+ z.string(),
102
+ z.array(z.union([
103
+ ResponseInputText$inboundSchema,
104
+ ResponseInputImage$inboundSchema.and(z.object({ type: z.literal("input_image") })),
105
+ ResponseInputFile$inboundSchema,
106
+ ])),
107
+ ]),
74
108
  status: z.nullable(ToolCallStatus$inboundSchema).optional(),
75
109
  }).transform((v) => {
76
110
  return remap$(v, {
@@ -170,6 +204,19 @@ export function openAIResponsesInputContent2FromJSON(jsonString) {
170
204
  return safeParse(jsonString, (x) => OpenAIResponsesInputContent2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesInputContent2' from JSON`);
171
205
  }
172
206
  /** @internal */
207
+ export const OpenAIResponsesInputPhaseFinalAnswer$inboundSchema = z.enum(OpenAIResponsesInputPhaseFinalAnswer);
208
+ /** @internal */
209
+ export const OpenAIResponsesInputPhaseCommentary$inboundSchema = z.enum(OpenAIResponsesInputPhaseCommentary);
210
+ /** @internal */
211
+ export const OpenAIResponsesInputPhaseUnion$inboundSchema = z.union([
212
+ OpenAIResponsesInputPhaseCommentary$inboundSchema,
213
+ OpenAIResponsesInputPhaseFinalAnswer$inboundSchema,
214
+ z.any(),
215
+ ]);
216
+ export function openAIResponsesInputPhaseUnionFromJSON(jsonString) {
217
+ return safeParse(jsonString, (x) => OpenAIResponsesInputPhaseUnion$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesInputPhaseUnion' from JSON`);
218
+ }
219
+ /** @internal */
173
220
  export const OpenAIResponsesInputMessage1$inboundSchema = z.object({
174
221
  type: OpenAIResponsesInputTypeMessage1$inboundSchema.optional(),
175
222
  role: z.union([
@@ -187,6 +234,11 @@ export const OpenAIResponsesInputMessage1$inboundSchema = z.object({
187
234
  ])),
188
235
  z.string(),
189
236
  ]),
237
+ phase: z.nullable(z.union([
238
+ OpenAIResponsesInputPhaseCommentary$inboundSchema,
239
+ OpenAIResponsesInputPhaseFinalAnswer$inboundSchema,
240
+ z.any(),
241
+ ])).optional(),
190
242
  });
191
243
  export function openAIResponsesInputMessage1FromJSON(jsonString) {
192
244
  return safeParse(jsonString, (x) => OpenAIResponsesInputMessage1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesInputMessage1' from JSON`);
@@ -5,7 +5,7 @@ import { OpenAIResponsesReasoningEffort } from "./openairesponsesreasoningeffort
5
5
  import { ReasoningSummaryVerbosity } from "./reasoningsummaryverbosity.js";
6
6
  export type OpenAIResponsesReasoningConfig = {
7
7
  effort?: OpenAIResponsesReasoningEffort | null | undefined;
8
- summary?: ReasoningSummaryVerbosity | undefined;
8
+ summary?: ReasoningSummaryVerbosity | null | undefined;
9
9
  };
10
10
  /** @internal */
11
11
  export declare const OpenAIResponsesReasoningConfig$inboundSchema: z.ZodType<OpenAIResponsesReasoningConfig, unknown>;
@@ -9,7 +9,7 @@ import { ReasoningSummaryVerbosity$inboundSchema, } from "./reasoningsummaryverb
9
9
  /** @internal */
10
10
  export const OpenAIResponsesReasoningConfig$inboundSchema = z.object({
11
11
  effort: z.nullable(OpenAIResponsesReasoningEffort$inboundSchema).optional(),
12
- summary: ReasoningSummaryVerbosity$inboundSchema.optional(),
12
+ summary: z.nullable(ReasoningSummaryVerbosity$inboundSchema).optional(),
13
13
  });
14
14
  export function openAIResponsesReasoningConfigFromJSON(jsonString) {
15
15
  return safeParse(jsonString, (x) => OpenAIResponsesReasoningConfig$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenAIResponsesReasoningConfig' from JSON`);
@@ -0,0 +1,20 @@
1
+ import * as z from "zod/v4";
2
+ import { Result as SafeParseResult } from "../types/fp.js";
3
+ import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
+ /**
5
+ * Apply patch tool configuration
6
+ */
7
+ export type OpenResponsesApplyPatchTool = {
8
+ type: "apply_patch";
9
+ };
10
+ /** @internal */
11
+ export declare const OpenResponsesApplyPatchTool$inboundSchema: z.ZodType<OpenResponsesApplyPatchTool, unknown>;
12
+ /** @internal */
13
+ export type OpenResponsesApplyPatchTool$Outbound = {
14
+ type: "apply_patch";
15
+ };
16
+ /** @internal */
17
+ export declare const OpenResponsesApplyPatchTool$outboundSchema: z.ZodType<OpenResponsesApplyPatchTool$Outbound, OpenResponsesApplyPatchTool>;
18
+ export declare function openResponsesApplyPatchToolToJSON(openResponsesApplyPatchTool: OpenResponsesApplyPatchTool): string;
19
+ export declare function openResponsesApplyPatchToolFromJSON(jsonString: string): SafeParseResult<OpenResponsesApplyPatchTool, SDKValidationError>;
20
+ //# sourceMappingURL=openresponsesapplypatchtool.d.ts.map
@@ -0,0 +1,21 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: 84640a5e950b
4
+ */
5
+ import * as z from "zod/v4";
6
+ import { safeParse } from "../lib/schemas.js";
7
+ /** @internal */
8
+ export const OpenResponsesApplyPatchTool$inboundSchema = z.object({
9
+ type: z.literal("apply_patch"),
10
+ });
11
+ /** @internal */
12
+ export const OpenResponsesApplyPatchTool$outboundSchema = z.object({
13
+ type: z.literal("apply_patch"),
14
+ });
15
+ export function openResponsesApplyPatchToolToJSON(openResponsesApplyPatchTool) {
16
+ return JSON.stringify(OpenResponsesApplyPatchTool$outboundSchema.parse(openResponsesApplyPatchTool));
17
+ }
18
+ export function openResponsesApplyPatchToolFromJSON(jsonString) {
19
+ return safeParse(jsonString, (x) => OpenResponsesApplyPatchTool$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenResponsesApplyPatchTool' from JSON`);
20
+ }
21
+ //# sourceMappingURL=openresponsesapplypatchtool.js.map
@@ -0,0 +1,68 @@
1
+ import * as z from "zod/v4";
2
+ import { ClosedEnum, OpenEnum } from "../types/enums.js";
3
+ import { Result as SafeParseResult } from "../types/fp.js";
4
+ import { SDKValidationError } from "./errors/sdkvalidationerror.js";
5
+ export declare const ContainerType: {
6
+ readonly Auto: "auto";
7
+ };
8
+ export type ContainerType = ClosedEnum<typeof ContainerType>;
9
+ export declare const MemoryLimit: {
10
+ readonly Oneg: "1g";
11
+ readonly Fourg: "4g";
12
+ readonly Sixteeng: "16g";
13
+ readonly SixtyFourg: "64g";
14
+ };
15
+ export type MemoryLimit = OpenEnum<typeof MemoryLimit>;
16
+ export type ContainerAuto = {
17
+ type: ContainerType;
18
+ fileIds?: Array<string> | undefined;
19
+ memoryLimit?: MemoryLimit | null | undefined;
20
+ };
21
+ export type Container = ContainerAuto | string;
22
+ /**
23
+ * Code interpreter tool configuration
24
+ */
25
+ export type OpenResponsesCodeInterpreterTool = {
26
+ type: "code_interpreter";
27
+ container: ContainerAuto | string;
28
+ };
29
+ /** @internal */
30
+ export declare const ContainerType$inboundSchema: z.ZodEnum<typeof ContainerType>;
31
+ /** @internal */
32
+ export declare const ContainerType$outboundSchema: z.ZodEnum<typeof ContainerType>;
33
+ /** @internal */
34
+ export declare const MemoryLimit$inboundSchema: z.ZodType<MemoryLimit, unknown>;
35
+ /** @internal */
36
+ export declare const MemoryLimit$outboundSchema: z.ZodType<string, MemoryLimit>;
37
+ /** @internal */
38
+ export declare const ContainerAuto$inboundSchema: z.ZodType<ContainerAuto, unknown>;
39
+ /** @internal */
40
+ export type ContainerAuto$Outbound = {
41
+ type: string;
42
+ file_ids?: Array<string> | undefined;
43
+ memory_limit?: string | null | undefined;
44
+ };
45
+ /** @internal */
46
+ export declare const ContainerAuto$outboundSchema: z.ZodType<ContainerAuto$Outbound, ContainerAuto>;
47
+ export declare function containerAutoToJSON(containerAuto: ContainerAuto): string;
48
+ export declare function containerAutoFromJSON(jsonString: string): SafeParseResult<ContainerAuto, SDKValidationError>;
49
+ /** @internal */
50
+ export declare const Container$inboundSchema: z.ZodType<Container, unknown>;
51
+ /** @internal */
52
+ export type Container$Outbound = ContainerAuto$Outbound | string;
53
+ /** @internal */
54
+ export declare const Container$outboundSchema: z.ZodType<Container$Outbound, Container>;
55
+ export declare function containerToJSON(container: Container): string;
56
+ export declare function containerFromJSON(jsonString: string): SafeParseResult<Container, SDKValidationError>;
57
+ /** @internal */
58
+ export declare const OpenResponsesCodeInterpreterTool$inboundSchema: z.ZodType<OpenResponsesCodeInterpreterTool, unknown>;
59
+ /** @internal */
60
+ export type OpenResponsesCodeInterpreterTool$Outbound = {
61
+ type: "code_interpreter";
62
+ container: ContainerAuto$Outbound | string;
63
+ };
64
+ /** @internal */
65
+ export declare const OpenResponsesCodeInterpreterTool$outboundSchema: z.ZodType<OpenResponsesCodeInterpreterTool$Outbound, OpenResponsesCodeInterpreterTool>;
66
+ export declare function openResponsesCodeInterpreterToolToJSON(openResponsesCodeInterpreterTool: OpenResponsesCodeInterpreterTool): string;
67
+ export declare function openResponsesCodeInterpreterToolFromJSON(jsonString: string): SafeParseResult<OpenResponsesCodeInterpreterTool, SDKValidationError>;
68
+ //# sourceMappingURL=openresponsescodeinterpretertool.d.ts.map