diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock
index 694b01d2..52e529f4 100644
--- a/.speakeasy/gen.lock
+++ b/.speakeasy/gen.lock
@@ -1,19 +1,19 @@
lockVersion: 2.0.0
id: c48cf606-fb42-4a45-9c23-8f0555307828
management:
- docChecksum: 564504dc148e4a96d8e4b7a96ec05de4
+ docChecksum: 71c8ad142a8771298fc33c554a34f8fc
docVersion: 1.0.0
speakeasyVersion: 1.803.2
generationVersion: 2.950.13
- releaseVersion: 1.3.242
- configChecksum: f1ff7a2e429e073c3eff0e0a11c6fa82
+ releaseVersion: 1.3.243
+ configChecksum: 8e8fac1cf7a5b30acc4669d7eb63eddb
repoURL: https://github.com/OpenRouterTeam/python-sdk.git
installationURL: https://github.com/OpenRouterTeam/python-sdk.git
published: true
persistentEdits:
- generation_id: 3c15b8df-70f6-44b9-87ac-a60e2dd44e26
- pristine_commit_hash: e992b6ac99481811165bb393291db57b92dba96e
- pristine_tree_hash: 2c80519385d1bda4fecae021ccd18045c0ab97b7
+ generation_id: 6bdd2415-f232-4697-92d4-abf14814fb8d
+ pristine_commit_hash: 4961056dbe17230f727025c9a4c87497bc6df72a
+ pristine_tree_hash: 27e7d504b0d273ab1c7ac6e88279046b7512a2f8
features:
python:
acceptHeaders: 3.0.0
@@ -8796,8 +8796,8 @@ trackedFiles:
pristine_git_object: 38be122fce694e660cd56d82182dd3d15098479d
docs/components/speechrequest.mdx:
id: 06e81b0433f6
- last_write_checksum: sha1:f4a57410dea91dc21a19a50493051e2cf0c2d563
- pristine_git_object: 97d60e2b42e158b78ff0d39a1b0116ae72abadc9
+ last_write_checksum: sha1:34aa30a244b4bfd300bc2ce9088dc7959ae04678
+ pristine_git_object: 20df033ed8bf659a2788ace32915adf6c6a74c70
docs/components/speechrequestdatacollection.mdx:
id: 6c5938568888
last_write_checksum: sha1:89a08b4c4de66c1ef7676792a38747e030ed6729
@@ -12636,8 +12636,8 @@ trackedFiles:
pristine_git_object: bcbe30fccceb97caa3a0e170038245dcc7f1e540
docs/sdks/tts/README.mdx:
id: cd1132543884
- last_write_checksum: sha1:ac8c0a881fbee9549e886c00414834cac5a66cb9
- pristine_git_object: ef6bb7ffbb2f294c7e361d1d1629610794ad8b51
+ last_write_checksum: sha1:dd814abd82b8fa498b0c84cd0af540c607132bd9
+ pristine_git_object: d3d9218fe4c68a3d282f0ce8e39f2186a0b8a47a
docs/sdks/vault/README.mdx:
id: 3738c6722acd
last_write_checksum: sha1:290b439ff730b9eabf4a6ef93737d1c61006b0fa
@@ -12656,8 +12656,8 @@ trackedFiles:
pristine_git_object: 3e38f1a929f7d6b1d6de74604aa87e3d8f010544
pyproject.toml:
id: 5d07e7d72637
- last_write_checksum: sha1:4d01bae473472bd886468c34d07280273b672caa
- pristine_git_object: 16a010e28a81ba732b4ccf61526f146a603dd397
+ last_write_checksum: sha1:b52626a9ac31d5773337db1c72e3bfb65d2c9fc3
+ pristine_git_object: 65b206f7393fad89ebbc4cb8414484eb4c6f828f
scripts/prepare_readme.py:
id: e0c5957a6035
last_write_checksum: sha1:77f44b60b98bc126557ec27391f91dfba764bb54
@@ -12684,8 +12684,8 @@ trackedFiles:
pristine_git_object: 86713cfea633e09d33b3d4e65281071fe20e6137
src/openrouter/_version.py:
id: d8d15ad6c586
- last_write_checksum: sha1:d13eca9afa6b4129c0043c39c68023b5962e44c5
- pristine_git_object: 5540ddaefaf29c0aacd70b7d52630aa897322500
+ last_write_checksum: sha1:ae87b6fb98e6501b6b99bc67b23105d8bff835cf
+ pristine_git_object: 5e770fce330c79c8ba36abfc7ea8d5962fd412b8
src/openrouter/alpha.py:
id: 306c4d93308d
last_write_checksum: sha1:80cc0f39649445431cc2247ed0e0765438467766
@@ -16276,8 +16276,8 @@ trackedFiles:
pristine_git_object: 69c0355e7d575e6b7c52183d3cd5696611e4e8bf
src/openrouter/components/speechrequest.py:
id: 2a9400167112
- last_write_checksum: sha1:92375ff35858416c3e95123e58f6ad564a9a0e86
- pristine_git_object: 8262e372b4308b7eeb0909ebd1f4dd238b2ffb21
+ last_write_checksum: sha1:ad13db254847e479ccdbf8d09646f130ef52cb6c
+ pristine_git_object: 47a21c98f92a07c1fc35472f751753e678f9d05c
src/openrouter/components/speechsupportedparameters.py:
id: 618f33cc9229
last_write_checksum: sha1:6f3fe1b11d56407227306a93fb6d232066158913
@@ -17844,8 +17844,8 @@ trackedFiles:
pristine_git_object: 701fa8597ff85f41a60736ade55fcb32f9ec7125
src/openrouter/tts.py:
id: 5055d4b95f1d
- last_write_checksum: sha1:ad38f58ec523d58d5dabcd9174ad6f34974b2e77
- pristine_git_object: 1726f3c855f4a89ba3d1adbec1f88f08003098c6
+ last_write_checksum: sha1:c6759fe4b36959d756e94f5817a2d3e3f1f4e198
+ pristine_git_object: 3f8339d0d07dd3807fc7263a75375d6057bcc5bf
src/openrouter/types/__init__.py:
id: 5eab536205b7
last_write_checksum: sha1:f9ad14217f832e74f594285960125add50324be9
diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml
index 9bd78786..4c9aff91 100644
--- a/.speakeasy/gen.yaml
+++ b/.speakeasy/gen.yaml
@@ -37,7 +37,7 @@ generation:
documentation: mintlify
preApplyUnionDiscriminators: true
python:
- version: 1.3.242
+ version: 1.3.243
additionalDependencies:
dev:
pytest: '>=8.3'
diff --git a/.speakeasy/out.openapi.yaml b/.speakeasy/out.openapi.yaml
index b225889a..c4865f3a 100644
--- a/.speakeasy/out.openapi.yaml
+++ b/.speakeasy/out.openapi.yaml
@@ -37034,7 +37034,7 @@ components:
$ref: '#/components/schemas/SpeechInputReference'
type: 'array'
instructions:
- description: 'Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers.'
+ description: 'Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`.'
example: 'Speak in a warm and friendly tone.'
type: 'string'
model:
diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock
index 5102b55f..0eef5ab8 100644
--- a/.speakeasy/workflow.lock
+++ b/.speakeasy/workflow.lock
@@ -2,8 +2,8 @@ speakeasyVersion: 1.803.2
sources:
OpenRouter API:
sourceNamespace: open-router-chat-completions-api
- sourceRevisionDigest: sha256:2b21bb87c330c1780b2a1f5e309f979389f502e6d87e365e66b90e3268e5eefb
- sourceBlobDigest: sha256:357d639760437485808b53da41d4f635ebf74c25e93742b5af6ccfa0ecaa9fbc
+ sourceRevisionDigest: sha256:10c3504a51db3373ac0499ee5053645406656196f2c57775bcb2ad46dfdcb1c9
+ sourceBlobDigest: sha256:42ba74d1683c77b46105c7531ef35a678bfb618574202f4e365a063a9a898659
tags:
- latest
- 1.0.0
@@ -11,10 +11,10 @@ targets:
open-router:
source: OpenRouter API
sourceNamespace: open-router-chat-completions-api
- sourceRevisionDigest: sha256:2b21bb87c330c1780b2a1f5e309f979389f502e6d87e365e66b90e3268e5eefb
- sourceBlobDigest: sha256:357d639760437485808b53da41d4f635ebf74c25e93742b5af6ccfa0ecaa9fbc
+ sourceRevisionDigest: sha256:10c3504a51db3373ac0499ee5053645406656196f2c57775bcb2ad46dfdcb1c9
+ sourceBlobDigest: sha256:42ba74d1683c77b46105c7531ef35a678bfb618574202f4e365a063a9a898659
codeSamplesNamespace: open-router-python-code-samples
- codeSamplesRevisionDigest: sha256:6f3bd53f4aa77372325d2b45d1e87a5ca0e48c953f5e00c22475bf013e1fb77d
+ codeSamplesRevisionDigest: sha256:ce53a5199d9041683635a2f8597fce589231288db7034d391e3bae057f338888
workflow:
workflowVersion: 1.0.0
speakeasyVersion: 1.803.2
diff --git a/RELEASES.md b/RELEASES.md
index 1776437d..7c968d1c 100644
--- a/RELEASES.md
+++ b/RELEASES.md
@@ -5189,4 +5189,14 @@ Based on:
### Generated
- [python v1.3.242] .
### Releases
-- [PyPI v1.3.242] https://pypi.org/project/openrouter/1.3.242 - .
\ No newline at end of file
+- [PyPI v1.3.242] https://pypi.org/project/openrouter/1.3.242 - .
+
+## 2026-12-04 09:35:16
+### Changes
+Based on:
+- OpenAPI Doc
+- Speakeasy CLI 1.803.2 (2.950.13) https://github.com/speakeasy-api/speakeasy
+### Generated
+- [python v1.3.243] .
+### Releases
+- [PyPI v1.3.243] https://pypi.org/project/openrouter/1.3.243 - .
\ No newline at end of file
diff --git a/docs/components/speechrequest.mdx b/docs/components/speechrequest.mdx
index 97d60e2b..20df033e 100644
--- a/docs/components/speechrequest.mdx
+++ b/docs/components/speechrequest.mdx
@@ -11,7 +11,7 @@ Text-to-speech request input
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `input` | [components.SpeechInput](../components/speechinput.mdx) | ✔️ | Text to synthesize, or a list of turns for multi-speaker input. Each turn has its own text, voice, and instructions. Multi-speaker input is supported by Gemini TTS models, by Fish Audio models other than S1, and by Speechify dialogue models. | Hello world |
| `input_references` | List[[components.SpeechInputReference](../components/speechinputreference.mdx)] | ➖ | Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference. | [
\{
"input_audio": \{
"data": "data:audio/wav;base64,UklGRuQXDABXQVZF..."
},
"type": "input_audio"
},
\{
"text": "I used to rule the world.",
"type": "text"
}
] |
-| `instructions` | *Optional[str]* | ➖ | Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers. | Speak in a warm and friendly tone. |
+| `instructions` | *Optional[str]* | ➖ | Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`. | Speak in a warm and friendly tone. |
| `model` | *str* | ✔️ | TTS model identifier | mistralai/voxtral-mini-tts-2603 |
| `output_delivery` | [Optional[components.OutputDelivery]](../components/outputdelivery.mdx) | ➖ | `stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`. | stream |
| `provider` | [Optional[components.SpeechRequestProvider]](../components/speechrequestprovider.mdx) | ➖ | Provider configuration: provider routing preferences (`order`, `only`, `ignore`, `allow_fallbacks`), data policy routing preferences (`zdr`, `data_collection`) and provider-specific passthrough options | |
diff --git a/docs/sdks/tts/README.mdx b/docs/sdks/tts/README.mdx
index ef6bb7ff..d3d9218f 100644
--- a/docs/sdks/tts/README.mdx
+++ b/docs/sdks/tts/README.mdx
@@ -48,7 +48,7 @@ with OpenRouter(
| `x_open_router_title` | *Optional[str]* | ➖ | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| |
| `x_open_router_categories` | *Optional[str]* | ➖ | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| |
| `input_references` | List[[components.SpeechInputReference](../../components/speechinputreference.mdx)] | ➖ | Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference. | [
\{
"input_audio": \{
"data": "data:audio/wav;base64,UklGRuQXDABXQVZF..."
},
"type": "input_audio"
},
\{
"text": "I used to rule the world.",
"type": "text"
}
] |
-| `instructions` | *Optional[str]* | ➖ | Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers. | Speak in a warm and friendly tone. |
+| `instructions` | *Optional[str]* | ➖ | Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`. | Speak in a warm and friendly tone. |
| `output_delivery` | [Optional[components.OutputDelivery]](../../components/outputdelivery.mdx) | ➖ | `stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`. | stream |
| `provider` | [Optional[components.SpeechRequestProvider]](../../components/speechrequestprovider.mdx) | ➖ | Provider configuration: provider routing preferences (`order`, `only`, `ignore`, `allow_fallbacks`), data policy routing preferences (`zdr`, `data_collection`) and provider-specific passthrough options | |
| `response_format` | [Optional[components.SpeechRequestResponseFormat]](../../components/speechrequestresponseformat.mdx) | ➖ | Audio output format. Defaults to `pcm`, or to `mp3` when `timestamp_granularities` is nonempty. | pcm |
diff --git a/pyproject.toml b/pyproject.toml
index 16a010e2..65b206f7 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
[project]
name = "openrouter"
-version = "1.3.242"
+version = "1.3.243"
description = "Official Python Client SDK for OpenRouter."
authors = [{ name = "OpenRouter" },]
readme = "README-PYPI.md"
diff --git a/src/openrouter/_version.py b/src/openrouter/_version.py
index 5540ddae..5e770fce 100644
--- a/src/openrouter/_version.py
+++ b/src/openrouter/_version.py
@@ -3,10 +3,10 @@
import importlib.metadata
__title__: str = "openrouter"
-__version__: str = "1.3.242"
+__version__: str = "1.3.243"
__openapi_doc_version__: str = "1.0.0"
__gen_version__: str = "2.950.13"
-__user_agent__: str = "speakeasy-sdk/python 1.3.242 2.950.13 1.0.0 openrouter"
+__user_agent__: str = "speakeasy-sdk/python 1.3.243 2.950.13 1.0.0 openrouter"
try:
if __package__ is not None:
diff --git a/src/openrouter/components/speechrequest.py b/src/openrouter/components/speechrequest.py
index 8262e372..47a21c98 100644
--- a/src/openrouter/components/speechrequest.py
+++ b/src/openrouter/components/speechrequest.py
@@ -194,7 +194,7 @@ class SpeechRequestTypedDict(TypedDict):
input_references: NotRequired[List[SpeechInputReferenceTypedDict]]
r"""Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference."""
instructions: NotRequired[str]
- r"""Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers."""
+ r"""Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`."""
output_delivery: NotRequired[OutputDelivery]
r"""`stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`."""
provider: NotRequired[SpeechRequestProviderTypedDict]
@@ -228,7 +228,7 @@ class SpeechRequest(BaseModel):
r"""Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference."""
instructions: Optional[str] = None
- r"""Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers."""
+ r"""Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`."""
output_delivery: Optional[OutputDelivery] = None
r"""`stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`."""
diff --git a/src/openrouter/tts.py b/src/openrouter/tts.py
index 1726f3c8..3f8339d0 100644
--- a/src/openrouter/tts.py
+++ b/src/openrouter/tts.py
@@ -65,7 +65,7 @@ def create_speech(
:param x_open_router_categories: Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
:param input_references: Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference.
- :param instructions: Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers.
+ :param instructions: Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`.
:param output_delivery: `stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`.
:param provider: Provider configuration: provider routing preferences (`order`, `only`, `ignore`, `allow_fallbacks`), data policy routing preferences (`zdr`, `data_collection`) and provider-specific passthrough options
:param response_format: Audio output format. Defaults to `pcm`, or to `mp3` when `timestamp_granularities` is nonempty.
@@ -340,7 +340,7 @@ async def create_speech_async(
:param x_open_router_categories: Comma-separated list of app categories (e.g. \"cli-agent,cloud-agent\"). Used for marketplace rankings.
:param input_references: Reference content for stateless voice cloning or voice design. Audio mode: one to three `input_audio` parts, each optionally paired with a `text` part carrying its transcript (a single clip accepts its transcript before or after it; with multiple clips each transcript immediately follows its clip), plus at most one `image_url` part as a scene image on providers that condition the cloned voice on its setting; only routed to endpoints that support voice cloning (and multiple references or image references when those parts are sent). Image mode: exactly one `image_url` part; only routed to endpoints that support image references. Video mode: exactly one `video_url` part with a public http(s) URL, optionally with one to three `input_audio` parts (and their `text` transcripts) grouped as in audio mode, and no `image_url` part; Seed Audio 1.5 ignores those transcripts, so the words the voices speak go in `input`; only routed to endpoints that support video references (and voice cloning when clips are sent, plus multiple references for two or three clips). An empty array is treated as no reference.
- :param instructions: Delivery instructions for the whole request, such as tone, pacing, or emotion. Supported by OpenAI gpt-4o-mini-tts, Gemini TTS, and Fish Audio models. Ignored by other providers.
+ :param instructions: Delivery instructions for the whole request, such as tone, pacing, or emotion. For the selected endpoint in the [Speech Models API](https://openrouter.ai/docs/guides/overview/multimodal/tts#via-the-speech-models-api), look for `supported_parameters.instructions` in the `output_modalities` entry with `type: speech`.
:param output_delivery: `stream` (default) streams the audio bytes directly in the response body (or returns inline base64 JSON when `timestamp_granularities` is nonempty). `url` stores the generated audio in OpenRouter storage and returns a JSON response with a signed download `url`, `expires_at`, and `media_type` (plus `words` and/or `characters` when `timestamp_granularities` is nonempty). The URL is a bearer link: anyone holding it can download the audio until it expires, up to 24 hours after the audio was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. When a URL cannot be issued (zero-data-retention via account settings, guardrails, `provider.zdr`, or a ZDR endpoint; no workspace; or storage failure), untimed requests fall back to streaming raw audio bytes (except on a storage failure for responses larger than 10 MiB, which returns an error), and timed requests fall back to inline base64 JSON (`{audio, media_type, words?, characters?}`) with no `url`.
:param provider: Provider configuration: provider routing preferences (`order`, `only`, `ignore`, `allow_fallbacks`), data policy routing preferences (`zdr`, `data_collection`) and provider-specific passthrough options
:param response_format: Audio output format. Defaults to `pcm`, or to `mp3` when `timestamp_granularities` is nonempty.
diff --git a/uv.lock b/uv.lock
index 3bdfc1bb..e10df93a 100644
--- a/uv.lock
+++ b/uv.lock
@@ -231,7 +231,7 @@ wheels = [
[[package]]
name = "openrouter"
-version = "1.3.242"
+version = "1.3.243"
source = { editable = "." }
dependencies = [
{ name = "httpcore" },