@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.
- package/FUNCTIONS.md +2 -1
- package/_speakeasy/.github/action-inputs-config.json +4 -0
- package/esm/funcs/analyticsGetUserActivity.js +2 -1
- package/esm/funcs/apiKeysCreate.js +2 -1
- package/esm/funcs/apiKeysDelete.js +2 -1
- package/esm/funcs/apiKeysGet.js +2 -1
- package/esm/funcs/apiKeysGetCurrentKeyMetadata.js +2 -1
- package/esm/funcs/apiKeysList.js +2 -1
- package/esm/funcs/apiKeysUpdate.js +2 -1
- package/esm/funcs/betaResponsesSend.js +2 -1
- package/esm/funcs/call-model.d.ts +19 -70
- package/esm/funcs/call-model.js +29 -71
- package/esm/funcs/chatSend.d.ts +3 -3
- package/esm/funcs/chatSend.js +20 -3
- package/esm/funcs/creditsCreateCoinbaseCharge.js +2 -1
- package/esm/funcs/creditsGetCredits.js +2 -1
- package/esm/funcs/embeddingsGenerate.js +2 -1
- package/esm/funcs/embeddingsListModels.js +2 -1
- package/esm/funcs/endpointsList.js +2 -1
- package/esm/funcs/endpointsListZdrEndpoints.js +2 -1
- package/esm/funcs/generationsGetGeneration.js +2 -1
- package/esm/funcs/guardrailsBulkAssignKeys.js +2 -1
- package/esm/funcs/guardrailsBulkAssignMembers.js +2 -1
- package/esm/funcs/guardrailsBulkUnassignKeys.js +2 -1
- package/esm/funcs/guardrailsBulkUnassignMembers.js +2 -1
- package/esm/funcs/guardrailsCreate.js +2 -1
- package/esm/funcs/guardrailsDelete.js +2 -1
- package/esm/funcs/guardrailsGet.js +2 -1
- package/esm/funcs/guardrailsList.js +2 -1
- package/esm/funcs/guardrailsListGuardrailKeyAssignments.js +2 -1
- package/esm/funcs/guardrailsListGuardrailMemberAssignments.js +2 -1
- package/esm/funcs/guardrailsListKeyAssignments.js +2 -1
- package/esm/funcs/guardrailsListMemberAssignments.js +2 -1
- package/esm/funcs/guardrailsUpdate.js +2 -1
- package/esm/funcs/modelsCount.d.ts +1 -1
- package/esm/funcs/modelsCount.js +9 -4
- package/esm/funcs/modelsList.js +3 -1
- package/esm/funcs/modelsListForUser.js +2 -1
- package/esm/funcs/oAuthCreateAuthCode.d.ts +1 -1
- package/esm/funcs/oAuthCreateAuthCode.js +4 -3
- package/esm/funcs/oAuthExchangeAuthCodeForAPIKey.js +2 -1
- package/esm/funcs/providersList.js +2 -1
- package/esm/index.d.ts +22 -23
- package/esm/index.js +20 -17
- package/esm/lib/anthropic-compat.d.ts +2 -1
- package/esm/lib/anthropic-compat.js +1 -2
- package/esm/lib/async-params.d.ts +19 -5
- package/esm/lib/async-params.js +5 -1
- package/esm/lib/chat-compat.d.ts +1 -1
- package/esm/lib/chat-compat.js +1 -2
- package/esm/lib/claude-type-guards.d.ts +2 -2
- package/esm/lib/config.d.ts +8 -10
- package/esm/lib/config.js +2 -2
- package/esm/lib/conversation-state.d.ts +1 -1
- package/esm/lib/conversation-state.js +35 -32
- package/esm/lib/env.d.ts +6 -2
- package/esm/lib/env.js +7 -3
- package/esm/lib/model-result.d.ts +73 -17
- package/esm/lib/model-result.js +329 -125
- package/esm/lib/sdks.d.ts +1 -1
- package/esm/lib/sdks.js +8 -28
- package/esm/lib/stream-transformers.d.ts +5 -4
- package/esm/lib/stream-transformers.js +24 -29
- package/esm/lib/stream-type-guards.js +8 -32
- package/esm/lib/tool-context.d.ts +68 -0
- package/esm/lib/tool-context.js +175 -0
- package/esm/lib/tool-executor.d.ts +9 -5
- package/esm/lib/tool-executor.js +26 -16
- package/esm/lib/tool-orchestrator.d.ts +2 -2
- package/esm/lib/tool-types.d.ts +101 -14
- package/esm/lib/tool-types.js +17 -0
- package/esm/lib/tool.d.ts +49 -60
- package/esm/lib/tool.js +15 -19
- package/esm/lib/turn-context.d.ts +1 -1
- package/esm/models/assistantmessage.d.ts +53 -36
- package/esm/models/assistantmessage.js +38 -47
- package/esm/models/assistantmessageimages.d.ts +33 -0
- package/esm/models/assistantmessageimages.js +44 -0
- package/esm/models/chatcompletionaudiooutput.d.ts +38 -0
- package/esm/models/chatcompletionaudiooutput.js +36 -0
- package/esm/models/chatgenerationparams.d.ts +527 -131
- package/esm/models/chatgenerationparams.js +280 -97
- package/esm/models/chatgenerationtokenusage.d.ts +48 -0
- package/esm/models/chatmessagecontentitem.d.ts +16 -10
- package/esm/models/chatmessagecontentitem.js +28 -4
- package/esm/models/chatmessagecontentitemaudio.d.ts +20 -2
- package/esm/models/chatmessagecontentitemaudio.js +9 -2
- package/esm/models/chatmessagecontentitemcachecontrol.d.ts +19 -8
- package/esm/models/chatmessagecontentitemcachecontrol.js +14 -9
- package/esm/models/chatmessagecontentitemfile.d.ts +57 -0
- package/esm/models/chatmessagecontentitemfile.js +59 -0
- package/esm/models/chatmessagecontentitemimage.d.ts +26 -3
- package/esm/models/chatmessagecontentitemimage.js +12 -2
- package/esm/models/chatmessagecontentitemtext.d.ts +17 -2
- package/esm/models/chatmessagecontentitemtext.js +9 -2
- package/esm/models/chatmessagecontentitemvideo.d.ts +12 -55
- package/esm/models/chatmessagecontentitemvideo.js +5 -72
- package/esm/models/chatmessagecontentitemvideolegacy.d.ts +28 -0
- package/esm/models/chatmessagecontentitemvideolegacy.js +33 -0
- package/esm/models/chatmessagetokenlogprob.d.ts +15 -0
- package/esm/models/chatmessagetokenlogprobs.d.ts +10 -1
- package/esm/models/chatmessagetokenlogprobs.js +2 -1
- package/esm/models/chatmessagetoolcall.d.ts +23 -2
- package/esm/models/chatmessagetoolcall.js +9 -2
- package/esm/models/chatresponse.d.ts +30 -2
- package/esm/models/chatresponse.js +7 -2
- package/esm/models/chatresponsechoice.d.ts +13 -2
- package/esm/models/chatresponsechoice.js +1 -2
- package/esm/models/chatstreamingchoice.d.ts +13 -2
- package/esm/models/chatstreamingchoice.js +1 -2
- package/esm/models/chatstreamingmessagechunk.d.ts +31 -2
- package/esm/models/chatstreamingmessagechunk.js +7 -2
- package/esm/models/chatstreamingmessagetoolcall.d.ts +38 -1
- package/esm/models/chatstreamingmessagetoolcall.js +9 -1
- package/esm/models/chatstreamingresponsechunk.d.ts +46 -12
- package/esm/models/chatstreamingresponsechunk.js +12 -26
- package/esm/models/chatstreamoptions.d.ts +8 -0
- package/esm/models/compoundfilter.d.ts +36 -0
- package/esm/models/compoundfilter.js +32 -0
- package/esm/models/conflictresponseerrordata.d.ts +17 -0
- package/esm/models/conflictresponseerrordata.js +16 -0
- package/esm/models/contextcompressionengine.d.ts +15 -0
- package/esm/models/contextcompressionengine.js +14 -0
- package/esm/models/datetimeservertool.d.ts +30 -0
- package/esm/models/datetimeservertool.js +22 -0
- package/esm/models/debugoptions.d.ts +18 -0
- package/esm/models/debugoptions.js +18 -0
- package/esm/models/defaultparameters.d.ts +3 -0
- package/esm/models/defaultparameters.js +6 -0
- package/esm/models/developermessage.d.ts +12 -0
- package/esm/models/errors/conflictresponseerror.d.ts +33 -0
- package/esm/models/errors/{chaterror.js → conflictresponseerror.js} +17 -7
- package/esm/models/errors/index.d.ts +1 -1
- package/esm/models/errors/index.js +1 -1
- package/esm/models/index.d.ts +35 -12
- package/esm/models/index.js +35 -12
- package/esm/models/jsonschemaconfig.d.ts +17 -2
- package/esm/models/jsonschemaconfig.js +1 -1
- package/esm/models/message.d.ts +9 -2
- package/esm/models/message.js +1 -1
- package/esm/models/modelscountresponse.d.ts +4 -4
- package/esm/models/modelscountresponse.js +4 -4
- package/esm/models/namedtoolchoice.d.ts +15 -2
- package/esm/models/namedtoolchoice.js +6 -1
- package/esm/models/openairesponsesinputunion.d.ts +32 -1
- package/esm/models/openairesponsesinputunion.js +53 -1
- package/esm/models/openairesponsesreasoningconfig.d.ts +1 -1
- package/esm/models/openairesponsesreasoningconfig.js +1 -1
- package/esm/models/openresponsesapplypatchtool.d.ts +20 -0
- package/esm/models/openresponsesapplypatchtool.js +21 -0
- package/esm/models/openresponsescodeinterpretertool.d.ts +68 -0
- package/esm/models/openresponsescodeinterpretertool.js +85 -0
- package/esm/models/openresponsescomputertool.d.ts +39 -0
- package/esm/models/openresponsescomputertool.js +50 -0
- package/esm/models/openresponsescustomtool.d.ts +75 -0
- package/esm/models/openresponsescustomtool.js +95 -0
- package/esm/models/openresponseseasyinputmessage.d.ts +30 -4
- package/esm/models/openresponseseasyinputmessage.js +28 -2
- package/esm/models/openresponsesfilesearchtool.d.ts +111 -0
- package/esm/models/openresponsesfilesearchtool.js +180 -0
- package/esm/models/openresponsesfunctioncalloutput.d.ts +46 -7
- package/esm/models/openresponsesfunctioncalloutput.js +56 -4
- package/esm/models/openresponsesfunctionshelltool.d.ts +20 -0
- package/esm/models/openresponsesfunctionshelltool.js +21 -0
- package/esm/models/openresponsesimagegenerationtool.d.ts +125 -0
- package/esm/models/openresponsesimagegenerationtool.js +153 -0
- package/esm/models/openresponsesinputmessageitem.d.ts +2 -2
- package/esm/models/openresponsesinputmessageitem.js +2 -2
- package/esm/models/openresponsesinputunion.d.ts +207 -0
- package/esm/models/openresponsesinputunion.js +225 -0
- package/esm/models/openresponseslocalshelltool.d.ts +20 -0
- package/esm/models/openresponseslocalshelltool.js +21 -0
- package/esm/models/openresponsesmcptool.d.ts +128 -0
- package/esm/models/openresponsesmcptool.js +173 -0
- package/esm/models/openresponsesnonstreamingresponse.d.ts +15 -6
- package/esm/models/openresponsesnonstreamingresponse.js +30 -3
- package/esm/models/openresponsesreasoning.d.ts +2 -2
- package/esm/models/openresponsesreasoning.js +1 -1
- package/esm/models/openresponsesreasoningconfig.d.ts +2 -2
- package/esm/models/openresponsesreasoningconfig.js +1 -1
- package/esm/models/openresponsesrequest.d.ts +111 -39
- package/esm/models/openresponsesrequest.js +112 -38
- package/esm/models/openresponsesstreamevent.d.ts +52 -4
- package/esm/models/openresponsesstreamevent.js +54 -3
- package/esm/models/openresponseswebsearch20250826tool.d.ts +29 -0
- package/esm/models/openresponseswebsearch20250826tool.js +23 -0
- package/esm/models/openresponseswebsearchcallcompleted.d.ts +16 -0
- package/esm/models/openresponseswebsearchcallcompleted.js +24 -0
- package/esm/models/openresponseswebsearchcallinprogress.d.ts +16 -0
- package/esm/models/openresponseswebsearchcallinprogress.js +24 -0
- package/esm/models/openresponseswebsearchcallsearching.d.ts +16 -0
- package/esm/models/openresponseswebsearchcallsearching.js +24 -0
- package/esm/models/openresponseswebsearchpreview20250311tool.d.ts +44 -0
- package/esm/models/openresponseswebsearchpreview20250311tool.js +51 -0
- package/esm/models/openresponseswebsearchpreviewtool.d.ts +44 -0
- package/esm/models/openresponseswebsearchpreviewtool.js +47 -0
- package/esm/models/openresponseswebsearchtool.d.ts +29 -0
- package/esm/models/openresponseswebsearchtool.js +23 -0
- package/esm/models/operations/bulkassignkeystoguardrail.d.ts +16 -3
- package/esm/models/operations/bulkassignkeystoguardrail.js +2 -2
- package/esm/models/operations/bulkassignmemberstoguardrail.d.ts +16 -3
- package/esm/models/operations/bulkassignmemberstoguardrail.js +2 -2
- package/esm/models/operations/bulkunassignkeysfromguardrail.d.ts +16 -3
- package/esm/models/operations/bulkunassignkeysfromguardrail.js +2 -2
- package/esm/models/operations/bulkunassignmembersfromguardrail.d.ts +16 -3
- package/esm/models/operations/bulkunassignmembersfromguardrail.js +2 -2
- package/esm/models/operations/createauthkeyscode.d.ts +40 -3
- package/esm/models/operations/createauthkeyscode.js +16 -2
- package/esm/models/operations/createcoinbasecharge.d.ts +16 -3
- package/esm/models/operations/createcoinbasecharge.js +2 -2
- package/esm/models/operations/createembeddings.d.ts +16 -3
- package/esm/models/operations/createembeddings.js +2 -2
- package/esm/models/operations/createguardrail.d.ts +25 -3
- package/esm/models/operations/createguardrail.js +6 -2
- package/esm/models/operations/createkeys.d.ts +16 -3
- package/esm/models/operations/createkeys.js +2 -2
- package/esm/models/operations/createresponses.d.ts +16 -3
- package/esm/models/operations/createresponses.js +2 -2
- package/esm/models/operations/deleteguardrail.d.ts +16 -3
- package/esm/models/operations/deleteguardrail.js +2 -2
- package/esm/models/operations/deletekeys.d.ts +16 -3
- package/esm/models/operations/deletekeys.js +2 -2
- package/esm/models/operations/exchangeauthcodeforapikey.d.ts +16 -3
- package/esm/models/operations/exchangeauthcodeforapikey.js +2 -2
- package/esm/models/operations/getcredits.d.ts +16 -3
- package/esm/models/operations/getcredits.js +2 -2
- package/esm/models/operations/getcurrentkey.d.ts +16 -3
- package/esm/models/operations/getcurrentkey.js +2 -2
- package/esm/models/operations/getgeneration.d.ts +27 -3
- package/esm/models/operations/getgeneration.js +9 -2
- package/esm/models/operations/getguardrail.d.ts +20 -3
- package/esm/models/operations/getguardrail.js +4 -2
- package/esm/models/operations/getkey.d.ts +16 -3
- package/esm/models/operations/getkey.js +2 -2
- package/esm/models/operations/getmodels.d.ts +21 -3
- package/esm/models/operations/getmodels.js +4 -2
- package/esm/models/operations/getuseractivity.d.ts +16 -3
- package/esm/models/operations/getuseractivity.js +2 -2
- package/esm/models/operations/list.d.ts +16 -3
- package/esm/models/operations/list.js +2 -2
- package/esm/models/operations/listembeddingsmodels.d.ts +16 -3
- package/esm/models/operations/listembeddingsmodels.js +2 -2
- package/esm/models/operations/listendpoints.d.ts +16 -3
- package/esm/models/operations/listendpoints.js +2 -2
- package/esm/models/operations/listendpointszdr.d.ts +16 -3
- package/esm/models/operations/listendpointszdr.js +2 -2
- package/esm/models/operations/listguardrailkeyassignments.d.ts +16 -3
- package/esm/models/operations/listguardrailkeyassignments.js +2 -2
- package/esm/models/operations/listguardrailmemberassignments.d.ts +16 -3
- package/esm/models/operations/listguardrailmemberassignments.js +2 -2
- package/esm/models/operations/listguardrails.d.ts +20 -3
- package/esm/models/operations/listguardrails.js +4 -2
- package/esm/models/operations/listkeyassignments.d.ts +16 -3
- package/esm/models/operations/listkeyassignments.js +2 -2
- package/esm/models/operations/listmemberassignments.d.ts +16 -3
- package/esm/models/operations/listmemberassignments.js +2 -2
- package/esm/models/operations/listmodelscount.d.ts +21 -3
- package/esm/models/operations/listmodelscount.js +4 -2
- package/esm/models/operations/listmodelsuser.d.ts +16 -3
- package/esm/models/operations/listmodelsuser.js +2 -2
- package/esm/models/operations/listproviders.d.ts +16 -3
- package/esm/models/operations/listproviders.js +2 -2
- package/esm/models/operations/sendchatcompletionrequest.d.ts +27 -5
- package/esm/models/operations/sendchatcompletionrequest.js +22 -4
- package/esm/models/operations/updateguardrail.d.ts +25 -3
- package/esm/models/operations/updateguardrail.js +6 -2
- package/esm/models/operations/updatekeys.d.ts +16 -3
- package/esm/models/operations/updatekeys.js +2 -2
- package/esm/models/outputmessage.d.ts +23 -0
- package/esm/models/outputmessage.js +24 -0
- package/esm/models/outputmodality.d.ts +1 -0
- package/esm/models/outputmodality.js +1 -0
- package/esm/models/providername.d.ts +3 -0
- package/esm/models/providername.js +3 -0
- package/esm/models/providerpreferences.d.ts +49 -14
- package/esm/models/providerpreferences.js +33 -15
- package/esm/models/providersort.d.ts +7 -0
- package/esm/models/providersort.js +4 -0
- package/esm/models/providersortconfig.d.ts +31 -2
- package/esm/models/providersortconfig.js +16 -2
- package/esm/models/reasoningdetailencrypted.d.ts +42 -0
- package/esm/models/reasoningdetailencrypted.js +42 -0
- package/esm/models/reasoningdetailsummary.d.ts +42 -0
- package/esm/models/reasoningdetailsummary.js +42 -0
- package/esm/models/reasoningdetailtext.d.ts +44 -0
- package/esm/models/reasoningdetailtext.js +44 -0
- package/esm/models/reasoningdetailunion.d.ts +19 -0
- package/esm/models/reasoningdetailunion.js +28 -0
- package/esm/models/responseformatjsonobject.d.ts +20 -0
- package/esm/models/responseformatjsonobject.js +21 -0
- package/esm/models/responseformatjsonschema.d.ts +6 -0
- package/esm/models/responseformattext.d.ts +15 -0
- package/esm/models/responseformattext.js +13 -0
- package/esm/models/responseformattextconfig.d.ts +3 -3
- package/esm/models/responseformattextconfig.js +3 -3
- package/esm/models/responseformattextgrammar.d.ts +6 -0
- package/esm/models/responseformattextpython.d.ts +15 -0
- package/esm/models/responseformattextpython.js +13 -0
- package/esm/models/responseoutputtext.d.ts +8 -8
- package/esm/models/responseoutputtext.js +10 -9
- package/esm/models/responseserrorfield.d.ts +4 -4
- package/esm/models/responseserrorfield.js +4 -4
- package/esm/models/responsesoutputitem.d.ts +2 -13
- package/esm/models/responsesoutputitem.js +8 -6
- package/esm/models/responsesoutputitemreasoning.d.ts +3 -32
- package/esm/models/responsesoutputitemreasoning.js +3 -45
- package/esm/models/responsesoutputmessage.d.ts +24 -32
- package/esm/models/responsesoutputmessage.js +26 -47
- package/esm/models/responsesservertooloutput.d.ts +42 -0
- package/esm/models/responsesservertooloutput.js +44 -0
- package/esm/models/responseswebsearchcalloutput.d.ts +90 -5
- package/esm/models/responseswebsearchcalloutput.js +113 -5
- package/esm/models/responseswebsearchservertool.d.ts +35 -0
- package/esm/models/responseswebsearchservertool.js +28 -0
- package/esm/models/systemmessage.d.ts +12 -0
- package/esm/models/toolchoiceoption.d.ts +31 -0
- package/esm/models/toolchoiceoption.js +32 -0
- package/esm/models/tooldefinitionjson.d.ts +62 -10
- package/esm/models/tooldefinitionjson.js +29 -6
- package/esm/models/toolresponsemessage.d.ts +12 -0
- package/esm/models/usermessage.d.ts +12 -0
- package/esm/models/videoinput.d.ts +23 -0
- package/esm/models/videoinput.js +22 -0
- package/esm/models/websearchengine.d.ts +2 -0
- package/esm/models/websearchengine.js +2 -0
- package/esm/models/websearchservertool.d.ts +116 -0
- package/esm/models/websearchservertool.js +77 -0
- package/esm/models/websearchshorthand.d.ts +215 -0
- package/esm/models/websearchshorthand.js +138 -0
- package/esm/sdk/chat.d.ts +1 -1
- package/esm/sdk/sdk.d.ts +6 -3
- package/esm/sdk/sdk.js +3 -4
- package/esm/types/index.d.ts +0 -2
- package/esm/types/index.js +0 -1
- package/jsr.json +1 -1
- package/package.json +11 -6
- package/turbo.json +10 -0
- package/esm/models/chaterror.d.ts +0 -17
- package/esm/models/chaterror.js +0 -25
- package/esm/models/errors/chaterror.d.ts +0 -19
- package/esm/models/openresponsesinput.d.ts +0 -28
- package/esm/models/openresponsesinput.js +0 -54
- package/esm/models/openresponseslogprobs.d.ts +0 -16
- package/esm/models/openresponseslogprobs.js +0 -22
- package/esm/models/openresponsestoplogprobs.d.ts +0 -14
- package/esm/models/openresponsestoplogprobs.js +0 -15
- package/esm/models/providersortunion.d.ts +0 -10
- package/esm/models/providersortunion.js +0 -13
- package/esm/models/responsesformatjsonobject.d.ts +0 -20
- package/esm/models/responsesformatjsonobject.js +0 -21
- package/esm/models/schema10.d.ts +0 -33
- package/esm/models/schema10.js +0 -30
- package/esm/models/schema14.d.ts +0 -8
- package/esm/models/schema14.js +0 -12
- package/esm/models/schema17.d.ts +0 -102
- package/esm/models/schema17.js +0 -95
- package/esm/models/schema19.d.ts +0 -92
- package/esm/models/schema19.js +0 -109
- package/esm/models/schema5.d.ts +0 -86
- package/esm/models/schema5.js +0 -89
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 1693a27fc478
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../lib/schemas.js";
|
|
8
|
+
import * as openEnums from "../types/enums.js";
|
|
9
|
+
export const ConnectorId = {
|
|
10
|
+
ConnectorDropbox: "connector_dropbox",
|
|
11
|
+
ConnectorGmail: "connector_gmail",
|
|
12
|
+
ConnectorGooglecalendar: "connector_googlecalendar",
|
|
13
|
+
ConnectorGoogledrive: "connector_googledrive",
|
|
14
|
+
ConnectorMicrosoftteams: "connector_microsoftteams",
|
|
15
|
+
ConnectorOutlookcalendar: "connector_outlookcalendar",
|
|
16
|
+
ConnectorOutlookemail: "connector_outlookemail",
|
|
17
|
+
ConnectorSharepoint: "connector_sharepoint",
|
|
18
|
+
};
|
|
19
|
+
export const RequireApprovalNever = {
|
|
20
|
+
Never: "never",
|
|
21
|
+
};
|
|
22
|
+
export const RequireApprovalAlways = {
|
|
23
|
+
Always: "always",
|
|
24
|
+
};
|
|
25
|
+
/** @internal */
|
|
26
|
+
export const AllowedTools$inboundSchema = z
|
|
27
|
+
.object({
|
|
28
|
+
tool_names: z.array(z.string()).optional(),
|
|
29
|
+
read_only: z.boolean().optional(),
|
|
30
|
+
}).transform((v) => {
|
|
31
|
+
return remap$(v, {
|
|
32
|
+
"tool_names": "toolNames",
|
|
33
|
+
"read_only": "readOnly",
|
|
34
|
+
});
|
|
35
|
+
});
|
|
36
|
+
/** @internal */
|
|
37
|
+
export const AllowedTools$outboundSchema = z.object({
|
|
38
|
+
toolNames: z.array(z.string()).optional(),
|
|
39
|
+
readOnly: z.boolean().optional(),
|
|
40
|
+
}).transform((v) => {
|
|
41
|
+
return remap$(v, {
|
|
42
|
+
toolNames: "tool_names",
|
|
43
|
+
readOnly: "read_only",
|
|
44
|
+
});
|
|
45
|
+
});
|
|
46
|
+
export function allowedToolsToJSON(allowedTools) {
|
|
47
|
+
return JSON.stringify(AllowedTools$outboundSchema.parse(allowedTools));
|
|
48
|
+
}
|
|
49
|
+
export function allowedToolsFromJSON(jsonString) {
|
|
50
|
+
return safeParse(jsonString, (x) => AllowedTools$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AllowedTools' from JSON`);
|
|
51
|
+
}
|
|
52
|
+
/** @internal */
|
|
53
|
+
export const ConnectorId$inboundSchema = openEnums.inboundSchema(ConnectorId);
|
|
54
|
+
/** @internal */
|
|
55
|
+
export const ConnectorId$outboundSchema = openEnums.outboundSchema(ConnectorId);
|
|
56
|
+
/** @internal */
|
|
57
|
+
export const RequireApprovalNever$inboundSchema = z.enum(RequireApprovalNever);
|
|
58
|
+
/** @internal */
|
|
59
|
+
export const RequireApprovalNever$outboundSchema = RequireApprovalNever$inboundSchema;
|
|
60
|
+
/** @internal */
|
|
61
|
+
export const RequireApprovalAlways$inboundSchema = z.enum(RequireApprovalAlways);
|
|
62
|
+
/** @internal */
|
|
63
|
+
export const RequireApprovalAlways$outboundSchema = RequireApprovalAlways$inboundSchema;
|
|
64
|
+
/** @internal */
|
|
65
|
+
export const Never$inboundSchema = z.object({
|
|
66
|
+
tool_names: z.array(z.string()).optional(),
|
|
67
|
+
}).transform((v) => {
|
|
68
|
+
return remap$(v, {
|
|
69
|
+
"tool_names": "toolNames",
|
|
70
|
+
});
|
|
71
|
+
});
|
|
72
|
+
/** @internal */
|
|
73
|
+
export const Never$outboundSchema = z.object({
|
|
74
|
+
toolNames: z.array(z.string()).optional(),
|
|
75
|
+
}).transform((v) => {
|
|
76
|
+
return remap$(v, {
|
|
77
|
+
toolNames: "tool_names",
|
|
78
|
+
});
|
|
79
|
+
});
|
|
80
|
+
export function neverToJSON(never) {
|
|
81
|
+
return JSON.stringify(Never$outboundSchema.parse(never));
|
|
82
|
+
}
|
|
83
|
+
export function neverFromJSON(jsonString) {
|
|
84
|
+
return safeParse(jsonString, (x) => Never$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Never' from JSON`);
|
|
85
|
+
}
|
|
86
|
+
/** @internal */
|
|
87
|
+
export const Always$inboundSchema = z.object({
|
|
88
|
+
tool_names: z.array(z.string()).optional(),
|
|
89
|
+
}).transform((v) => {
|
|
90
|
+
return remap$(v, {
|
|
91
|
+
"tool_names": "toolNames",
|
|
92
|
+
});
|
|
93
|
+
});
|
|
94
|
+
/** @internal */
|
|
95
|
+
export const Always$outboundSchema = z
|
|
96
|
+
.object({
|
|
97
|
+
toolNames: z.array(z.string()).optional(),
|
|
98
|
+
}).transform((v) => {
|
|
99
|
+
return remap$(v, {
|
|
100
|
+
toolNames: "tool_names",
|
|
101
|
+
});
|
|
102
|
+
});
|
|
103
|
+
export function alwaysToJSON(always) {
|
|
104
|
+
return JSON.stringify(Always$outboundSchema.parse(always));
|
|
105
|
+
}
|
|
106
|
+
export function alwaysFromJSON(jsonString) {
|
|
107
|
+
return safeParse(jsonString, (x) => Always$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Always' from JSON`);
|
|
108
|
+
}
|
|
109
|
+
/** @internal */
|
|
110
|
+
export const RequireApproval$inboundSchema = z.object({
|
|
111
|
+
never: z.lazy(() => Never$inboundSchema).optional(),
|
|
112
|
+
always: z.lazy(() => Always$inboundSchema).optional(),
|
|
113
|
+
});
|
|
114
|
+
/** @internal */
|
|
115
|
+
export const RequireApproval$outboundSchema = z.object({
|
|
116
|
+
never: z.lazy(() => Never$outboundSchema).optional(),
|
|
117
|
+
always: z.lazy(() => Always$outboundSchema).optional(),
|
|
118
|
+
});
|
|
119
|
+
export function requireApprovalToJSON(requireApproval) {
|
|
120
|
+
return JSON.stringify(RequireApproval$outboundSchema.parse(requireApproval));
|
|
121
|
+
}
|
|
122
|
+
export function requireApprovalFromJSON(jsonString) {
|
|
123
|
+
return safeParse(jsonString, (x) => RequireApproval$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RequireApproval' from JSON`);
|
|
124
|
+
}
|
|
125
|
+
/** @internal */
|
|
126
|
+
export const OpenResponsesMcpTool$inboundSchema = z.object({
|
|
127
|
+
type: z.literal("mcp"),
|
|
128
|
+
server_label: z.string(),
|
|
129
|
+
allowed_tools: z.nullable(z.any()).optional(),
|
|
130
|
+
authorization: z.string().optional(),
|
|
131
|
+
connector_id: ConnectorId$inboundSchema.optional(),
|
|
132
|
+
headers: z.nullable(z.record(z.string(), z.string())).optional(),
|
|
133
|
+
require_approval: z.nullable(z.any()).optional(),
|
|
134
|
+
server_description: z.string().optional(),
|
|
135
|
+
server_url: z.string().optional(),
|
|
136
|
+
}).transform((v) => {
|
|
137
|
+
return remap$(v, {
|
|
138
|
+
"server_label": "serverLabel",
|
|
139
|
+
"allowed_tools": "allowedTools",
|
|
140
|
+
"connector_id": "connectorId",
|
|
141
|
+
"require_approval": "requireApproval",
|
|
142
|
+
"server_description": "serverDescription",
|
|
143
|
+
"server_url": "serverUrl",
|
|
144
|
+
});
|
|
145
|
+
});
|
|
146
|
+
/** @internal */
|
|
147
|
+
export const OpenResponsesMcpTool$outboundSchema = z.object({
|
|
148
|
+
type: z.literal("mcp"),
|
|
149
|
+
serverLabel: z.string(),
|
|
150
|
+
allowedTools: z.nullable(z.any()).optional(),
|
|
151
|
+
authorization: z.string().optional(),
|
|
152
|
+
connectorId: ConnectorId$outboundSchema.optional(),
|
|
153
|
+
headers: z.nullable(z.record(z.string(), z.string())).optional(),
|
|
154
|
+
requireApproval: z.nullable(z.any()).optional(),
|
|
155
|
+
serverDescription: z.string().optional(),
|
|
156
|
+
serverUrl: z.string().optional(),
|
|
157
|
+
}).transform((v) => {
|
|
158
|
+
return remap$(v, {
|
|
159
|
+
serverLabel: "server_label",
|
|
160
|
+
allowedTools: "allowed_tools",
|
|
161
|
+
connectorId: "connector_id",
|
|
162
|
+
requireApproval: "require_approval",
|
|
163
|
+
serverDescription: "server_description",
|
|
164
|
+
serverUrl: "server_url",
|
|
165
|
+
});
|
|
166
|
+
});
|
|
167
|
+
export function openResponsesMcpToolToJSON(openResponsesMcpTool) {
|
|
168
|
+
return JSON.stringify(OpenResponsesMcpTool$outboundSchema.parse(openResponsesMcpTool));
|
|
169
|
+
}
|
|
170
|
+
export function openResponsesMcpToolFromJSON(jsonString) {
|
|
171
|
+
return safeParse(jsonString, (x) => OpenResponsesMcpTool$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenResponsesMcpTool' from JSON`);
|
|
172
|
+
}
|
|
173
|
+
//# sourceMappingURL=openresponsesmcptool.js.map
|
|
@@ -10,6 +10,15 @@ import { OpenAIResponsesResponseStatus } from "./openairesponsesresponsestatus.j
|
|
|
10
10
|
import { OpenAIResponsesServiceTier } from "./openairesponsesservicetier.js";
|
|
11
11
|
import { OpenAIResponsesToolChoiceUnion } from "./openairesponsestoolchoiceunion.js";
|
|
12
12
|
import { OpenAIResponsesTruncation } from "./openairesponsestruncation.js";
|
|
13
|
+
import { OpenResponsesApplyPatchTool } from "./openresponsesapplypatchtool.js";
|
|
14
|
+
import { OpenResponsesCodeInterpreterTool } from "./openresponsescodeinterpretertool.js";
|
|
15
|
+
import { OpenResponsesComputerTool } from "./openresponsescomputertool.js";
|
|
16
|
+
import { OpenResponsesCustomTool } from "./openresponsescustomtool.js";
|
|
17
|
+
import { OpenResponsesFileSearchTool } from "./openresponsesfilesearchtool.js";
|
|
18
|
+
import { OpenResponsesFunctionShellTool } from "./openresponsesfunctionshelltool.js";
|
|
19
|
+
import { OpenResponsesImageGenerationTool } from "./openresponsesimagegenerationtool.js";
|
|
20
|
+
import { OpenResponsesLocalShellTool } from "./openresponseslocalshelltool.js";
|
|
21
|
+
import { OpenResponsesMcpTool } from "./openresponsesmcptool.js";
|
|
13
22
|
import { OpenResponsesUsage } from "./openresponsesusage.js";
|
|
14
23
|
import { OpenResponsesWebSearch20250826Tool } from "./openresponseswebsearch20250826tool.js";
|
|
15
24
|
import { OpenResponsesWebSearchPreview20250311Tool } from "./openresponseswebsearchpreview20250311tool.js";
|
|
@@ -18,10 +27,10 @@ import { OpenResponsesWebSearchTool } from "./openresponseswebsearchtool.js";
|
|
|
18
27
|
import { ResponsesErrorField } from "./responseserrorfield.js";
|
|
19
28
|
import { ResponsesOutputItem } from "./responsesoutputitem.js";
|
|
20
29
|
import { ResponseTextConfig } from "./responsetextconfig.js";
|
|
21
|
-
export declare const
|
|
30
|
+
export declare const OpenResponsesNonStreamingResponseObject: {
|
|
22
31
|
readonly Response: "response";
|
|
23
32
|
};
|
|
24
|
-
export type
|
|
33
|
+
export type OpenResponsesNonStreamingResponseObject = ClosedEnum<typeof OpenResponsesNonStreamingResponseObject>;
|
|
25
34
|
/**
|
|
26
35
|
* Function tool definition
|
|
27
36
|
*/
|
|
@@ -34,13 +43,13 @@ export type OpenResponsesNonStreamingResponseToolFunction = {
|
|
|
34
43
|
[k: string]: any | null;
|
|
35
44
|
} | null;
|
|
36
45
|
};
|
|
37
|
-
export type OpenResponsesNonStreamingResponseToolUnion = OpenResponsesNonStreamingResponseToolFunction | OpenResponsesWebSearchPreviewTool | OpenResponsesWebSearchPreview20250311Tool | OpenResponsesWebSearchTool | OpenResponsesWebSearch20250826Tool;
|
|
46
|
+
export type OpenResponsesNonStreamingResponseToolUnion = OpenResponsesNonStreamingResponseToolFunction | OpenResponsesWebSearchPreviewTool | OpenResponsesWebSearchPreview20250311Tool | OpenResponsesWebSearchTool | OpenResponsesWebSearch20250826Tool | OpenResponsesFileSearchTool | OpenResponsesComputerTool | OpenResponsesCodeInterpreterTool | OpenResponsesMcpTool | OpenResponsesImageGenerationTool | OpenResponsesLocalShellTool | OpenResponsesFunctionShellTool | OpenResponsesApplyPatchTool | OpenResponsesCustomTool;
|
|
38
47
|
/**
|
|
39
48
|
* Complete non-streaming response from the Responses API
|
|
40
49
|
*/
|
|
41
50
|
export type OpenResponsesNonStreamingResponse = {
|
|
42
51
|
id: string;
|
|
43
|
-
object:
|
|
52
|
+
object: OpenResponsesNonStreamingResponseObject;
|
|
44
53
|
createdAt: number;
|
|
45
54
|
model: string;
|
|
46
55
|
status: OpenAIResponsesResponseStatus;
|
|
@@ -73,7 +82,7 @@ export type OpenResponsesNonStreamingResponse = {
|
|
|
73
82
|
metadata: {
|
|
74
83
|
[k: string]: string;
|
|
75
84
|
} | null;
|
|
76
|
-
tools: Array<OpenResponsesNonStreamingResponseToolFunction | OpenResponsesWebSearchPreviewTool | OpenResponsesWebSearchPreview20250311Tool | OpenResponsesWebSearchTool | OpenResponsesWebSearch20250826Tool>;
|
|
85
|
+
tools: Array<OpenResponsesNonStreamingResponseToolFunction | OpenResponsesWebSearchPreviewTool | OpenResponsesWebSearchPreview20250311Tool | OpenResponsesWebSearchTool | OpenResponsesWebSearch20250826Tool | OpenResponsesFileSearchTool | OpenResponsesComputerTool | OpenResponsesCodeInterpreterTool | OpenResponsesMcpTool | OpenResponsesImageGenerationTool | OpenResponsesLocalShellTool | OpenResponsesFunctionShellTool | OpenResponsesApplyPatchTool | OpenResponsesCustomTool>;
|
|
77
86
|
toolChoice: OpenAIResponsesToolChoiceUnion;
|
|
78
87
|
parallelToolCalls: boolean;
|
|
79
88
|
prompt?: OpenAIResponsesPrompt | null | undefined;
|
|
@@ -89,7 +98,7 @@ export type OpenResponsesNonStreamingResponse = {
|
|
|
89
98
|
text?: ResponseTextConfig | undefined;
|
|
90
99
|
};
|
|
91
100
|
/** @internal */
|
|
92
|
-
export declare const
|
|
101
|
+
export declare const OpenResponsesNonStreamingResponseObject$inboundSchema: z.ZodEnum<typeof OpenResponsesNonStreamingResponseObject>;
|
|
93
102
|
/** @internal */
|
|
94
103
|
export declare const OpenResponsesNonStreamingResponseToolFunction$inboundSchema: z.ZodType<OpenResponsesNonStreamingResponseToolFunction, unknown>;
|
|
95
104
|
export declare function openResponsesNonStreamingResponseToolFunctionFromJSON(jsonString: string): SafeParseResult<OpenResponsesNonStreamingResponseToolFunction, SDKValidationError>;
|
|
@@ -13,6 +13,15 @@ import { OpenAIResponsesResponseStatus$inboundSchema, } from "./openairesponsesr
|
|
|
13
13
|
import { OpenAIResponsesServiceTier$inboundSchema, } from "./openairesponsesservicetier.js";
|
|
14
14
|
import { OpenAIResponsesToolChoiceUnion$inboundSchema, } from "./openairesponsestoolchoiceunion.js";
|
|
15
15
|
import { OpenAIResponsesTruncation$inboundSchema, } from "./openairesponsestruncation.js";
|
|
16
|
+
import { OpenResponsesApplyPatchTool$inboundSchema, } from "./openresponsesapplypatchtool.js";
|
|
17
|
+
import { OpenResponsesCodeInterpreterTool$inboundSchema, } from "./openresponsescodeinterpretertool.js";
|
|
18
|
+
import { OpenResponsesComputerTool$inboundSchema, } from "./openresponsescomputertool.js";
|
|
19
|
+
import { OpenResponsesCustomTool$inboundSchema, } from "./openresponsescustomtool.js";
|
|
20
|
+
import { OpenResponsesFileSearchTool$inboundSchema, } from "./openresponsesfilesearchtool.js";
|
|
21
|
+
import { OpenResponsesFunctionShellTool$inboundSchema, } from "./openresponsesfunctionshelltool.js";
|
|
22
|
+
import { OpenResponsesImageGenerationTool$inboundSchema, } from "./openresponsesimagegenerationtool.js";
|
|
23
|
+
import { OpenResponsesLocalShellTool$inboundSchema, } from "./openresponseslocalshelltool.js";
|
|
24
|
+
import { OpenResponsesMcpTool$inboundSchema, } from "./openresponsesmcptool.js";
|
|
16
25
|
import { OpenResponsesUsage$inboundSchema, } from "./openresponsesusage.js";
|
|
17
26
|
import { OpenResponsesWebSearch20250826Tool$inboundSchema, } from "./openresponseswebsearch20250826tool.js";
|
|
18
27
|
import { OpenResponsesWebSearchPreview20250311Tool$inboundSchema, } from "./openresponseswebsearchpreview20250311tool.js";
|
|
@@ -21,11 +30,11 @@ import { OpenResponsesWebSearchTool$inboundSchema, } from "./openresponseswebsea
|
|
|
21
30
|
import { ResponsesErrorField$inboundSchema, } from "./responseserrorfield.js";
|
|
22
31
|
import { ResponsesOutputItem$inboundSchema, } from "./responsesoutputitem.js";
|
|
23
32
|
import { ResponseTextConfig$inboundSchema, } from "./responsetextconfig.js";
|
|
24
|
-
export const
|
|
33
|
+
export const OpenResponsesNonStreamingResponseObject = {
|
|
25
34
|
Response: "response",
|
|
26
35
|
};
|
|
27
36
|
/** @internal */
|
|
28
|
-
export const
|
|
37
|
+
export const OpenResponsesNonStreamingResponseObject$inboundSchema = z.enum(OpenResponsesNonStreamingResponseObject);
|
|
29
38
|
/** @internal */
|
|
30
39
|
export const OpenResponsesNonStreamingResponseToolFunction$inboundSchema = z.object({
|
|
31
40
|
type: z.literal("function"),
|
|
@@ -44,6 +53,15 @@ export const OpenResponsesNonStreamingResponseToolUnion$inboundSchema = z.union(
|
|
|
44
53
|
OpenResponsesWebSearchPreview20250311Tool$inboundSchema,
|
|
45
54
|
OpenResponsesWebSearchTool$inboundSchema,
|
|
46
55
|
OpenResponsesWebSearch20250826Tool$inboundSchema,
|
|
56
|
+
OpenResponsesFileSearchTool$inboundSchema,
|
|
57
|
+
OpenResponsesComputerTool$inboundSchema,
|
|
58
|
+
OpenResponsesCodeInterpreterTool$inboundSchema,
|
|
59
|
+
OpenResponsesMcpTool$inboundSchema,
|
|
60
|
+
OpenResponsesImageGenerationTool$inboundSchema,
|
|
61
|
+
OpenResponsesLocalShellTool$inboundSchema,
|
|
62
|
+
OpenResponsesFunctionShellTool$inboundSchema,
|
|
63
|
+
OpenResponsesApplyPatchTool$inboundSchema,
|
|
64
|
+
OpenResponsesCustomTool$inboundSchema,
|
|
47
65
|
]);
|
|
48
66
|
export function openResponsesNonStreamingResponseToolUnionFromJSON(jsonString) {
|
|
49
67
|
return safeParse(jsonString, (x) => OpenResponsesNonStreamingResponseToolUnion$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OpenResponsesNonStreamingResponseToolUnion' from JSON`);
|
|
@@ -51,7 +69,7 @@ export function openResponsesNonStreamingResponseToolUnionFromJSON(jsonString) {
|
|
|
51
69
|
/** @internal */
|
|
52
70
|
export const OpenResponsesNonStreamingResponse$inboundSchema = z.object({
|
|
53
71
|
id: z.string(),
|
|
54
|
-
object:
|
|
72
|
+
object: OpenResponsesNonStreamingResponseObject$inboundSchema,
|
|
55
73
|
created_at: z.number(),
|
|
56
74
|
model: z.string(),
|
|
57
75
|
status: OpenAIResponsesResponseStatus$inboundSchema,
|
|
@@ -79,6 +97,15 @@ export const OpenResponsesNonStreamingResponse$inboundSchema = z.object({
|
|
|
79
97
|
OpenResponsesWebSearchPreview20250311Tool$inboundSchema,
|
|
80
98
|
OpenResponsesWebSearchTool$inboundSchema,
|
|
81
99
|
OpenResponsesWebSearch20250826Tool$inboundSchema,
|
|
100
|
+
OpenResponsesFileSearchTool$inboundSchema,
|
|
101
|
+
OpenResponsesComputerTool$inboundSchema,
|
|
102
|
+
OpenResponsesCodeInterpreterTool$inboundSchema,
|
|
103
|
+
OpenResponsesMcpTool$inboundSchema,
|
|
104
|
+
OpenResponsesImageGenerationTool$inboundSchema,
|
|
105
|
+
OpenResponsesLocalShellTool$inboundSchema,
|
|
106
|
+
OpenResponsesFunctionShellTool$inboundSchema,
|
|
107
|
+
OpenResponsesApplyPatchTool$inboundSchema,
|
|
108
|
+
OpenResponsesCustomTool$inboundSchema,
|
|
82
109
|
])),
|
|
83
110
|
tool_choice: OpenAIResponsesToolChoiceUnion$inboundSchema,
|
|
84
111
|
parallel_tool_calls: z.boolean(),
|
|
@@ -34,7 +34,7 @@ export type OpenResponsesReasoningFormat = OpenEnum<typeof OpenResponsesReasonin
|
|
|
34
34
|
export type OpenResponsesReasoning = {
|
|
35
35
|
type: OpenResponsesReasoningType;
|
|
36
36
|
id: string;
|
|
37
|
-
content?: Array<ReasoningTextContent> | undefined;
|
|
37
|
+
content?: Array<ReasoningTextContent> | null | undefined;
|
|
38
38
|
summary: Array<ReasoningSummaryText>;
|
|
39
39
|
encryptedContent?: string | null | undefined;
|
|
40
40
|
status?: OpenResponsesReasoningStatusCompleted | OpenResponsesReasoningStatusIncomplete | OpenResponsesReasoningStatusInProgress | undefined;
|
|
@@ -60,7 +60,7 @@ export declare const OpenResponsesReasoningFormat$outboundSchema: z.ZodType<stri
|
|
|
60
60
|
export type OpenResponsesReasoning$Outbound = {
|
|
61
61
|
type: string;
|
|
62
62
|
id: string;
|
|
63
|
-
content?: Array<ReasoningTextContent$Outbound> | undefined;
|
|
63
|
+
content?: Array<ReasoningTextContent$Outbound> | null | undefined;
|
|
64
64
|
summary: Array<ReasoningSummaryText$Outbound>;
|
|
65
65
|
encrypted_content?: string | null | undefined;
|
|
66
66
|
status?: string | string | string | undefined;
|
|
@@ -50,7 +50,7 @@ export const OpenResponsesReasoningFormat$outboundSchema = openEnums.outboundSch
|
|
|
50
50
|
export const OpenResponsesReasoning$outboundSchema = z.object({
|
|
51
51
|
type: OpenResponsesReasoningType$outboundSchema,
|
|
52
52
|
id: z.string(),
|
|
53
|
-
content: z.array(ReasoningTextContent$outboundSchema).optional(),
|
|
53
|
+
content: z.nullable(z.array(ReasoningTextContent$outboundSchema)).optional(),
|
|
54
54
|
summary: z.array(ReasoningSummaryText$outboundSchema),
|
|
55
55
|
encryptedContent: z.nullable(z.string()).optional(),
|
|
56
56
|
status: z.union([
|
|
@@ -6,14 +6,14 @@ import { ReasoningSummaryVerbosity } from "./reasoningsummaryverbosity.js";
|
|
|
6
6
|
*/
|
|
7
7
|
export type OpenResponsesReasoningConfig = {
|
|
8
8
|
effort?: OpenAIResponsesReasoningEffort | null | undefined;
|
|
9
|
-
summary?: ReasoningSummaryVerbosity | undefined;
|
|
9
|
+
summary?: ReasoningSummaryVerbosity | null | undefined;
|
|
10
10
|
maxTokens?: number | null | undefined;
|
|
11
11
|
enabled?: boolean | null | undefined;
|
|
12
12
|
};
|
|
13
13
|
/** @internal */
|
|
14
14
|
export type OpenResponsesReasoningConfig$Outbound = {
|
|
15
15
|
effort?: string | null | undefined;
|
|
16
|
-
summary?: string | undefined;
|
|
16
|
+
summary?: string | null | undefined;
|
|
17
17
|
max_tokens?: number | null | undefined;
|
|
18
18
|
enabled?: boolean | null | undefined;
|
|
19
19
|
};
|
|
@@ -9,7 +9,7 @@ import { ReasoningSummaryVerbosity$outboundSchema, } from "./reasoningsummaryver
|
|
|
9
9
|
/** @internal */
|
|
10
10
|
export const OpenResponsesReasoningConfig$outboundSchema = z.object({
|
|
11
11
|
effort: z.nullable(OpenAIResponsesReasoningEffort$outboundSchema).optional(),
|
|
12
|
-
summary: ReasoningSummaryVerbosity$outboundSchema.optional(),
|
|
12
|
+
summary: z.nullable(ReasoningSummaryVerbosity$outboundSchema).optional(),
|
|
13
13
|
maxTokens: z.nullable(z.number()).optional(),
|
|
14
14
|
enabled: z.nullable(z.boolean()).optional(),
|
|
15
15
|
}).transform((v) => {
|