mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-07-30 12:20:57 +08:00
chore: 🐝 Update SDK - Generate (spec change merged) 0.11.2 (#388)
Co-authored-by: speakeasybot <bot@speakeasyapi.dev> Co-authored-by: speakeasy-github[bot] <128539517+speakeasy-github[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
speakeasybot
speakeasy-github[bot] <128539517+speakeasy-github[bot]@users.noreply.github.com>
parent
f6c5471023
commit
c2ae7dfde4
@@ -618,6 +618,14 @@ if TYPE_CHECKING:
|
||||
ListWorkspaceBudgetsRequest,
|
||||
ListWorkspaceBudgetsRequestTypedDict,
|
||||
)
|
||||
from .listworkspacemembers import (
|
||||
ListWorkspaceMembersGlobals,
|
||||
ListWorkspaceMembersGlobalsTypedDict,
|
||||
ListWorkspaceMembersRequest,
|
||||
ListWorkspaceMembersRequestTypedDict,
|
||||
ListWorkspaceMembersResponse,
|
||||
ListWorkspaceMembersResponseTypedDict,
|
||||
)
|
||||
from .listworkspaces import (
|
||||
ListWorkspacesGlobals,
|
||||
ListWorkspacesGlobalsTypedDict,
|
||||
@@ -1159,6 +1167,12 @@ __all__ = [
|
||||
"ListWorkspaceBudgetsGlobalsTypedDict",
|
||||
"ListWorkspaceBudgetsRequest",
|
||||
"ListWorkspaceBudgetsRequestTypedDict",
|
||||
"ListWorkspaceMembersGlobals",
|
||||
"ListWorkspaceMembersGlobalsTypedDict",
|
||||
"ListWorkspaceMembersRequest",
|
||||
"ListWorkspaceMembersRequestTypedDict",
|
||||
"ListWorkspaceMembersResponse",
|
||||
"ListWorkspaceMembersResponseTypedDict",
|
||||
"ListWorkspacesGlobals",
|
||||
"ListWorkspacesGlobalsTypedDict",
|
||||
"ListWorkspacesRequest",
|
||||
@@ -1721,6 +1735,12 @@ _dynamic_imports: dict[str, str] = {
|
||||
"ListWorkspaceBudgetsGlobalsTypedDict": ".listworkspacebudgets",
|
||||
"ListWorkspaceBudgetsRequest": ".listworkspacebudgets",
|
||||
"ListWorkspaceBudgetsRequestTypedDict": ".listworkspacebudgets",
|
||||
"ListWorkspaceMembersGlobals": ".listworkspacemembers",
|
||||
"ListWorkspaceMembersGlobalsTypedDict": ".listworkspacemembers",
|
||||
"ListWorkspaceMembersRequest": ".listworkspacemembers",
|
||||
"ListWorkspaceMembersRequestTypedDict": ".listworkspacemembers",
|
||||
"ListWorkspaceMembersResponse": ".listworkspacemembers",
|
||||
"ListWorkspaceMembersResponseTypedDict": ".listworkspacemembers",
|
||||
"ListWorkspacesGlobals": ".listworkspaces",
|
||||
"ListWorkspacesGlobalsTypedDict": ".listworkspaces",
|
||||
"ListWorkspacesRequest": ".listworkspaces",
|
||||
|
||||
@@ -0,0 +1,189 @@
|
||||
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
||||
|
||||
from __future__ import annotations
|
||||
from openrouter.components import (
|
||||
listworkspacemembersresponse as components_listworkspacemembersresponse,
|
||||
)
|
||||
from openrouter.types import BaseModel, UNSET_SENTINEL
|
||||
from openrouter.utils import (
|
||||
FieldMetadata,
|
||||
HeaderMetadata,
|
||||
PathParamMetadata,
|
||||
QueryParamMetadata,
|
||||
)
|
||||
import pydantic
|
||||
from pydantic import model_serializer
|
||||
from typing import Awaitable, Callable, Optional, Union
|
||||
from typing_extensions import Annotated, NotRequired, TypedDict
|
||||
|
||||
|
||||
class ListWorkspaceMembersGlobalsTypedDict(TypedDict):
|
||||
http_referer: NotRequired[str]
|
||||
r"""The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
||||
This is used to track API usage per application.
|
||||
|
||||
"""
|
||||
x_open_router_title: NotRequired[str]
|
||||
r"""The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
||||
|
||||
"""
|
||||
x_open_router_categories: NotRequired[str]
|
||||
r"""Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
|
||||
|
||||
"""
|
||||
|
||||
|
||||
class ListWorkspaceMembersGlobals(BaseModel):
|
||||
http_referer: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="HTTP-Referer"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
||||
This is used to track API usage per application.
|
||||
|
||||
"""
|
||||
|
||||
x_open_router_title: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="X-OpenRouter-Title"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
||||
|
||||
"""
|
||||
|
||||
x_open_router_categories: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="X-OpenRouter-Categories"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
|
||||
|
||||
"""
|
||||
|
||||
@model_serializer(mode="wrap")
|
||||
def serialize_model(self, handler):
|
||||
optional_fields = set(
|
||||
["HTTP-Referer", "X-OpenRouter-Title", "X-OpenRouter-Categories"]
|
||||
)
|
||||
serialized = handler(self)
|
||||
m = {}
|
||||
|
||||
for n, f in type(self).model_fields.items():
|
||||
k = f.alias or n
|
||||
val = serialized.get(k, serialized.get(n))
|
||||
|
||||
if val != UNSET_SENTINEL:
|
||||
if val is not None or k not in optional_fields:
|
||||
m[k] = val
|
||||
|
||||
return m
|
||||
|
||||
|
||||
class ListWorkspaceMembersRequestTypedDict(TypedDict):
|
||||
id: str
|
||||
r"""The workspace ID (UUID) or slug"""
|
||||
http_referer: NotRequired[str]
|
||||
r"""The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
||||
This is used to track API usage per application.
|
||||
|
||||
"""
|
||||
x_open_router_title: NotRequired[str]
|
||||
r"""The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
||||
|
||||
"""
|
||||
x_open_router_categories: NotRequired[str]
|
||||
r"""Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
|
||||
|
||||
"""
|
||||
offset: NotRequired[int]
|
||||
r"""Number of records to skip for pagination"""
|
||||
limit: NotRequired[int]
|
||||
r"""Maximum number of records to return (max 100)"""
|
||||
|
||||
|
||||
class ListWorkspaceMembersRequest(BaseModel):
|
||||
id: Annotated[
|
||||
str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
|
||||
]
|
||||
r"""The workspace ID (UUID) or slug"""
|
||||
|
||||
http_referer: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="HTTP-Referer"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
||||
This is used to track API usage per application.
|
||||
|
||||
"""
|
||||
|
||||
x_open_router_title: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="X-OpenRouter-Title"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
||||
|
||||
"""
|
||||
|
||||
x_open_router_categories: Annotated[
|
||||
Optional[str],
|
||||
pydantic.Field(alias="X-OpenRouter-Categories"),
|
||||
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
||||
] = None
|
||||
r"""Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
|
||||
|
||||
"""
|
||||
|
||||
offset: Annotated[
|
||||
Optional[int],
|
||||
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
||||
] = None
|
||||
r"""Number of records to skip for pagination"""
|
||||
|
||||
limit: Annotated[
|
||||
Optional[int],
|
||||
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
||||
] = None
|
||||
r"""Maximum number of records to return (max 100)"""
|
||||
|
||||
@model_serializer(mode="wrap")
|
||||
def serialize_model(self, handler):
|
||||
optional_fields = set(
|
||||
[
|
||||
"HTTP-Referer",
|
||||
"X-OpenRouter-Title",
|
||||
"X-OpenRouter-Categories",
|
||||
"offset",
|
||||
"limit",
|
||||
]
|
||||
)
|
||||
serialized = handler(self)
|
||||
m = {}
|
||||
|
||||
for n, f in type(self).model_fields.items():
|
||||
k = f.alias or n
|
||||
val = serialized.get(k, serialized.get(n))
|
||||
|
||||
if val != UNSET_SENTINEL:
|
||||
if val is not None or k not in optional_fields:
|
||||
m[k] = val
|
||||
|
||||
return m
|
||||
|
||||
|
||||
class ListWorkspaceMembersResponseTypedDict(TypedDict):
|
||||
result: (
|
||||
components_listworkspacemembersresponse.ListWorkspaceMembersResponseTypedDict
|
||||
)
|
||||
|
||||
|
||||
class ListWorkspaceMembersResponse(BaseModel):
|
||||
next: Union[
|
||||
Callable[[], Optional[ListWorkspaceMembersResponse]],
|
||||
Callable[[], Awaitable[Optional[ListWorkspaceMembersResponse]]],
|
||||
]
|
||||
|
||||
result: components_listworkspacemembersresponse.ListWorkspaceMembersResponse
|
||||
Reference in New Issue
Block a user