mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-08-04 13:03:39 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
46f4661cf0 |
+4
-4
@@ -1,12 +1,12 @@
|
||||
lockVersion: 2.0.0
|
||||
id: cfd52247-6a25-4c6d-bbce-fe6fce0cd69d
|
||||
management:
|
||||
docChecksum: 56062ba1997e25ff8be6529c550e5de9
|
||||
docChecksum: b228e1eb4c66726b8a6591e0136607a3
|
||||
docVersion: 1.0.0
|
||||
speakeasyVersion: 1.666.0
|
||||
generationVersion: 2.768.0
|
||||
releaseVersion: 0.6.0
|
||||
configChecksum: 690b77f47b975e28d7e11a6b96fa1c2f
|
||||
releaseVersion: 0.5.3
|
||||
configChecksum: 58ed883d63da40283d4f48eabdf39a63
|
||||
repoURL: https://github.com/OpenRouterTeam/python-sdk.git
|
||||
installationURL: https://github.com/OpenRouterTeam/python-sdk.git
|
||||
published: true
|
||||
@@ -1232,7 +1232,7 @@ examples:
|
||||
speakeasy-default-get-current-key:
|
||||
responses:
|
||||
"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":
|
||||
application/json: {"error": {"code": 401, "message": "Missing Authentication header"}}
|
||||
"500":
|
||||
|
||||
+1
-1
@@ -31,7 +31,7 @@ generation:
|
||||
skipResponseBodyAssertions: false
|
||||
preApplyUnionDiscriminators: true
|
||||
python:
|
||||
version: 0.6.0
|
||||
version: 0.5.3
|
||||
additionalDependencies:
|
||||
dev: {}
|
||||
main: {}
|
||||
|
||||
@@ -13461,14 +13461,9 @@ paths:
|
||||
type: boolean
|
||||
description: Whether this is a free tier API key
|
||||
example: false
|
||||
is_management_key:
|
||||
type: boolean
|
||||
description: Whether this is a management key
|
||||
example: false
|
||||
is_provisioning_key:
|
||||
type: boolean
|
||||
description: Whether this is a management key
|
||||
deprecated: true
|
||||
example: false
|
||||
limit_remaining:
|
||||
type: number
|
||||
@@ -13527,7 +13522,6 @@ paths:
|
||||
- byok_usage_weekly
|
||||
- byok_usage_monthly
|
||||
- is_free_tier
|
||||
- is_management_key
|
||||
- is_provisioning_key
|
||||
- limit_remaining
|
||||
- limit_reset
|
||||
@@ -13546,7 +13540,6 @@ paths:
|
||||
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
|
||||
@@ -13571,7 +13564,6 @@ paths:
|
||||
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
|
||||
|
||||
@@ -13519,14 +13519,9 @@ paths:
|
||||
type: boolean
|
||||
description: Whether this is a free tier API key
|
||||
example: false
|
||||
is_management_key:
|
||||
type: boolean
|
||||
description: Whether this is a management key
|
||||
example: false
|
||||
is_provisioning_key:
|
||||
type: boolean
|
||||
description: Whether this is a management key
|
||||
deprecated: true
|
||||
example: false
|
||||
limit_remaining:
|
||||
type: number
|
||||
@@ -13585,7 +13580,6 @@ paths:
|
||||
- byok_usage_weekly
|
||||
- byok_usage_monthly
|
||||
- is_free_tier
|
||||
- is_management_key
|
||||
- is_provisioning_key
|
||||
- limit_remaining
|
||||
- limit_reset
|
||||
@@ -13604,7 +13598,6 @@ paths:
|
||||
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
|
||||
@@ -13629,7 +13622,6 @@ paths:
|
||||
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
|
||||
|
||||
@@ -8,8 +8,8 @@ sources:
|
||||
- latest
|
||||
OpenRouter API:
|
||||
sourceNamespace: open-router-chat-completions-api
|
||||
sourceRevisionDigest: sha256:2dbe784978f60cb53a0d081e1b5f4cbb42ca86b1ff8f4361869fa78c42e042ee
|
||||
sourceBlobDigest: sha256:851aadf3180735f9dbfdb2904011de231d3805d187499c24a450a224cacf1ed2
|
||||
sourceRevisionDigest: sha256:d5c5c69528cba8b48e0f87b66fcb6eed44dc3bc4e507bc677935a5652d136449
|
||||
sourceBlobDigest: sha256:f122e0bca81c9667d887bfa53aa1f61825a53557370d67d40dbdf44cf69e6183
|
||||
tags:
|
||||
- latest
|
||||
- main
|
||||
@@ -18,10 +18,10 @@ targets:
|
||||
open-router:
|
||||
source: OpenRouter API
|
||||
sourceNamespace: open-router-chat-completions-api
|
||||
sourceRevisionDigest: sha256:2dbe784978f60cb53a0d081e1b5f4cbb42ca86b1ff8f4361869fa78c42e042ee
|
||||
sourceBlobDigest: sha256:851aadf3180735f9dbfdb2904011de231d3805d187499c24a450a224cacf1ed2
|
||||
sourceRevisionDigest: sha256:d5c5c69528cba8b48e0f87b66fcb6eed44dc3bc4e507bc677935a5652d136449
|
||||
sourceBlobDigest: sha256:f122e0bca81c9667d887bfa53aa1f61825a53557370d67d40dbdf44cf69e6183
|
||||
codeSamplesNamespace: open-router-python-code-samples
|
||||
codeSamplesRevisionDigest: sha256:cf9f3fd9983864e3c5dd5bc3fa9198efc9493f4fbc671130e8f07e87722c43dd
|
||||
codeSamplesRevisionDigest: sha256:d3b6e9ed4ef04654fb3a74919cdafca5b8dc07a39790bd608baddb5f3a8da3da
|
||||
workflow:
|
||||
workflowVersion: 1.0.0
|
||||
speakeasyVersion: 1.666.0
|
||||
|
||||
@@ -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_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_management_key` | *bool* | :heavy_check_mark: | Whether this is a management 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 |
|
||||
| `is_provisioning_key` | *bool* | :heavy_check_mark: | Whether this is a management key | false |
|
||||
| `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 |
|
||||
| `include_byok_in_limit` | *bool* | :heavy_check_mark: | Whether to include external BYOK usage in the credit limit | false |
|
||||
|
||||
@@ -5,6 +5,6 @@ API key details
|
||||
|
||||
## Fields
|
||||
|
||||
| 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/>} |
|
||||
| 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_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
-1
@@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = "openrouter"
|
||||
version = "0.6.0"
|
||||
version = "0.5.3"
|
||||
description = "Official Python Client SDK for OpenRouter."
|
||||
authors = [{ name = "OpenRouter" },]
|
||||
readme = "README-PYPI.md"
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
import importlib.metadata
|
||||
|
||||
__title__: str = "openrouter"
|
||||
__version__: str = "0.6.0"
|
||||
__version__: str = "0.5.3"
|
||||
__openapi_doc_version__: str = "1.0.0"
|
||||
__gen_version__: str = "2.768.0"
|
||||
__user_agent__: str = "speakeasy-sdk/python 0.6.0 2.768.0 1.0.0 openrouter"
|
||||
__user_agent__: str = "speakeasy-sdk/python 0.5.3 2.768.0 1.0.0 openrouter"
|
||||
|
||||
try:
|
||||
if __package__ is not None:
|
||||
|
||||
@@ -137,8 +137,6 @@ class GetCurrentKeyDataTypedDict(TypedDict):
|
||||
r"""External BYOK usage (in USD) for current UTC month"""
|
||||
is_free_tier: bool
|
||||
r"""Whether this is a free tier API key"""
|
||||
is_management_key: bool
|
||||
r"""Whether this is a management key"""
|
||||
is_provisioning_key: bool
|
||||
r"""Whether this is a management key"""
|
||||
limit_remaining: Nullable[float]
|
||||
@@ -189,15 +187,7 @@ class GetCurrentKeyData(BaseModel):
|
||||
is_free_tier: bool
|
||||
r"""Whether this is a free tier API key"""
|
||||
|
||||
is_management_key: bool
|
||||
r"""Whether this is a management key"""
|
||||
|
||||
is_provisioning_key: Annotated[
|
||||
bool,
|
||||
pydantic.Field(
|
||||
deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible."
|
||||
),
|
||||
]
|
||||
is_provisioning_key: bool
|
||||
r"""Whether this is a management key"""
|
||||
|
||||
limit_remaining: Nullable[float]
|
||||
|
||||
Reference in New Issue
Block a user