Kling 4.0 Video Edit

kwaivgi/kling-v4.0/video-edit

kwaivgi/kling-v4.0/video-edit. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

İlgili modeller

Kling 4.0 Video Edit İlgili modeller 1

Tüm parametreler, çıktı şeması ve güncel fiyatlar

Yapay zeka model API pazarıTek platformda her şeyEn popülerKoşullarGörsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.
prompt *Prompttextarea—≤ 5000 chars
imagesReference imagesimage_upload—image/* · 0–10 items
keep_original_soundKeep original soundbooleantrue—
resolutionResolutionselect720p720p | 1080p
durationDurationselect—3 ~ 30 · step 1 · 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | …
aspect_ratioAspect ratioselect—16:9 | 9:16 | 1:1 | 21:9

Tüm parametreler, çıktı şeması ve güncel fiyatlar

Daha fazla bilgiTek platformda her şeyGörsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.
videosarray<string>

API

Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

cURL
# 1) Submit — returns { "task_uuid": "..." }
curl -X POST "https://www.namifusion.com/api/v1/marketplace/run/kwaivgi/kling-v4.0/video-edit" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "prompt": "A cinematic portrait, dramatic rim light, shallow depth of field",
    "keep_original_sound": true,
    "resolution": "720p"
  }
}'

# 2) Poll until status is "completed", then read the output URLs
curl "https://www.namifusion.com/api/v1/marketplace/run/tasks/TASK_UUID" \
  -H "Authorization: Bearer YOUR_API_KEY"
Python
import time, requests

API_KEY = "YOUR_API_KEY"
HEADERS = {"Authorization": f"Bearer {API_KEY}"}

# 1) Submit
resp = requests.post(
    "https://www.namifusion.com/api/v1/marketplace/run/kwaivgi/kling-v4.0/video-edit",
    headers=HEADERS,
    json={
        "input": {
            "prompt": "A cinematic portrait, dramatic rim light, shallow depth of field",
            "keep_original_sound": True,
            "resolution": "720p"
        }
    },
)
resp.raise_for_status()  # 401/402/429/5xx stop here instead of polling a bad task
task = resp.json()

# 2) Poll until a terminal state (completed / failed / cancelled).
#    This model is allowed up to 1800s server-side.
deadline = time.time() + 1860
while task.get("status") not in ("completed", "failed", "cancelled"):
    if time.time() > deadline:
        raise TimeoutError(f"still {task.get('status')} — keep the task_uuid and poll later")
    time.sleep(3)
    poll = requests.get(f"https://www.namifusion.com/api/v1/marketplace/run/tasks/{task['task_uuid']}", headers=HEADERS)
    poll.raise_for_status()
    task = poll.json()

print(task["status"], task.get("output"))
JavaScript
const API_KEY = "YOUR_API_KEY";
const HEADERS = { Authorization: `Bearer ${API_KEY}` };

// 1) Submit
const resp = await fetch("https://www.namifusion.com/api/v1/marketplace/run/kwaivgi/kling-v4.0/video-edit", {
  method: "POST",
  headers: { ...HEADERS, "Content-Type": "application/json" },
  body: JSON.stringify({
    "input": {
      "prompt": "A cinematic portrait, dramatic rim light, shallow depth of field",
      "keep_original_sound": true,
      "resolution": "720p"
    }
  }),
});
if (!resp.ok) throw new Error(`submit failed: ${resp.status} ${await resp.text()}`);
let task = await resp.json();

// 2) Poll until a terminal state (completed / failed / cancelled).
//    This model is allowed up to 1800s server-side.
const deadline = Date.now() + 1860 * 1000;
while (!["completed", "failed", "cancelled"].includes(task.status)) {
  if (Date.now() > deadline) throw new Error(`still ${task.status} — keep the task_uuid and poll later`);
  await new Promise((r) => setTimeout(r, 3000));
  const poll = await fetch(`https://www.namifusion.com/api/v1/marketplace/run/tasks/${task.task_uuid}`, { headers: HEADERS });
  if (!poll.ok) throw new Error(`poll failed: ${poll.status}`);
  task = await poll.json();
}

console.log(task.status, task.output);

API belgeleri

Kling 4.0 · Video Edit

Edit an existing video using a text instruction and optional image references. Specify what should change and what motion or composition should be preserved.

Inputs

  • prompt: required string.
  • video: required single video-URL string, not an array. Source video must be at least 3 seconds; footage beyond 30 seconds is trimmed.
  • images: optional image-URL array, at most 10.
  • keep_original_sound: boolean, default true. Set false to generate new synchronized audio.
  • resolution: "720p" (default) or "1080p".
  • duration: optional integer from 3 through 30. If omitted, it follows input duration, rounded up to whole seconds and capped at 30; there is no fixed 5-second default.
  • aspect_ratio: optional "16:9", "9:16", "1:1" or "21:9". Omit to follow the source video; do not send "auto".

Limits and references

Refer to the source as @Video1. @Image1, @Image2 and later image references follow images array order. This endpoint does not accept a videos array or audio-reference uploads.

List price and initial credit charge

720p: $0.094 per counted second. 1080p: $0.141 per counted second.

Let D be output seconds and V = ceil(min(total input-video seconds, 30)). With video input, cost = rate × (D + max(D, V)). At 720p, D=5 and an 8.2-second input give V=9 and a cost of $1.316; the initial charge is 131.60 credits.

If duration is omitted, D=V. When D=V=5, cost is $0.94 at 720p or $1.41 at 1080p. The effective $0.188/$0.282 per output second is not a general formula for unequal input and output lengths.

1 USD = 100 Nami credits. Round the total charge upward to 0.01 credit: credits = ceil(cost_usd × 10000) / 100. These are list prices; no promotional discount is applied.

Reference images, aspect ratio and audio-preservation settings add no separate charge.

MaaS mapping

video remains a single string in MaaS; images remains an array. Preserve omission of duration and aspect_ratio when following the input. All other named fields retain their names in MaaS. Send duration as an integer and keep_original_sound as a boolean where supported. Array order is preserved.

Nami API

Send a POST request with Authorization: Bearer YOUR_NAMI_API_KEY and Content-Type: application/json to:

https://www.namifusion.com/api/v1/marketplace/run/kwaivgi/kling-v4.0/video-edit

Example request body:

{
  "input": {
    "video": "https://example.com/source-video.mp4",
    "images": [
      "https://example.com/jacket-reference.jpg"
    ],
    "prompt": "Change the jacket in @Video1 to match @Image1. Preserve the original subject motion, camera movement and background.",
    "keep_original_sound": true,
    "resolution": "720p"
  }
}

Replace example.com URLs with publicly accessible media URLs. Use the returned task_uuid to poll GET https://www.namifusion.com/api/v1/marketplace/run/tasks/{task_uuid} with the same authorization. On success, read generated video URLs from output.videos.

İlgili modeller

VT Lip Sync
Videodan videoyaNamiFusion

VT Lip Sync

namifusion/vt-lipsync. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.200 / çalıştırma başına
Kling Omni Video O3
Videodan videoyaKling

Kling Omni Video O3

kwaivgi/kling-video-o3/video-edit. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.378 / çalıştırma başına
Kling Omni Video O3
Videodan videoyaKling

Kling Omni Video O3

kwaivgi/kling-video-o3/reference-to-video. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.630 / çalıştırma başına
Kling 3.0 Standard
Videodan videoyaKling

Kling 3.0 Standard

kwaivgi/kling-v3.0/motion-control. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.378 / çalıştırma başına
seedance-2-0 reference-to-video
Videodan videoyaDoubao

seedance-2-0 reference-to-video

doubao/seedance-2-0/reference-to-video. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.4413 / çalıştırma başına
black-forest-labs/flux-3/video-upscale
Videodan videoyaBlack Forest Labs

black-forest-labs/flux-3/video-upscale

black-forest-labs/flux-3/video-upscale. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.790 / çalıştırma başına
black-forest-labs/flux-3/video-extend-draft
Videodan videoyaBlack Forest Labs

black-forest-labs/flux-3/video-extend-draft

black-forest-labs/flux-3/video-extend-draft. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $0.600 / çalıştırma başına
black-forest-labs/flux-3/video-extend
Videodan videoyaBlack Forest Labs

black-forest-labs/flux-3/video-extend

black-forest-labs/flux-3/video-extend. Görsel, video ve yüz değiştirme model API’lerine göz at. Bir modeli dene ve birleşik REST API ile entegre et.

başlangıç $2.05 / çalıştırma başına