feat: regenerate SDK with updated OpenAPI spec

Speakeasy regeneration with latest schema changes including
type renames and new server tool models.
This commit is contained in:
OpenRouter SDK Bot
2026-03-27 15:18:14 -04:00
parent e72a84e82d
commit 5ab44f08f0
375 changed files with 36229 additions and 5480 deletions
+47 -6
View File
@@ -21,10 +21,14 @@ class GetGenerationGlobalsTypedDict(TypedDict):
This is used to track API usage per application.
"""
x_title: NotRequired[str]
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 GetGenerationGlobals(BaseModel):
@@ -38,15 +42,24 @@ class GetGenerationGlobals(BaseModel):
"""
x_title: Annotated[
x_open_router_title: Annotated[
Optional[str],
pydantic.Field(alias="X-Title"),
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.
"""
class GetGenerationRequestTypedDict(TypedDict):
id: str
@@ -55,10 +68,14 @@ class GetGenerationRequestTypedDict(TypedDict):
This is used to track API usage per application.
"""
x_title: NotRequired[str]
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 GetGenerationRequest(BaseModel):
@@ -76,20 +93,30 @@ class GetGenerationRequest(BaseModel):
"""
x_title: Annotated[
x_open_router_title: Annotated[
Optional[str],
pydantic.Field(alias="X-Title"),
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.
"""
APIType = Union[
Literal[
"completions",
"embeddings",
"video",
],
UnrecognizedStr,
]
@@ -126,6 +153,7 @@ ProviderName = Union[
"Together 2",
"Ubicloud",
"01.AI",
"AkashML",
"AI21",
"AionLabs",
"Alibaba",
@@ -183,6 +211,7 @@ ProviderName = Union[
"Parasail",
"Perplexity",
"Phala",
"Reka",
"Relace",
"SambaNova",
"Seed",
@@ -341,6 +370,10 @@ class GetGenerationDataTypedDict(TypedDict):
r"""Router used for the request (e.g., openrouter/auto)"""
provider_responses: Nullable[List[ProviderResponseTypedDict]]
r"""List of provider responses for this generation, including fallback attempts"""
user_agent: Nullable[str]
r"""User-Agent header from the request"""
http_referer: Nullable[str]
r"""Referer header from the request"""
class GetGenerationData(BaseModel):
@@ -448,6 +481,12 @@ class GetGenerationData(BaseModel):
provider_responses: Nullable[List[ProviderResponse]]
r"""List of provider responses for this generation, including fallback attempts"""
user_agent: Nullable[str]
r"""User-Agent header from the request"""
http_referer: Nullable[str]
r"""Referer header from the request"""
@model_serializer(mode="wrap")
def serialize_model(self, handler):
optional_fields = []
@@ -479,6 +518,8 @@ class GetGenerationData(BaseModel):
"api_type",
"router",
"provider_responses",
"user_agent",
"http_referer",
]
null_default_fields = []