Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "5.15.0"
".": "5.16.0"
}
8 changes: 4 additions & 4 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 63
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runwayml/runwayml-673462285f9cc77f80b538a726a55a7d003ce89b0dd5aeacf45b3901459abfa7.yml
openapi_spec_hash: 130cf273e4489beb3b7e2922f1ff26ae
config_hash: 8bd51a43d85b7a841080e78e6f673b63
configured_endpoints: 64
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runwayml/runwayml-72678a32f9ad57c2bed47a9c300c735e91b9f6e0a0583ea9cc549a066e343f82.yml
openapi_spec_hash: 79e4633b48de45cb04aeb086b8b08818
config_hash: e22d747d6682946b15b39a0d286ed0a8
20 changes: 19 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,30 @@
# Changelog

## 5.16.0 (2026-08-25)

Full Changelog: [v5.15.0...v5.16.0](https://github.com/runwayml/sdk-python/compare/v5.15.0...v5.16.0)

### Features

* **api:** add video_to_hdr (ruby) ([7d46450](https://github.com/runwayml/sdk-python/commit/7d464503dc7745ffa6c8e274ba4076f907da75e7))
* **api:** add HDR outputFormat on gen4.5 (text/image-to-video) and sdr_rec709_10bit on aleph2 ([7d46450](https://github.com/runwayml/sdk-python/commit/7d464503dc7745ffa6c8e274ba4076f907da75e7))
* **client:** make video_to_hdr waitable ([0a14fa2](https://github.com/runwayml/sdk-python/commit/0a14fa282d1c9a0ce9259ea00efbe16a2ad9b9c7))


### Bug Fixes

* **client:** drop duplicate generate/routers properties ([499c3c8](https://github.com/runwayml/sdk-python/commit/499c3c8f1c8ad3ef1033d55c8b7128c96c1e4cef))
* **client:** restore Client/AsyncClient aliases ([a45e3af](https://github.com/runwayml/sdk-python/commit/a45e3aff6bf892cf442b0ba78a5e8f846bdf6d2e))

## 5.15.0 (2026-08-18)

Full Changelog: [v5.14.0...v5.15.0](https://github.com/runwayml/sdk-python/compare/v5.14.0...v5.15.0)

### Features

* **api:** Seedance 2.5 1080p, Grok Imagine Video 1.5, Grok Imagine Image 2 ([46f53db](https://github.com/runwayml/sdk-python/commit/46f53dbc5ea2a643bacaf4a702974c5baebd45a0))
* **api:** add 1080p on seedance2_5 (text/image/video-to-video) ([46f53db](https://github.com/runwayml/sdk-python/commit/46f53dbc5ea2a643bacaf4a702974c5baebd45a0))
* **api:** add grok_imagine_1_5 (text/image-to-video) ([46f53db](https://github.com/runwayml/sdk-python/commit/46f53dbc5ea2a643bacaf4a702974c5baebd45a0))
* **api:** add grok_imagine_image_2 (text-to-image) ([46f53db](https://github.com/runwayml/sdk-python/commit/46f53dbc5ea2a643bacaf4a702974c5baebd45a0))


### Bug Fixes
Expand Down
48 changes: 30 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ Nested request parameters are [TypedDicts](https://docs.python.org/3/library/typ

Typed requests and responses provide autocomplete and documentation within your editor. If you would like to see type errors in VS Code to help catch bugs earlier, set `python.analysis.typeCheckingMode` to `basic`.

from datetime import datetime

## Pagination

List methods in the RunwayML API are paginated.
Expand All @@ -132,14 +134,16 @@ from runwayml import RunwayML

client = RunwayML()

all_routers = []
all_webapps = []
# Automatically fetches more pages as needed.
for router in client.routers.list(
for webapp in client.organization.webapp.list_usage(
from_=datetime.fromisoformat("2019-12-27T18:11:19.117"),
limit=1,
to=datetime.fromisoformat("2019-12-27T18:11:19.117"),
):
# Do something with router here
all_routers.append(router)
print(all_routers)
# Do something with webapp here
all_webapps.append(webapp)
print(all_webapps)
```

Or, asynchronously:
Expand All @@ -152,13 +156,15 @@ client = AsyncRunwayML()


async def main() -> None:
all_routers = []
all_webapps = []
# Iterate through items across all pages, issuing requests as needed.
async for router in client.routers.list(
async for webapp in client.organization.webapp.list_usage(
from_=datetime.fromisoformat("2019-12-27T18:11:19.117"),
limit=1,
to=datetime.fromisoformat("2019-12-27T18:11:19.117"),
):
all_routers.append(router)
print(all_routers)
all_webapps.append(webapp)
print(all_webapps)


asyncio.run(main())
Expand All @@ -167,8 +173,10 @@ asyncio.run(main())
Alternatively, you can use the `.has_next_page()`, `.next_page_info()`, or `.get_next_page()` methods for more granular control working with pages:

```python
first_page = await client.routers.list(
first_page = await client.organization.webapp.list_usage(
from_=datetime.fromisoformat("2019-12-27T18:11:19.117"),
limit=1,
to=datetime.fromisoformat("2019-12-27T18:11:19.117"),
)
if first_page.has_next_page():
print(f"will fetch next page using these details: {first_page.next_page_info()}")
Expand All @@ -181,13 +189,15 @@ if first_page.has_next_page():
Or just work directly with the returned data:

```python
first_page = await client.routers.list(
first_page = await client.organization.webapp.list_usage(
from_=datetime.fromisoformat("2019-12-27T18:11:19.117"),
limit=1,
to=datetime.fromisoformat("2019-12-27T18:11:19.117"),
)

print(f"next page cursor: {first_page.next_cursor}") # => "next page cursor: ..."
for router in first_page.data:
print(router.id)
for webapp in first_page.data:
print(webapp.credits)

# Remove `await` for non-async usage.
```
Expand All @@ -201,13 +211,15 @@ from runwayml import RunwayML

client = RunwayML()

text_to_image = client.text_to_image.create(
image_to_video = client.image_to_video.create(
duration=2,
model="gen4_image",
prompt_text="promptText",
ratio="1920:1080",
model="gen4.5",
prompt_image="https://example.com/image.jpg",
prompt_text="x",
ratio="1280:720",
content_moderation={},
)
print(text_to_image.id)
print(image_to_video.content_moderation)
```

## Handling errors
Expand Down
12 changes: 12 additions & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,18 @@ Methods:

- <code title="post /v1/video_to_video">client.video_to_video.<a href="./src/runwayml/resources/video_to_video.py">create</a>(\*\*<a href="src/runwayml/types/video_to_video_create_params.py">params</a>) -> <a href="./src/runwayml/types/video_to_video_create_response.py">VideoToVideoCreateResponse</a></code>

# VideoToHdr

Types:

```python
from runwayml.types import VideoToHdrCreateResponse
```

Methods:

- <code title="post /v1/video_to_hdr">client.video_to_hdr.<a href="./src/runwayml/resources/video_to_hdr.py">create</a>(\*\*<a href="src/runwayml/types/video_to_hdr_create_params.py">params</a>) -> <a href="./src/runwayml/types/video_to_hdr_create_response.py">VideoToHdrCreateResponse</a></code>

# TextToVideo

Types:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "runwayml"
version = "5.15.0"
version = "5.16.0"
description = "The official Python library for the runwayml API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion release-please-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"packages": {
".": {}
},
"$schema": "https://raw.githubusercontent.com/stainless-api/release-please/main/schemas/config.json",
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"include-v-in-tag": true,
"include-component-in-tag": false,
"versioning": "prerelease",
Expand Down
15 changes: 8 additions & 7 deletions scripts/mock

Large diffs are not rendered by default.

44 changes: 44 additions & 0 deletions src/runwayml/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
workflows,
organization,
sound_effect,
video_to_hdr,
avatar_videos,
image_upscale,
text_to_image,
Expand All @@ -72,6 +73,7 @@
from .resources.documents import DocumentsResource, AsyncDocumentsResource
from .resources.workflows import WorkflowsResource, AsyncWorkflowsResource
from .resources.sound_effect import SoundEffectResource, AsyncSoundEffectResource
from .resources.video_to_hdr import VideoToHdrResource, AsyncVideoToHdrResource
from .resources.avatar_videos import AvatarVideosResource, AsyncAvatarVideosResource
from .resources.image_upscale import ImageUpscaleResource, AsyncImageUpscaleResource
from .resources.text_to_image import TextToImageResource, AsyncTextToImageResource
Expand Down Expand Up @@ -199,6 +201,13 @@ def video_to_video(self) -> VideoToVideoResource:

return VideoToVideoResource(self)

@cached_property
def video_to_hdr(self) -> VideoToHdrResource:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import VideoToHdrResource

return VideoToHdrResource(self)

@cached_property
def text_to_video(self) -> TextToVideoResource:
"""These endpoints all kick off tasks to create generations."""
Expand Down Expand Up @@ -554,6 +563,13 @@ def video_to_video(self) -> AsyncVideoToVideoResource:

return AsyncVideoToVideoResource(self)

@cached_property
def video_to_hdr(self) -> AsyncVideoToHdrResource:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import AsyncVideoToHdrResource

return AsyncVideoToHdrResource(self)

@cached_property
def text_to_video(self) -> AsyncTextToVideoResource:
"""These endpoints all kick off tasks to create generations."""
Expand Down Expand Up @@ -845,6 +861,13 @@ def video_to_video(self) -> video_to_video.VideoToVideoResourceWithRawResponse:

return VideoToVideoResourceWithRawResponse(self._client.video_to_video)

@cached_property
def video_to_hdr(self) -> video_to_hdr.VideoToHdrResourceWithRawResponse:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import VideoToHdrResourceWithRawResponse

return VideoToHdrResourceWithRawResponse(self._client.video_to_hdr)

@cached_property
def text_to_video(self) -> text_to_video.TextToVideoResourceWithRawResponse:
"""These endpoints all kick off tasks to create generations."""
Expand Down Expand Up @@ -1021,6 +1044,13 @@ def video_to_video(self) -> video_to_video.AsyncVideoToVideoResourceWithRawRespo

return AsyncVideoToVideoResourceWithRawResponse(self._client.video_to_video)

@cached_property
def video_to_hdr(self) -> video_to_hdr.AsyncVideoToHdrResourceWithRawResponse:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import AsyncVideoToHdrResourceWithRawResponse

return AsyncVideoToHdrResourceWithRawResponse(self._client.video_to_hdr)

@cached_property
def text_to_video(self) -> text_to_video.AsyncTextToVideoResourceWithRawResponse:
"""These endpoints all kick off tasks to create generations."""
Expand Down Expand Up @@ -1197,6 +1227,13 @@ def video_to_video(self) -> video_to_video.VideoToVideoResourceWithStreamingResp

return VideoToVideoResourceWithStreamingResponse(self._client.video_to_video)

@cached_property
def video_to_hdr(self) -> video_to_hdr.VideoToHdrResourceWithStreamingResponse:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import VideoToHdrResourceWithStreamingResponse

return VideoToHdrResourceWithStreamingResponse(self._client.video_to_hdr)

@cached_property
def text_to_video(self) -> text_to_video.TextToVideoResourceWithStreamingResponse:
"""These endpoints all kick off tasks to create generations."""
Expand Down Expand Up @@ -1373,6 +1410,13 @@ def video_to_video(self) -> video_to_video.AsyncVideoToVideoResourceWithStreamin

return AsyncVideoToVideoResourceWithStreamingResponse(self._client.video_to_video)

@cached_property
def video_to_hdr(self) -> video_to_hdr.AsyncVideoToHdrResourceWithStreamingResponse:
"""These endpoints all kick off tasks to create generations."""
from .resources.video_to_hdr import AsyncVideoToHdrResourceWithStreamingResponse

return AsyncVideoToHdrResourceWithStreamingResponse(self._client.video_to_hdr)

@cached_property
def text_to_video(self) -> text_to_video.AsyncTextToVideoResourceWithStreamingResponse:
"""These endpoints all kick off tasks to create generations."""
Expand Down
2 changes: 1 addition & 1 deletion src/runwayml/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "runwayml"
__version__ = "5.15.0" # x-release-please-version
__version__ = "5.16.0" # x-release-please-version
14 changes: 14 additions & 0 deletions src/runwayml/resources/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,14 @@
SoundEffectResourceWithStreamingResponse,
AsyncSoundEffectResourceWithStreamingResponse,
)
from .video_to_hdr import (
VideoToHdrResource,
AsyncVideoToHdrResource,
VideoToHdrResourceWithRawResponse,
AsyncVideoToHdrResourceWithRawResponse,
VideoToHdrResourceWithStreamingResponse,
AsyncVideoToHdrResourceWithStreamingResponse,
)
from .avatar_videos import (
AvatarVideosResource,
AsyncAvatarVideosResource,
Expand Down Expand Up @@ -228,6 +236,12 @@
"AsyncVideoToVideoResourceWithRawResponse",
"VideoToVideoResourceWithStreamingResponse",
"AsyncVideoToVideoResourceWithStreamingResponse",
"VideoToHdrResource",
"AsyncVideoToHdrResource",
"VideoToHdrResourceWithRawResponse",
"AsyncVideoToHdrResourceWithRawResponse",
"VideoToHdrResourceWithStreamingResponse",
"AsyncVideoToHdrResourceWithStreamingResponse",
"TextToVideoResource",
"AsyncTextToVideoResource",
"TextToVideoResourceWithRawResponse",
Expand Down
Loading