Skip to content

Commit 9cdfd74

Browse files
authored
feat(api-nodes): enable Kling 3.0 Motion Control (#12785)
1 parent bd21363 commit 9cdfd74

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

comfy_api_nodes/apis/kling.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,3 +148,4 @@ class MotionControlRequest(BaseModel):
148148
keep_original_sound: str = Field(...)
149149
character_orientation: str = Field(...)
150150
mode: str = Field(..., description="'pro' or 'std'")
151+
model_name: str = Field(...)

comfy_api_nodes/nodes_kling.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2747,6 +2747,7 @@ def define_schema(cls) -> IO.Schema:
27472747
"but the character orientation matches the reference image (camera/other details via prompt).",
27482748
),
27492749
IO.Combo.Input("mode", options=["pro", "std"]),
2750+
IO.Combo.Input("model", options=["kling-v3", "kling-v2-6"], optional=True),
27502751
],
27512752
outputs=[
27522753
IO.Video.Output(),
@@ -2777,6 +2778,7 @@ async def execute(
27772778
keep_original_sound: bool,
27782779
character_orientation: str,
27792780
mode: str,
2781+
model: str = "kling-v2-6",
27802782
) -> IO.NodeOutput:
27812783
validate_string(prompt, max_length=2500)
27822784
validate_image_dimensions(reference_image, min_width=340, min_height=340)
@@ -2797,6 +2799,7 @@ async def execute(
27972799
keep_original_sound="yes" if keep_original_sound else "no",
27982800
character_orientation=character_orientation,
27992801
mode=mode,
2802+
model_name=model,
28002803
),
28012804
)
28022805
if response.code:

0 commit comments

Comments
 (0)