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 .sdk.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"id": "4b61b700-10e9-475a-aa03-c2cf9488f9bd",
"id": "e02520db-ece6-46e6-baee-c209b0871330",
"tracked_paths": [
{
"editable": true,
Expand Down
2 changes: 1 addition & 1 deletion magic_hour/environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class Environment(enum.Enum):
"""Pre-defined base URLs for the API"""

ENVIRONMENT = "https://api.magichour.ai"
MOCK_SERVER = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.99.0"
MOCK_SERVER = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.100.0"


def _get_base_url(
Expand Down
30 changes: 15 additions & 15 deletions magic_hour/resources/v1/character_replace/README.md

Large diffs are not rendered by default.

26 changes: 18 additions & 8 deletions magic_hour/resources/v1/character_replace/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ def generate(
] = type_utils.NOT_GIVEN,
model: typing.Union[
typing.Optional[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal[
"kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"
]
],
type_utils.NotGiven,
] = type_utils.NOT_GIVEN,
Expand Down Expand Up @@ -135,7 +137,9 @@ def create(
end_seconds: float,
model: typing.Union[
typing.Optional[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal[
"kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"
]
],
type_utils.NotGiven,
] = type_utils.NOT_GIVEN,
Expand Down Expand Up @@ -187,8 +191,9 @@ def create(
model: Model to use. Defaults to `wan-animate`.

* **`wan-animate`**: 480p, 720p. Supports `points` subject selection.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–10 seconds in `replace` mode or 3–30 seconds in `animate` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–30 seconds in `replace` mode or 1–60 seconds in `animate` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–30 seconds in `animate` mode or 3–10 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`kling-4.0`**: 720p, 1080p. Clips of 3–30 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–60 seconds in `animate` mode or 1–30 seconds in `replace` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
name: Give your video a custom name for easy identification.
resolution: Output video resolution. Must be supported by `model`. Defaults to the lowest resolution available on your plan for that model.
start_seconds: Start time of your clip (seconds). Must be ≥ 0.
Expand Down Expand Up @@ -267,7 +272,9 @@ async def generate(
] = type_utils.NOT_GIVEN,
model: typing.Union[
typing.Optional[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal[
"kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"
]
],
type_utils.NotGiven,
] = type_utils.NOT_GIVEN,
Expand Down Expand Up @@ -356,7 +363,9 @@ async def create(
end_seconds: float,
model: typing.Union[
typing.Optional[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal[
"kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"
]
],
type_utils.NotGiven,
] = type_utils.NOT_GIVEN,
Expand Down Expand Up @@ -408,8 +417,9 @@ async def create(
model: Model to use. Defaults to `wan-animate`.

* **`wan-animate`**: 480p, 720p. Supports `points` subject selection.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–10 seconds in `replace` mode or 3–30 seconds in `animate` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–30 seconds in `replace` mode or 1–60 seconds in `animate` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–30 seconds in `animate` mode or 3–10 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`kling-4.0`**: 720p, 1080p. Clips of 3–30 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–60 seconds in `animate` mode or 1–30 seconds in `replace` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
name: Give your video a custom name for easy identification.
resolution: Output video resolution. Must be supported by `model`. Defaults to the lowest resolution available on your plan for that model.
start_seconds: Start time of your clip (seconds). Must be ≥ 0.
Expand Down
9 changes: 5 additions & 4 deletions magic_hour/types/params/v1_character_replace_create_body.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,15 @@ class V1CharacterReplaceCreateBody(typing_extensions.TypedDict):
"""

model: typing_extensions.NotRequired[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal["kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"]
]
"""
Model to use. Defaults to `wan-animate`.

* **`wan-animate`**: 480p, 720p. Supports `points` subject selection.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–10 seconds in `replace` mode or 3–30 seconds in `animate` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–30 seconds in `replace` mode or 1–60 seconds in `animate` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
* **`kling-3.0`**: 720p, 1080p. Clips of 3–30 seconds in `animate` mode or 3–10 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`kling-4.0`**: 720p, 1080p. Clips of 3–30 seconds in `replace` mode. Picks the main person automatically, so `points` are rejected.
* **`minimax-h3`**: 480p, 720p, 1080p. Clips of 1–60 seconds in `animate` mode or 1–30 seconds in `replace` mode. Subject `points` are `replace`-only; `animate` with `selection_mode` `point` returns 422, and with `auto` or no `selection_mode` the points are ignored.
"""

name: typing_extensions.NotRequired[str]
Expand Down Expand Up @@ -78,7 +79,7 @@ class _SerializerV1CharacterReplaceCreateBody(pydantic.BaseModel):
alias="end_seconds",
)
model: typing.Optional[
typing_extensions.Literal["kling-3.0", "minimax-h3", "wan-animate"]
typing_extensions.Literal["kling-3.0", "kling-4.0", "minimax-h3", "wan-animate"]
] = pydantic.Field(alias="model", default=None)
name: typing.Optional[str] = pydantic.Field(alias="name", default=None)
resolution: typing.Optional[typing_extensions.Literal["1080p", "480p", "720p"]] = (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class V1CharacterReplaceCreateBodyStyle(typing_extensions.TypedDict):

prompt: typing_extensions.NotRequired[str]
"""
Optional direction. Supported by kling-3.0, minimax-h3. For MiniMax H3 in replace mode, ignored and not saved when `selection_mode` is `point`; applies only to automatic person selection.
Optional direction. Supported by kling-3.0, kling-4.0, minimax-h3. For MiniMax H3 in replace mode, ignored and not saved when `selection_mode` is `point`; applies only to automatic person selection.
"""

selection_mode: typing_extensions.NotRequired[
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "magic_hour"
version = "0.99.0"
version = "0.100.0"
description = "Python SDK for Magic Hour API"
readme = "README.md"
authors = ["Magic Hour <support@magichour.ai>"]
Expand Down
Loading