@openrouter/sdk 1.4.25 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/funcs/apiKeysList.d.ts +1 -1
- package/esm/funcs/apiKeysList.js +3 -2
- package/esm/funcs/apiKeysUpdate.d.ts +4 -2
- package/esm/funcs/apiKeysUpdate.js +5 -3
- package/esm/funcs/chatSend.d.ts +4 -2
- package/esm/funcs/containersPromoteContainerFile.d.ts +1 -1
- package/esm/funcs/containersPromoteContainerFile.js +2 -2
- package/esm/funcs/embeddingsGenerate.d.ts +1 -1
- package/esm/funcs/embeddingsGenerate.js +2 -2
- package/esm/funcs/{endUsersCreate.d.ts → externalUsersCreate.d.ts} +3 -3
- package/esm/funcs/{endUsersCreate.js → externalUsersCreate.js} +11 -11
- package/esm/funcs/{endUsersDelete.d.ts → externalUsersDelete.d.ts} +3 -3
- package/esm/funcs/{endUsersDelete.js → externalUsersDelete.js} +8 -8
- package/esm/funcs/{endUsersGet.d.ts → externalUsersGet.d.ts} +3 -3
- package/esm/funcs/{endUsersGet.js → externalUsersGet.js} +10 -10
- package/esm/funcs/{endUsersList.d.ts → externalUsersList.d.ts} +3 -3
- package/esm/funcs/{endUsersList.js → externalUsersList.js} +10 -10
- package/esm/funcs/{endUsersUpdate.d.ts → externalUsersUpdate.d.ts} +3 -3
- package/esm/funcs/{endUsersUpdate.js → externalUsersUpdate.js} +11 -11
- package/esm/funcs/filesUpload.d.ts +1 -1
- package/esm/funcs/filesUpload.js +2 -2
- package/esm/funcs/guardrailsListKeyAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListKeyAssignments.js +2 -2
- package/esm/funcs/guardrailsListMemberAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListMemberAssignments.js +2 -2
- package/esm/funcs/imagesGenerate.d.ts +4 -2
- package/esm/funcs/internsGetInternConnections.d.ts +21 -0
- package/esm/funcs/internsGetInternConnections.js +105 -0
- package/esm/funcs/internsGetInternDaemon.d.ts +1 -1
- package/esm/funcs/internsGetInternDaemon.js +1 -1
- package/esm/funcs/internsGetInternIcon.d.ts +20 -0
- package/esm/funcs/internsGetInternIcon.js +109 -0
- package/esm/funcs/internsSignInternDaemonAccessRequest.d.ts +22 -0
- package/esm/funcs/internsSignInternDaemonAccessRequest.js +109 -0
- package/esm/funcs/internsSignInternDaemonRequest.d.ts +20 -0
- package/esm/funcs/internsSignInternDaemonRequest.js +109 -0
- package/esm/funcs/modelsListForUser.js +1 -0
- package/esm/funcs/privateEndpointsUpdatePricing.d.ts +1 -1
- package/esm/funcs/privateEndpointsUpdatePricing.js +1 -1
- package/esm/funcs/responsesSend.d.ts +4 -2
- package/esm/funcs/vaultDeleteInternVaultSecret.d.ts +1 -1
- package/esm/funcs/vaultDeleteInternVaultSecret.js +2 -2
- package/esm/funcs/vaultDeleteVaultSecret.d.ts +1 -1
- package/esm/funcs/vaultDeleteVaultSecret.js +2 -2
- package/esm/funcs/vaultListInternConnections.d.ts +20 -0
- package/esm/funcs/vaultListInternConnections.js +104 -0
- package/esm/funcs/vaultStoreVaultSecret.d.ts +1 -1
- package/esm/funcs/vaultStoreVaultSecret.js +2 -2
- package/esm/funcs/videoGenerationGenerate.d.ts +1 -1
- package/esm/funcs/videoGenerationGenerate.js +2 -2
- package/esm/lib/config.d.ts +3 -3
- package/esm/lib/config.js +3 -3
- package/esm/lib/encodings.d.ts +10 -9
- package/esm/lib/encodings.js +29 -13
- package/esm/lib/http.d.ts +1 -1
- package/esm/lib/http.js +1 -1
- package/esm/lib/security.d.ts +5 -4
- package/esm/lib/security.js +4 -5
- package/esm/models/additionaltoolsitem.d.ts +16 -1
- package/esm/models/additionaltoolsitem.js +10 -0
- package/esm/models/alignment.d.ts +1 -1
- package/esm/models/alignmentplugin.d.ts +9 -8
- package/esm/models/alignmentplugin.js +3 -2
- package/esm/models/alignmentrule.d.ts +31 -0
- package/esm/models/alignmentrule.js +25 -0
- package/esm/models/alignmentrulerecord.d.ts +7 -3
- package/esm/models/alignmentrulerecord.js +2 -1
- package/esm/models/armorautomode.d.ts +44 -0
- package/esm/models/armorautomode.js +49 -0
- package/esm/models/armorcontext.d.ts +22 -0
- package/esm/models/armorcontext.js +25 -0
- package/esm/models/armorenvironmententry.d.ts +14 -0
- package/esm/models/armorenvironmententry.js +14 -0
- package/esm/models/armorplugin.d.ts +92 -0
- package/esm/models/armorplugin.js +60 -0
- package/esm/models/armorrule.d.ts +30 -0
- package/esm/models/armorrule.js +16 -0
- package/esm/models/armorsafeguardresult.d.ts +69 -0
- package/esm/models/armorsafeguardresult.js +83 -0
- package/esm/models/batchlistitem.d.ts +8 -0
- package/esm/models/batchlistitem.js +3 -0
- package/esm/models/batchobject.d.ts +13 -0
- package/esm/models/batchobject.js +6 -0
- package/esm/models/batchsubmitbody.d.ts +5 -0
- package/esm/models/batchsubmitbody.js +2 -0
- package/esm/models/byokkey.d.ts +3 -3
- package/esm/models/byokkey.js +1 -1
- package/esm/models/byokproviderslug.d.ts +2 -0
- package/esm/models/byokproviderslug.js +2 -0
- package/esm/models/chatcontenttext.d.ts +1 -1
- package/esm/models/chatfunctiontool.d.ts +4 -0
- package/esm/models/chatfunctiontool.js +7 -0
- package/esm/models/chatrequest.d.ts +16 -9
- package/esm/models/chatrequest.js +9 -6
- package/esm/models/chatresult.d.ts +10 -0
- package/esm/models/chatresult.js +5 -0
- package/esm/models/chatstreamchunk.d.ts +7 -0
- package/esm/models/chatstreamchunk.js +5 -0
- package/esm/models/chatwebsearchshorthand.d.ts +1 -1
- package/esm/models/clientclosedrequestresponseerrordata.d.ts +17 -0
- package/esm/models/clientclosedrequestresponseerrordata.js +16 -0
- package/esm/models/computeruseservertool.d.ts +5 -5
- package/esm/models/computeruseservertool.js +5 -5
- package/esm/models/createbyokkeyrequest.d.ts +3 -3
- package/esm/models/createbyokkeyrequest.js +1 -1
- package/esm/models/createexternaluserrequest.d.ts +15 -0
- package/esm/models/createexternaluserrequest.js +13 -0
- package/esm/models/createguardrailrequest.d.ts +10 -0
- package/esm/models/createguardrailrequest.js +4 -0
- package/esm/models/createobservabilitydestinationrequest.d.ts +5 -0
- package/esm/models/createobservabilitydestinationrequest.js +2 -0
- package/esm/models/customtool.d.ts +2 -0
- package/esm/models/customtool.js +11 -0
- package/esm/models/decisionsboxanswer.d.ts +21 -0
- package/esm/models/decisionsboxanswer.js +26 -0
- package/esm/models/decisionsboxquestion.d.ts +34 -0
- package/esm/models/decisionsboxquestion.js +23 -0
- package/esm/models/decisionsrequest.d.ts +6 -5
- package/esm/models/decisionsrequest.js +3 -0
- package/esm/models/decisionsresponse.d.ts +4 -3
- package/esm/models/decisionsresponse.js +3 -0
- package/esm/models/deferredbm25search.d.ts +17 -0
- package/esm/models/deferredbm25search.js +19 -0
- package/esm/models/deferredcustomsearch.d.ts +21 -0
- package/esm/models/deferredcustomsearch.js +23 -0
- package/esm/models/deferredregexsearch.d.ts +17 -0
- package/esm/models/deferredregexsearch.js +19 -0
- package/esm/models/deferredtoolscontrol.d.ts +62 -0
- package/esm/models/deferredtoolscontrol.js +38 -0
- package/esm/models/deferredtoolssearchstrategy.d.ts +14 -0
- package/esm/models/deferredtoolssearchstrategy.js +18 -0
- package/esm/models/errors/batchpaymentrequiredresponseerror.d.ts +16 -0
- package/esm/models/errors/batchpaymentrequiredresponseerror.js +5 -0
- package/esm/models/errors/clientclosedrequestresponseerror.d.ts +39 -0
- package/esm/models/errors/clientclosedrequestresponseerror.js +47 -0
- package/esm/models/errors/index.d.ts +1 -0
- package/esm/models/errors/index.js +1 -0
- package/esm/models/{enduser.d.ts → externaluser.d.ts} +5 -5
- package/esm/models/{enduser.js → externaluser.js} +6 -5
- package/esm/models/externaluserresponse.d.ts +11 -0
- package/esm/models/externaluserresponse.js +15 -0
- package/esm/models/guardrail.d.ts +8 -0
- package/esm/models/guardrail.js +4 -0
- package/esm/models/imagegenerationproviderpreferences.d.ts +12 -0
- package/esm/models/imagegenerationproviderpreferences.js +3 -0
- package/esm/models/index.d.ts +34 -6
- package/esm/models/index.js +34 -6
- package/esm/models/inputsunion.d.ts +7 -4
- package/esm/models/inputsunion.js +9 -0
- package/esm/models/inputtext.d.ts +1 -1
- package/esm/models/intern.d.ts +12 -0
- package/esm/models/intern.js +6 -0
- package/esm/models/internconnection.d.ts +118 -0
- package/esm/models/internconnection.js +105 -0
- package/esm/models/internconnectionlist.d.ts +11 -0
- package/esm/models/internconnectionlist.js +15 -0
- package/esm/models/jevrouterplugin.d.ts +5 -0
- package/esm/models/jevrouterplugin.js +2 -0
- package/esm/models/keybudget.d.ts +80 -0
- package/esm/models/keybudget.js +58 -0
- package/esm/models/legacywebsearchservertool.d.ts +1 -1
- package/esm/models/listexternalusersresponse.d.ts +15 -0
- package/esm/models/listexternalusersresponse.js +21 -0
- package/esm/models/messagesmessageparam.d.ts +7 -6
- package/esm/models/messagesmessageparam.js +4 -0
- package/esm/models/messagesrequest.d.ts +11 -4
- package/esm/models/messagesrequest.js +6 -0
- package/esm/models/namespacefunctiontool.d.ts +5 -5
- package/esm/models/namespacefunctiontool.js +5 -5
- package/esm/models/observabilityarizedestination.d.ts +4 -0
- package/esm/models/observabilityarizedestination.js +2 -0
- package/esm/models/observabilitybraintrustdestination.d.ts +4 -0
- package/esm/models/observabilitybraintrustdestination.js +2 -0
- package/esm/models/observabilityclickhousedestination.d.ts +4 -0
- package/esm/models/observabilityclickhousedestination.js +2 -0
- package/esm/models/observabilitydatadogdestination.d.ts +4 -0
- package/esm/models/observabilitydatadogdestination.js +2 -0
- package/esm/models/observabilitygrafanadestination.d.ts +4 -0
- package/esm/models/observabilitygrafanadestination.js +2 -0
- package/esm/models/observabilitylangfusedestination.d.ts +4 -0
- package/esm/models/observabilitylangfusedestination.js +2 -0
- package/esm/models/observabilitylangsmithdestination.d.ts +4 -0
- package/esm/models/observabilitylangsmithdestination.js +2 -0
- package/esm/models/observabilitynewrelicdestination.d.ts +4 -0
- package/esm/models/observabilitynewrelicdestination.js +2 -0
- package/esm/models/observabilityopikdestination.d.ts +4 -0
- package/esm/models/observabilityopikdestination.js +2 -0
- package/esm/models/observabilityotelcollectordestination.d.ts +4 -0
- package/esm/models/observabilityotelcollectordestination.js +2 -0
- package/esm/models/observabilityposthogdestination.d.ts +4 -0
- package/esm/models/observabilityposthogdestination.js +2 -0
- package/esm/models/observabilityrampdestination.d.ts +4 -0
- package/esm/models/observabilityrampdestination.js +2 -0
- package/esm/models/observabilitys3destination.d.ts +4 -0
- package/esm/models/observabilitys3destination.js +2 -0
- package/esm/models/observabilitysentrydestination.d.ts +4 -0
- package/esm/models/observabilitysentrydestination.js +2 -0
- package/esm/models/observabilitysnowflakedestination.d.ts +4 -0
- package/esm/models/observabilitysnowflakedestination.js +2 -0
- package/esm/models/observabilityweavedestination.d.ts +4 -0
- package/esm/models/observabilityweavedestination.js +2 -0
- package/esm/models/observabilitywebhookdestination.d.ts +8 -4
- package/esm/models/observabilitywebhookdestination.js +5 -4
- package/esm/models/openresponseserrorfield.d.ts +1 -0
- package/esm/models/openresponseserrorfield.js +1 -0
- package/esm/models/openresponseserrormetadata.d.ts +1 -1
- package/esm/models/openresponsesresult.d.ts +19 -3
- package/esm/models/openresponsesresult.js +14 -0
- package/esm/models/operations/{createenduser.d.ts → createexternaluser.d.ts} +8 -8
- package/esm/models/operations/createexternaluser.js +23 -0
- package/esm/models/operations/deleteexternaluser.d.ts +58 -0
- package/esm/models/operations/{deleteenduser.js → deleteexternaluser.js} +5 -5
- package/esm/models/operations/getcurrentkey.d.ts +5 -0
- package/esm/models/operations/getcurrentkey.js +4 -1
- package/esm/models/operations/{updateenduser.d.ts → getexternaluser.d.ts} +7 -10
- package/esm/models/operations/{getenduser.js → getexternaluser.js} +5 -5
- package/esm/models/operations/{deleteenduser.d.ts → getinternconnections.d.ts} +9 -9
- package/esm/models/operations/getinternconnections.js +21 -0
- package/esm/models/operations/{getenduser.d.ts → getinternicon.d.ts} +14 -9
- package/esm/models/operations/getinternicon.js +22 -0
- package/esm/models/operations/index.d.ts +10 -5
- package/esm/models/operations/index.js +10 -5
- package/esm/models/operations/list.d.ts +5 -0
- package/esm/models/operations/list.js +2 -0
- package/esm/models/operations/listbatches.d.ts +4 -4
- package/esm/models/operations/listbatches.js +3 -3
- package/esm/models/operations/listbyokkeys.d.ts +2 -0
- package/esm/models/operations/listbyokkeys.js +2 -0
- package/esm/models/operations/{listendusers.d.ts → listexternalusers.d.ts} +11 -11
- package/esm/models/operations/listexternalusers.js +38 -0
- package/esm/models/operations/listinternconnections.d.ts +75 -0
- package/esm/models/operations/listinternconnections.js +36 -0
- package/esm/models/operations/listmodelsuser.d.ts +29 -0
- package/esm/models/operations/listmodelsuser.js +21 -0
- package/esm/models/operations/signinterndaemonaccessrequest.d.ts +72 -0
- package/esm/models/operations/signinterndaemonaccessrequest.js +38 -0
- package/esm/models/operations/signinterndaemonrequest.d.ts +72 -0
- package/esm/models/operations/signinterndaemonrequest.js +38 -0
- package/esm/models/operations/updateexternaluser.d.ts +61 -0
- package/esm/models/operations/updateexternaluser.js +24 -0
- package/esm/models/operations/updatekeys.d.ts +5 -0
- package/esm/models/operations/updatekeys.js +2 -0
- package/esm/models/oranthropiccontentblock.d.ts +2 -1
- package/esm/models/oranthropiccontentblock.js +2 -0
- package/esm/models/oranthropictoolsearchresult.d.ts +17 -0
- package/esm/models/oranthropictoolsearchresult.js +21 -0
- package/esm/models/oranthropictoolsearchresultparam.d.ts +23 -0
- package/esm/models/oranthropictoolsearchresultparam.js +20 -0
- package/esm/models/outputapplypatchservertoolitem.d.ts +7 -2
- package/esm/models/outputapplypatchservertoolitem.js +5 -3
- package/esm/models/outputarmorblockeditem.d.ts +71 -0
- package/esm/models/outputarmorblockeditem.js +60 -0
- package/esm/models/outputdatetimeitem.d.ts +7 -2
- package/esm/models/outputdatetimeitem.js +5 -3
- package/esm/models/outputimagegenerationservertoolitem.d.ts +7 -2
- package/esm/models/outputimagegenerationservertoolitem.js +5 -3
- package/esm/models/outputitems.d.ts +5 -1
- package/esm/models/outputitems.js +4 -0
- package/esm/models/outputsearchmodelsservertoolitem.d.ts +7 -2
- package/esm/models/outputsearchmodelsservertoolitem.js +5 -3
- package/esm/models/outputtoolsearchcallitem.d.ts +26 -0
- package/esm/models/outputtoolsearchcallitem.js +30 -0
- package/esm/models/outputtoolsearchservertoolitem.d.ts +30 -2
- package/esm/models/outputtoolsearchservertoolitem.js +36 -3
- package/esm/models/outputwebsearchservertoolitem.d.ts +7 -2
- package/esm/models/outputwebsearchservertoolitem.js +5 -3
- package/esm/models/preview20250311websearchservertool.d.ts +1 -1
- package/esm/models/previewwebsearchservertool.d.ts +1 -1
- package/esm/models/privateendpointpricing.d.ts +10 -0
- package/esm/models/privateendpointpricing.js +15 -0
- package/esm/models/promptcachebreakpoint.d.ts +3 -1
- package/esm/models/promptcachebreakpoint.js +2 -0
- package/esm/models/promptcacheoptions.d.ts +1 -1
- package/esm/models/providername.d.ts +2 -0
- package/esm/models/providername.js +2 -0
- package/esm/models/provideroptions.d.ts +12 -0
- package/esm/models/provideroptions.js +3 -0
- package/esm/models/providerresponse.d.ts +2 -0
- package/esm/models/providerresponse.js +2 -0
- package/esm/models/publicendpoint.d.ts +11 -2
- package/esm/models/publicendpoint.js +5 -0
- package/esm/models/publicservicetier.d.ts +17 -0
- package/esm/models/publicservicetier.js +16 -0
- package/esm/models/responsesrequest.d.ts +42 -6
- package/esm/models/responsesrequest.js +22 -0
- package/esm/models/signinterndaemonrequest.d.ts +54 -0
- package/esm/models/signinterndaemonrequest.js +30 -0
- package/esm/models/signinterndaemonresponse.d.ts +32 -0
- package/esm/models/signinterndaemonresponse.js +27 -0
- package/esm/models/speechinput.d.ts +12 -0
- package/esm/models/speechinput.js +12 -0
- package/esm/models/speechinputreferenceimage.d.ts +1 -1
- package/esm/models/speechrequest.d.ts +10 -4
- package/esm/models/speechrequest.js +3 -1
- package/esm/models/speechturn.d.ts +25 -0
- package/esm/models/speechturn.js +15 -0
- package/esm/models/switchyardrouterplugin.d.ts +1 -1
- package/esm/models/tokenexchangerequest.d.ts +7 -6
- package/esm/models/tokenexchangerequest.js +4 -2
- package/esm/models/tokenexchangeresponse.d.ts +3 -0
- package/esm/models/toolsearchcallitem.d.ts +47 -0
- package/esm/models/toolsearchcallitem.js +42 -0
- package/esm/models/toolsearchoutputitem.d.ts +150 -0
- package/esm/models/toolsearchoutputitem.js +181 -0
- package/esm/models/updatebyokkeyrequest.d.ts +3 -3
- package/esm/models/updatebyokkeyrequest.js +1 -1
- package/esm/models/updateexternaluserrequest.d.ts +15 -0
- package/esm/models/updateexternaluserrequest.js +18 -0
- package/esm/models/updateguardrailrequest.d.ts +10 -0
- package/esm/models/updateguardrailrequest.js +4 -0
- package/esm/models/updateobservabilitydestinationrequest.d.ts +5 -0
- package/esm/models/updateobservabilitydestinationrequest.js +2 -0
- package/esm/models/videogenerationrequest.d.ts +12 -0
- package/esm/models/videogenerationrequest.js +3 -0
- package/esm/models/videogenerationresponse.d.ts +11 -0
- package/esm/models/videogenerationresponse.js +3 -0
- package/esm/models/webfetchengineenum.d.ts +2 -2
- package/esm/models/webfetchengineenum.js +1 -1
- package/esm/models/webfetchservertoolconfig.d.ts +1 -1
- package/esm/models/websearchconfig.d.ts +1 -1
- package/esm/models/websearchengineenum.d.ts +2 -2
- package/esm/models/websearchengineenum.js +1 -1
- package/esm/models/websearchservertool.d.ts +1 -1
- package/esm/models/websearchservertoolconfig.d.ts +1 -1
- package/esm/models/workspacebudget.d.ts +4 -4
- package/esm/models/workspacebudget.js +3 -3
- package/esm/sdk/apikeys.d.ts +3 -1
- package/esm/sdk/apikeys.js +3 -1
- package/esm/sdk/betaresponses.d.ts +4 -2
- package/esm/sdk/chat.d.ts +4 -2
- package/esm/sdk/endusers.d.ts +10 -10
- package/esm/sdk/endusers.js +15 -15
- package/esm/sdk/externalusers.d.ts +44 -0
- package/esm/sdk/externalusers.js +60 -0
- package/esm/sdk/images.d.ts +3 -2
- package/esm/sdk/interns.d.ts +31 -1
- package/esm/sdk/interns.js +43 -1
- package/esm/sdk/privateendpoints.d.ts +1 -1
- package/esm/sdk/privateendpoints.js +1 -1
- package/esm/sdk/responses.d.ts +4 -2
- package/esm/sdk/sdk.d.ts +5 -2
- package/esm/sdk/sdk.js +7 -3
- package/esm/sdk/vault.d.ts +7 -0
- package/esm/sdk/vault.js +10 -0
- package/jsr.json +1 -1
- package/package.json +6 -6
- package/esm/models/batchlisttimestamp.d.ts +0 -12
- package/esm/models/batchlisttimestamp.js +0 -15
- package/esm/models/createenduserrequest.d.ts +0 -15
- package/esm/models/createenduserrequest.js +0 -13
- package/esm/models/enduserresponse.d.ts +0 -11
- package/esm/models/enduserresponse.js +0 -15
- package/esm/models/listendusersresponse.d.ts +0 -15
- package/esm/models/listendusersresponse.js +0 -21
- package/esm/models/operations/createenduser.js +0 -23
- package/esm/models/operations/listendusers.js +0 -38
- package/esm/models/operations/updateenduser.js +0 -24
- package/esm/models/updateenduserrequest.d.ts +0 -15
- package/esm/models/updateenduserrequest.js +0 -18
|
@@ -22,10 +22,15 @@ export const ChatFunctionToolType = {
|
|
|
22
22
|
};
|
|
23
23
|
/** @internal */
|
|
24
24
|
export const ChatFunctionToolFunctionFunction$outboundSchema = z.object({
|
|
25
|
+
deferLoading: z.boolean().optional(),
|
|
25
26
|
description: z.string().optional(),
|
|
26
27
|
name: z.string(),
|
|
27
28
|
parameters: z.record(z.string(), z.any()).optional(),
|
|
28
29
|
strict: z.nullable(z.boolean()).optional(),
|
|
30
|
+
}).transform((v) => {
|
|
31
|
+
return remap$(v, {
|
|
32
|
+
deferLoading: "defer_loading",
|
|
33
|
+
});
|
|
29
34
|
});
|
|
30
35
|
export function chatFunctionToolFunctionFunctionToJSON(chatFunctionToolFunctionFunction) {
|
|
31
36
|
return JSON.stringify(ChatFunctionToolFunctionFunction$outboundSchema.parse(chatFunctionToolFunctionFunction));
|
|
@@ -35,11 +40,13 @@ export const ChatFunctionToolType$outboundSchema = z.enum(ChatFunctionToolType);
|
|
|
35
40
|
/** @internal */
|
|
36
41
|
export const ChatFunctionToolFunction$outboundSchema = z.object({
|
|
37
42
|
cacheControl: ChatContentCacheControl$outboundSchema.optional(),
|
|
43
|
+
deferLoading: z.boolean().optional(),
|
|
38
44
|
function: z.lazy(() => ChatFunctionToolFunctionFunction$outboundSchema),
|
|
39
45
|
type: ChatFunctionToolType$outboundSchema,
|
|
40
46
|
}).transform((v) => {
|
|
41
47
|
return remap$(v, {
|
|
42
48
|
cacheControl: "cache_control",
|
|
49
|
+
deferLoading: "defer_loading",
|
|
43
50
|
});
|
|
44
51
|
});
|
|
45
52
|
export function chatFunctionToolFunctionToJSON(chatFunctionToolFunction) {
|
|
@@ -2,6 +2,7 @@ import * as z from "zod/v4";
|
|
|
2
2
|
import { OpenEnum } from "../types/enums.js";
|
|
3
3
|
import { AlignmentPlugin, AlignmentPlugin$Outbound } from "./alignmentplugin.js";
|
|
4
4
|
import { AnthropicCacheControlDirective, AnthropicCacheControlDirective$Outbound } from "./anthropiccachecontroldirective.js";
|
|
5
|
+
import { ArmorPlugin, ArmorPlugin$Outbound } from "./armorplugin.js";
|
|
5
6
|
import { AutoBetaRouterPlugin, AutoBetaRouterPlugin$Outbound } from "./autobetarouterplugin.js";
|
|
6
7
|
import { AutoRouterPlugin, AutoRouterPlugin$Outbound } from "./autorouterplugin.js";
|
|
7
8
|
import { ChatDebugOptions, ChatDebugOptions$Outbound } from "./chatdebugoptions.js";
|
|
@@ -16,6 +17,7 @@ import { ChatReasoningSummaryVerbosityEnum } from "./chatreasoningsummaryverbosi
|
|
|
16
17
|
import { ChatStreamOptions, ChatStreamOptions$Outbound } from "./chatstreamoptions.js";
|
|
17
18
|
import { ChatToolChoice, ChatToolChoice$Outbound } from "./chattoolchoice.js";
|
|
18
19
|
import { ContextCompressionPlugin, ContextCompressionPlugin$Outbound } from "./contextcompressionplugin.js";
|
|
20
|
+
import { DeferredToolsControl, DeferredToolsControl$Outbound } from "./deferredtoolscontrol.js";
|
|
19
21
|
import { FileParserPlugin, FileParserPlugin$Outbound } from "./fileparserplugin.js";
|
|
20
22
|
import { FusionPlugin, FusionPlugin$Outbound } from "./fusionplugin.js";
|
|
21
23
|
import { ImageConfig, ImageConfig$Outbound } from "./imageconfig.js";
|
|
@@ -37,7 +39,7 @@ export declare const Modality: {
|
|
|
37
39
|
readonly Audio: "audio";
|
|
38
40
|
};
|
|
39
41
|
export type Modality = OpenEnum<typeof Modality>;
|
|
40
|
-
export type ChatRequestPlugin = AlignmentPlugin | AutoBetaRouterPlugin | AutoRouterPlugin | ContextCompressionPlugin | FileParserPlugin | FusionPlugin | JevRouterPlugin | ModerationPlugin | ParetoRouterPlugin | ResponseHealingPlugin | SwitchyardRouterPlugin | WebSearchPlugin | WebFetchPlugin;
|
|
42
|
+
export type ChatRequestPlugin = AlignmentPlugin | ArmorPlugin | AutoBetaRouterPlugin | AutoRouterPlugin | ContextCompressionPlugin | FileParserPlugin | FusionPlugin | JevRouterPlugin | ModerationPlugin | ParetoRouterPlugin | ResponseHealingPlugin | SwitchyardRouterPlugin | WebSearchPlugin | WebFetchPlugin;
|
|
41
43
|
/**
|
|
42
44
|
* Constrains effort on reasoning for reasoning models
|
|
43
45
|
*/
|
|
@@ -103,7 +105,7 @@ export type ChatRequestServiceTier = OpenEnum<typeof ChatRequestServiceTier>;
|
|
|
103
105
|
/**
|
|
104
106
|
* Stop sequences (up to 4)
|
|
105
107
|
*/
|
|
106
|
-
export type
|
|
108
|
+
export type ChatRequestStop = string | Array<string>;
|
|
107
109
|
/**
|
|
108
110
|
* Chat completion request parameters
|
|
109
111
|
*/
|
|
@@ -116,6 +118,10 @@ export type ChatRequest = {
|
|
|
116
118
|
* Debug options for inspecting request transformations (streaming only)
|
|
117
119
|
*/
|
|
118
120
|
debug?: ChatDebugOptions | undefined;
|
|
121
|
+
/**
|
|
122
|
+
* Opt-in versioned router-level deferred-tool protocol. Replay assistant reasoning unchanged on continuation; keep the catalog unchanged.
|
|
123
|
+
*/
|
|
124
|
+
deferredTools?: DeferredToolsControl | undefined;
|
|
119
125
|
/**
|
|
120
126
|
* Frequency penalty (-2.0 to 2.0)
|
|
121
127
|
*/
|
|
@@ -177,7 +183,7 @@ export type ChatRequest = {
|
|
|
177
183
|
/**
|
|
178
184
|
* Plugins you want to enable for this request, including their settings.
|
|
179
185
|
*/
|
|
180
|
-
plugins?: Array<AlignmentPlugin | AutoBetaRouterPlugin | AutoRouterPlugin | ContextCompressionPlugin | FileParserPlugin | FusionPlugin | JevRouterPlugin | ModerationPlugin | ParetoRouterPlugin | ResponseHealingPlugin | SwitchyardRouterPlugin | WebSearchPlugin | WebFetchPlugin> | undefined;
|
|
186
|
+
plugins?: Array<AlignmentPlugin | ArmorPlugin | AutoBetaRouterPlugin | AutoRouterPlugin | ContextCompressionPlugin | FileParserPlugin | FusionPlugin | JevRouterPlugin | ModerationPlugin | ParetoRouterPlugin | ResponseHealingPlugin | SwitchyardRouterPlugin | WebSearchPlugin | WebFetchPlugin> | undefined;
|
|
181
187
|
/**
|
|
182
188
|
* Static predicted output content. Supported models can use this to reduce latency when much of the response is known in advance.
|
|
183
189
|
*/
|
|
@@ -188,7 +194,7 @@ export type ChatRequest = {
|
|
|
188
194
|
presencePenalty?: number | null | undefined;
|
|
189
195
|
promptCacheKey?: string | null | undefined;
|
|
190
196
|
/**
|
|
191
|
-
* Request-level prompt-cache controls. `mode: "explicit"` disables OpenAI-managed breakpoints so only blocks marked with `prompt_cache_breakpoint` are cached. Only supported by OpenAI GPT-5.6 and newer.
|
|
197
|
+
* Request-level prompt-cache controls. `mode: "explicit"` disables OpenAI-managed breakpoints so only blocks marked with `prompt_cache_breakpoint` are cached. `ttl` sets the minimum cache lifetime for every breakpoint the request writes: "30m" (default) or "12h" (billed at the higher 12h cache-write rate). Only supported by OpenAI GPT-5.6 and newer.
|
|
192
198
|
*/
|
|
193
199
|
promptCacheOptions?: PromptCacheOptions | null | undefined;
|
|
194
200
|
/**
|
|
@@ -279,7 +285,7 @@ export type ChatRequest = {
|
|
|
279
285
|
/** @internal */
|
|
280
286
|
export declare const Modality$outboundSchema: z.ZodType<string, Modality>;
|
|
281
287
|
/** @internal */
|
|
282
|
-
export type ChatRequestPlugin$Outbound = AlignmentPlugin$Outbound | AutoBetaRouterPlugin$Outbound | AutoRouterPlugin$Outbound | ContextCompressionPlugin$Outbound | FileParserPlugin$Outbound | FusionPlugin$Outbound | JevRouterPlugin$Outbound | ModerationPlugin$Outbound | ParetoRouterPlugin$Outbound | ResponseHealingPlugin$Outbound | SwitchyardRouterPlugin$Outbound | WebSearchPlugin$Outbound | WebFetchPlugin$Outbound;
|
|
288
|
+
export type ChatRequestPlugin$Outbound = AlignmentPlugin$Outbound | ArmorPlugin$Outbound | AutoBetaRouterPlugin$Outbound | AutoRouterPlugin$Outbound | ContextCompressionPlugin$Outbound | FileParserPlugin$Outbound | FusionPlugin$Outbound | JevRouterPlugin$Outbound | ModerationPlugin$Outbound | ParetoRouterPlugin$Outbound | ResponseHealingPlugin$Outbound | SwitchyardRouterPlugin$Outbound | WebSearchPlugin$Outbound | WebFetchPlugin$Outbound;
|
|
283
289
|
/** @internal */
|
|
284
290
|
export declare const ChatRequestPlugin$outboundSchema: z.ZodType<ChatRequestPlugin$Outbound, ChatRequestPlugin>;
|
|
285
291
|
export declare function chatRequestPluginToJSON(chatRequestPlugin: ChatRequestPlugin): string;
|
|
@@ -303,14 +309,15 @@ export declare function responseFormatToJSON(responseFormat: ResponseFormat): st
|
|
|
303
309
|
/** @internal */
|
|
304
310
|
export declare const ChatRequestServiceTier$outboundSchema: z.ZodType<string, ChatRequestServiceTier>;
|
|
305
311
|
/** @internal */
|
|
306
|
-
export type
|
|
312
|
+
export type ChatRequestStop$Outbound = string | Array<string>;
|
|
307
313
|
/** @internal */
|
|
308
|
-
export declare const
|
|
309
|
-
export declare function
|
|
314
|
+
export declare const ChatRequestStop$outboundSchema: z.ZodType<ChatRequestStop$Outbound, ChatRequestStop>;
|
|
315
|
+
export declare function chatRequestStopToJSON(chatRequestStop: ChatRequestStop): string;
|
|
310
316
|
/** @internal */
|
|
311
317
|
export type ChatRequest$Outbound = {
|
|
312
318
|
cache_control?: AnthropicCacheControlDirective$Outbound | undefined;
|
|
313
319
|
debug?: ChatDebugOptions$Outbound | undefined;
|
|
320
|
+
deferred_tools?: DeferredToolsControl$Outbound | undefined;
|
|
314
321
|
frequency_penalty?: number | null | undefined;
|
|
315
322
|
image_config?: {
|
|
316
323
|
[k: string]: ImageConfig$Outbound;
|
|
@@ -330,7 +337,7 @@ export type ChatRequest$Outbound = {
|
|
|
330
337
|
model?: string | undefined;
|
|
331
338
|
models?: Array<string> | undefined;
|
|
332
339
|
parallel_tool_calls?: boolean | null | undefined;
|
|
333
|
-
plugins?: Array<AlignmentPlugin$Outbound | AutoBetaRouterPlugin$Outbound | AutoRouterPlugin$Outbound | ContextCompressionPlugin$Outbound | FileParserPlugin$Outbound | FusionPlugin$Outbound | JevRouterPlugin$Outbound | ModerationPlugin$Outbound | ParetoRouterPlugin$Outbound | ResponseHealingPlugin$Outbound | SwitchyardRouterPlugin$Outbound | WebSearchPlugin$Outbound | WebFetchPlugin$Outbound> | undefined;
|
|
340
|
+
plugins?: Array<AlignmentPlugin$Outbound | ArmorPlugin$Outbound | AutoBetaRouterPlugin$Outbound | AutoRouterPlugin$Outbound | ContextCompressionPlugin$Outbound | FileParserPlugin$Outbound | FusionPlugin$Outbound | JevRouterPlugin$Outbound | ModerationPlugin$Outbound | ParetoRouterPlugin$Outbound | ResponseHealingPlugin$Outbound | SwitchyardRouterPlugin$Outbound | WebSearchPlugin$Outbound | WebFetchPlugin$Outbound> | undefined;
|
|
334
341
|
prediction?: Prediction$Outbound | null | undefined;
|
|
335
342
|
presence_penalty?: number | null | undefined;
|
|
336
343
|
prompt_cache_key?: string | null | undefined;
|
|
@@ -7,6 +7,7 @@ import { remap as remap$ } from "../lib/primitives.js";
|
|
|
7
7
|
import * as openEnums from "../types/enums.js";
|
|
8
8
|
import { AlignmentPlugin$outboundSchema, } from "./alignmentplugin.js";
|
|
9
9
|
import { AnthropicCacheControlDirective$outboundSchema, } from "./anthropiccachecontroldirective.js";
|
|
10
|
+
import { ArmorPlugin$outboundSchema, } from "./armorplugin.js";
|
|
10
11
|
import { AutoBetaRouterPlugin$outboundSchema, } from "./autobetarouterplugin.js";
|
|
11
12
|
import { AutoRouterPlugin$outboundSchema, } from "./autorouterplugin.js";
|
|
12
13
|
import { ChatDebugOptions$outboundSchema, } from "./chatdebugoptions.js";
|
|
@@ -21,6 +22,7 @@ import { ChatReasoningSummaryVerbosityEnum$outboundSchema, } from "./chatreasoni
|
|
|
21
22
|
import { ChatStreamOptions$outboundSchema, } from "./chatstreamoptions.js";
|
|
22
23
|
import { ChatToolChoice$outboundSchema, } from "./chattoolchoice.js";
|
|
23
24
|
import { ContextCompressionPlugin$outboundSchema, } from "./contextcompressionplugin.js";
|
|
25
|
+
import { DeferredToolsControl$outboundSchema, } from "./deferredtoolscontrol.js";
|
|
24
26
|
import { FileParserPlugin$outboundSchema, } from "./fileparserplugin.js";
|
|
25
27
|
import { FusionPlugin$outboundSchema, } from "./fusionplugin.js";
|
|
26
28
|
import { ImageConfig$outboundSchema, } from "./imageconfig.js";
|
|
@@ -83,6 +85,7 @@ export const Modality$outboundSchema = openEnums
|
|
|
83
85
|
/** @internal */
|
|
84
86
|
export const ChatRequestPlugin$outboundSchema = z.union([
|
|
85
87
|
AlignmentPlugin$outboundSchema,
|
|
88
|
+
ArmorPlugin$outboundSchema,
|
|
86
89
|
AutoBetaRouterPlugin$outboundSchema,
|
|
87
90
|
AutoRouterPlugin$outboundSchema,
|
|
88
91
|
ContextCompressionPlugin$outboundSchema,
|
|
@@ -126,17 +129,15 @@ export function responseFormatToJSON(responseFormat) {
|
|
|
126
129
|
/** @internal */
|
|
127
130
|
export const ChatRequestServiceTier$outboundSchema = openEnums.outboundSchema(ChatRequestServiceTier);
|
|
128
131
|
/** @internal */
|
|
129
|
-
export const
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
]);
|
|
133
|
-
export function stopToJSON(stop) {
|
|
134
|
-
return JSON.stringify(Stop$outboundSchema.parse(stop));
|
|
132
|
+
export const ChatRequestStop$outboundSchema = z.union([z.string(), z.array(z.string())]);
|
|
133
|
+
export function chatRequestStopToJSON(chatRequestStop) {
|
|
134
|
+
return JSON.stringify(ChatRequestStop$outboundSchema.parse(chatRequestStop));
|
|
135
135
|
}
|
|
136
136
|
/** @internal */
|
|
137
137
|
export const ChatRequest$outboundSchema = z.object({
|
|
138
138
|
cacheControl: AnthropicCacheControlDirective$outboundSchema.optional(),
|
|
139
139
|
debug: ChatDebugOptions$outboundSchema.optional(),
|
|
140
|
+
deferredTools: DeferredToolsControl$outboundSchema.optional(),
|
|
140
141
|
frequencyPenalty: z.nullable(z.number()).optional(),
|
|
141
142
|
imageConfig: z.record(z.string(), ImageConfig$outboundSchema).optional(),
|
|
142
143
|
logitBias: z.nullable(z.record(z.string(), z.number())).optional(),
|
|
@@ -152,6 +153,7 @@ export const ChatRequest$outboundSchema = z.object({
|
|
|
152
153
|
parallelToolCalls: z.nullable(z.boolean()).optional(),
|
|
153
154
|
plugins: z.array(z.union([
|
|
154
155
|
AlignmentPlugin$outboundSchema,
|
|
156
|
+
ArmorPlugin$outboundSchema,
|
|
155
157
|
AutoBetaRouterPlugin$outboundSchema,
|
|
156
158
|
AutoRouterPlugin$outboundSchema,
|
|
157
159
|
ContextCompressionPlugin$outboundSchema,
|
|
@@ -201,6 +203,7 @@ export const ChatRequest$outboundSchema = z.object({
|
|
|
201
203
|
}).transform((v) => {
|
|
202
204
|
return remap$(v, {
|
|
203
205
|
cacheControl: "cache_control",
|
|
206
|
+
deferredTools: "deferred_tools",
|
|
204
207
|
frequencyPenalty: "frequency_penalty",
|
|
205
208
|
imageConfig: "image_config",
|
|
206
209
|
logitBias: "logit_bias",
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
2
|
import { ClosedEnum } from "../types/enums.js";
|
|
3
3
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
+
import { Alignment } from "./alignment.js";
|
|
5
|
+
import { ArmorSafeguardResult } from "./armorsafeguardresult.js";
|
|
4
6
|
import { ChatChoice } from "./chatchoice.js";
|
|
5
7
|
import { ChatUsage } from "./chatusage.js";
|
|
6
8
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
@@ -13,6 +15,10 @@ export type ChatResultObject = ClosedEnum<typeof ChatResultObject>;
|
|
|
13
15
|
* Chat completion response
|
|
14
16
|
*/
|
|
15
17
|
export type ChatResult = {
|
|
18
|
+
/**
|
|
19
|
+
* Beta. The result of the alignment plugin for this request; the shape may change.
|
|
20
|
+
*/
|
|
21
|
+
alignment?: Alignment | undefined;
|
|
16
22
|
/**
|
|
17
23
|
* List of completion choices
|
|
18
24
|
*/
|
|
@@ -31,6 +37,10 @@ export type ChatResult = {
|
|
|
31
37
|
model: string;
|
|
32
38
|
object: ChatResultObject;
|
|
33
39
|
openrouterMetadata?: OpenRouterMetadata | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* OpenRouter Armor's verdict for each client tool call of this response, present whenever Armor evaluated the response (even when nothing was flagged). Independent of the `openrouter_metadata` opt-in.
|
|
42
|
+
*/
|
|
43
|
+
safeguardResults?: Array<ArmorSafeguardResult> | undefined;
|
|
34
44
|
/**
|
|
35
45
|
* The service tier used by the upstream provider for this request
|
|
36
46
|
*/
|
package/esm/models/chatresult.js
CHANGED
|
@@ -5,6 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../lib/schemas.js";
|
|
8
|
+
import { Alignment$inboundSchema } from "./alignment.js";
|
|
9
|
+
import { ArmorSafeguardResult$inboundSchema, } from "./armorsafeguardresult.js";
|
|
8
10
|
import { ChatChoice$inboundSchema } from "./chatchoice.js";
|
|
9
11
|
import { ChatUsage$inboundSchema } from "./chatusage.js";
|
|
10
12
|
import { OpenRouterMetadata$inboundSchema, } from "./openroutermetadata.js";
|
|
@@ -16,18 +18,21 @@ export const ChatResultObject$inboundSchema = z.enum(ChatResultObject);
|
|
|
16
18
|
/** @internal */
|
|
17
19
|
export const ChatResult$inboundSchema = z
|
|
18
20
|
.object({
|
|
21
|
+
alignment: Alignment$inboundSchema.optional(),
|
|
19
22
|
choices: z.array(ChatChoice$inboundSchema),
|
|
20
23
|
created: z.int(),
|
|
21
24
|
id: z.string(),
|
|
22
25
|
model: z.string(),
|
|
23
26
|
object: ChatResultObject$inboundSchema,
|
|
24
27
|
openrouter_metadata: OpenRouterMetadata$inboundSchema.optional(),
|
|
28
|
+
safeguard_results: z.array(ArmorSafeguardResult$inboundSchema).optional(),
|
|
25
29
|
service_tier: z.nullable(z.string()).optional(),
|
|
26
30
|
system_fingerprint: z.nullable(z.string()),
|
|
27
31
|
usage: ChatUsage$inboundSchema.optional(),
|
|
28
32
|
}).transform((v) => {
|
|
29
33
|
return remap$(v, {
|
|
30
34
|
"openrouter_metadata": "openrouterMetadata",
|
|
35
|
+
"safeguard_results": "safeguardResults",
|
|
31
36
|
"service_tier": "serviceTier",
|
|
32
37
|
"system_fingerprint": "systemFingerprint",
|
|
33
38
|
});
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
2
|
import { ClosedEnum } from "../types/enums.js";
|
|
3
3
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
+
import { Alignment } from "./alignment.js";
|
|
4
5
|
import { ApiErrorType } from "./apierrortype.js";
|
|
6
|
+
import { ArmorSafeguardResult } from "./armorsafeguardresult.js";
|
|
5
7
|
import { ChatStreamChoice } from "./chatstreamchoice.js";
|
|
6
8
|
import { ChatUsage } from "./chatusage.js";
|
|
7
9
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
@@ -44,6 +46,7 @@ export type ChatStreamChunkObject = ClosedEnum<typeof ChatStreamChunkObject>;
|
|
|
44
46
|
* Streaming chat completion chunk
|
|
45
47
|
*/
|
|
46
48
|
export type ChatStreamChunk = {
|
|
49
|
+
alignment?: Alignment | undefined;
|
|
47
50
|
/**
|
|
48
51
|
* List of streaming chunk choices
|
|
49
52
|
*/
|
|
@@ -66,6 +69,10 @@ export type ChatStreamChunk = {
|
|
|
66
69
|
model: string;
|
|
67
70
|
object: ChatStreamChunkObject;
|
|
68
71
|
openrouterMetadata?: OpenRouterMetadata | undefined;
|
|
72
|
+
/**
|
|
73
|
+
* OpenRouter Armor's verdict for each client tool call of this response, present whenever Armor evaluated the response (even when nothing was flagged). Independent of the `openrouter_metadata` opt-in.
|
|
74
|
+
*/
|
|
75
|
+
safeguardResults?: Array<ArmorSafeguardResult> | undefined;
|
|
69
76
|
/**
|
|
70
77
|
* The service tier used by the upstream provider for this request
|
|
71
78
|
*/
|
|
@@ -5,7 +5,9 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../lib/schemas.js";
|
|
8
|
+
import { Alignment$inboundSchema } from "./alignment.js";
|
|
8
9
|
import { ApiErrorType$inboundSchema } from "./apierrortype.js";
|
|
10
|
+
import { ArmorSafeguardResult$inboundSchema, } from "./armorsafeguardresult.js";
|
|
9
11
|
import { ChatStreamChoice$inboundSchema, } from "./chatstreamchoice.js";
|
|
10
12
|
import { ChatUsage$inboundSchema } from "./chatusage.js";
|
|
11
13
|
import { OpenRouterMetadata$inboundSchema, } from "./openroutermetadata.js";
|
|
@@ -38,6 +40,7 @@ export function chatStreamChunkErrorFromJSON(jsonString) {
|
|
|
38
40
|
export const ChatStreamChunkObject$inboundSchema = z.enum(ChatStreamChunkObject);
|
|
39
41
|
/** @internal */
|
|
40
42
|
export const ChatStreamChunk$inboundSchema = z.object({
|
|
43
|
+
alignment: Alignment$inboundSchema.optional(),
|
|
41
44
|
choices: z.array(ChatStreamChoice$inboundSchema),
|
|
42
45
|
created: z.int(),
|
|
43
46
|
error: z.lazy(() => ChatStreamChunkError$inboundSchema).optional(),
|
|
@@ -45,12 +48,14 @@ export const ChatStreamChunk$inboundSchema = z.object({
|
|
|
45
48
|
model: z.string(),
|
|
46
49
|
object: ChatStreamChunkObject$inboundSchema,
|
|
47
50
|
openrouter_metadata: OpenRouterMetadata$inboundSchema.optional(),
|
|
51
|
+
safeguard_results: z.array(ArmorSafeguardResult$inboundSchema).optional(),
|
|
48
52
|
service_tier: z.nullable(z.string()).optional(),
|
|
49
53
|
system_fingerprint: z.string().optional(),
|
|
50
54
|
usage: ChatUsage$inboundSchema.optional(),
|
|
51
55
|
}).transform((v) => {
|
|
52
56
|
return remap$(v, {
|
|
53
57
|
"openrouter_metadata": "openrouterMetadata",
|
|
58
|
+
"safeguard_results": "safeguardResults",
|
|
54
59
|
"service_tier": "serviceTier",
|
|
55
60
|
"system_fingerprint": "systemFingerprint",
|
|
56
61
|
});
|
|
@@ -22,7 +22,7 @@ export type ChatWebSearchShorthand = {
|
|
|
22
22
|
*/
|
|
23
23
|
allowedDomains?: Array<string> | undefined;
|
|
24
24
|
/**
|
|
25
|
-
* Which search engine to use. "auto" (default) uses native if the provider supports it, otherwise Exa. "native" forces the provider's built-in search. "exa" forces the Exa search API. "firecrawl" uses Firecrawl
|
|
25
|
+
* Which search engine to use. "auto" (default) uses native if the provider supports it, otherwise Exa. "native" forces the provider's built-in search. "exa" forces the Exa search API. "firecrawl" uses the Firecrawl search API. "parallel" uses the Parallel search API. "perplexity" uses the Perplexity Search API (raw ranked results).
|
|
26
26
|
*/
|
|
27
27
|
engine?: WebSearchEngineEnum | undefined;
|
|
28
28
|
/**
|
|
@@ -0,0 +1,17 @@
|
|
|
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
|
+
* Error data for ClientClosedRequestResponse
|
|
6
|
+
*/
|
|
7
|
+
export type ClientClosedRequestResponseErrorData = {
|
|
8
|
+
code: number;
|
|
9
|
+
message: string;
|
|
10
|
+
metadata?: {
|
|
11
|
+
[k: string]: any;
|
|
12
|
+
} | null | undefined;
|
|
13
|
+
};
|
|
14
|
+
/** @internal */
|
|
15
|
+
export declare const ClientClosedRequestResponseErrorData$inboundSchema: z.ZodType<ClientClosedRequestResponseErrorData, unknown>;
|
|
16
|
+
export declare function clientClosedRequestResponseErrorDataFromJSON(jsonString: string): SafeParseResult<ClientClosedRequestResponseErrorData, SDKValidationError>;
|
|
17
|
+
//# sourceMappingURL=clientclosedrequestresponseerrordata.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: ce503b476fc7
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { safeParse } from "../lib/schemas.js";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export const ClientClosedRequestResponseErrorData$inboundSchema = z.object({
|
|
9
|
+
code: z.int(),
|
|
10
|
+
message: z.string(),
|
|
11
|
+
metadata: z.nullable(z.record(z.string(), z.any())).optional(),
|
|
12
|
+
});
|
|
13
|
+
export function clientClosedRequestResponseErrorDataFromJSON(jsonString) {
|
|
14
|
+
return safeParse(jsonString, (x) => ClientClosedRequestResponseErrorData$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ClientClosedRequestResponseErrorData' from JSON`);
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=clientclosedrequestresponseerrordata.js.map
|
|
@@ -2,14 +2,14 @@ import * as z from "zod/v4";
|
|
|
2
2
|
import { ClosedEnum, OpenEnum } from "../types/enums.js";
|
|
3
3
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
4
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
5
|
-
export declare const
|
|
5
|
+
export declare const EnvironmentEnum: {
|
|
6
6
|
readonly Windows: "windows";
|
|
7
7
|
readonly Mac: "mac";
|
|
8
8
|
readonly Linux: "linux";
|
|
9
9
|
readonly Ubuntu: "ubuntu";
|
|
10
10
|
readonly Browser: "browser";
|
|
11
11
|
};
|
|
12
|
-
export type
|
|
12
|
+
export type EnvironmentEnum = OpenEnum<typeof EnvironmentEnum>;
|
|
13
13
|
export declare const ComputerUseServerToolType: {
|
|
14
14
|
readonly ComputerUsePreview: "computer_use_preview";
|
|
15
15
|
};
|
|
@@ -20,13 +20,13 @@ export type ComputerUseServerToolType = ClosedEnum<typeof ComputerUseServerToolT
|
|
|
20
20
|
export type ComputerUseServerTool = {
|
|
21
21
|
displayHeight: number;
|
|
22
22
|
displayWidth: number;
|
|
23
|
-
environment:
|
|
23
|
+
environment: EnvironmentEnum;
|
|
24
24
|
type: ComputerUseServerToolType;
|
|
25
25
|
};
|
|
26
26
|
/** @internal */
|
|
27
|
-
export declare const
|
|
27
|
+
export declare const EnvironmentEnum$inboundSchema: z.ZodType<EnvironmentEnum, unknown>;
|
|
28
28
|
/** @internal */
|
|
29
|
-
export declare const
|
|
29
|
+
export declare const EnvironmentEnum$outboundSchema: z.ZodType<string, EnvironmentEnum>;
|
|
30
30
|
/** @internal */
|
|
31
31
|
export declare const ComputerUseServerToolType$inboundSchema: z.ZodEnum<typeof ComputerUseServerToolType>;
|
|
32
32
|
/** @internal */
|
|
@@ -6,7 +6,7 @@ import * as z from "zod/v4";
|
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../lib/schemas.js";
|
|
8
8
|
import * as openEnums from "../types/enums.js";
|
|
9
|
-
export const
|
|
9
|
+
export const EnvironmentEnum = {
|
|
10
10
|
Windows: "windows",
|
|
11
11
|
Mac: "mac",
|
|
12
12
|
Linux: "linux",
|
|
@@ -17,9 +17,9 @@ export const ComputerUseServerToolType = {
|
|
|
17
17
|
ComputerUsePreview: "computer_use_preview",
|
|
18
18
|
};
|
|
19
19
|
/** @internal */
|
|
20
|
-
export const
|
|
20
|
+
export const EnvironmentEnum$inboundSchema = openEnums.inboundSchema(EnvironmentEnum);
|
|
21
21
|
/** @internal */
|
|
22
|
-
export const
|
|
22
|
+
export const EnvironmentEnum$outboundSchema = openEnums.outboundSchema(EnvironmentEnum);
|
|
23
23
|
/** @internal */
|
|
24
24
|
export const ComputerUseServerToolType$inboundSchema = z.enum(ComputerUseServerToolType);
|
|
25
25
|
/** @internal */
|
|
@@ -28,7 +28,7 @@ export const ComputerUseServerToolType$outboundSchema = ComputerUseServerToolTyp
|
|
|
28
28
|
export const ComputerUseServerTool$inboundSchema = z.object({
|
|
29
29
|
display_height: z.int(),
|
|
30
30
|
display_width: z.int(),
|
|
31
|
-
environment:
|
|
31
|
+
environment: EnvironmentEnum$inboundSchema,
|
|
32
32
|
type: ComputerUseServerToolType$inboundSchema,
|
|
33
33
|
}).transform((v) => {
|
|
34
34
|
return remap$(v, {
|
|
@@ -40,7 +40,7 @@ export const ComputerUseServerTool$inboundSchema = z.object({
|
|
|
40
40
|
export const ComputerUseServerTool$outboundSchema = z.object({
|
|
41
41
|
displayHeight: z.int(),
|
|
42
42
|
displayWidth: z.int(),
|
|
43
|
-
environment:
|
|
43
|
+
environment: EnvironmentEnum$outboundSchema,
|
|
44
44
|
type: ComputerUseServerToolType$outboundSchema,
|
|
45
45
|
}).transform((v) => {
|
|
46
46
|
return remap$(v, {
|
|
@@ -2,7 +2,7 @@ import * as z from "zod/v4";
|
|
|
2
2
|
import { OpenEnum } from "../types/enums.js";
|
|
3
3
|
import { BYOKProviderSlug } from "./byokproviderslug.js";
|
|
4
4
|
/**
|
|
5
|
-
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers,
|
|
5
|
+
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers, Azure accepts `europe` or `us` and Anthropic accepts `us` only. Defaults to the key's region for OpenAI and Fireworks, otherwise `null`.
|
|
6
6
|
*/
|
|
7
7
|
export declare const CreateBYOKKeyRequestDeclaredRegion: {
|
|
8
8
|
readonly Global: "global";
|
|
@@ -10,7 +10,7 @@ export declare const CreateBYOKKeyRequestDeclaredRegion: {
|
|
|
10
10
|
readonly Us: "us";
|
|
11
11
|
};
|
|
12
12
|
/**
|
|
13
|
-
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers,
|
|
13
|
+
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers, Azure accepts `europe` or `us` and Anthropic accepts `us` only. Defaults to the key's region for OpenAI and Fireworks, otherwise `null`.
|
|
14
14
|
*/
|
|
15
15
|
export type CreateBYOKKeyRequestDeclaredRegion = OpenEnum<typeof CreateBYOKKeyRequestDeclaredRegion>;
|
|
16
16
|
export type CreateBYOKKeyRequest = {
|
|
@@ -27,7 +27,7 @@ export type CreateBYOKKeyRequest = {
|
|
|
27
27
|
*/
|
|
28
28
|
allowedUserIds?: Array<string> | null | undefined;
|
|
29
29
|
/**
|
|
30
|
-
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers,
|
|
30
|
+
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers, Azure accepts `europe` or `us` and Anthropic accepts `us` only. Defaults to the key's region for OpenAI and Fireworks, otherwise `null`.
|
|
31
31
|
*/
|
|
32
32
|
declaredRegion?: CreateBYOKKeyRequestDeclaredRegion | null | undefined;
|
|
33
33
|
/**
|
|
@@ -7,7 +7,7 @@ import { remap as remap$ } from "../lib/primitives.js";
|
|
|
7
7
|
import * as openEnums from "../types/enums.js";
|
|
8
8
|
import { BYOKProviderSlug$outboundSchema, } from "./byokproviderslug.js";
|
|
9
9
|
/**
|
|
10
|
-
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers,
|
|
10
|
+
* Your declaration of the data region in which the upstream provider account behind this credential processes requests, used for routing eligibility on OpenRouter's regional hosts. `null` means undeclared and `global` is behaviorally identical: the credential follows the region OpenRouter records for the endpoint. `europe` or `us` lets requests to `eu.openrouter.ai` or `us.openrouter.ai` use this credential for that provider (private endpoints, endpoints pinned to another cloud region, cross-region inference profiles and video models are excluded). Self-declared and not verified by OpenRouter. For OpenAI and Fireworks the region comes from the key material (a `{"api_key": ..., "region": ...}` key), so the value must match the key's region. Among other providers, Azure accepts `europe` or `us` and Anthropic accepts `us` only. Defaults to the key's region for OpenAI and Fireworks, otherwise `null`.
|
|
11
11
|
*/
|
|
12
12
|
export const CreateBYOKKeyRequestDeclaredRegion = {
|
|
13
13
|
Global: "global",
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
export type CreateExternalUserRequest = {
|
|
3
|
+
/**
|
|
4
|
+
* Immutable case-sensitive tracking string supplied as user on inference requests or as external.user on API keys: 1 to 512 characters, well-formed Unicode, no NUL, no surrounding whitespace. URL-encode it in resource paths; an ID of `.` or `..` cannot be addressed by path, so look it up with the list filter.
|
|
5
|
+
*/
|
|
6
|
+
user: string;
|
|
7
|
+
};
|
|
8
|
+
/** @internal */
|
|
9
|
+
export type CreateExternalUserRequest$Outbound = {
|
|
10
|
+
user: string;
|
|
11
|
+
};
|
|
12
|
+
/** @internal */
|
|
13
|
+
export declare const CreateExternalUserRequest$outboundSchema: z.ZodType<CreateExternalUserRequest$Outbound, CreateExternalUserRequest>;
|
|
14
|
+
export declare function createExternalUserRequestToJSON(createExternalUserRequest: CreateExternalUserRequest): string;
|
|
15
|
+
//# sourceMappingURL=createexternaluserrequest.d.ts.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: dabbf073ef0b
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
/** @internal */
|
|
7
|
+
export const CreateExternalUserRequest$outboundSchema = z.object({
|
|
8
|
+
user: z.string(),
|
|
9
|
+
});
|
|
10
|
+
export function createExternalUserRequestToJSON(createExternalUserRequest) {
|
|
11
|
+
return JSON.stringify(CreateExternalUserRequest$outboundSchema.parse(createExternalUserRequest));
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=createexternaluserrequest.js.map
|
|
@@ -4,6 +4,14 @@ import { ContentFilterEntry, ContentFilterEntry$Outbound } from "./contentfilter
|
|
|
4
4
|
import { GuardrailDataRegion } from "./guardraildataregion.js";
|
|
5
5
|
import { GuardrailInterval } from "./guardrailinterval.js";
|
|
6
6
|
export type CreateGuardrailRequest = {
|
|
7
|
+
/**
|
|
8
|
+
* Whether ZDR-only requests to google/* models may use endpoints that may retain prompts for safety monitoring. false allows only zero-retention endpoints. A guardrail can only be more restrictive than the account setting. Inherits the account setting when not provided.
|
|
9
|
+
*/
|
|
10
|
+
allowSafetyRetentionGoogle?: boolean | null | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Whether ZDR-only requests to models outside the named providers (for example open-weight models on Vertex) may use endpoints that may retain prompts for safety monitoring. false allows only zero-retention endpoints. A guardrail can only be more restrictive than the account setting. Inherits the account setting when not provided.
|
|
13
|
+
*/
|
|
14
|
+
allowSafetyRetentionOther?: boolean | null | undefined;
|
|
7
15
|
/**
|
|
8
16
|
* Data regions through which requests governed by this guardrail must arrive. `global` is https://openrouter.ai, `europe` is https://eu.openrouter.ai, and `us` is https://us.openrouter.ai. Requests arriving through any other region are rejected. `null` leaves the ingress region unrestricted. When several guardrails apply (workspace default, member, API key), the effective regions are the intersection of every non-null value. An empty array is rejected.
|
|
9
17
|
*/
|
|
@@ -97,6 +105,8 @@ export type CreateGuardrailRequest = {
|
|
|
97
105
|
};
|
|
98
106
|
/** @internal */
|
|
99
107
|
export type CreateGuardrailRequest$Outbound = {
|
|
108
|
+
allow_safety_retention_google?: boolean | null | undefined;
|
|
109
|
+
allow_safety_retention_other?: boolean | null | undefined;
|
|
100
110
|
allowed_data_regions?: Array<string> | null | undefined;
|
|
101
111
|
allowed_models?: Array<string> | null | undefined;
|
|
102
112
|
allowed_providers?: Array<string> | null | undefined;
|
|
@@ -10,6 +10,8 @@ import { GuardrailDataRegion$outboundSchema, } from "./guardraildataregion.js";
|
|
|
10
10
|
import { GuardrailInterval$outboundSchema, } from "./guardrailinterval.js";
|
|
11
11
|
/** @internal */
|
|
12
12
|
export const CreateGuardrailRequest$outboundSchema = z.object({
|
|
13
|
+
allowSafetyRetentionGoogle: z.nullable(z.boolean()).optional(),
|
|
14
|
+
allowSafetyRetentionOther: z.nullable(z.boolean()).optional(),
|
|
13
15
|
allowedDataRegions: z.nullable(z.array(GuardrailDataRegion$outboundSchema))
|
|
14
16
|
.optional(),
|
|
15
17
|
allowedModels: z.nullable(z.array(z.string())).optional(),
|
|
@@ -36,6 +38,8 @@ export const CreateGuardrailRequest$outboundSchema = z.object({
|
|
|
36
38
|
workspaceId: z.string().optional(),
|
|
37
39
|
}).transform((v) => {
|
|
38
40
|
return remap$(v, {
|
|
41
|
+
allowSafetyRetentionGoogle: "allow_safety_retention_google",
|
|
42
|
+
allowSafetyRetentionOther: "allow_safety_retention_other",
|
|
39
43
|
allowedDataRegions: "allowed_data_regions",
|
|
40
44
|
allowedModels: "allowed_models",
|
|
41
45
|
allowedProviders: "allowed_providers",
|
|
@@ -37,6 +37,10 @@ export type CreateObservabilityDestinationRequest = {
|
|
|
37
37
|
* When true, include cost and billing generation metadata.
|
|
38
38
|
*/
|
|
39
39
|
broadcastGenerationCost?: boolean | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Beta. When true, include openrouter_cost_allocation: per-token-kind usage and cost, sent only when they reconcile with the billed cost.
|
|
42
|
+
*/
|
|
43
|
+
broadcastGenerationCostAllocation?: boolean | undefined;
|
|
40
44
|
/**
|
|
41
45
|
* When true, include identity generation metadata.
|
|
42
46
|
*/
|
|
@@ -90,6 +94,7 @@ export declare const CreateObservabilityDestinationRequestType$outboundSchema: z
|
|
|
90
94
|
export type CreateObservabilityDestinationRequest$Outbound = {
|
|
91
95
|
api_key_hashes?: Array<string> | null | undefined;
|
|
92
96
|
broadcast_generation_cost: boolean;
|
|
97
|
+
broadcast_generation_cost_allocation: boolean;
|
|
93
98
|
broadcast_generation_identity: boolean;
|
|
94
99
|
broadcast_generation_request_context: boolean;
|
|
95
100
|
config: {
|
|
@@ -36,6 +36,7 @@ export const CreateObservabilityDestinationRequestType$outboundSchema = openEnum
|
|
|
36
36
|
export const CreateObservabilityDestinationRequest$outboundSchema = z.object({
|
|
37
37
|
apiKeyHashes: z.nullable(z.array(z.string())).optional(),
|
|
38
38
|
broadcastGenerationCost: z.boolean().default(false),
|
|
39
|
+
broadcastGenerationCostAllocation: z.boolean().default(false),
|
|
39
40
|
broadcastGenerationIdentity: z.boolean().default(false),
|
|
40
41
|
broadcastGenerationRequestContext: z.boolean().default(false),
|
|
41
42
|
config: z.record(z.string(), z.any()),
|
|
@@ -52,6 +53,7 @@ export const CreateObservabilityDestinationRequest$outboundSchema = z.object({
|
|
|
52
53
|
return remap$(v, {
|
|
53
54
|
apiKeyHashes: "api_key_hashes",
|
|
54
55
|
broadcastGenerationCost: "broadcast_generation_cost",
|
|
56
|
+
broadcastGenerationCostAllocation: "broadcast_generation_cost_allocation",
|
|
55
57
|
broadcastGenerationIdentity: "broadcast_generation_identity",
|
|
56
58
|
broadcastGenerationRequestContext: "broadcast_generation_request_context",
|
|
57
59
|
filterRules: "filter_rules",
|
|
@@ -29,6 +29,7 @@ export type CustomTool = {
|
|
|
29
29
|
* Lets the model keep working after calling this tool instead of waiting for its output. The tool is still executed by the client; return the result in a later request as a `function_call_output` with the original `call_id`. Only honored by providers whose Responses API supports async tools; ignored elsewhere.
|
|
30
30
|
*/
|
|
31
31
|
async?: boolean | undefined;
|
|
32
|
+
deferLoading?: boolean | undefined;
|
|
32
33
|
description?: string | undefined;
|
|
33
34
|
format?: FormatText | FormatGrammar | discriminatedUnionTypes.Unknown<"type"> | undefined;
|
|
34
35
|
name: string;
|
|
@@ -77,6 +78,7 @@ export declare const CustomTool$inboundSchema: z.ZodType<CustomTool, unknown>;
|
|
|
77
78
|
/** @internal */
|
|
78
79
|
export type CustomTool$Outbound = {
|
|
79
80
|
async?: boolean | undefined;
|
|
81
|
+
defer_loading?: boolean | undefined;
|
|
80
82
|
description?: string | undefined;
|
|
81
83
|
format?: FormatText$Outbound | FormatGrammar$Outbound | undefined;
|
|
82
84
|
name: string;
|