BYOKey Kling Image to Video
Kling image-to-video — animate a still, optionally end on a different frame
- start_frame
- end_frame
- output
- video_id
- duration
The image-to-video sibling of the pack's Kling text-to-video node, and honestly the more interesting one. BYOKey_Kling_Image2Video calls Kling's API (api.klingai.com, Bearer key) and animates a reference image into a video - with the nice twist that it also accepts an optional end_frame, so you can generate a video that starts on one image and transitions to another. That start-to-end control is the feature that makes this worth wiring into a workflow: product shots, scene transitions, character loops, morphing a concept render into a final look.
The KB's video coverage keeps Kling on the short list of hosted models people actually rate for motion quality, and unlike most of the pack's video nodes, this one carries separate controls for model, mode, cfg, ratio, and duration - no combined presets here (that's the text-to-video node's thing). More knobs, more fine control.
How it works
Standard submit-and-poll: POST the generation with your start_frame, optional end_frame, and prompt; poll until done; download the result into a ComfyUI VIDEO output. It blocks while waiting, governed by poll_interval (default 10s) and max_wait (default 600s). Alongside the video it also returns video_id and duration STRINGs for tracking and downstream timing.
The inputs that matter
start_frame- the reference image the video starts from. The tooltip has real constraints: at least 300x300px, aspect ratio between 1:2.5 and 2.5:1. Feed it something that obeys those or Kling may reject or degrade the job.end_frame- optional; same constraints as start_frame. Only when you actually want a two-endpoint transition - the interpolation is the expensive, exciting part.prompt+negative_prompt- both capped at 500 characters here (unlike the 2500 on the text-to-video node). Be economical: describe the motion and what to avoid, not the whole scene.model_name-kling-v2-master(default),kling-v2-1-master,kling-v2-5-turbo,kling-v2-1, or the v1 line (v1-6 down to v1-0). Newer/higher tiers are pricier and better.cfg_scale- 0 to 1, default 0.8. Prompt adherence; lower if motion is too literal, higher if it drifts.mode-std(standard) orpro. Note the tooltip: kling-v2-5-turbo forces pro mode, so don't pick turbo expecting cheap standard pricing.aspect_ratio- 16:9, 9:16, or 1:1.duration- 5 or 10 seconds.
Outputs: output (VIDEO), video_id (STRING), duration (STRING).
Installing it
It's one of 37 nodes in comfyui-byokey, no extra dependencies beyond ComfyUI's bundled torch/aiohttp/PIL/numpy/av. Install via ComfyUI Manager (search "byokey") or:
cd ComfyUI/custom_nodes
git clone https://github.com/MeteorAndy/comfyui-byokey.git
Restart, and it's under api/byokey/video. No model downloads - Kling renders it.
Gotchas
The frame constraints are the thing people trip on: a weird-aspect-ratio source image can get rejected or produce garbage motion, so crop/prepare your start_frame before wiring it in. And the cost story is the usual video one - 10s pro-mode runs add up, and the turbo model quietly forces you into pro mode, which is the kind of detail that shows up on your bill. Keep drafts at 5s/std and reserve pro for finals. Standard pack hygiene: your key is saved into the workflow JSON, so scrub it before sharing. If you've got a still that needs to move - or two stills that need to become one motion - this is the node.
Inputs (13)
| Name | Type | Default | Description |
|---|---|---|---|
| api_key | STRING | Kling API key (Bearer token) | |
| base_url | STRING | https://api.klingai.com | Kling API host. Override for relays/proxies. |
| start_frame | IMAGE | Reference image. At least 300x300px, aspect ratio 1:2.5 ~ 2.5:1. | |
| prompt | STRING | Positive text prompt. Max 500 characters. | |
| negative_prompt | STRING | Negative text prompt. Max 500 characters. | |
| model_name | COMBO | kling-v2-master | 8 options: kling-v2-master, kling-v2-1-master, kling-v2-5-turbo, kling-v2-1, kling-v1-6, kling-v1-5, +2 |
| cfg_scale | FLOAT | 0.800–1 | How closely the video follows the prompt. |
| mode | COMBO | std | std = standard, pro = higher quality. kling-v2-5-turbo forces pro. |
| aspect_ratio | COMBO | 16:9 | 3 options: 16:9, 9:16, 1:1 |
| duration | COMBO | 5 | 2 options: 5, 10 |
| end_frameopt | IMAGE | Optional end frame (image_tail). Same constraints as start_frame. | |
| poll_intervalopt | INT | 101–120 | Seconds between status polls. |
| max_waitopt | INT | 60030–3600 | Max seconds to wait for completion. |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| output | VIDEO | — |
| video_id | STRING | — |
| duration | STRING | — |