mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-08-01 12:40:23 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
82bbe75d87 |
+7
-59
@@ -1,12 +1,12 @@
|
|||||||
lockVersion: 2.0.0
|
lockVersion: 2.0.0
|
||||||
id: cfd52247-6a25-4c6d-bbce-fe6fce0cd69d
|
id: cfd52247-6a25-4c6d-bbce-fe6fce0cd69d
|
||||||
management:
|
management:
|
||||||
docChecksum: 56062ba1997e25ff8be6529c550e5de9
|
docChecksum: 8e4409198e29bd1054772727ad1cd368
|
||||||
docVersion: 1.0.0
|
docVersion: 1.0.0
|
||||||
speakeasyVersion: 1.666.0
|
speakeasyVersion: 1.666.0
|
||||||
generationVersion: 2.768.0
|
generationVersion: 2.768.0
|
||||||
releaseVersion: 0.6.0
|
releaseVersion: 0.4.0
|
||||||
configChecksum: 690b77f47b975e28d7e11a6b96fa1c2f
|
configChecksum: 3a0d4d70223d25bf75028237ebd7e079
|
||||||
repoURL: https://github.com/OpenRouterTeam/python-sdk.git
|
repoURL: https://github.com/OpenRouterTeam/python-sdk.git
|
||||||
installationURL: https://github.com/OpenRouterTeam/python-sdk.git
|
installationURL: https://github.com/OpenRouterTeam/python-sdk.git
|
||||||
published: true
|
published: true
|
||||||
@@ -498,19 +498,15 @@ generatedFiles:
|
|||||||
- docs/models/internal/globals.md
|
- docs/models/internal/globals.md
|
||||||
- docs/models/utils/retryconfig.md
|
- docs/models/utils/retryconfig.md
|
||||||
- docs/operations/apitype.md
|
- docs/operations/apitype.md
|
||||||
- docs/operations/bulkassignkeystoguardrailglobals.md
|
|
||||||
- docs/operations/bulkassignkeystoguardrailrequest.md
|
- docs/operations/bulkassignkeystoguardrailrequest.md
|
||||||
- docs/operations/bulkassignkeystoguardrailrequestbody.md
|
- docs/operations/bulkassignkeystoguardrailrequestbody.md
|
||||||
- docs/operations/bulkassignkeystoguardrailresponse.md
|
- docs/operations/bulkassignkeystoguardrailresponse.md
|
||||||
- docs/operations/bulkassignmemberstoguardrailglobals.md
|
|
||||||
- docs/operations/bulkassignmemberstoguardrailrequest.md
|
- docs/operations/bulkassignmemberstoguardrailrequest.md
|
||||||
- docs/operations/bulkassignmemberstoguardrailrequestbody.md
|
- docs/operations/bulkassignmemberstoguardrailrequestbody.md
|
||||||
- docs/operations/bulkassignmemberstoguardrailresponse.md
|
- docs/operations/bulkassignmemberstoguardrailresponse.md
|
||||||
- docs/operations/bulkunassignkeysfromguardrailglobals.md
|
|
||||||
- docs/operations/bulkunassignkeysfromguardrailrequest.md
|
- docs/operations/bulkunassignkeysfromguardrailrequest.md
|
||||||
- docs/operations/bulkunassignkeysfromguardrailrequestbody.md
|
- docs/operations/bulkunassignkeysfromguardrailrequestbody.md
|
||||||
- docs/operations/bulkunassignkeysfromguardrailresponse.md
|
- docs/operations/bulkunassignkeysfromguardrailresponse.md
|
||||||
- docs/operations/bulkunassignmembersfromguardrailglobals.md
|
|
||||||
- docs/operations/bulkunassignmembersfromguardrailrequest.md
|
- docs/operations/bulkunassignmembersfromguardrailrequest.md
|
||||||
- docs/operations/bulkunassignmembersfromguardrailrequestbody.md
|
- docs/operations/bulkunassignmembersfromguardrailrequestbody.md
|
||||||
- docs/operations/bulkunassignmembersfromguardrailresponse.md
|
- docs/operations/bulkunassignmembersfromguardrailresponse.md
|
||||||
@@ -521,119 +517,77 @@ generatedFiles:
|
|||||||
- docs/operations/contenttext.md
|
- docs/operations/contenttext.md
|
||||||
- docs/operations/createauthkeyscodecodechallengemethod.md
|
- docs/operations/createauthkeyscodecodechallengemethod.md
|
||||||
- docs/operations/createauthkeyscodedata.md
|
- docs/operations/createauthkeyscodedata.md
|
||||||
- docs/operations/createauthkeyscodeglobals.md
|
|
||||||
- docs/operations/createauthkeyscoderequest.md
|
- docs/operations/createauthkeyscoderequest.md
|
||||||
- docs/operations/createauthkeyscoderequestbody.md
|
|
||||||
- docs/operations/createauthkeyscoderesponse.md
|
- docs/operations/createauthkeyscoderesponse.md
|
||||||
- docs/operations/createcoinbasechargedata.md
|
- docs/operations/createcoinbasechargedata.md
|
||||||
- docs/operations/createcoinbasechargeglobals.md
|
|
||||||
- docs/operations/createcoinbasechargerequest.md
|
|
||||||
- docs/operations/createcoinbasechargeresponse.md
|
- docs/operations/createcoinbasechargeresponse.md
|
||||||
- docs/operations/createcoinbasechargesecurity.md
|
- docs/operations/createcoinbasechargesecurity.md
|
||||||
- docs/operations/createembeddingsdata.md
|
- docs/operations/createembeddingsdata.md
|
||||||
- docs/operations/createembeddingsglobals.md
|
|
||||||
- docs/operations/createembeddingsrequest.md
|
- docs/operations/createembeddingsrequest.md
|
||||||
- docs/operations/createembeddingsrequestbody.md
|
|
||||||
- docs/operations/createembeddingsresponse.md
|
- docs/operations/createembeddingsresponse.md
|
||||||
- docs/operations/createembeddingsresponsebody.md
|
- docs/operations/createembeddingsresponsebody.md
|
||||||
- docs/operations/createguardraildata.md
|
- docs/operations/createguardraildata.md
|
||||||
- docs/operations/createguardrailglobals.md
|
|
||||||
- docs/operations/createguardrailrequest.md
|
- docs/operations/createguardrailrequest.md
|
||||||
- docs/operations/createguardrailrequestbody.md
|
|
||||||
- docs/operations/createguardrailresetintervalrequest.md
|
- docs/operations/createguardrailresetintervalrequest.md
|
||||||
- docs/operations/createguardrailresetintervalresponse.md
|
- docs/operations/createguardrailresetintervalresponse.md
|
||||||
- docs/operations/createguardrailresponse.md
|
- docs/operations/createguardrailresponse.md
|
||||||
- docs/operations/createkeysdata.md
|
- docs/operations/createkeysdata.md
|
||||||
- docs/operations/createkeysglobals.md
|
|
||||||
- docs/operations/createkeyslimitreset.md
|
- docs/operations/createkeyslimitreset.md
|
||||||
- docs/operations/createkeysrequest.md
|
- docs/operations/createkeysrequest.md
|
||||||
- docs/operations/createkeysrequestbody.md
|
|
||||||
- docs/operations/createkeysresponse.md
|
- docs/operations/createkeysresponse.md
|
||||||
- docs/operations/createresponsesglobals.md
|
|
||||||
- docs/operations/createresponsesrequest.md
|
|
||||||
- docs/operations/createresponsesresponse.md
|
- docs/operations/createresponsesresponse.md
|
||||||
- docs/operations/createresponsesresponsebody.md
|
- docs/operations/createresponsesresponsebody.md
|
||||||
- docs/operations/deleteguardrailglobals.md
|
|
||||||
- docs/operations/deleteguardrailrequest.md
|
- docs/operations/deleteguardrailrequest.md
|
||||||
- docs/operations/deleteguardrailresponse.md
|
- docs/operations/deleteguardrailresponse.md
|
||||||
- docs/operations/deletekeysglobals.md
|
|
||||||
- docs/operations/deletekeysrequest.md
|
- docs/operations/deletekeysrequest.md
|
||||||
- docs/operations/deletekeysresponse.md
|
- docs/operations/deletekeysresponse.md
|
||||||
- docs/operations/embedding.md
|
- docs/operations/embedding.md
|
||||||
- docs/operations/encodingformat.md
|
- docs/operations/encodingformat.md
|
||||||
- docs/operations/exchangeauthcodeforapikeycodechallengemethod.md
|
- docs/operations/exchangeauthcodeforapikeycodechallengemethod.md
|
||||||
- docs/operations/exchangeauthcodeforapikeyglobals.md
|
|
||||||
- docs/operations/exchangeauthcodeforapikeyrequest.md
|
- docs/operations/exchangeauthcodeforapikeyrequest.md
|
||||||
- docs/operations/exchangeauthcodeforapikeyrequestbody.md
|
|
||||||
- docs/operations/exchangeauthcodeforapikeyresponse.md
|
- docs/operations/exchangeauthcodeforapikeyresponse.md
|
||||||
- docs/operations/getcreditsdata.md
|
- docs/operations/getcreditsdata.md
|
||||||
- docs/operations/getcreditsglobals.md
|
|
||||||
- docs/operations/getcreditsrequest.md
|
|
||||||
- docs/operations/getcreditsresponse.md
|
- docs/operations/getcreditsresponse.md
|
||||||
- docs/operations/getcurrentkeydata.md
|
- docs/operations/getcurrentkeydata.md
|
||||||
- docs/operations/getcurrentkeyglobals.md
|
|
||||||
- docs/operations/getcurrentkeyrequest.md
|
|
||||||
- docs/operations/getcurrentkeyresponse.md
|
- docs/operations/getcurrentkeyresponse.md
|
||||||
- docs/operations/getgenerationdata.md
|
- docs/operations/getgenerationdata.md
|
||||||
- docs/operations/getgenerationglobals.md
|
|
||||||
- docs/operations/getgenerationrequest.md
|
- docs/operations/getgenerationrequest.md
|
||||||
- docs/operations/getgenerationresponse.md
|
- docs/operations/getgenerationresponse.md
|
||||||
- docs/operations/getguardraildata.md
|
- docs/operations/getguardraildata.md
|
||||||
- docs/operations/getguardrailglobals.md
|
|
||||||
- docs/operations/getguardrailrequest.md
|
- docs/operations/getguardrailrequest.md
|
||||||
- docs/operations/getguardrailresetinterval.md
|
- docs/operations/getguardrailresetinterval.md
|
||||||
- docs/operations/getguardrailresponse.md
|
- docs/operations/getguardrailresponse.md
|
||||||
- docs/operations/getkeydata.md
|
- docs/operations/getkeydata.md
|
||||||
- docs/operations/getkeyglobals.md
|
|
||||||
- docs/operations/getkeyrequest.md
|
- docs/operations/getkeyrequest.md
|
||||||
- docs/operations/getkeyresponse.md
|
- docs/operations/getkeyresponse.md
|
||||||
- docs/operations/getmodelsglobals.md
|
|
||||||
- docs/operations/getmodelsrequest.md
|
- docs/operations/getmodelsrequest.md
|
||||||
- docs/operations/getuseractivityglobals.md
|
|
||||||
- docs/operations/getuseractivityrequest.md
|
- docs/operations/getuseractivityrequest.md
|
||||||
- docs/operations/getuseractivityresponse.md
|
- docs/operations/getuseractivityresponse.md
|
||||||
- docs/operations/imageurl.md
|
- docs/operations/imageurl.md
|
||||||
- docs/operations/input.md
|
- docs/operations/input.md
|
||||||
- docs/operations/inputunion.md
|
- docs/operations/inputunion.md
|
||||||
- docs/operations/listdata.md
|
- docs/operations/listdata.md
|
||||||
- docs/operations/listembeddingsmodelsglobals.md
|
|
||||||
- docs/operations/listembeddingsmodelsrequest.md
|
|
||||||
- docs/operations/listendpointsglobals.md
|
|
||||||
- docs/operations/listendpointsrequest.md
|
- docs/operations/listendpointsrequest.md
|
||||||
- docs/operations/listendpointsresponse.md
|
- docs/operations/listendpointsresponse.md
|
||||||
- docs/operations/listendpointszdrglobals.md
|
|
||||||
- docs/operations/listendpointszdrrequest.md
|
|
||||||
- docs/operations/listendpointszdrresponse.md
|
- docs/operations/listendpointszdrresponse.md
|
||||||
- docs/operations/listglobals.md
|
|
||||||
- docs/operations/listguardrailkeyassignmentsdata.md
|
- docs/operations/listguardrailkeyassignmentsdata.md
|
||||||
- docs/operations/listguardrailkeyassignmentsglobals.md
|
|
||||||
- docs/operations/listguardrailkeyassignmentsrequest.md
|
- docs/operations/listguardrailkeyassignmentsrequest.md
|
||||||
- docs/operations/listguardrailkeyassignmentsresponse.md
|
- docs/operations/listguardrailkeyassignmentsresponse.md
|
||||||
- docs/operations/listguardrailmemberassignmentsdata.md
|
- docs/operations/listguardrailmemberassignmentsdata.md
|
||||||
- docs/operations/listguardrailmemberassignmentsglobals.md
|
|
||||||
- docs/operations/listguardrailmemberassignmentsrequest.md
|
- docs/operations/listguardrailmemberassignmentsrequest.md
|
||||||
- docs/operations/listguardrailmemberassignmentsresponse.md
|
- docs/operations/listguardrailmemberassignmentsresponse.md
|
||||||
- docs/operations/listguardrailsdata.md
|
- docs/operations/listguardrailsdata.md
|
||||||
- docs/operations/listguardrailsglobals.md
|
|
||||||
- docs/operations/listguardrailsrequest.md
|
- docs/operations/listguardrailsrequest.md
|
||||||
- docs/operations/listguardrailsresetinterval.md
|
- docs/operations/listguardrailsresetinterval.md
|
||||||
- docs/operations/listguardrailsresponse.md
|
- docs/operations/listguardrailsresponse.md
|
||||||
- docs/operations/listkeyassignmentsdata.md
|
- docs/operations/listkeyassignmentsdata.md
|
||||||
- docs/operations/listkeyassignmentsglobals.md
|
|
||||||
- docs/operations/listkeyassignmentsrequest.md
|
- docs/operations/listkeyassignmentsrequest.md
|
||||||
- docs/operations/listkeyassignmentsresponse.md
|
- docs/operations/listkeyassignmentsresponse.md
|
||||||
- docs/operations/listmemberassignmentsdata.md
|
- docs/operations/listmemberassignmentsdata.md
|
||||||
- docs/operations/listmemberassignmentsglobals.md
|
|
||||||
- docs/operations/listmemberassignmentsrequest.md
|
- docs/operations/listmemberassignmentsrequest.md
|
||||||
- docs/operations/listmemberassignmentsresponse.md
|
- docs/operations/listmemberassignmentsresponse.md
|
||||||
- docs/operations/listmodelscountglobals.md
|
|
||||||
- docs/operations/listmodelscountrequest.md
|
|
||||||
- docs/operations/listmodelsuserglobals.md
|
|
||||||
- docs/operations/listmodelsuserrequest.md
|
|
||||||
- docs/operations/listmodelsusersecurity.md
|
- docs/operations/listmodelsusersecurity.md
|
||||||
- docs/operations/listprovidersdata.md
|
- docs/operations/listprovidersdata.md
|
||||||
- docs/operations/listprovidersglobals.md
|
|
||||||
- docs/operations/listprovidersrequest.md
|
|
||||||
- docs/operations/listprovidersresponse.md
|
- docs/operations/listprovidersresponse.md
|
||||||
- docs/operations/listrequest.md
|
- docs/operations/listrequest.md
|
||||||
- docs/operations/listresponse.md
|
- docs/operations/listresponse.md
|
||||||
@@ -643,21 +597,17 @@ generatedFiles:
|
|||||||
- docs/operations/providername.md
|
- docs/operations/providername.md
|
||||||
- docs/operations/providerresponse.md
|
- docs/operations/providerresponse.md
|
||||||
- docs/operations/ratelimit.md
|
- docs/operations/ratelimit.md
|
||||||
- docs/operations/sendchatcompletionrequestglobals.md
|
|
||||||
- docs/operations/sendchatcompletionrequestrequest.md
|
|
||||||
- docs/operations/sendchatcompletionrequestresponse.md
|
- docs/operations/sendchatcompletionrequestresponse.md
|
||||||
- docs/operations/transferintent.md
|
- docs/operations/transferintent.md
|
||||||
- docs/operations/typeimageurl.md
|
- docs/operations/typeimageurl.md
|
||||||
- docs/operations/typetext.md
|
- docs/operations/typetext.md
|
||||||
- docs/operations/updateguardraildata.md
|
- docs/operations/updateguardraildata.md
|
||||||
- docs/operations/updateguardrailglobals.md
|
|
||||||
- docs/operations/updateguardrailrequest.md
|
- docs/operations/updateguardrailrequest.md
|
||||||
- docs/operations/updateguardrailrequestbody.md
|
- docs/operations/updateguardrailrequestbody.md
|
||||||
- docs/operations/updateguardrailresetintervalrequest.md
|
- docs/operations/updateguardrailresetintervalrequest.md
|
||||||
- docs/operations/updateguardrailresetintervalresponse.md
|
- docs/operations/updateguardrailresetintervalresponse.md
|
||||||
- docs/operations/updateguardrailresponse.md
|
- docs/operations/updateguardrailresponse.md
|
||||||
- docs/operations/updatekeysdata.md
|
- docs/operations/updatekeysdata.md
|
||||||
- docs/operations/updatekeysglobals.md
|
|
||||||
- docs/operations/updatekeyslimitreset.md
|
- docs/operations/updatekeyslimitreset.md
|
||||||
- docs/operations/updatekeysrequest.md
|
- docs/operations/updatekeysrequest.md
|
||||||
- docs/operations/updatekeysrequestbody.md
|
- docs/operations/updatekeysrequestbody.md
|
||||||
@@ -902,7 +852,6 @@ generatedFiles:
|
|||||||
- src/openrouter/operations/getmodels.py
|
- src/openrouter/operations/getmodels.py
|
||||||
- src/openrouter/operations/getuseractivity.py
|
- src/openrouter/operations/getuseractivity.py
|
||||||
- src/openrouter/operations/list.py
|
- src/openrouter/operations/list.py
|
||||||
- src/openrouter/operations/listembeddingsmodels.py
|
|
||||||
- src/openrouter/operations/listendpoints.py
|
- src/openrouter/operations/listendpoints.py
|
||||||
- src/openrouter/operations/listendpointszdr.py
|
- src/openrouter/operations/listendpointszdr.py
|
||||||
- src/openrouter/operations/listguardrailkeyassignments.py
|
- src/openrouter/operations/listguardrailkeyassignments.py
|
||||||
@@ -910,7 +859,6 @@ generatedFiles:
|
|||||||
- src/openrouter/operations/listguardrails.py
|
- src/openrouter/operations/listguardrails.py
|
||||||
- src/openrouter/operations/listkeyassignments.py
|
- src/openrouter/operations/listkeyassignments.py
|
||||||
- src/openrouter/operations/listmemberassignments.py
|
- src/openrouter/operations/listmemberassignments.py
|
||||||
- src/openrouter/operations/listmodelscount.py
|
|
||||||
- src/openrouter/operations/listmodelsuser.py
|
- src/openrouter/operations/listmodelsuser.py
|
||||||
- src/openrouter/operations/listproviders.py
|
- src/openrouter/operations/listproviders.py
|
||||||
- src/openrouter/operations/sendchatcompletionrequest.py
|
- src/openrouter/operations/sendchatcompletionrequest.py
|
||||||
@@ -987,7 +935,7 @@ examples:
|
|||||||
"401":
|
"401":
|
||||||
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
||||||
"403":
|
"403":
|
||||||
application/json: {"error": {"code": 403, "message": "Only management keys can perform this operation"}}
|
application/json: {"error": {"code": 403, "message": "Only provisioning keys can perform this operation"}}
|
||||||
"500":
|
"500":
|
||||||
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
||||||
getCredits:
|
getCredits:
|
||||||
@@ -998,7 +946,7 @@ examples:
|
|||||||
"401":
|
"401":
|
||||||
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
||||||
"403":
|
"403":
|
||||||
application/json: {"error": {"code": 403, "message": "Only management keys can perform this operation"}}
|
application/json: {"error": {"code": 403, "message": "Only provisioning keys can perform this operation"}}
|
||||||
"500":
|
"500":
|
||||||
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
||||||
createCoinbaseCharge:
|
createCoinbaseCharge:
|
||||||
@@ -1232,7 +1180,7 @@ examples:
|
|||||||
speakeasy-default-get-current-key:
|
speakeasy-default-get-current-key:
|
||||||
responses:
|
responses:
|
||||||
"200":
|
"200":
|
||||||
application/json: {"data": {"label": "sk-or-v1-au7...890", "limit": 100, "usage": 25.5, "usage_daily": 25.5, "usage_weekly": 25.5, "usage_monthly": 25.5, "byok_usage": 17.38, "byok_usage_daily": 17.38, "byok_usage_weekly": 17.38, "byok_usage_monthly": 17.38, "is_free_tier": false, "is_management_key": false, "is_provisioning_key": false, "limit_remaining": 74.5, "limit_reset": "monthly", "include_byok_in_limit": false, "rate_limit": {"requests": 1000, "interval": "1h", "note": "This field is deprecated and safe to ignore."}}}
|
application/json: {"data": {"label": "sk-or-v1-au7...890", "limit": 100, "usage": 25.5, "usage_daily": 25.5, "usage_weekly": 25.5, "usage_monthly": 25.5, "byok_usage": 17.38, "byok_usage_daily": 17.38, "byok_usage_weekly": 17.38, "byok_usage_monthly": 17.38, "is_free_tier": false, "is_provisioning_key": false, "limit_remaining": 74.5, "limit_reset": "monthly", "include_byok_in_limit": false, "rate_limit": {"requests": 1000, "interval": "1h", "note": "This field is deprecated and safe to ignore."}}}
|
||||||
"401":
|
"401":
|
||||||
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
||||||
"500":
|
"500":
|
||||||
@@ -1247,7 +1195,7 @@ examples:
|
|||||||
"400":
|
"400":
|
||||||
application/json: {"error": {"code": 400, "message": "Invalid request parameters"}}
|
application/json: {"error": {"code": 400, "message": "Invalid request parameters"}}
|
||||||
"403":
|
"403":
|
||||||
application/json: {"error": {"code": 403, "message": "Only management keys can perform this operation"}}
|
application/json: {"error": {"code": 403, "message": "Only provisioning keys can perform this operation"}}
|
||||||
"500":
|
"500":
|
||||||
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
application/json: {"error": {"code": 500, "message": "Internal Server Error"}}
|
||||||
createAuthKeysCode:
|
createAuthKeysCode:
|
||||||
|
|||||||
+1
-1
@@ -31,7 +31,7 @@ generation:
|
|||||||
skipResponseBodyAssertions: false
|
skipResponseBodyAssertions: false
|
||||||
preApplyUnionDiscriminators: true
|
preApplyUnionDiscriminators: true
|
||||||
python:
|
python:
|
||||||
version: 0.6.0
|
version: 0.4.0
|
||||||
additionalDependencies:
|
additionalDependencies:
|
||||||
dev: {}
|
dev: {}
|
||||||
main: {}
|
main: {}
|
||||||
|
|||||||
+41
-84
@@ -4403,6 +4403,7 @@ components:
|
|||||||
- tool_use
|
- tool_use
|
||||||
- pause_turn
|
- pause_turn
|
||||||
- refusal
|
- refusal
|
||||||
|
- model_context_window_exceeded
|
||||||
stop_sequence:
|
stop_sequence:
|
||||||
type: string
|
type: string
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -4430,9 +4431,6 @@ components:
|
|||||||
required:
|
required:
|
||||||
- ephemeral_5m_input_tokens
|
- ephemeral_5m_input_tokens
|
||||||
- ephemeral_1h_input_tokens
|
- ephemeral_1h_input_tokens
|
||||||
inference_geo:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
server_tool_use:
|
server_tool_use:
|
||||||
type: object
|
type: object
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -4454,7 +4452,6 @@ components:
|
|||||||
- cache_creation_input_tokens
|
- cache_creation_input_tokens
|
||||||
- cache_read_input_tokens
|
- cache_read_input_tokens
|
||||||
- cache_creation
|
- cache_creation
|
||||||
- inference_geo
|
|
||||||
- server_tool_use
|
- server_tool_use
|
||||||
- service_tier
|
- service_tier
|
||||||
required:
|
required:
|
||||||
@@ -4489,7 +4486,6 @@ components:
|
|||||||
cache_creation_input_tokens: null
|
cache_creation_input_tokens: null
|
||||||
cache_read_input_tokens: null
|
cache_read_input_tokens: null
|
||||||
cache_creation: null
|
cache_creation: null
|
||||||
inference_geo: null
|
|
||||||
server_tool_use: null
|
server_tool_use: null
|
||||||
service_tier: standard
|
service_tier: standard
|
||||||
AnthropicMessagesStreamEvent:
|
AnthropicMessagesStreamEvent:
|
||||||
@@ -4809,9 +4805,6 @@ components:
|
|||||||
required:
|
required:
|
||||||
- ephemeral_5m_input_tokens
|
- ephemeral_5m_input_tokens
|
||||||
- ephemeral_1h_input_tokens
|
- ephemeral_1h_input_tokens
|
||||||
inference_geo:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
server_tool_use:
|
server_tool_use:
|
||||||
type: object
|
type: object
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -4833,7 +4826,6 @@ components:
|
|||||||
- cache_creation_input_tokens
|
- cache_creation_input_tokens
|
||||||
- cache_read_input_tokens
|
- cache_read_input_tokens
|
||||||
- cache_creation
|
- cache_creation
|
||||||
- inference_geo
|
|
||||||
- server_tool_use
|
- server_tool_use
|
||||||
- service_tier
|
- service_tier
|
||||||
required:
|
required:
|
||||||
@@ -4867,6 +4859,7 @@ components:
|
|||||||
- tool_use
|
- tool_use
|
||||||
- pause_turn
|
- pause_turn
|
||||||
- refusal
|
- refusal
|
||||||
|
- model_context_window_exceeded
|
||||||
stop_sequence:
|
stop_sequence:
|
||||||
type: string
|
type: string
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -6531,22 +6524,6 @@ components:
|
|||||||
- role
|
- role
|
||||||
- content
|
- content
|
||||||
description: Anthropic message with OpenRouter extensions
|
description: Anthropic message with OpenRouter extensions
|
||||||
AnthropicOutputConfig:
|
|
||||||
type: object
|
|
||||||
properties:
|
|
||||||
effort:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
enum:
|
|
||||||
- low
|
|
||||||
- medium
|
|
||||||
- high
|
|
||||||
- max
|
|
||||||
description: >-
|
|
||||||
How much effort the model should put into its response. Higher effort levels may result in more thorough
|
|
||||||
analysis but take longer. Valid values are `low`, `medium`, `high`, or `max`.
|
|
||||||
example: medium
|
|
||||||
description: Configuration for controlling output behavior. Currently supports the effort parameter for Claude Opus 4.5.
|
|
||||||
AnthropicMessagesRequest:
|
AnthropicMessagesRequest:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -6960,14 +6937,6 @@ components:
|
|||||||
- disabled
|
- disabled
|
||||||
required:
|
required:
|
||||||
- type
|
- type
|
||||||
- type: object
|
|
||||||
properties:
|
|
||||||
type:
|
|
||||||
type: string
|
|
||||||
enum:
|
|
||||||
- adaptive
|
|
||||||
required:
|
|
||||||
- type
|
|
||||||
service_tier:
|
service_tier:
|
||||||
type: string
|
type: string
|
||||||
enum:
|
enum:
|
||||||
@@ -7195,8 +7164,6 @@ components:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
type: string
|
type: string
|
||||||
output_config:
|
|
||||||
$ref: '#/components/schemas/AnthropicOutputConfig'
|
|
||||||
required:
|
required:
|
||||||
- model
|
- model
|
||||||
- max_tokens
|
- max_tokens
|
||||||
@@ -7298,7 +7265,7 @@ components:
|
|||||||
description: Error data for ForbiddenResponse
|
description: Error data for ForbiddenResponse
|
||||||
example:
|
example:
|
||||||
code: 403
|
code: 403
|
||||||
message: Only management keys can perform this operation
|
message: Only provisioning keys can perform this operation
|
||||||
ForbiddenResponse:
|
ForbiddenResponse:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -7313,7 +7280,7 @@ components:
|
|||||||
example:
|
example:
|
||||||
error:
|
error:
|
||||||
code: 403
|
code: 403
|
||||||
message: Only management keys can perform this operation
|
message: Only provisioning keys can perform this operation
|
||||||
CreateChargeRequest:
|
CreateChargeRequest:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -9267,8 +9234,6 @@ components:
|
|||||||
anyOf:
|
anyOf:
|
||||||
- type: string
|
- type: string
|
||||||
- type: number
|
- type: number
|
||||||
- type: array
|
|
||||||
items: {}
|
|
||||||
modalities:
|
modalities:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
@@ -9822,8 +9787,8 @@ paths:
|
|||||||
operationId: getUserActivity
|
operationId: getUserActivity
|
||||||
summary: Get user activity grouped by endpoint
|
summary: Get user activity grouped by endpoint
|
||||||
description: >-
|
description: >-
|
||||||
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Management
|
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -9874,7 +9839,7 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/UnauthorizedResponse'
|
$ref: '#/components/schemas/UnauthorizedResponse'
|
||||||
'403':
|
'403':
|
||||||
description: Forbidden - Only management keys can fetch activity
|
description: Forbidden - Only provisioning keys can fetch activity
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
@@ -9893,8 +9858,8 @@ paths:
|
|||||||
summary: Get remaining credits
|
summary: Get remaining credits
|
||||||
operationId: getCredits
|
operationId: getCredits
|
||||||
description: >-
|
description: >-
|
||||||
Get total credits purchased and used for the authenticated user. [Management
|
Get total credits purchased and used for the authenticated user. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
responses:
|
responses:
|
||||||
'200':
|
'200':
|
||||||
description: Returns the total credits purchased and used
|
description: Returns the total credits purchased and used
|
||||||
@@ -9934,7 +9899,7 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/UnauthorizedResponse'
|
$ref: '#/components/schemas/UnauthorizedResponse'
|
||||||
'403':
|
'403':
|
||||||
description: Forbidden - Only management keys can fetch credits
|
description: Forbidden - Only provisioning keys can fetch credits
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
@@ -10957,8 +10922,8 @@ paths:
|
|||||||
- API Keys
|
- API Keys
|
||||||
summary: List API keys
|
summary: List API keys
|
||||||
description: >-
|
description: >-
|
||||||
List all API keys for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys)
|
List all API keys for the authenticated user. [Provisioning
|
||||||
required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11158,8 +11123,8 @@ paths:
|
|||||||
- API Keys
|
- API Keys
|
||||||
summary: Create a new API key
|
summary: Create a new API key
|
||||||
description: >-
|
description: >-
|
||||||
Create a new API key for the authenticated user. [Management
|
Create a new API key for the authenticated user. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
requestBody:
|
requestBody:
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
@@ -11401,7 +11366,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Update an API key
|
summary: Update an API key
|
||||||
description: Update an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Update an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11644,7 +11609,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Delete an API key
|
summary: Delete an API key
|
||||||
description: Delete an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Delete an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11702,7 +11667,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Get a single API key
|
summary: Get a single API key
|
||||||
description: Get a single API key by hash. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Get a single API key by hash. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11900,8 +11865,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List guardrails
|
summary: List guardrails
|
||||||
description: >-
|
description: >-
|
||||||
List all guardrails for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys)
|
List all guardrails for the authenticated user. [Provisioning
|
||||||
required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12057,8 +12022,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Create a guardrail
|
summary: Create a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Create a new guardrail for the authenticated user. [Management
|
Create a new guardrail for the authenticated user. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
requestBody:
|
requestBody:
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
@@ -12270,7 +12235,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Get a guardrail
|
summary: Get a guardrail
|
||||||
description: Get a single guardrail by ID. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Get a single guardrail by ID. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12416,7 +12381,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Update a guardrail
|
summary: Update a guardrail
|
||||||
description: Update an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Update an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12631,7 +12596,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Delete a guardrail
|
summary: Delete a guardrail
|
||||||
description: Delete an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Delete an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12685,8 +12650,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List all key assignments
|
summary: List all key assignments
|
||||||
description: >-
|
description: >-
|
||||||
List all API key guardrail assignments for the authenticated user. [Management
|
List all API key guardrail assignments for the authenticated user. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12784,8 +12749,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List all member assignments
|
summary: List all member assignments
|
||||||
description: >-
|
description: >-
|
||||||
List all organization member guardrail assignments for the authenticated user. [Management
|
List all organization member guardrail assignments for the authenticated user. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12878,8 +12843,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List key assignments for a guardrail
|
summary: List key assignments for a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
List all API key assignments for a specific guardrail. [Management
|
List all API key assignments for a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12991,8 +12956,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk assign keys to a guardrail
|
summary: Bulk assign keys to a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Assign multiple API keys to a specific guardrail. [Management
|
Assign multiple API keys to a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13067,8 +13032,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List member assignments for a guardrail
|
summary: List member assignments for a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
List all organization member assignments for a specific guardrail. [Management
|
List all organization member assignments for a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13175,8 +13140,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk assign members to a guardrail
|
summary: Bulk assign members to a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Assign multiple organization members to a specific guardrail. [Management
|
Assign multiple organization members to a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13252,8 +13217,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk unassign keys from a guardrail
|
summary: Bulk unassign keys from a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Unassign multiple API keys from a specific guardrail. [Management
|
Unassign multiple API keys from a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13328,8 +13293,8 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk unassign members from a guardrail
|
summary: Bulk unassign members from a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Unassign multiple organization members from a specific guardrail. [Management
|
Unassign multiple organization members from a specific guardrail. [Provisioning
|
||||||
key](/docs/guides/overview/auth/management-api-keys) required.
|
key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13461,14 +13426,9 @@ paths:
|
|||||||
type: boolean
|
type: boolean
|
||||||
description: Whether this is a free tier API key
|
description: Whether this is a free tier API key
|
||||||
example: false
|
example: false
|
||||||
is_management_key:
|
|
||||||
type: boolean
|
|
||||||
description: Whether this is a management key
|
|
||||||
example: false
|
|
||||||
is_provisioning_key:
|
is_provisioning_key:
|
||||||
type: boolean
|
type: boolean
|
||||||
description: Whether this is a management key
|
description: Whether this is a provisioning key
|
||||||
deprecated: true
|
|
||||||
example: false
|
example: false
|
||||||
limit_remaining:
|
limit_remaining:
|
||||||
type: number
|
type: number
|
||||||
@@ -13527,7 +13487,6 @@ paths:
|
|||||||
- byok_usage_weekly
|
- byok_usage_weekly
|
||||||
- byok_usage_monthly
|
- byok_usage_monthly
|
||||||
- is_free_tier
|
- is_free_tier
|
||||||
- is_management_key
|
|
||||||
- is_provisioning_key
|
- is_provisioning_key
|
||||||
- limit_remaining
|
- limit_remaining
|
||||||
- limit_reset
|
- limit_reset
|
||||||
@@ -13546,7 +13505,6 @@ paths:
|
|||||||
byok_usage_weekly: 17.38
|
byok_usage_weekly: 17.38
|
||||||
byok_usage_monthly: 17.38
|
byok_usage_monthly: 17.38
|
||||||
is_free_tier: false
|
is_free_tier: false
|
||||||
is_management_key: false
|
|
||||||
is_provisioning_key: false
|
is_provisioning_key: false
|
||||||
limit_remaining: 74.5
|
limit_remaining: 74.5
|
||||||
limit_reset: monthly
|
limit_reset: monthly
|
||||||
@@ -13571,7 +13529,6 @@ paths:
|
|||||||
byok_usage_weekly: 17.38
|
byok_usage_weekly: 17.38
|
||||||
byok_usage_monthly: 17.38
|
byok_usage_monthly: 17.38
|
||||||
is_free_tier: false
|
is_free_tier: false
|
||||||
is_management_key: false
|
|
||||||
is_provisioning_key: false
|
is_provisioning_key: false
|
||||||
limit_remaining: 74.5
|
limit_remaining: 74.5
|
||||||
limit_reset: monthly
|
limit_reset: monthly
|
||||||
|
|||||||
+27
-154
@@ -4407,6 +4407,7 @@ components:
|
|||||||
- tool_use
|
- tool_use
|
||||||
- pause_turn
|
- pause_turn
|
||||||
- refusal
|
- refusal
|
||||||
|
- model_context_window_exceeded
|
||||||
x-speakeasy-unknown-values: allow
|
x-speakeasy-unknown-values: allow
|
||||||
stop_sequence:
|
stop_sequence:
|
||||||
type: string
|
type: string
|
||||||
@@ -4435,9 +4436,6 @@ components:
|
|||||||
required:
|
required:
|
||||||
- ephemeral_5m_input_tokens
|
- ephemeral_5m_input_tokens
|
||||||
- ephemeral_1h_input_tokens
|
- ephemeral_1h_input_tokens
|
||||||
inference_geo:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
server_tool_use:
|
server_tool_use:
|
||||||
type: object
|
type: object
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -4460,7 +4458,6 @@ components:
|
|||||||
- cache_creation_input_tokens
|
- cache_creation_input_tokens
|
||||||
- cache_read_input_tokens
|
- cache_read_input_tokens
|
||||||
- cache_creation
|
- cache_creation
|
||||||
- inference_geo
|
|
||||||
- server_tool_use
|
- server_tool_use
|
||||||
- service_tier
|
- service_tier
|
||||||
required:
|
required:
|
||||||
@@ -4495,7 +4492,6 @@ components:
|
|||||||
cache_creation_input_tokens: null
|
cache_creation_input_tokens: null
|
||||||
cache_read_input_tokens: null
|
cache_read_input_tokens: null
|
||||||
cache_creation: null
|
cache_creation: null
|
||||||
inference_geo: null
|
|
||||||
server_tool_use: null
|
server_tool_use: null
|
||||||
service_tier: standard
|
service_tier: standard
|
||||||
AnthropicMessagesStreamEvent:
|
AnthropicMessagesStreamEvent:
|
||||||
@@ -4816,9 +4812,6 @@ components:
|
|||||||
required:
|
required:
|
||||||
- ephemeral_5m_input_tokens
|
- ephemeral_5m_input_tokens
|
||||||
- ephemeral_1h_input_tokens
|
- ephemeral_1h_input_tokens
|
||||||
inference_geo:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
server_tool_use:
|
server_tool_use:
|
||||||
type: object
|
type: object
|
||||||
nullable: true
|
nullable: true
|
||||||
@@ -4841,7 +4834,6 @@ components:
|
|||||||
- cache_creation_input_tokens
|
- cache_creation_input_tokens
|
||||||
- cache_read_input_tokens
|
- cache_read_input_tokens
|
||||||
- cache_creation
|
- cache_creation
|
||||||
- inference_geo
|
|
||||||
- server_tool_use
|
- server_tool_use
|
||||||
- service_tier
|
- service_tier
|
||||||
required:
|
required:
|
||||||
@@ -4875,6 +4867,7 @@ components:
|
|||||||
- tool_use
|
- tool_use
|
||||||
- pause_turn
|
- pause_turn
|
||||||
- refusal
|
- refusal
|
||||||
|
- model_context_window_exceeded
|
||||||
x-speakeasy-unknown-values: allow
|
x-speakeasy-unknown-values: allow
|
||||||
stop_sequence:
|
stop_sequence:
|
||||||
type: string
|
type: string
|
||||||
@@ -6559,22 +6552,6 @@ components:
|
|||||||
- role
|
- role
|
||||||
- content
|
- content
|
||||||
description: Anthropic message with OpenRouter extensions
|
description: Anthropic message with OpenRouter extensions
|
||||||
AnthropicOutputConfig:
|
|
||||||
type: object
|
|
||||||
properties:
|
|
||||||
effort:
|
|
||||||
type: string
|
|
||||||
nullable: true
|
|
||||||
enum:
|
|
||||||
- low
|
|
||||||
- medium
|
|
||||||
- high
|
|
||||||
- max
|
|
||||||
description: >-
|
|
||||||
How much effort the model should put into its response. Higher effort levels may result in more thorough analysis but take longer. Valid values are `low`, `medium`, `high`, or `max`.
|
|
||||||
example: medium
|
|
||||||
x-speakeasy-unknown-values: allow
|
|
||||||
description: Configuration for controlling output behavior. Currently supports the effort parameter for Claude Opus 4.5.
|
|
||||||
AnthropicMessagesRequest:
|
AnthropicMessagesRequest:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -6993,14 +6970,6 @@ components:
|
|||||||
- disabled
|
- disabled
|
||||||
required:
|
required:
|
||||||
- type
|
- type
|
||||||
- type: object
|
|
||||||
properties:
|
|
||||||
type:
|
|
||||||
type: string
|
|
||||||
enum:
|
|
||||||
- adaptive
|
|
||||||
required:
|
|
||||||
- type
|
|
||||||
service_tier:
|
service_tier:
|
||||||
type: string
|
type: string
|
||||||
enum:
|
enum:
|
||||||
@@ -7213,8 +7182,6 @@ components:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
type: string
|
type: string
|
||||||
output_config:
|
|
||||||
$ref: '#/components/schemas/AnthropicOutputConfig'
|
|
||||||
required:
|
required:
|
||||||
- model
|
- model
|
||||||
- max_tokens
|
- max_tokens
|
||||||
@@ -7316,7 +7283,7 @@ components:
|
|||||||
description: Error data for ForbiddenResponse
|
description: Error data for ForbiddenResponse
|
||||||
example:
|
example:
|
||||||
code: 403
|
code: 403
|
||||||
message: Only management keys can perform this operation
|
message: Only provisioning keys can perform this operation
|
||||||
ForbiddenResponse:
|
ForbiddenResponse:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -7331,7 +7298,7 @@ components:
|
|||||||
example:
|
example:
|
||||||
error:
|
error:
|
||||||
code: 403
|
code: 403
|
||||||
message: Only management keys can perform this operation
|
message: Only provisioning keys can perform this operation
|
||||||
CreateChargeRequest:
|
CreateChargeRequest:
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
@@ -9275,8 +9242,6 @@ components:
|
|||||||
anyOf:
|
anyOf:
|
||||||
- type: string
|
- type: string
|
||||||
- type: number
|
- type: number
|
||||||
- type: array
|
|
||||||
items: {}
|
|
||||||
modalities:
|
modalities:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
@@ -9595,9 +9560,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
||||||
operationId: createResponses
|
operationId: createResponses
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/messages:
|
/messages:
|
||||||
post:
|
post:
|
||||||
x-speakeasy-ignore: true
|
x-speakeasy-ignore: true
|
||||||
@@ -9826,9 +9788,6 @@ paths:
|
|||||||
- type
|
- type
|
||||||
- error
|
- error
|
||||||
operationId: createMessages
|
operationId: createMessages
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/activity:
|
/activity:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -9836,7 +9795,7 @@ paths:
|
|||||||
operationId: getUserActivity
|
operationId: getUserActivity
|
||||||
summary: Get user activity grouped by endpoint
|
summary: Get user activity grouped by endpoint
|
||||||
description: >-
|
description: >-
|
||||||
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -9887,7 +9846,7 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/UnauthorizedResponse'
|
$ref: '#/components/schemas/UnauthorizedResponse'
|
||||||
'403':
|
'403':
|
||||||
description: Forbidden - Only management keys can fetch activity
|
description: Forbidden - Only provisioning keys can fetch activity
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
@@ -9898,9 +9857,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/credits:
|
/credits:
|
||||||
get:
|
get:
|
||||||
x-speakeasy-name-override: getCredits
|
x-speakeasy-name-override: getCredits
|
||||||
@@ -9909,7 +9865,7 @@ paths:
|
|||||||
summary: Get remaining credits
|
summary: Get remaining credits
|
||||||
operationId: getCredits
|
operationId: getCredits
|
||||||
description: >-
|
description: >-
|
||||||
Get total credits purchased and used for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Get total credits purchased and used for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
responses:
|
responses:
|
||||||
'200':
|
'200':
|
||||||
description: Returns the total credits purchased and used
|
description: Returns the total credits purchased and used
|
||||||
@@ -9949,7 +9905,7 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/UnauthorizedResponse'
|
$ref: '#/components/schemas/UnauthorizedResponse'
|
||||||
'403':
|
'403':
|
||||||
description: Forbidden - Only management keys can fetch credits
|
description: Forbidden - Only provisioning keys can fetch credits
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
@@ -9960,9 +9916,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/credits/coinbase:
|
/credits/coinbase:
|
||||||
post:
|
post:
|
||||||
security:
|
security:
|
||||||
@@ -10085,9 +10038,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/embeddings:
|
/embeddings:
|
||||||
post:
|
post:
|
||||||
x-speakeasy-name-override: generate
|
x-speakeasy-name-override: generate
|
||||||
@@ -10292,9 +10242,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
||||||
operationId: createEmbeddings
|
operationId: createEmbeddings
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/embeddings/models:
|
/embeddings/models:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10322,9 +10269,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: listEmbeddingsModels
|
operationId: listEmbeddingsModels
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/generation:
|
/generation:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10723,9 +10667,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
$ref: '#/components/schemas/ProviderOverloadedResponse'
|
||||||
operationId: getGeneration
|
operationId: getGeneration
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/models/count:
|
/models/count:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10746,9 +10687,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: listModelsCount
|
operationId: listModelsCount
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/models:
|
/models:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10803,9 +10741,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: getModels
|
operationId: getModels
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/models/user:
|
/models/user:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10842,9 +10777,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: listModelsUser
|
operationId: listModelsUser
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/models/{author}/{slug}/endpoints:
|
/models/{author}/{slug}/endpoints:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10887,9 +10819,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/endpoints/zdr:
|
/endpoints/zdr:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10917,9 +10846,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: listEndpointsZdr
|
operationId: listEndpointsZdr
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/providers:
|
/providers:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@@ -10981,9 +10907,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/keys:
|
/keys:
|
||||||
get:
|
get:
|
||||||
operationId: list
|
operationId: list
|
||||||
@@ -10992,7 +10915,7 @@ paths:
|
|||||||
- API Keys
|
- API Keys
|
||||||
summary: List API keys
|
summary: List API keys
|
||||||
description: >-
|
description: >-
|
||||||
List all API keys for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API keys for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11192,7 +11115,7 @@ paths:
|
|||||||
- API Keys
|
- API Keys
|
||||||
summary: Create a new API key
|
summary: Create a new API key
|
||||||
description: >-
|
description: >-
|
||||||
Create a new API key for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Create a new API key for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
requestBody:
|
requestBody:
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
@@ -11427,16 +11350,13 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: createKeys
|
operationId: createKeys
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/keys/{hash}:
|
/keys/{hash}:
|
||||||
patch:
|
patch:
|
||||||
x-speakeasy-name-override: update
|
x-speakeasy-name-override: update
|
||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Update an API key
|
summary: Update an API key
|
||||||
description: Update an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Update an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11679,7 +11599,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Delete an API key
|
summary: Delete an API key
|
||||||
description: Delete an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Delete an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11737,7 +11657,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- API Keys
|
- API Keys
|
||||||
summary: Get a single API key
|
summary: Get a single API key
|
||||||
description: Get a single API key by hash. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Get a single API key by hash. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -11927,9 +11847,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails:
|
/guardrails:
|
||||||
get:
|
get:
|
||||||
operationId: listGuardrails
|
operationId: listGuardrails
|
||||||
@@ -11938,7 +11855,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List guardrails
|
summary: List guardrails
|
||||||
description: >-
|
description: >-
|
||||||
List all guardrails for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all guardrails for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12095,7 +12012,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Create a guardrail
|
summary: Create a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Create a new guardrail for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Create a new guardrail for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
requestBody:
|
requestBody:
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
@@ -12302,9 +12219,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/{id}:
|
/guardrails/{id}:
|
||||||
get:
|
get:
|
||||||
operationId: getGuardrail
|
operationId: getGuardrail
|
||||||
@@ -12312,7 +12226,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Get a guardrail
|
summary: Get a guardrail
|
||||||
description: Get a single guardrail by ID. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Get a single guardrail by ID. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12459,7 +12373,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Update a guardrail
|
summary: Update a guardrail
|
||||||
description: Update an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Update an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12676,7 +12590,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Delete a guardrail
|
summary: Delete a guardrail
|
||||||
description: Delete an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
description: Delete an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12722,9 +12636,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/assignments/keys:
|
/guardrails/assignments/keys:
|
||||||
get:
|
get:
|
||||||
operationId: listKeyAssignments
|
operationId: listKeyAssignments
|
||||||
@@ -12733,7 +12644,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List all key assignments
|
summary: List all key assignments
|
||||||
description: >-
|
description: >-
|
||||||
List all API key guardrail assignments for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API key guardrail assignments for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12823,9 +12734,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/assignments/members:
|
/guardrails/assignments/members:
|
||||||
get:
|
get:
|
||||||
operationId: listMemberAssignments
|
operationId: listMemberAssignments
|
||||||
@@ -12834,7 +12742,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List all member assignments
|
summary: List all member assignments
|
||||||
description: >-
|
description: >-
|
||||||
List all organization member guardrail assignments for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all organization member guardrail assignments for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -12919,9 +12827,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/{id}/assignments/keys:
|
/guardrails/{id}/assignments/keys:
|
||||||
get:
|
get:
|
||||||
operationId: listGuardrailKeyAssignments
|
operationId: listGuardrailKeyAssignments
|
||||||
@@ -12930,7 +12835,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List key assignments for a guardrail
|
summary: List key assignments for a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
List all API key assignments for a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API key assignments for a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13042,7 +12947,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk assign keys to a guardrail
|
summary: Bulk assign keys to a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Assign multiple API keys to a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Assign multiple API keys to a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13109,9 +13014,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/{id}/assignments/members:
|
/guardrails/{id}/assignments/members:
|
||||||
get:
|
get:
|
||||||
operationId: listGuardrailMemberAssignments
|
operationId: listGuardrailMemberAssignments
|
||||||
@@ -13120,7 +13022,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: List member assignments for a guardrail
|
summary: List member assignments for a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
List all organization member assignments for a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all organization member assignments for a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13227,7 +13129,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk assign members to a guardrail
|
summary: Bulk assign members to a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Assign multiple organization members to a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Assign multiple organization members to a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13295,9 +13197,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/{id}/assignments/keys/remove:
|
/guardrails/{id}/assignments/keys/remove:
|
||||||
post:
|
post:
|
||||||
operationId: bulkUnassignKeysFromGuardrail
|
operationId: bulkUnassignKeysFromGuardrail
|
||||||
@@ -13306,7 +13205,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk unassign keys from a guardrail
|
summary: Bulk unassign keys from a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Unassign multiple API keys from a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Unassign multiple API keys from a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13373,9 +13272,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/guardrails/{id}/assignments/members/remove:
|
/guardrails/{id}/assignments/members/remove:
|
||||||
post:
|
post:
|
||||||
operationId: bulkUnassignMembersFromGuardrail
|
operationId: bulkUnassignMembersFromGuardrail
|
||||||
@@ -13384,7 +13280,7 @@ paths:
|
|||||||
- Guardrails
|
- Guardrails
|
||||||
summary: Bulk unassign members from a guardrail
|
summary: Bulk unassign members from a guardrail
|
||||||
description: >-
|
description: >-
|
||||||
Unassign multiple organization members from a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Unassign multiple organization members from a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
parameters:
|
parameters:
|
||||||
- schema:
|
- schema:
|
||||||
type: string
|
type: string
|
||||||
@@ -13452,9 +13348,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/key:
|
/key:
|
||||||
get:
|
get:
|
||||||
operationId: getCurrentKey
|
operationId: getCurrentKey
|
||||||
@@ -13519,14 +13412,9 @@ paths:
|
|||||||
type: boolean
|
type: boolean
|
||||||
description: Whether this is a free tier API key
|
description: Whether this is a free tier API key
|
||||||
example: false
|
example: false
|
||||||
is_management_key:
|
|
||||||
type: boolean
|
|
||||||
description: Whether this is a management key
|
|
||||||
example: false
|
|
||||||
is_provisioning_key:
|
is_provisioning_key:
|
||||||
type: boolean
|
type: boolean
|
||||||
description: Whether this is a management key
|
description: Whether this is a provisioning key
|
||||||
deprecated: true
|
|
||||||
example: false
|
example: false
|
||||||
limit_remaining:
|
limit_remaining:
|
||||||
type: number
|
type: number
|
||||||
@@ -13585,7 +13473,6 @@ paths:
|
|||||||
- byok_usage_weekly
|
- byok_usage_weekly
|
||||||
- byok_usage_monthly
|
- byok_usage_monthly
|
||||||
- is_free_tier
|
- is_free_tier
|
||||||
- is_management_key
|
|
||||||
- is_provisioning_key
|
- is_provisioning_key
|
||||||
- limit_remaining
|
- limit_remaining
|
||||||
- limit_reset
|
- limit_reset
|
||||||
@@ -13604,7 +13491,6 @@ paths:
|
|||||||
byok_usage_weekly: 17.38
|
byok_usage_weekly: 17.38
|
||||||
byok_usage_monthly: 17.38
|
byok_usage_monthly: 17.38
|
||||||
is_free_tier: false
|
is_free_tier: false
|
||||||
is_management_key: false
|
|
||||||
is_provisioning_key: false
|
is_provisioning_key: false
|
||||||
limit_remaining: 74.5
|
limit_remaining: 74.5
|
||||||
limit_reset: monthly
|
limit_reset: monthly
|
||||||
@@ -13629,7 +13515,6 @@ paths:
|
|||||||
byok_usage_weekly: 17.38
|
byok_usage_weekly: 17.38
|
||||||
byok_usage_monthly: 17.38
|
byok_usage_monthly: 17.38
|
||||||
is_free_tier: false
|
is_free_tier: false
|
||||||
is_management_key: false
|
|
||||||
is_provisioning_key: false
|
is_provisioning_key: false
|
||||||
limit_remaining: 74.5
|
limit_remaining: 74.5
|
||||||
limit_reset: monthly
|
limit_reset: monthly
|
||||||
@@ -13651,9 +13536,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/auth/keys:
|
/auth/keys:
|
||||||
post:
|
post:
|
||||||
operationId: exchangeAuthCodeForAPIKey
|
operationId: exchangeAuthCodeForAPIKey
|
||||||
@@ -13732,9 +13614,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/auth/keys/code:
|
/auth/keys/code:
|
||||||
post:
|
post:
|
||||||
x-speakeasy-name-override: createAuthCode
|
x-speakeasy-name-override: createAuthCode
|
||||||
@@ -13836,9 +13715,6 @@ paths:
|
|||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/InternalServerResponse'
|
$ref: '#/components/schemas/InternalServerResponse'
|
||||||
operationId: createAuthKeysCode
|
operationId: createAuthKeysCode
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
/chat/completions:
|
/chat/completions:
|
||||||
post:
|
post:
|
||||||
summary: Create a chat completion
|
summary: Create a chat completion
|
||||||
@@ -13893,9 +13769,6 @@ paths:
|
|||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/components/schemas/ChatError'
|
$ref: '#/components/schemas/ChatError'
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
servers:
|
servers:
|
||||||
- url: https://openrouter.ai/api/v1
|
- url: https://openrouter.ai/api/v1
|
||||||
description: Production server
|
description: Production server
|
||||||
|
|||||||
@@ -33,11 +33,3 @@ actions:
|
|||||||
type: string
|
type: string
|
||||||
description: |
|
description: |
|
||||||
The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
||||||
|
|
||||||
# Add header parameters to all paths so Speakeasy matches them with globals
|
|
||||||
- target: $.paths[*]
|
|
||||||
description: Reference app identification headers on all paths so Speakeasy injects them via globals
|
|
||||||
update:
|
|
||||||
parameters:
|
|
||||||
- $ref: "#/components/parameters/AppIdentifier"
|
|
||||||
- $ref: "#/components/parameters/AppDisplayName"
|
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ sources:
|
|||||||
- latest
|
- latest
|
||||||
OpenRouter API:
|
OpenRouter API:
|
||||||
sourceNamespace: open-router-chat-completions-api
|
sourceNamespace: open-router-chat-completions-api
|
||||||
sourceRevisionDigest: sha256:2dbe784978f60cb53a0d081e1b5f4cbb42ca86b1ff8f4361869fa78c42e042ee
|
sourceRevisionDigest: sha256:5a70452e80a4866581d37c656017d24be6d65f95748f11f4f1dc0e7e141d2bdb
|
||||||
sourceBlobDigest: sha256:851aadf3180735f9dbfdb2904011de231d3805d187499c24a450a224cacf1ed2
|
sourceBlobDigest: sha256:51b950d5a574b3b01e723aaa5bf02223c33b8ed92f749728653a4a4312d8f7c0
|
||||||
tags:
|
tags:
|
||||||
- latest
|
- latest
|
||||||
- main
|
- main
|
||||||
@@ -18,10 +18,10 @@ targets:
|
|||||||
open-router:
|
open-router:
|
||||||
source: OpenRouter API
|
source: OpenRouter API
|
||||||
sourceNamespace: open-router-chat-completions-api
|
sourceNamespace: open-router-chat-completions-api
|
||||||
sourceRevisionDigest: sha256:2dbe784978f60cb53a0d081e1b5f4cbb42ca86b1ff8f4361869fa78c42e042ee
|
sourceRevisionDigest: sha256:5a70452e80a4866581d37c656017d24be6d65f95748f11f4f1dc0e7e141d2bdb
|
||||||
sourceBlobDigest: sha256:851aadf3180735f9dbfdb2904011de231d3805d187499c24a450a224cacf1ed2
|
sourceBlobDigest: sha256:51b950d5a574b3b01e723aaa5bf02223c33b8ed92f749728653a4a4312d8f7c0
|
||||||
codeSamplesNamespace: open-router-python-code-samples
|
codeSamplesNamespace: open-router-python-code-samples
|
||||||
codeSamplesRevisionDigest: sha256:cf9f3fd9983864e3c5dd5bc3fa9198efc9493f4fbc671130e8f07e87722c43dd
|
codeSamplesRevisionDigest: sha256:bc0c0939ef451d21d3e6a1d4be4cd452012f2bb1547b25a2eb9f0b89445bf408
|
||||||
workflow:
|
workflow:
|
||||||
workflowVersion: 1.0.0
|
workflowVersion: 1.0.0
|
||||||
speakeasyVersion: 1.666.0
|
speakeasyVersion: 1.666.0
|
||||||
|
|||||||
@@ -182,8 +182,6 @@ import os
|
|||||||
def main():
|
def main():
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
# Rest of application here...
|
# Rest of application here...
|
||||||
@@ -193,8 +191,6 @@ def main():
|
|||||||
async def amain():
|
async def amain():
|
||||||
|
|
||||||
async with OpenRouter(
|
async with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
# Rest of application here...
|
# Rest of application here...
|
||||||
|
|||||||
@@ -6,8 +6,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -32,8 +30,6 @@ import os
|
|||||||
async def main():
|
async def main():
|
||||||
|
|
||||||
async with OpenRouter(
|
async with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
|
|||||||
@@ -15,9 +15,3 @@ value: str = /* values here */
|
|||||||
value: float = /* values here */
|
value: float = /* values here */
|
||||||
```
|
```
|
||||||
|
|
||||||
### `List[Any]`
|
|
||||||
|
|
||||||
```python
|
|
||||||
value: List[Any] = /* values here */
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|||||||
@@ -7,5 +7,5 @@ Forbidden - Authentication successful but insufficient permissions
|
|||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ |
|
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ |
|
||||||
| `error` | [components.ForbiddenResponseErrorData](../components/forbiddenresponseerrordata.md) | :heavy_check_mark: | Error data for ForbiddenResponse | {<br/>"code": 403,<br/>"message": "Only management keys can perform this operation"<br/>} |
|
| `error` | [components.ForbiddenResponseErrorData](../components/forbiddenresponseerrordata.md) | :heavy_check_mark: | Error data for ForbiddenResponse | {<br/>"code": 403,<br/>"message": "Only provisioning keys can perform this operation"<br/>} |
|
||||||
| `user_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | |
|
| `user_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# BulkAssignKeysToGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `request_body` | [operations.BulkAssignKeysToGuardrailRequestBody](../operations/bulkassignkeystoguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
| `request_body` | [operations.BulkAssignKeysToGuardrailRequestBody](../operations/bulkassignkeystoguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# BulkAssignMembersToGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `request_body` | [operations.BulkAssignMembersToGuardrailRequestBody](../operations/bulkassignmemberstoguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
| `request_body` | [operations.BulkAssignMembersToGuardrailRequestBody](../operations/bulkassignmemberstoguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# BulkUnassignKeysFromGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `request_body` | [operations.BulkUnassignKeysFromGuardrailRequestBody](../operations/bulkunassignkeysfromguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
| `request_body` | [operations.BulkUnassignKeysFromGuardrailRequestBody](../operations/bulkunassignkeysfromguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# BulkUnassignMembersFromGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `request_body` | [operations.BulkUnassignMembersFromGuardrailRequestBody](../operations/bulkunassignmembersfromguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
| `request_body` | [operations.BulkUnassignMembersFromGuardrailRequestBody](../operations/bulkunassignmembersfromguardrailrequestbody.md) | :heavy_check_mark: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateAuthKeysCodeGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,9 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
| `callback_url` | *str* | :heavy_check_mark: | The callback URL to redirect to after authorization. Note, only https URLs on ports 443 and 3000 are allowed. | https://myapp.com/auth/callback |
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
| `code_challenge` | *Optional[str]* | :heavy_minus_sign: | PKCE code challenge for enhanced security | E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM |
|
||||||
| `request_body` | [operations.CreateAuthKeysCodeRequestBody](../operations/createauthkeyscoderequestbody.md) | :heavy_check_mark: | N/A | {<br/>"callback_url": "https://myapp.com/auth/callback",<br/>"code_challenge": "E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM",<br/>"code_challenge_method": "S256",<br/>"limit": 100<br/>} |
|
| `code_challenge_method` | [Optional[operations.CreateAuthKeysCodeCodeChallengeMethod]](../operations/createauthkeyscodecodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
||||||
|
| `limit` | *Optional[float]* | :heavy_minus_sign: | Credit limit for the API key to be created | 100 |
|
||||||
|
| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Optional expiration time for the API key to be created | |
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
# CreateAuthKeysCodeRequestBody
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `callback_url` | *str* | :heavy_check_mark: | The callback URL to redirect to after authorization. Note, only https URLs on ports 443 and 3000 are allowed. | https://myapp.com/auth/callback |
|
|
||||||
| `code_challenge` | *Optional[str]* | :heavy_minus_sign: | PKCE code challenge for enhanced security | E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM |
|
|
||||||
| `code_challenge_method` | [Optional[operations.CreateAuthKeysCodeCodeChallengeMethod]](../operations/createauthkeyscodecodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
|
||||||
| `limit` | *Optional[float]* | :heavy_minus_sign: | Credit limit for the API key to be created | 100 |
|
|
||||||
| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Optional expiration time for the API key to be created | |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateCoinbaseChargeGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
# CreateCoinbaseChargeRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `create_charge_request` | [components.CreateChargeRequest](../components/createchargerequest.md) | :heavy_check_mark: | N/A | {<br/>"amount": 100,<br/>"sender": "0x1234567890123456789012345678901234567890",<br/>"chain_id": 1<br/>} |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateEmbeddingsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,11 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
| `input` | [operations.InputUnion](../operations/inputunion.md) | :heavy_check_mark: | N/A |
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
| `model` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `request_body` | [operations.CreateEmbeddingsRequestBody](../operations/createembeddingsrequestbody.md) | :heavy_check_mark: | N/A |
|
| `encoding_format` | [Optional[operations.EncodingFormat]](../operations/encodingformat.md) | :heavy_minus_sign: | N/A |
|
||||||
|
| `dimensions` | *Optional[int]* | :heavy_minus_sign: | N/A |
|
||||||
|
| `user` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
||||||
|
| `provider` | [Optional[components.ProviderPreferences]](../components/providerpreferences.md) | :heavy_minus_sign: | Provider routing preferences for the request. |
|
||||||
|
| `input_type` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
# CreateEmbeddingsRequestBody
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
|
|
||||||
| `input` | [operations.InputUnion](../operations/inputunion.md) | :heavy_check_mark: | N/A |
|
|
||||||
| `model` | *str* | :heavy_check_mark: | N/A |
|
|
||||||
| `encoding_format` | [Optional[operations.EncodingFormat]](../operations/encodingformat.md) | :heavy_minus_sign: | N/A |
|
|
||||||
| `dimensions` | *Optional[int]* | :heavy_minus_sign: | N/A |
|
|
||||||
| `user` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
|
||||||
| `provider` | [Optional[components.ProviderPreferences]](../components/providerpreferences.md) | :heavy_minus_sign: | Provider routing preferences for the request. |
|
|
||||||
| `input_type` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,11 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
| `name` | *str* | :heavy_check_mark: | Name for the new guardrail | My New Guardrail |
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Description of the guardrail | A guardrail for limiting API usage |
|
||||||
| `request_body` | [operations.CreateGuardrailRequestBody](../operations/createguardrailrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "My New Guardrail",<br/>"description": "A guardrail for limiting API usage",<br/>"limit_usd": 50,<br/>"reset_interval": "monthly",<br/>"allowed_providers": [<br/>"openai",<br/>"anthropic",<br/>"deepseek"<br/>],<br/>"allowed_models": null,<br/>"enforce_zdr": false<br/>} |
|
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | Spending limit in USD | 50 |
|
||||||
|
| `reset_interval` | [OptionalNullable[operations.CreateGuardrailResetIntervalRequest]](../operations/createguardrailresetintervalrequest.md) | :heavy_minus_sign: | Interval at which the limit resets (daily, weekly, monthly) | monthly |
|
||||||
|
| `allowed_providers` | List[*str*] | :heavy_minus_sign: | List of allowed provider IDs | [<br/>"openai",<br/>"anthropic",<br/>"deepseek"<br/>] |
|
||||||
|
| `allowed_models` | List[*str*] | :heavy_minus_sign: | Array of model identifiers (slug or canonical_slug accepted) | [<br/>"openai/gpt-5.2",<br/>"anthropic/claude-4.5-opus-20251124",<br/>"deepseek/deepseek-r1-0528:free"<br/>] |
|
||||||
|
| `enforce_zdr` | *OptionalNullable[bool]* | :heavy_minus_sign: | Whether to enforce zero data retention | false |
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
# CreateGuardrailRequestBody
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
|
|
||||||
| `name` | *str* | :heavy_check_mark: | Name for the new guardrail | My New Guardrail |
|
|
||||||
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Description of the guardrail | A guardrail for limiting API usage |
|
|
||||||
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | Spending limit in USD | 50 |
|
|
||||||
| `reset_interval` | [OptionalNullable[operations.CreateGuardrailResetIntervalRequest]](../operations/createguardrailresetintervalrequest.md) | :heavy_minus_sign: | Interval at which the limit resets (daily, weekly, monthly) | monthly |
|
|
||||||
| `allowed_providers` | List[*str*] | :heavy_minus_sign: | List of allowed provider IDs | [<br/>"openai",<br/>"anthropic",<br/>"deepseek"<br/>] |
|
|
||||||
| `allowed_models` | List[*str*] | :heavy_minus_sign: | Array of model identifiers (slug or canonical_slug accepted) | [<br/>"openai/gpt-5.2",<br/>"anthropic/claude-4.5-opus-20251124",<br/>"deepseek/deepseek-r1-0528:free"<br/>] |
|
|
||||||
| `enforce_zdr` | *OptionalNullable[bool]* | :heavy_minus_sign: | Whether to enforce zero data retention | false |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateKeysGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,9 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
| `name` | *str* | :heavy_check_mark: | Name for the new API key | My New API Key |
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | Optional spending limit for the API key in USD | 50 |
|
||||||
| `request_body` | [operations.CreateKeysRequestBody](../operations/createkeysrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "My New API Key",<br/>"limit": 50,<br/>"limit_reset": "monthly",<br/>"include_byok_in_limit": true,<br/>"expires_at": "2027-12-31T23:59:59Z"<br/>} |
|
| `limit_reset` | [OptionalNullable[operations.CreateKeysLimitReset]](../operations/createkeyslimitreset.md) | :heavy_minus_sign: | Type of limit reset for the API key (daily, weekly, monthly, or null for no reset). Resets happen automatically at midnight UTC, and weeks are Monday through Sunday. | monthly |
|
||||||
|
| `include_byok_in_limit` | *Optional[bool]* | :heavy_minus_sign: | Whether to include BYOK usage in the limit | true |
|
||||||
|
| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Optional ISO 8601 UTC timestamp when the API key should expire. Must be UTC, other timezones will be rejected | 2027-12-31T23:59:59Z |
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
# CreateKeysRequestBody
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `name` | *str* | :heavy_check_mark: | Name for the new API key | My New API Key |
|
|
||||||
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | Optional spending limit for the API key in USD | 50 |
|
|
||||||
| `limit_reset` | [OptionalNullable[operations.CreateKeysLimitReset]](../operations/createkeyslimitreset.md) | :heavy_minus_sign: | Type of limit reset for the API key (daily, weekly, monthly, or null for no reset). Resets happen automatically at midnight UTC, and weeks are Monday through Sunday. | monthly |
|
|
||||||
| `include_byok_in_limit` | *Optional[bool]* | :heavy_minus_sign: | Whether to include BYOK usage in the limit | true |
|
|
||||||
| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Optional ISO 8601 UTC timestamp when the API key should expire. Must be UTC, other timezones will be rejected | 2027-12-31T23:59:59Z |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# CreateResponsesGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
# CreateResponsesRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `open_responses_request` | [components.OpenResponsesRequest](../components/openresponsesrequest.md) | :heavy_check_mark: | N/A | {<br/>"model": "anthropic/claude-4.5-sonnet-20250929",<br/>"input": [<br/>{<br/>"type": "message",<br/>"content": "Hello, how are you?",<br/>"role": "user"<br/>}<br/>],<br/>"temperature": 0.7,<br/>"top_p": 0.9,<br/>"tools": [<br/>{<br/>"type": "function",<br/>"name": "get_current_weather",<br/>"description": "Get the current weather in a given location",<br/>"parameters": {<br/>"type": "object",<br/>"properties": {<br/>"location": {<br/>"type": "string"<br/>}<br/>}<br/>}<br/>}<br/>]<br/>} |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# DeleteGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to delete | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to delete | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# DeleteKeysGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to delete | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to delete | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ExchangeAuthCodeForAPIKeyGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,7 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
| `code` | *str* | :heavy_check_mark: | The authorization code received from the OAuth redirect | auth_code_abc123def456 |
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
| `code_verifier` | *Optional[str]* | :heavy_minus_sign: | The code verifier if code_challenge was used in the authorization request | dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk |
|
||||||
| `request_body` | [operations.ExchangeAuthCodeForAPIKeyRequestBody](../operations/exchangeauthcodeforapikeyrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"code": "auth_code_abc123def456",<br/>"code_verifier": "dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk",<br/>"code_challenge_method": "S256"<br/>} |
|
| `code_challenge_method` | [OptionalNullable[operations.ExchangeAuthCodeForAPIKeyCodeChallengeMethod]](../operations/exchangeauthcodeforapikeycodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
# ExchangeAuthCodeForAPIKeyRequestBody
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
||||||
| `code` | *str* | :heavy_check_mark: | The authorization code received from the OAuth redirect | auth_code_abc123def456 |
|
|
||||||
| `code_verifier` | *Optional[str]* | :heavy_minus_sign: | The code verifier if code_challenge was used in the authorization request | dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk |
|
|
||||||
| `code_challenge_method` | [OptionalNullable[operations.ExchangeAuthCodeForAPIKeyCodeChallengeMethod]](../operations/exchangeauthcodeforapikeycodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetCreditsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetCreditsRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -18,8 +18,7 @@ Current API key information
|
|||||||
| `byok_usage_weekly` | *float* | :heavy_check_mark: | External BYOK usage (in USD) for the current UTC week (Monday-Sunday) | 17.38 |
|
| `byok_usage_weekly` | *float* | :heavy_check_mark: | External BYOK usage (in USD) for the current UTC week (Monday-Sunday) | 17.38 |
|
||||||
| `byok_usage_monthly` | *float* | :heavy_check_mark: | External BYOK usage (in USD) for current UTC month | 17.38 |
|
| `byok_usage_monthly` | *float* | :heavy_check_mark: | External BYOK usage (in USD) for current UTC month | 17.38 |
|
||||||
| `is_free_tier` | *bool* | :heavy_check_mark: | Whether this is a free tier API key | false |
|
| `is_free_tier` | *bool* | :heavy_check_mark: | Whether this is a free tier API key | false |
|
||||||
| `is_management_key` | *bool* | :heavy_check_mark: | Whether this is a management key | false |
|
| `is_provisioning_key` | *bool* | :heavy_check_mark: | Whether this is a provisioning key | false |
|
||||||
| ~~`is_provisioning_key`~~ | *bool* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.<br/><br/>Whether this is a management key | false |
|
|
||||||
| `limit_remaining` | *Nullable[float]* | :heavy_check_mark: | Remaining spending limit in USD | 74.5 |
|
| `limit_remaining` | *Nullable[float]* | :heavy_check_mark: | Remaining spending limit in USD | 74.5 |
|
||||||
| `limit_reset` | *Nullable[str]* | :heavy_check_mark: | Type of limit reset for the API key | monthly |
|
| `limit_reset` | *Nullable[str]* | :heavy_check_mark: | Type of limit reset for the API key | monthly |
|
||||||
| `include_byok_in_limit` | *bool* | :heavy_check_mark: | Whether to include external BYOK usage in the credit limit | false |
|
| `include_byok_in_limit` | *bool* | :heavy_check_mark: | Whether to include external BYOK usage in the credit limit | false |
|
||||||
|
|||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetCurrentKeyGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetCurrentKeyRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -6,5 +6,5 @@ API key details
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `data` | [operations.GetCurrentKeyData](../operations/getcurrentkeydata.md) | :heavy_check_mark: | Current API key information | {<br/>"label": "sk-or-v1-au7...890",<br/>"limit": 100,<br/>"usage": 25.5,<br/>"usage_daily": 25.5,<br/>"usage_weekly": 25.5,<br/>"usage_monthly": 25.5,<br/>"byok_usage": 17.38,<br/>"byok_usage_daily": 17.38,<br/>"byok_usage_weekly": 17.38,<br/>"byok_usage_monthly": 17.38,<br/>"is_free_tier": false,<br/>"is_management_key": false,<br/>"is_provisioning_key": false,<br/>"limit_remaining": 74.5,<br/>"limit_reset": "monthly",<br/>"include_byok_in_limit": false,<br/>"expires_at": "2027-12-31T23:59:59Z",<br/>"rate_limit": {<br/>"requests": 1000,<br/>"interval": "1h",<br/>"note": "This field is deprecated and safe to ignore."<br/>}<br/>} |
|
| `data` | [operations.GetCurrentKeyData](../operations/getcurrentkeydata.md) | :heavy_check_mark: | Current API key information | {<br/>"label": "sk-or-v1-au7...890",<br/>"limit": 100,<br/>"usage": 25.5,<br/>"usage_daily": 25.5,<br/>"usage_weekly": 25.5,<br/>"usage_monthly": 25.5,<br/>"byok_usage": 17.38,<br/>"byok_usage_daily": 17.38,<br/>"byok_usage_weekly": 17.38,<br/>"byok_usage_monthly": 17.38,<br/>"is_free_tier": false,<br/>"is_provisioning_key": false,<br/>"limit_remaining": 74.5,<br/>"limit_reset": "monthly",<br/>"include_byok_in_limit": false,<br/>"expires_at": "2027-12-31T23:59:59Z",<br/>"rate_limit": {<br/>"requests": 1000,<br/>"interval": "1h",<br/>"note": "This field is deprecated and safe to ignore."<br/>}<br/>} |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetGenerationGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------ | ------------------ | ------------------ | ------------------ |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | N/A |
|
| `id` | *str* | :heavy_check_mark: | N/A |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to retrieve | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to retrieve | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetKeyGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to retrieve | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to retrieve | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetModelsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `category` | [Optional[operations.Category]](../operations/category.md) | :heavy_minus_sign: | Filter models by use case category | programming |
|
| `category` | [Optional[operations.Category]](../operations/category.md) | :heavy_minus_sign: | Filter models by use case category | programming |
|
||||||
| `supported_parameters` | *Optional[str]* | :heavy_minus_sign: | N/A | |
|
| `supported_parameters` | *Optional[str]* | :heavy_minus_sign: | N/A | |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# GetUserActivityGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,7 +4,5 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `date_` | *Optional[str]* | :heavy_minus_sign: | Filter by a single UTC date in the last 30 days (YYYY-MM-DD format). | 2025-08-24 |
|
| `date_` | *Optional[str]* | :heavy_minus_sign: | Filter by a single UTC date in the last 30 days (YYYY-MM-DD format). | 2025-08-24 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListEmbeddingsModelsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListEmbeddingsModelsRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListEndpointsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------ | ------------------ | ------------------ | ------------------ |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `author` | *str* | :heavy_check_mark: | N/A |
|
| `author` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `slug` | *str* | :heavy_check_mark: | N/A |
|
| `slug` | *str* | :heavy_check_mark: | N/A |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListEndpointsZdrGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListEndpointsZdrRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListGuardrailKeyAssignmentsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,9 +4,7 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListGuardrailMemberAssignmentsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,9 +4,7 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListGuardrailsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListKeyAssignmentsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListMemberAssignmentsGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListModelsCountGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListModelsCountRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListModelsUserGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListModelsUserRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListProvidersGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# ListProvidersRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `include_disabled` | *Optional[str]* | :heavy_minus_sign: | Whether to include disabled API keys in the response | false |
|
| `include_disabled` | *Optional[str]* | :heavy_minus_sign: | Whether to include disabled API keys in the response | false |
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of API keys to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of API keys to skip for pagination | 0 |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# SendChatCompletionRequestGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
# SendChatCompletionRequestRequest
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `chat_generation_params` | [components.ChatGenerationParams](../components/chatgenerationparams.md) | :heavy_check_mark: | Chat completion request parameters |
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# UpdateGuardrailGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to update | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to update | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `request_body` | [operations.UpdateGuardrailRequestBody](../operations/updateguardrailrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "Updated Guardrail Name",<br/>"description": "Updated description",<br/>"limit_usd": 75,<br/>"reset_interval": "weekly"<br/>} |
|
| `request_body` | [operations.UpdateGuardrailRequestBody](../operations/updateguardrailrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "Updated Guardrail Name",<br/>"description": "Updated description",<br/>"limit_usd": 75,<br/>"reset_interval": "weekly"<br/>} |
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
# UpdateKeysGlobals
|
|
||||||
|
|
||||||
|
|
||||||
## Fields
|
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
@@ -4,8 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to update | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to update | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
| `request_body` | [operations.UpdateKeysRequestBody](../operations/updatekeysrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "Updated API Key Name",<br/>"disabled": false,<br/>"limit": 75,<br/>"limit_reset": "daily",<br/>"include_byok_in_limit": true<br/>} |
|
| `request_body` | [operations.UpdateKeysRequestBody](../operations/updatekeysrequestbody.md) | :heavy_check_mark: | N/A | {<br/>"name": "Updated API Key Name",<br/>"disabled": false,<br/>"limit": 75,<br/>"limit_reset": "daily",<br/>"include_byok_in_limit": true<br/>} |
|
||||||
@@ -11,7 +11,7 @@ Analytics and usage endpoints
|
|||||||
|
|
||||||
## get_user_activity
|
## get_user_activity
|
||||||
|
|
||||||
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Returns user activity data grouped by endpoint for the last 30 (completed) UTC days. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -22,8 +22,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -37,9 +35,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `date_` | *Optional[str]* | :heavy_minus_sign: | Filter by a single UTC date in the last 30 days (YYYY-MM-DD format). | 2025-08-24 |
|
| `date_` | *Optional[str]* | :heavy_minus_sign: | Filter by a single UTC date in the last 30 days (YYYY-MM-DD format). | 2025-08-24 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ API key management endpoints
|
|||||||
|
|
||||||
## list
|
## list
|
||||||
|
|
||||||
List all API keys for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API keys for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -27,8 +27,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -42,9 +40,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `include_disabled` | *Optional[str]* | :heavy_minus_sign: | Whether to include disabled API keys in the response | false |
|
| `include_disabled` | *Optional[str]* | :heavy_minus_sign: | Whether to include disabled API keys in the response | false |
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of API keys to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of API keys to skip for pagination | 0 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -64,7 +60,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## create
|
## create
|
||||||
|
|
||||||
Create a new API key for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Create a new API key for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -75,8 +71,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -92,8 +86,6 @@ with OpenRouter(
|
|||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `name` | *str* | :heavy_check_mark: | Name for the new API key | My New API Key |
|
| `name` | *str* | :heavy_check_mark: | Name for the new API key | My New API Key |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | Optional spending limit for the API key in USD | 50 |
|
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | Optional spending limit for the API key in USD | 50 |
|
||||||
| `limit_reset` | [OptionalNullable[operations.CreateKeysLimitReset]](../../operations/createkeyslimitreset.md) | :heavy_minus_sign: | Type of limit reset for the API key (daily, weekly, monthly, or null for no reset). Resets happen automatically at midnight UTC, and weeks are Monday through Sunday. | monthly |
|
| `limit_reset` | [OptionalNullable[operations.CreateKeysLimitReset]](../../operations/createkeyslimitreset.md) | :heavy_minus_sign: | Type of limit reset for the API key (daily, weekly, monthly, or null for no reset). Resets happen automatically at midnight UTC, and weeks are Monday through Sunday. | monthly |
|
||||||
| `include_byok_in_limit` | *Optional[bool]* | :heavy_minus_sign: | Whether to include BYOK usage in the limit | true |
|
| `include_byok_in_limit` | *Optional[bool]* | :heavy_minus_sign: | Whether to include BYOK usage in the limit | true |
|
||||||
@@ -116,7 +108,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## update
|
## update
|
||||||
|
|
||||||
Update an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Update an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -127,8 +119,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -144,8 +134,6 @@ with OpenRouter(
|
|||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to update | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to update | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `name` | *Optional[str]* | :heavy_minus_sign: | New name for the API key | Updated API Key Name |
|
| `name` | *Optional[str]* | :heavy_minus_sign: | New name for the API key | Updated API Key Name |
|
||||||
| `disabled` | *Optional[bool]* | :heavy_minus_sign: | Whether to disable the API key | false |
|
| `disabled` | *Optional[bool]* | :heavy_minus_sign: | Whether to disable the API key | false |
|
||||||
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | New spending limit for the API key in USD | 75 |
|
| `limit` | *OptionalNullable[float]* | :heavy_minus_sign: | New spending limit for the API key in USD | 75 |
|
||||||
@@ -170,7 +158,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## delete
|
## delete
|
||||||
|
|
||||||
Delete an existing API key. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Delete an existing API key. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -181,8 +169,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -196,10 +182,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to delete | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to delete | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -218,7 +202,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## get
|
## get
|
||||||
|
|
||||||
Get a single API key by hash. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Get a single API key by hash. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -229,8 +213,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -244,10 +226,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to retrieve | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
| `hash` | *str* | :heavy_check_mark: | The hash identifier of the API key to retrieve | f01d52606dc8f0a8303a7b5cc3fa07109c2e346cec7c0a16b40de462992ce943 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -277,8 +257,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -292,9 +270,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -20,8 +20,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -37,10 +35,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ |
|
||||||
| `messages` | List[[components.Message](../../components/message.md)] | :heavy_check_mark: | N/A |
|
| `messages` | List[[components.Message](../../components/message.md)] | :heavy_check_mark: | N/A |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `provider` | [OptionalNullable[components.Schema0]](../../components/schema0.md) | :heavy_minus_sign: | N/A |
|
| `provider` | [OptionalNullable[components.Schema0]](../../components/schema0.md) | :heavy_minus_sign: | N/A |
|
||||||
| `plugins` | List[[components.Schema17](../../components/schema17.md)] | :heavy_minus_sign: | N/A |
|
| `plugins` | List[[components.Schema17](../../components/schema17.md)] | :heavy_minus_sign: | N/A |
|
||||||
| `route` | [OptionalNullable[components.Route]](../../components/route.md) | :heavy_minus_sign: | N/A |
|
| `route` | [OptionalNullable[components.Route]](../../components/route.md) | :heavy_minus_sign: | N/A |
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ Credit management endpoints
|
|||||||
|
|
||||||
## get_credits
|
## get_credits
|
||||||
|
|
||||||
Get total credits purchased and used for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Get total credits purchased and used for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -23,8 +23,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -38,9 +36,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -68,10 +64,7 @@ from openrouter import OpenRouter, operations
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter() as open_router:
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
) as open_router:
|
|
||||||
|
|
||||||
res = open_router.credits.create_coinbase_charge(security=operations.CreateCoinbaseChargeSecurity(
|
res = open_router.credits.create_coinbase_charge(security=operations.CreateCoinbaseChargeSecurity(
|
||||||
bearer=os.getenv("OPENROUTER_BEARER", ""),
|
bearer=os.getenv("OPENROUTER_BEARER", ""),
|
||||||
@@ -85,13 +78,11 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------- |
|
||||||
| `security` | [operations.CreateCoinbaseChargeSecurity](../../operations/createcoinbasechargesecurity.md) | :heavy_check_mark: | N/A |
|
| `security` | [operations.CreateCoinbaseChargeSecurity](../../operations/createcoinbasechargesecurity.md) | :heavy_check_mark: | N/A |
|
||||||
| `amount` | *float* | :heavy_check_mark: | N/A |
|
| `amount` | *float* | :heavy_check_mark: | N/A |
|
||||||
| `sender` | *str* | :heavy_check_mark: | N/A |
|
| `sender` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `chain_id` | [components.ChainID](../../components/chainid.md) | :heavy_check_mark: | N/A |
|
| `chain_id` | [components.ChainID](../../components/chainid.md) | :heavy_check_mark: | N/A |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -23,8 +23,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -38,11 +36,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- |
|
||||||
| `input` | [operations.InputUnion](../../operations/inputunion.md) | :heavy_check_mark: | N/A |
|
| `input` | [operations.InputUnion](../../operations/inputunion.md) | :heavy_check_mark: | N/A |
|
||||||
| `model` | *str* | :heavy_check_mark: | N/A |
|
| `model` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `encoding_format` | [Optional[operations.EncodingFormat]](../../operations/encodingformat.md) | :heavy_minus_sign: | N/A |
|
| `encoding_format` | [Optional[operations.EncodingFormat]](../../operations/encodingformat.md) | :heavy_minus_sign: | N/A |
|
||||||
| `dimensions` | *Optional[int]* | :heavy_minus_sign: | N/A |
|
| `dimensions` | *Optional[int]* | :heavy_minus_sign: | N/A |
|
||||||
| `user` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
| `user` | *Optional[str]* | :heavy_minus_sign: | N/A |
|
||||||
@@ -83,8 +79,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -98,9 +92,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -23,8 +23,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -38,11 +36,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `author` | *str* | :heavy_check_mark: | N/A |
|
| `author` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `slug` | *str* | :heavy_check_mark: | N/A |
|
| `slug` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -70,8 +66,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -85,9 +79,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -22,8 +22,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -37,10 +35,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | N/A |
|
| `id` | *str* | :heavy_check_mark: | N/A |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ Guardrails endpoints
|
|||||||
|
|
||||||
## list
|
## list
|
||||||
|
|
||||||
List all guardrails for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all guardrails for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -34,8 +34,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -49,9 +47,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -70,7 +66,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## create
|
## create
|
||||||
|
|
||||||
Create a new guardrail for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Create a new guardrail for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -81,8 +77,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -96,10 +90,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `name` | *str* | :heavy_check_mark: | Name for the new guardrail | My New Guardrail |
|
| `name` | *str* | :heavy_check_mark: | Name for the new guardrail | My New Guardrail |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Description of the guardrail | A guardrail for limiting API usage |
|
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Description of the guardrail | A guardrail for limiting API usage |
|
||||||
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | Spending limit in USD | 50 |
|
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | Spending limit in USD | 50 |
|
||||||
| `reset_interval` | [OptionalNullable[operations.CreateGuardrailResetIntervalRequest]](../../operations/createguardrailresetintervalrequest.md) | :heavy_minus_sign: | Interval at which the limit resets (daily, weekly, monthly) | monthly |
|
| `reset_interval` | [OptionalNullable[operations.CreateGuardrailResetIntervalRequest]](../../operations/createguardrailresetintervalrequest.md) | :heavy_minus_sign: | Interval at which the limit resets (daily, weekly, monthly) | monthly |
|
||||||
@@ -123,7 +115,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## get
|
## get
|
||||||
|
|
||||||
Get a single guardrail by ID. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Get a single guardrail by ID. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -134,8 +126,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -149,10 +139,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to retrieve | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to retrieve | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -170,7 +158,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## update
|
## update
|
||||||
|
|
||||||
Update an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Update an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -181,8 +169,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -196,10 +182,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to update | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to update | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `name` | *Optional[str]* | :heavy_minus_sign: | New name for the guardrail | Updated Guardrail Name |
|
| `name` | *Optional[str]* | :heavy_minus_sign: | New name for the guardrail | Updated Guardrail Name |
|
||||||
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | New description for the guardrail | Updated description |
|
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | New description for the guardrail | Updated description |
|
||||||
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | New spending limit in USD | 75 |
|
| `limit_usd` | *OptionalNullable[float]* | :heavy_minus_sign: | New spending limit in USD | 75 |
|
||||||
@@ -225,7 +209,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## delete
|
## delete
|
||||||
|
|
||||||
Delete an existing guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Delete an existing guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -236,8 +220,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -251,10 +233,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to delete | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail to delete | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -272,7 +252,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## list_key_assignments
|
## list_key_assignments
|
||||||
|
|
||||||
List all API key guardrail assignments for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API key guardrail assignments for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -283,8 +263,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -298,9 +276,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -319,7 +295,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## list_member_assignments
|
## list_member_assignments
|
||||||
|
|
||||||
List all organization member guardrail assignments for the authenticated user. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all organization member guardrail assignments for the authenticated user. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -330,8 +306,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -345,9 +319,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -366,7 +338,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## list_guardrail_key_assignments
|
## list_guardrail_key_assignments
|
||||||
|
|
||||||
List all API key assignments for a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all API key assignments for a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -377,8 +349,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -392,10 +362,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -415,7 +383,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## bulk_assign_keys
|
## bulk_assign_keys
|
||||||
|
|
||||||
Assign multiple API keys to a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Assign multiple API keys to a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -426,8 +394,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -443,11 +409,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `key_hashes` | List[*str*] | :heavy_check_mark: | Array of API key hashes to assign to the guardrail | [<br/>"c56454edb818d6b14bc0d61c46025f1450b0f4012d12304ab40aacb519fcbc93"<br/>] |
|
| `key_hashes` | List[*str*] | :heavy_check_mark: | Array of API key hashes to assign to the guardrail | [<br/>"c56454edb818d6b14bc0d61c46025f1450b0f4012d12304ab40aacb519fcbc93"<br/>] |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -466,7 +430,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## list_guardrail_member_assignments
|
## list_guardrail_member_assignments
|
||||||
|
|
||||||
List all organization member assignments for a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
List all organization member assignments for a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -477,8 +441,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -492,10 +454,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
| `offset` | *Optional[str]* | :heavy_minus_sign: | Number of records to skip for pagination | 0 |
|
||||||
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
| `limit` | *Optional[str]* | :heavy_minus_sign: | Maximum number of records to return (max 100) | 50 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -515,7 +475,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## bulk_assign_members
|
## bulk_assign_members
|
||||||
|
|
||||||
Assign multiple organization members to a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Assign multiple organization members to a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -526,8 +486,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -544,11 +502,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `member_user_ids` | List[*str*] | :heavy_check_mark: | Array of member user IDs to assign to the guardrail | [<br/>"user_abc123",<br/>"user_def456"<br/>] |
|
| `member_user_ids` | List[*str*] | :heavy_check_mark: | Array of member user IDs to assign to the guardrail | [<br/>"user_abc123",<br/>"user_def456"<br/>] |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -567,7 +523,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## bulk_unassign_keys
|
## bulk_unassign_keys
|
||||||
|
|
||||||
Unassign multiple API keys from a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Unassign multiple API keys from a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -578,8 +534,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -595,11 +549,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `key_hashes` | List[*str*] | :heavy_check_mark: | Array of API key hashes to unassign from the guardrail | [<br/>"c56454edb818d6b14bc0d61c46025f1450b0f4012d12304ab40aacb519fcbc93"<br/>] |
|
| `key_hashes` | List[*str*] | :heavy_check_mark: | Array of API key hashes to unassign from the guardrail | [<br/>"c56454edb818d6b14bc0d61c46025f1450b0f4012d12304ab40aacb519fcbc93"<br/>] |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -618,7 +570,7 @@ with OpenRouter(
|
|||||||
|
|
||||||
## bulk_unassign_members
|
## bulk_unassign_members
|
||||||
|
|
||||||
Unassign multiple organization members from a specific guardrail. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
Unassign multiple organization members from a specific guardrail. [Provisioning key](/docs/guides/overview/auth/provisioning-api-keys) required.
|
||||||
|
|
||||||
### Example Usage
|
### Example Usage
|
||||||
|
|
||||||
@@ -629,8 +581,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -647,11 +597,9 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
| `id` | *str* | :heavy_check_mark: | The unique identifier of the guardrail | 550e8400-e29b-41d4-a716-446655440000 |
|
||||||
| `member_user_ids` | List[*str*] | :heavy_check_mark: | Array of member user IDs to unassign from the guardrail | [<br/>"user_abc123",<br/>"user_def456"<br/>] |
|
| `member_user_ids` | List[*str*] | :heavy_check_mark: | Array of member user IDs to unassign from the guardrail | [<br/>"user_abc123",<br/>"user_def456"<br/>] |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -24,8 +24,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -39,9 +37,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
@@ -68,8 +64,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -83,9 +77,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `category` | [Optional[operations.Category]](../../operations/category.md) | :heavy_minus_sign: | Filter models by use case category | programming |
|
| `category` | [Optional[operations.Category]](../../operations/category.md) | :heavy_minus_sign: | Filter models by use case category | programming |
|
||||||
| `supported_parameters` | *Optional[str]* | :heavy_minus_sign: | N/A | |
|
| `supported_parameters` | *Optional[str]* | :heavy_minus_sign: | N/A | |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -114,10 +106,7 @@ from openrouter import OpenRouter, operations
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter() as open_router:
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
) as open_router:
|
|
||||||
|
|
||||||
res = open_router.models.list_for_user(security=operations.ListModelsUserSecurity(
|
res = open_router.models.list_for_user(security=operations.ListModelsUserSecurity(
|
||||||
bearer=os.getenv("OPENROUTER_BEARER", ""),
|
bearer=os.getenv("OPENROUTER_BEARER", ""),
|
||||||
@@ -131,10 +120,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
|
||||||
| `security` | [operations.ListModelsUserSecurity](../../operations/listmodelsusersecurity.md) | :heavy_check_mark: | N/A |
|
| `security` | [operations.ListModelsUserSecurity](../../operations/listmodelsusersecurity.md) | :heavy_check_mark: | The security requirements to use for the request. |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -23,8 +23,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -38,10 +36,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `code` | *str* | :heavy_check_mark: | The authorization code received from the OAuth redirect | auth_code_abc123def456 |
|
| `code` | *str* | :heavy_check_mark: | The authorization code received from the OAuth redirect | auth_code_abc123def456 |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `code_verifier` | *Optional[str]* | :heavy_minus_sign: | The code verifier if code_challenge was used in the authorization request | dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk |
|
| `code_verifier` | *Optional[str]* | :heavy_minus_sign: | The code verifier if code_challenge was used in the authorization request | dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk |
|
||||||
| `code_challenge_method` | [OptionalNullable[operations.ExchangeAuthCodeForAPIKeyCodeChallengeMethod]](../../operations/exchangeauthcodeforapikeycodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
| `code_challenge_method` | [OptionalNullable[operations.ExchangeAuthCodeForAPIKeyCodeChallengeMethod]](../../operations/exchangeauthcodeforapikeycodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | |
|
||||||
@@ -72,8 +68,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -87,10 +81,8 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `callback_url` | *str* | :heavy_check_mark: | The callback URL to redirect to after authorization. Note, only https URLs on ports 443 and 3000 are allowed. | https://myapp.com/auth/callback |
|
| `callback_url` | *str* | :heavy_check_mark: | The callback URL to redirect to after authorization. Note, only https URLs on ports 443 and 3000 are allowed. | https://myapp.com/auth/callback |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `code_challenge` | *Optional[str]* | :heavy_minus_sign: | PKCE code challenge for enhanced security | E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM |
|
| `code_challenge` | *Optional[str]* | :heavy_minus_sign: | PKCE code challenge for enhanced security | E9Melhoa2OwvFrEMTJguCHaoeK1t8URWbuGJSstw-cM |
|
||||||
| `code_challenge_method` | [Optional[operations.CreateAuthKeysCodeCodeChallengeMethod]](../../operations/createauthkeyscodecodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
| `code_challenge_method` | [Optional[operations.CreateAuthKeysCodeCodeChallengeMethod]](../../operations/createauthkeyscodecodechallengemethod.md) | :heavy_minus_sign: | The method used to generate the code challenge | S256 |
|
||||||
| `limit` | *Optional[float]* | :heavy_minus_sign: | Credit limit for the API key to be created | 100 |
|
| `limit` | *Optional[float]* | :heavy_minus_sign: | Credit limit for the API key to be created | 100 |
|
||||||
|
|||||||
@@ -22,8 +22,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -37,9 +35,7 @@ with OpenRouter(
|
|||||||
### Parameters
|
### Parameters
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
| Parameter | Type | Required | Description |
|
||||||
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
|
|
||||||
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |
|
||||||
|
|
||||||
### Response
|
### Response
|
||||||
|
|||||||
@@ -22,8 +22,6 @@ import os
|
|||||||
|
|
||||||
|
|
||||||
with OpenRouter(
|
with OpenRouter(
|
||||||
http_referer="<value>",
|
|
||||||
x_title="<value>",
|
|
||||||
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
api_key=os.getenv("OPENROUTER_API_KEY", ""),
|
||||||
) as open_router:
|
) as open_router:
|
||||||
|
|
||||||
@@ -40,8 +38,6 @@ with OpenRouter(
|
|||||||
|
|
||||||
| Parameter | Type | Required | Description | Example |
|
| Parameter | Type | Required | Description | Example |
|
||||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> | |
|
|
||||||
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> | |
|
|
||||||
| `input` | [Optional[components.OpenResponsesInput]](../../components/openresponsesinput.md) | :heavy_minus_sign: | Input for a response request - can be a string or array of items | [<br/>{<br/>"role": "user",<br/>"content": "What is the weather today?"<br/>}<br/>] |
|
| `input` | [Optional[components.OpenResponsesInput]](../../components/openresponsesinput.md) | :heavy_minus_sign: | Input for a response request - can be a string or array of items | [<br/>{<br/>"role": "user",<br/>"content": "What is the weather today?"<br/>}<br/>] |
|
||||||
| `instructions` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | |
|
| `instructions` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | |
|
||||||
| `metadata` | Dict[str, *str*] | :heavy_minus_sign: | Metadata key-value pairs for the request. Keys must be ≤64 characters and cannot contain brackets. Values must be ≤512 characters. Maximum 16 pairs allowed. | {<br/>"user_id": "123",<br/>"session_id": "abc-def-ghi"<br/>} |
|
| `metadata` | Dict[str, *str*] | :heavy_minus_sign: | Metadata key-value pairs for the request. Keys must be ≤64 characters and cannot contain brackets. Values must be ≤512 characters. Maximum 16 pairs allowed. | {<br/>"user_id": "123",<br/>"session_id": "abc-def-ghi"<br/>} |
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "openrouter"
|
name = "openrouter"
|
||||||
version = "0.6.0"
|
version = "0.4.0"
|
||||||
description = "Official Python Client SDK for OpenRouter."
|
description = "Official Python Client SDK for OpenRouter."
|
||||||
authors = [{ name = "OpenRouter" },]
|
authors = [{ name = "OpenRouter" },]
|
||||||
readme = "README-PYPI.md"
|
readme = "README-PYPI.md"
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user