diff --git a/.oas-version b/.oas-version index 18b3114..feaae22 100644 --- a/.oas-version +++ b/.oas-version @@ -1 +1 @@ -1.10.4 +1.13.0 diff --git a/shotstack_sdk/__init__.py b/shotstack_sdk/__init__.py index 21a63c1..d3799ea 100644 --- a/shotstack_sdk/__init__.py +++ b/shotstack_sdk/__init__.py @@ -11,7 +11,7 @@ """ -__version__ = "1.10.4" +__version__ = "1.13.0" # import ApiClient from shotstack_sdk.api_client import ApiClient diff --git a/shotstack_sdk/api_client.py b/shotstack_sdk/api_client.py index 952fdb0..e020ea4 100644 --- a/shotstack_sdk/api_client.py +++ b/shotstack_sdk/api_client.py @@ -77,7 +77,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None, self.default_headers[header_name] = header_value self.cookie = cookie # Set default User-Agent. - self.user_agent = 'OpenAPI-Generator/1.10.4/python' + self.user_agent = 'OpenAPI-Generator/1.13.0/python' def __enter__(self): return self diff --git a/shotstack_sdk/configuration.py b/shotstack_sdk/configuration.py index 120b8b3..ada0268 100644 --- a/shotstack_sdk/configuration.py +++ b/shotstack_sdk/configuration.py @@ -410,7 +410,7 @@ def to_debug_report(self): "OS: {env}\n"\ "Python Version: {pyversion}\n"\ "Version of the API: v1\n"\ - "SDK Package Version: 1.10.4".\ + "SDK Package Version: 1.13.0".\ format(env=sys.platform, pyversion=sys.version) def get_host_settings(self): diff --git a/shotstack_sdk/model/asset.py b/shotstack_sdk/model/asset.py index 13eb10b..d194bbc 100644 --- a/shotstack_sdk/model/asset.py +++ b/shotstack_sdk/model/asset.py @@ -38,6 +38,7 @@ def lazy_import(): CaptionMargin ChromaKey Crop + Html5Asset HtmlAsset ImageAsset ImageToVideoAsset @@ -101,6 +102,7 @@ class Asset(ModelComposed): ''caption'': 'caption', ''rich-caption'': 'rich-caption', ''html'': 'html', + ''html5'': 'html5', ''title'': 'title', ''shape'': 'shape', ''svg'': 'svg', @@ -172,10 +174,22 @@ class Asset(ModelComposed): ('src',): { 'min_length': 1, }, + ('html',): { + 'max_length': 1000000, + }, + ('seed',): { + 'min_length': 1, + }, ('speed',): { 'inclusive_maximum': 10, 'inclusive_minimum': 0, }, + ('css',): { + 'max_length': 500000, + }, + ('js',): { + 'max_length': 500000, + }, } additional_properties_type = None @@ -196,11 +210,13 @@ def openapi_types(): return { 'type': (str,), # noqa: E501 'src': (str,), # noqa: E501 + 'prompt': (str,), # noqa: E501 'text': (str,), # noqa: E501 + 'voice': (str,), # noqa: E501 'html': (str,), # noqa: E501 'shape': (str,), # noqa: E501 - 'prompt': (str,), # noqa: E501 - 'voice': (str,), # noqa: E501 + 'seed': (str,), # noqa: E501 + 'model': (str,), # noqa: E501 'transcode': (bool,), # noqa: E501 'trim': (float,), # noqa: E501 'volume': (AudioAssetVolume,), # noqa: E501 @@ -221,11 +237,14 @@ def openapi_types(): 'border': (Border,), # noqa: E501 'padding': (RichCaptionAssetPadding,), # noqa: E501 'align': (RichTextAlignment,), # noqa: E501 + 'language': (str,), # noqa: E501 + 'newscaster': (bool,), # noqa: E501 'effect': (str,), # noqa: E501 'margin': (CaptionMargin,), # noqa: E501 'active': (RichCaptionActive,), # noqa: E501 'css': (str,), # noqa: E501 'position': (str,), # noqa: E501 + 'js': (str,), # noqa: E501 'color': (str,), # noqa: E501 'size': (str,), # noqa: E501 'offset': (Offset,), # noqa: E501 @@ -234,8 +253,6 @@ def openapi_types(): 'circle': (ShapeAssetCircle,), # noqa: E501 'line': (ShapeAssetLine,), # noqa: E501 'aspect_ratio': (str,), # noqa: E501 - 'language': (str,), # noqa: E501 - 'newscaster': (bool,), # noqa: E501 } @cached_property @@ -245,6 +262,7 @@ def discriminator(): 'audio': AudioAsset, 'caption': CaptionAsset, 'html': HtmlAsset, + 'html5': Html5Asset, 'image': ImageAsset, 'image-to-video': ImageToVideoAsset, 'luma': LumaAsset, @@ -259,6 +277,7 @@ def discriminator(): 'video': VideoAsset, 'AudioAsset': AudioAsset, 'CaptionAsset': CaptionAsset, + 'Html5Asset': Html5Asset, 'HtmlAsset': HtmlAsset, 'ImageAsset': ImageAsset, 'ImageToVideoAsset': ImageToVideoAsset, @@ -280,11 +299,13 @@ def discriminator(): attribute_map = { 'type': 'type', # noqa: E501 'src': 'src', # noqa: E501 + 'prompt': 'prompt', # noqa: E501 'text': 'text', # noqa: E501 + 'voice': 'voice', # noqa: E501 'html': 'html', # noqa: E501 'shape': 'shape', # noqa: E501 - 'prompt': 'prompt', # noqa: E501 - 'voice': 'voice', # noqa: E501 + 'seed': 'seed', # noqa: E501 + 'model': 'model', # noqa: E501 'transcode': 'transcode', # noqa: E501 'trim': 'trim', # noqa: E501 'volume': 'volume', # noqa: E501 @@ -305,11 +326,14 @@ def discriminator(): 'border': 'border', # noqa: E501 'padding': 'padding', # noqa: E501 'align': 'align', # noqa: E501 + 'language': 'language', # noqa: E501 + 'newscaster': 'newscaster', # noqa: E501 'effect': 'effect', # noqa: E501 'margin': 'margin', # noqa: E501 'active': 'active', # noqa: E501 'css': 'css', # noqa: E501 'position': 'position', # noqa: E501 + 'js': 'js', # noqa: E501 'color': 'color', # noqa: E501 'size': 'size', # noqa: E501 'offset': 'offset', # noqa: E501 @@ -318,8 +342,6 @@ def discriminator(): 'circle': 'circle', # noqa: E501 'line': 'line', # noqa: E501 'aspect_ratio': 'aspectRatio', # noqa: E501 - 'language': 'language', # noqa: E501 - 'newscaster': 'newscaster', # noqa: E501 } read_only_vars = { @@ -331,13 +353,13 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 """Asset - a model defined in OpenAPI Keyword Args: - type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', 'image', 'text', 'rich-text', 'audio', 'luma', 'caption', 'rich-caption', 'html', 'title', 'shape', 'svg', 'text-to-image', 'image-to-video', 'text-to-speech', ] # noqa: E501 + type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', 'image', 'text', 'rich-text', 'audio', 'luma', 'caption', 'rich-caption', 'html', 'html5', 'title', 'shape', 'svg', 'text-to-image', 'image-to-video', 'text-to-speech', ] # noqa: E501 src (str): The image source URL. The URL must be publicly accessible or include credentials. - text (str): The text to convert to speech. - html (str): The HTML text string. See list of [supported HTML tags](https://shotstack.io/docs/guide/architecting-an-application/html-support/#supported-html-tags). - shape (str): The shape to display. prompt (str): The instructions for modifying the image into a video sequence. + text (str): The text to convert to speech. voice (str): The voice to use for the text-to-speech conversion. + html (str): The HTML markup for the asset. Max 1,000,000 characters. + shape (str): The shape to display. _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. @@ -368,6 +390,8 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + seed (str): Seed image URL for image-to-video generation. The image is used as the starting frame; `prompt` describes the motion. Has no effect unless `prompt` is set.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `polly-neural`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 transcode (bool): Set to `true` to force re-encoding of the video during preprocessing. This can help resolve compatibility issues, fix rotation problems, synchronize audio, or convert formats. The video will be processed to ensure optimal compatibility with the rendering engine.. [optional] # noqa: E501 trim (float): The start trim point of the audio clip, in seconds (defaults to 0). Audio will start from the trim point. The audio will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (AudioAssetVolume): [optional] # noqa: E501 @@ -388,11 +412,14 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 border (Border): [optional] # noqa: E501 padding (RichCaptionAssetPadding): [optional] # noqa: E501 align (RichTextAlignment): [optional] # noqa: E501 + language (str): The language code for the text-to-speech conversion.. [optional] # noqa: E501 + newscaster (bool): Set the voice to newscaster mode.. [optional] if omitted the server will use the default value of False # noqa: E501 effect (str): The effect to apply to the audio asset . [optional] # noqa: E501 margin (CaptionMargin): [optional] # noqa: E501 active (RichCaptionActive): [optional] # noqa: E501 - css (str): The CSS text string to apply styling to the HTML. See list of [support CSS properties](https://shotstack.io/docs/guide/architecting-an-application/html-support/#supported-css-properties).. [optional] # noqa: E501 + css (str): The CSS string applied to the HTML. Max 500,000 characters.. [optional] # noqa: E501 position (str): Place the title in one of nine predefined positions of the viewport. . [optional] # noqa: E501 + js (str): Optional JavaScript. Use for chart libraries, animations, or DOM manipulation. `gsap`, `d3`, `anime` and `lottie` are always available. CSS animations, transitions, and `Element.animate()` are also captured automatically. Max 500,000 characters. . [optional] # noqa: E501 color (str): Set the text color using hexadecimal color notation. Transparency is supported by setting the first two characters of the hex string (opposite to HTML), i.e. #80ffffff will be white with 50% transparency.. [optional] # noqa: E501 size (str): Set the relative size of the text using predefined sizes from xx-small to xx-large. . [optional] # noqa: E501 offset (Offset): [optional] # noqa: E501 @@ -401,8 +428,6 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 circle (ShapeAssetCircle): [optional] # noqa: E501 line (ShapeAssetLine): [optional] # noqa: E501 aspect_ratio (str): The aspect ratio (shape) of the video output.. [optional] # noqa: E501 - language (str): The language code for the text-to-speech conversion.. [optional] # noqa: E501 - newscaster (bool): Set the voice to newscaster mode.. [optional] if omitted the server will use the default value of False # noqa: E501 """ type = kwargs.get('type', 'video') @@ -473,13 +498,13 @@ def __init__(self, *args, **kwargs): # noqa: E501 """Asset - a model defined in OpenAPI Keyword Args: - type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', 'image', 'text', 'rich-text', 'audio', 'luma', 'caption', 'rich-caption', 'html', 'title', 'shape', 'svg', 'text-to-image', 'image-to-video', 'text-to-speech', ] # noqa: E501 + type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', 'image', 'text', 'rich-text', 'audio', 'luma', 'caption', 'rich-caption', 'html', 'html5', 'title', 'shape', 'svg', 'text-to-image', 'image-to-video', 'text-to-speech', ] # noqa: E501 src (str): The image source URL. The URL must be publicly accessible or include credentials. - text (str): The text to convert to speech. - html (str): The HTML text string. See list of [supported HTML tags](https://shotstack.io/docs/guide/architecting-an-application/html-support/#supported-html-tags). - shape (str): The shape to display. prompt (str): The instructions for modifying the image into a video sequence. + text (str): The text to convert to speech. voice (str): The voice to use for the text-to-speech conversion. + html (str): The HTML markup for the asset. Max 1,000,000 characters. + shape (str): The shape to display. _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. @@ -510,6 +535,8 @@ def __init__(self, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + seed (str): Seed image URL for image-to-video generation. The image is used as the starting frame; `prompt` describes the motion. Has no effect unless `prompt` is set.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `polly-neural`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 transcode (bool): Set to `true` to force re-encoding of the video during preprocessing. This can help resolve compatibility issues, fix rotation problems, synchronize audio, or convert formats. The video will be processed to ensure optimal compatibility with the rendering engine.. [optional] # noqa: E501 trim (float): The start trim point of the audio clip, in seconds (defaults to 0). Audio will start from the trim point. The audio will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (AudioAssetVolume): [optional] # noqa: E501 @@ -530,11 +557,14 @@ def __init__(self, *args, **kwargs): # noqa: E501 border (Border): [optional] # noqa: E501 padding (RichCaptionAssetPadding): [optional] # noqa: E501 align (RichTextAlignment): [optional] # noqa: E501 + language (str): The language code for the text-to-speech conversion.. [optional] # noqa: E501 + newscaster (bool): Set the voice to newscaster mode.. [optional] if omitted the server will use the default value of False # noqa: E501 effect (str): The effect to apply to the audio asset . [optional] # noqa: E501 margin (CaptionMargin): [optional] # noqa: E501 active (RichCaptionActive): [optional] # noqa: E501 - css (str): The CSS text string to apply styling to the HTML. See list of [support CSS properties](https://shotstack.io/docs/guide/architecting-an-application/html-support/#supported-css-properties).. [optional] # noqa: E501 + css (str): The CSS string applied to the HTML. Max 500,000 characters.. [optional] # noqa: E501 position (str): Place the title in one of nine predefined positions of the viewport. . [optional] # noqa: E501 + js (str): Optional JavaScript. Use for chart libraries, animations, or DOM manipulation. `gsap`, `d3`, `anime` and `lottie` are always available. CSS animations, transitions, and `Element.animate()` are also captured automatically. Max 500,000 characters. . [optional] # noqa: E501 color (str): Set the text color using hexadecimal color notation. Transparency is supported by setting the first two characters of the hex string (opposite to HTML), i.e. #80ffffff will be white with 50% transparency.. [optional] # noqa: E501 size (str): Set the relative size of the text using predefined sizes from xx-small to xx-large. . [optional] # noqa: E501 offset (Offset): [optional] # noqa: E501 @@ -543,8 +573,6 @@ def __init__(self, *args, **kwargs): # noqa: E501 circle (ShapeAssetCircle): [optional] # noqa: E501 line (ShapeAssetLine): [optional] # noqa: E501 aspect_ratio (str): The aspect ratio (shape) of the video output.. [optional] # noqa: E501 - language (str): The language code for the text-to-speech conversion.. [optional] # noqa: E501 - newscaster (bool): Set the voice to newscaster mode.. [optional] if omitted the server will use the default value of False # noqa: E501 """ type = kwargs.get('type', 'video') @@ -615,6 +643,7 @@ def _composed_schemas(): 'oneOf': [ AudioAsset, CaptionAsset, + Html5Asset, HtmlAsset, ImageAsset, ImageToVideoAsset, diff --git a/shotstack_sdk/model/audio_asset.py b/shotstack_sdk/model/audio_asset.py index c6fd637..0d2d251 100644 --- a/shotstack_sdk/model/audio_asset.py +++ b/shotstack_sdk/model/audio_asset.py @@ -77,6 +77,9 @@ class AudioAsset(ModelNormal): 'pattern': r'', # noqa: E501 }, }, + ('prompt',): { + 'max_length': 4000, + }, ('speed',): { 'inclusive_maximum': 10, 'inclusive_minimum': 0, @@ -101,6 +104,11 @@ def openapi_types(): return { 'type': (str,), # noqa: E501 'src': (str,), # noqa: E501 + 'prompt': (str,), # noqa: E501 + 'voice': (str,), # noqa: E501 + 'language': (str,), # noqa: E501 + 'newscaster': (bool,), # noqa: E501 + 'model': (str,), # noqa: E501 'trim': (float,), # noqa: E501 'volume': (AudioAssetVolume,), # noqa: E501 'speed': (float,), # noqa: E501 @@ -115,6 +123,11 @@ def discriminator(): attribute_map = { 'type': 'type', # noqa: E501 'src': 'src', # noqa: E501 + 'prompt': 'prompt', # noqa: E501 + 'voice': 'voice', # noqa: E501 + 'language': 'language', # noqa: E501 + 'newscaster': 'newscaster', # noqa: E501 + 'model': 'model', # noqa: E501 'trim': 'trim', # noqa: E501 'volume': 'volume', # noqa: E501 'speed': 'speed', # noqa: E501 @@ -128,11 +141,10 @@ def discriminator(): @classmethod @convert_js_args_to_python_args - def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 """AudioAsset - a model defined in OpenAPI Args: - src (str): The audio source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `audio` for audio assets.. defaults to 'audio', must be one of ['audio', ] # noqa: E501 @@ -166,9 +178,15 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The audio source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt. When `voice` is set, the prompt is the spoken text (text-to-speech). Without `voice`, the prompt describes generated music or sound effects. The generated `src` is filled in automatically.. [optional] # noqa: E501 + voice (str): Voice identifier for text-to-speech generation (e.g. `Matthew`, `Joanna`). Only meaningful when `prompt` is set.. [optional] # noqa: E501 + language (str): Optional BCP-47 language code (e.g. `en-US`) for text-to-speech. Only meaningful when `prompt` and `voice` are set.. [optional] # noqa: E501 + newscaster (bool): Set to `true` to use the voice's newscaster mode when supported. Only meaningful when `prompt` and `voice` are set.. [optional] if omitted the server will use the default value of False # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `polly-neural`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 trim (float): The start trim point of the audio clip, in seconds (defaults to 0). Audio will start from the in trim point. The audio will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (AudioAssetVolume): [optional] # noqa: E501 - speed (float): Adjust the playback speed of the audio clip between 0 (paused) and 10 (10x normal speed), where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire audio (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire audio (i.e. original length / 2).. [optional] # noqa: E501 + speed (float): Adjust the playback speed of the audio clip between 0 (paused) and 10 (10x normal speed), where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire audio (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire audio (i.e. original length / 2).. [optional] # noqa: E501 effect (str): The effect to apply to the audio asset . [optional] # noqa: E501 """ @@ -199,7 +217,6 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ @@ -220,11 +237,10 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 ]) @convert_js_args_to_python_args - def __init__(self, src, *args, **kwargs): # noqa: E501 + def __init__(self, *args, **kwargs): # noqa: E501 """AudioAsset - a model defined in OpenAPI Args: - src (str): The audio source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `audio` for audio assets.. defaults to 'audio', must be one of ['audio', ] # noqa: E501 @@ -258,9 +274,15 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The audio source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt. When `voice` is set, the prompt is the spoken text (text-to-speech). Without `voice`, the prompt describes generated music or sound effects. The generated `src` is filled in automatically.. [optional] # noqa: E501 + voice (str): Voice identifier for text-to-speech generation (e.g. `Matthew`, `Joanna`). Only meaningful when `prompt` is set.. [optional] # noqa: E501 + language (str): Optional BCP-47 language code (e.g. `en-US`) for text-to-speech. Only meaningful when `prompt` and `voice` are set.. [optional] # noqa: E501 + newscaster (bool): Set to `true` to use the voice's newscaster mode when supported. Only meaningful when `prompt` and `voice` are set.. [optional] if omitted the server will use the default value of False # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `polly-neural`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 trim (float): The start trim point of the audio clip, in seconds (defaults to 0). Audio will start from the in trim point. The audio will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (AudioAssetVolume): [optional] # noqa: E501 - speed (float): Adjust the playback speed of the audio clip between 0 (paused) and 10 (10x normal speed), where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire audio (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire audio (i.e. original length / 2).. [optional] # noqa: E501 + speed (float): Adjust the playback speed of the audio clip between 0 (paused) and 10 (10x normal speed), where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire audio (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire audio (i.e. original length / 2).. [optional] # noqa: E501 effect (str): The effect to apply to the audio asset . [optional] # noqa: E501 """ @@ -289,7 +311,6 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/shotstack_sdk/model/clip.py b/shotstack_sdk/model/clip.py index 740bef0..c65a17c 100644 --- a/shotstack_sdk/model/clip.py +++ b/shotstack_sdk/model/clip.py @@ -151,6 +151,7 @@ def openapi_types(): 'asset': (Asset,), # noqa: E501 'start': (ClipStart,), # noqa: E501 'length': (ClipLength,), # noqa: E501 + 'id': (str,), # noqa: E501 'fit': (str,), # noqa: E501 'scale': (ClipScale,), # noqa: E501 'width': (float,), # noqa: E501 @@ -174,6 +175,7 @@ def discriminator(): 'asset': 'asset', # noqa: E501 'start': 'start', # noqa: E501 'length': 'length', # noqa: E501 + 'id': 'id', # noqa: E501 'fit': 'fit', # noqa: E501 'scale': 'scale', # noqa: E501 'width': 'width', # noqa: E501 @@ -234,6 +236,7 @@ def _from_openapi_data(cls, asset, start, length, *args, **kwargs): # noqa: E50 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + id (str): Optional client-generated identifier. Used by client SDKs (e.g. the Shotstack Studio SDK) to reference a clip across edits without relying on its position in the timeline. The render API does not use this field and it does not appear in render output.. [optional] # noqa: E501 fit (str): Set how the asset should be scaled to fit the viewport using one of the following options: . [optional] # noqa: E501 scale (ClipScale): [optional] # noqa: E501 width (float): Set the width of the clip bounding box in pixels. This constrains the width of the clip, overriding the default behavior where clips fill the viewport width.. [optional] # noqa: E501 @@ -335,6 +338,7 @@ def __init__(self, asset, start, length, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + id (str): Optional client-generated identifier. Used by client SDKs (e.g. the Shotstack Studio SDK) to reference a clip across edits without relying on its position in the timeline. The render API does not use this field and it does not appear in render output.. [optional] # noqa: E501 fit (str): Set how the asset should be scaled to fit the viewport using one of the following options: . [optional] # noqa: E501 scale (ClipScale): [optional] # noqa: E501 width (float): Set the width of the clip bounding box in pixels. This constrains the width of the clip, overriding the default behavior where clips fill the viewport width.. [optional] # noqa: E501 diff --git a/shotstack_sdk/model/html5_asset.py b/shotstack_sdk/model/html5_asset.py new file mode 100644 index 0000000..953a05b --- /dev/null +++ b/shotstack_sdk/model/html5_asset.py @@ -0,0 +1,284 @@ +""" + Shotstack + + Official Python SDK for the Shotstack Cloud Video Editing API + + The version of the OpenAPI document: v1 + Contact: pypi@shotstack.io + Generated by: https://openapi-generator.tech +""" + + +import re # noqa: F401 +import sys # noqa: F401 + +from shotstack_sdk.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from shotstack_sdk.exceptions import ApiAttributeError + + + +class Html5Asset(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + ('type',): { + ''html5'': 'html5', + }, + } + + validations = { + ('html',): { + 'max_length': 1000000, + }, + ('css',): { + 'max_length': 500000, + }, + ('js',): { + 'max_length': 500000, + }, + } + + additional_properties_type = None + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'type': (str,), # noqa: E501 + 'html': (str,), # noqa: E501 + 'css': (str,), # noqa: E501 + 'js': (str,), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + + attribute_map = { + 'type': 'type', # noqa: E501 + 'html': 'html', # noqa: E501 + 'css': 'css', # noqa: E501 + 'js': 'js', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, html, *args, **kwargs): # noqa: E501 + """Html5Asset - a model defined in OpenAPI + + Args: + html (str): The HTML markup for the asset. Max 1,000,000 characters. + + Keyword Args: + type (str): The type of asset - set to `html5` for HTML5/CSS3/JS.. defaults to 'html5', must be one of ['html5', ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + css (str): The CSS string applied to the HTML. Max 500,000 characters.. [optional] # noqa: E501 + js (str): Optional JavaScript. Use for chart libraries, animations, or DOM manipulation. `gsap`, `d3`, `anime` and `lottie` are always available. CSS animations, transitions, and `Element.animate()` are also captured automatically. Max 500,000 characters. . [optional] # noqa: E501 + """ + + type = kwargs.get('type', 'html5') + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.type = type + self.html = html + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, html, *args, **kwargs): # noqa: E501 + """Html5Asset - a model defined in OpenAPI + + Args: + html (str): The HTML markup for the asset. Max 1,000,000 characters. + + Keyword Args: + type (str): The type of asset - set to `html5` for HTML5/CSS3/JS.. defaults to 'html5', must be one of ['html5', ] # noqa: E501 + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + css (str): The CSS string applied to the HTML. Max 500,000 characters.. [optional] # noqa: E501 + js (str): Optional JavaScript. Use for chart libraries, animations, or DOM manipulation. `gsap`, `d3`, `anime` and `lottie` are always available. CSS animations, transitions, and `Element.animate()` are also captured automatically. Max 500,000 characters. . [optional] # noqa: E501 + """ + + type = kwargs.get('type', 'html5') + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + self.type = type + self.html = html + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/shotstack_sdk/model/image_asset.py b/shotstack_sdk/model/image_asset.py index 2dca609..34297a2 100644 --- a/shotstack_sdk/model/image_asset.py +++ b/shotstack_sdk/model/image_asset.py @@ -71,6 +71,9 @@ class ImageAsset(ModelNormal): 'pattern': r'', # noqa: E501 }, }, + ('prompt',): { + 'max_length': 4000, + }, } additional_properties_type = None @@ -91,6 +94,8 @@ def openapi_types(): return { 'type': (str,), # noqa: E501 'src': (str,), # noqa: E501 + 'prompt': (str,), # noqa: E501 + 'model': (str,), # noqa: E501 'crop': (Crop,), # noqa: E501 } @@ -102,6 +107,8 @@ def discriminator(): attribute_map = { 'type': 'type', # noqa: E501 'src': 'src', # noqa: E501 + 'prompt': 'prompt', # noqa: E501 + 'model': 'model', # noqa: E501 'crop': 'crop', # noqa: E501 } @@ -112,11 +119,10 @@ def discriminator(): @classmethod @convert_js_args_to_python_args - def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 """ImageAsset - a model defined in OpenAPI Args: - src (str): The image source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `image` for images.. defaults to 'image', must be one of ['image', ] # noqa: E501 @@ -150,6 +156,9 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The image source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt to generate the image from. When set without `src`, the engine generates an image and fills `src` automatically. Use `model` to choose the generator.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `flux-schnell`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 crop (Crop): [optional] # noqa: E501 """ @@ -180,7 +189,6 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ @@ -201,11 +209,10 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 ]) @convert_js_args_to_python_args - def __init__(self, src, *args, **kwargs): # noqa: E501 + def __init__(self, *args, **kwargs): # noqa: E501 """ImageAsset - a model defined in OpenAPI Args: - src (str): The image source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `image` for images.. defaults to 'image', must be one of ['image', ] # noqa: E501 @@ -239,6 +246,9 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The image source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt to generate the image from. When set without `src`, the engine generates an image and fills `src` automatically. Use `model` to choose the generator.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `flux-schnell`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 crop (Crop): [optional] # noqa: E501 """ @@ -267,7 +277,6 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/shotstack_sdk/model/rich_caption_asset.py b/shotstack_sdk/model/rich_caption_asset.py index 40fe07e..ff41834 100644 --- a/shotstack_sdk/model/rich_caption_asset.py +++ b/shotstack_sdk/model/rich_caption_asset.py @@ -140,7 +140,7 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 """RichCaptionAsset - a model defined in OpenAPI Args: - src (str): The URL to an SRT or VTT subtitles file, or an alias reference to auto-generate captions from an audio or video clip. For file URLs, the URL must be publicly accessible or include credentials. For auto-captioning, use the format `alias://clip-name` where clip-name is the alias of an audio, video, or text-to-speech clip. + src (str): Source for the caption words. Accepts three formats: (1) the URL to a subtitle file (`.srt`, `.vtt`, `.ttml`, or `.dfxp`) which is parsed directly; (2) the URL to an audio or video media file (`.mp4`, `.mov`, `.webm`, `.mp3`, `.wav`, `.m4a`, `.flac`, `.aac`, `.ogg`, and related formats) which is auto-transcribed; (3) an alias reference in the form `alias://clip-name` where `clip-name` is the alias of another audio, video, or text-to-speech clip in the same timeline — the referenced clip's source is auto-transcribed. For file URLs, the URL must be publicly accessible or include credentials. Content is classified at runtime and unsupported content types (HTML, PDF, images, archives) are rejected with a structured error. Keyword Args: type (str): The type of asset - set to `rich-caption` for rich captions.. defaults to 'rich-caption', must be one of ['rich-caption', ] # noqa: E501 @@ -238,7 +238,7 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 """RichCaptionAsset - a model defined in OpenAPI Args: - src (str): The URL to an SRT or VTT subtitles file, or an alias reference to auto-generate captions from an audio or video clip. For file URLs, the URL must be publicly accessible or include credentials. For auto-captioning, use the format `alias://clip-name` where clip-name is the alias of an audio, video, or text-to-speech clip. + src (str): Source for the caption words. Accepts three formats: (1) the URL to a subtitle file (`.srt`, `.vtt`, `.ttml`, or `.dfxp`) which is parsed directly; (2) the URL to an audio or video media file (`.mp4`, `.mov`, `.webm`, `.mp3`, `.wav`, `.m4a`, `.flac`, `.aac`, `.ogg`, and related formats) which is auto-transcribed; (3) an alias reference in the form `alias://clip-name` where `clip-name` is the alias of another audio, video, or text-to-speech clip in the same timeline — the referenced clip's source is auto-transcribed. For file URLs, the URL must be publicly accessible or include credentials. Content is classified at runtime and unsupported content types (HTML, PDF, images, archives) are rejected with a structured error. Keyword Args: type (str): The type of asset - set to `rich-caption` for rich captions.. defaults to 'rich-caption', must be one of ['rich-caption', ] # noqa: E501 diff --git a/shotstack_sdk/model/rich_text_background.py b/shotstack_sdk/model/rich_text_background.py index 8c650bd..4bc9c29 100644 --- a/shotstack_sdk/model/rich_text_background.py +++ b/shotstack_sdk/model/rich_text_background.py @@ -71,6 +71,10 @@ class RichTextBackground(ModelNormal): ('border_radius',): { 'inclusive_minimum': 0, }, + ('padding',): { + 'inclusive_maximum': 200, + 'inclusive_minimum': 0, + }, } additional_properties_type = None @@ -91,6 +95,8 @@ def openapi_types(): 'color': (str,), # noqa: E501 'opacity': (float,), # noqa: E501 'border_radius': (float,), # noqa: E501 + 'wrap': (bool,), # noqa: E501 + 'padding': (int,), # noqa: E501 } @cached_property @@ -102,6 +108,8 @@ def discriminator(): 'color': 'color', # noqa: E501 'opacity': 'opacity', # noqa: E501 'border_radius': 'borderRadius', # noqa: E501 + 'wrap': 'wrap', # noqa: E501 + 'padding': 'padding', # noqa: E501 } read_only_vars = { @@ -148,6 +156,8 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 color (str): The background color using hexadecimal color notation.. [optional] # noqa: E501 opacity (float): The opacity of the background where 1 is opaque and 0 is transparent.. [optional] if omitted the server will use the default value of 1 # noqa: E501 border_radius (float): The border radius of the background box in pixels. Must be 0 or greater.. [optional] if omitted the server will use the default value of 0 # noqa: E501 + wrap (bool): When true, the background pill shrinks to fit the rendered text bounding box plus the asset's padding (and stroke width, if present), producing a pill or badge effect. When false (default), the background fills the full asset content area. Available on rich-text and rich-caption assets only; not supported on legacy `type: text`. . [optional] if omitted the server will use the default value of False # noqa: E501 + padding (int): Inner padding in pixels between the wrap pill edge and the rendered text. Only takes effect when `wrap: true`. When omitted, the renderer applies a sensible default proportional to the font size (approximately 12% of the active page font size on rich-caption assets). Set to 0 for a pill that hugs the text exactly. Available on rich-text and rich-caption assets only. . [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -232,6 +242,8 @@ def __init__(self, *args, **kwargs): # noqa: E501 color (str): The background color using hexadecimal color notation.. [optional] # noqa: E501 opacity (float): The opacity of the background where 1 is opaque and 0 is transparent.. [optional] if omitted the server will use the default value of 1 # noqa: E501 border_radius (float): The border radius of the background box in pixels. Must be 0 or greater.. [optional] if omitted the server will use the default value of 0 # noqa: E501 + wrap (bool): When true, the background pill shrinks to fit the rendered text bounding box plus the asset's padding (and stroke width, if present), producing a pill or badge effect. When false (default), the background fills the full asset content area. Available on rich-text and rich-caption assets only; not supported on legacy `type: text`. . [optional] if omitted the server will use the default value of False # noqa: E501 + padding (int): Inner padding in pixels between the wrap pill edge and the rendered text. Only takes effect when `wrap: true`. When omitted, the renderer applies a sensible default proportional to the font size (approximately 12% of the active page font size on rich-caption assets). Set to 0 for a pill that hugs the text exactly. Available on rich-text and rich-caption assets only. . [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/shotstack_sdk/model/text_background.py b/shotstack_sdk/model/text_background.py index 28cfae0..9d3d35f 100644 --- a/shotstack_sdk/model/text_background.py +++ b/shotstack_sdk/model/text_background.py @@ -96,6 +96,7 @@ def openapi_types(): 'opacity': (float,), # noqa: E501 'padding': (float,), # noqa: E501 'border_radius': (float,), # noqa: E501 + 'wrap': (bool,), # noqa: E501 } @cached_property @@ -108,6 +109,7 @@ def discriminator(): 'opacity': 'opacity', # noqa: E501 'padding': 'padding', # noqa: E501 'border_radius': 'borderRadius', # noqa: E501 + 'wrap': 'wrap', # noqa: E501 } read_only_vars = { @@ -155,6 +157,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 opacity (float): The opacity of the background where 1 is opaque and 0 is transparent.. [optional] # noqa: E501 padding (float): Padding inside the background box in pixels.. [optional] # noqa: E501 border_radius (float): The border radius of the background box in pixels for rounded corners.. [optional] # noqa: E501 + wrap (bool): Not supported on legacy `text` assets. Accepted here only so validators can emit a clear migration error pointing users to `rich-text` or `rich-caption`, which support background wrapping natively.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -240,6 +243,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 opacity (float): The opacity of the background where 1 is opaque and 0 is transparent.. [optional] # noqa: E501 padding (float): Padding inside the background box in pixels.. [optional] # noqa: E501 border_radius (float): The border radius of the background box in pixels for rounded corners.. [optional] # noqa: E501 + wrap (bool): Not supported on legacy `text` assets. Accepted here only so validators can emit a clear migration error pointing users to `rich-text` or `rich-caption`, which support background wrapping natively.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/shotstack_sdk/model/video_asset.py b/shotstack_sdk/model/video_asset.py index 0dae74f..afb14d3 100644 --- a/shotstack_sdk/model/video_asset.py +++ b/shotstack_sdk/model/video_asset.py @@ -79,6 +79,12 @@ class VideoAsset(ModelNormal): 'pattern': r'', # noqa: E501 }, }, + ('prompt',): { + 'max_length': 4000, + }, + ('seed',): { + 'min_length': 1, + }, ('speed',): { 'inclusive_maximum': 10, 'inclusive_minimum': 0, @@ -103,6 +109,9 @@ def openapi_types(): return { 'type': (str,), # noqa: E501 'src': (str,), # noqa: E501 + 'prompt': (str,), # noqa: E501 + 'seed': (str,), # noqa: E501 + 'model': (str,), # noqa: E501 'transcode': (bool,), # noqa: E501 'trim': (float,), # noqa: E501 'volume': (VideoAssetVolume,), # noqa: E501 @@ -120,6 +129,9 @@ def discriminator(): attribute_map = { 'type': 'type', # noqa: E501 'src': 'src', # noqa: E501 + 'prompt': 'prompt', # noqa: E501 + 'seed': 'seed', # noqa: E501 + 'model': 'model', # noqa: E501 'transcode': 'transcode', # noqa: E501 'trim': 'trim', # noqa: E501 'volume': 'volume', # noqa: E501 @@ -136,11 +148,10 @@ def discriminator(): @classmethod @convert_js_args_to_python_args - def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 """VideoAsset - a model defined in OpenAPI Args: - src (str): The video source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', ] # noqa: E501 @@ -174,11 +185,15 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The video source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt to generate the video from. When set without `src`, the engine generates a video and fills `src` automatically. Optionally pair with `seed` for image-to-video. Use `model` to choose the generator.. [optional] # noqa: E501 + seed (str): Seed image URL for image-to-video generation. The image is used as the starting frame; `prompt` describes the motion. Has no effect unless `prompt` is set.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `luma-ray-3`, `runpod-itv-mini`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 transcode (bool): Set to `true` to force re-encoding of the video during preprocessing. This can help resolve compatibility issues, fix rotation problems, synchronize audio, or convert formats. The video will be processed to ensure optimal compatibility with the rendering engine.. [optional] # noqa: E501 trim (float): The start trim point of the video clip, in seconds (defaults to 0). Videos will start from the in trim point. The video will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (VideoAssetVolume): [optional] # noqa: E501 volume_effect (str): Preset volume effects to apply to the video asset . [optional] # noqa: E501 - speed (float): Adjust the playback speed of the video clip between 0 (paused) and 10 (10x normal speed) where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire video (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire video (i.e. original length / 2).. [optional] # noqa: E501 + speed (float): Adjust the playback speed of the video clip between 0 (paused) and 10 (10x normal speed) where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire video (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire video (i.e. original length / 2).. [optional] # noqa: E501 crop (Crop): [optional] # noqa: E501 chroma_key (ChromaKey): [optional] # noqa: E501 """ @@ -210,7 +225,6 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ @@ -231,11 +245,10 @@ def _from_openapi_data(cls, src, *args, **kwargs): # noqa: E501 ]) @convert_js_args_to_python_args - def __init__(self, src, *args, **kwargs): # noqa: E501 + def __init__(self, *args, **kwargs): # noqa: E501 """VideoAsset - a model defined in OpenAPI Args: - src (str): The video source URL. The URL must be publicly accessible or include credentials. Keyword Args: type (str): The type of asset - set to `video` for videos.. defaults to 'video', must be one of ['video', ] # noqa: E501 @@ -269,11 +282,15 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 Animal class but this time we won't travel through its discriminator because we passed in _visited_composed_classes = (Animal,) + src (str): The video source URL. The URL must be publicly accessible or include credentials. Provide either `src` or `prompt`, not both.. [optional] # noqa: E501 + prompt (str): A text prompt to generate the video from. When set without `src`, the engine generates a video and fills `src` automatically. Optionally pair with `seed` for image-to-video. Use `model` to choose the generator.. [optional] # noqa: E501 + seed (str): Seed image URL for image-to-video generation. The image is used as the starting frame; `prompt` describes the motion. Has no effect unless `prompt` is set.. [optional] # noqa: E501 + model (str): The generation model to use when `prompt` is set (e.g. `luma-ray-3`, `runpod-itv-mini`). Defaults to the platform's preferred generator if omitted.. [optional] # noqa: E501 transcode (bool): Set to `true` to force re-encoding of the video during preprocessing. This can help resolve compatibility issues, fix rotation problems, synchronize audio, or convert formats. The video will be processed to ensure optimal compatibility with the rendering engine.. [optional] # noqa: E501 trim (float): The start trim point of the video clip, in seconds (defaults to 0). Videos will start from the in trim point. The video will play until the file ends or the Clip length is reached.. [optional] # noqa: E501 volume (VideoAssetVolume): [optional] # noqa: E501 volume_effect (str): Preset volume effects to apply to the video asset . [optional] # noqa: E501 - speed (float): Adjust the playback speed of the video clip between 0 (paused) and 10 (10x normal speed) where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire video (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire video (i.e. original length / 2).. [optional] # noqa: E501 + speed (float): Adjust the playback speed of the video clip between 0 (paused) and 10 (10x normal speed) where 1 is normal speed (defaults to 1). Adjusting the speed will also adjust the duration of the clip and may require you to adjust the Clip length. For example, if you set speed to 0.5, the clip will need to be 2x as long to play the entire video (i.e. original length / 0.5). If you set speed to 2, the clip will need to be half as long to play the entire video (i.e. original length / 2).. [optional] # noqa: E501 crop (Crop): [optional] # noqa: E501 chroma_key (ChromaKey): [optional] # noqa: E501 """ @@ -303,7 +320,6 @@ def __init__(self, src, *args, **kwargs): # noqa: E501 self._visited_composed_classes = _visited_composed_classes + (self.__class__,) self.type = type - self.src = src for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \