YepAPI
AI Models

Kling Omni

Kling Omni API. One Kling model for reference-image video, first/last frame, and reference-video editing, 3-10 seconds.

Pricing, live playground and model overview: Kling Omni API on YepAPI

POST/v1/media/queue
from $0.19/second

Overview

Kling Omni — one Kling model for image-reference video, first/last-frame video and reference-video editing. Every request needs a reference: an image in imageData or a clip in options.referenceVideoUrl (for prompt-only video, use Kling 3.0 or Kling 4.0). Async operation — submit a job, poll for completion.

PropertyValue
Model IDkwaivgi/kling-omni
Aliaskling-omni
ProviderKling
Inputsreference images, first/last frame, reference video (one is required)
Aspect Ratios16:9, 9:16, 1:1
Duration3–10 seconds (5 or 10 seconds in first/last-frame mode)
Audio GenerationNot supported
BillingPer job — priced when queued, charged only on success
Pricingfrom $0.19/second

Usage

All media models use the async job queue. Submit a job, then poll for the result.

Step 1: Submit Job

Reference Images

Pass an image via imageData (without imageRole) to use it as a reference for the subject, style or setting. options.params passes this model's own parameters (see Model parameters).

const res = await fetch('https://api.yepapi.com/v1/media/queue', {
  method: 'POST',
  headers: {
    'x-api-key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    model: 'kwaivgi/kling-omni',
    prompt: 'The character from the reference image walks through a neon-lit night market',
    options: {
      duration: '5',
    },
    imageData: {
      mimeType: 'image/jpeg',
      base64: '...', // Base64-encoded image
    },
  }),
});
curl -X POST https://api.yepapi.com/v1/media/queue \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "kwaivgi/kling-omni", "prompt": "The character from the reference image walks through a neon-lit night market", "options": {"duration": "5"}, "imageData": {"mimeType": "image/jpeg", "base64": "..."}}'

First / Last Frame

Set options.imageRole to first_frame to switch to first/last-frame mode: imageData becomes the opening frame, and an optional closing frame goes in options.params.last_frame_url as a public image URL.

const res = await fetch('https://api.yepapi.com/v1/media/queue', {
  method: 'POST',
  headers: {
    'x-api-key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    model: 'kwaivgi/kling-omni',
    prompt: 'Smooth transition from the opening frame to the closing frame, slow push-in',
    options: {
      aspectRatio: '16:9',
      duration: '5',
      imageRole: 'first_frame',
      params: {
        last_frame_url: 'https://example.com/last-frame.jpg',
      },
    },
    imageData: {
      mimeType: 'image/jpeg',
      base64: '...', // Base64-encoded image
    },
  }),
});
curl -X POST https://api.yepapi.com/v1/media/queue \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "kwaivgi/kling-omni", "prompt": "Smooth transition from the opening frame to the closing frame, slow push-in", "options": {"aspectRatio": "16:9", "duration": "5", "imageRole": "first_frame", "params": {"last_frame_url": "https://example.com/last-frame.jpg"}}, "imageData": {"mimeType": "image/jpeg", "base64": "..."}}'

Reference Video

Pass a public MP4 or MOV URL in options.referenceVideoUrl to restyle, edit or continue an existing clip.

const res = await fetch('https://api.yepapi.com/v1/media/queue', {
  method: 'POST',
  headers: {
    'x-api-key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    model: 'kwaivgi/kling-omni',
    prompt: 'Restyle this clip as a hand-drawn watercolor animation',
    options: {
      aspectRatio: '16:9',
      duration: '5',
      referenceVideoUrl: 'https://example.com/reference.mp4', // public MP4 or MOV URL
    },
  }),
});
curl -X POST https://api.yepapi.com/v1/media/queue \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "kwaivgi/kling-omni", "prompt": "Restyle this clip as a hand-drawn watercolor animation", "options": {"aspectRatio": "16:9", "duration": "5", "referenceVideoUrl": "https://example.com/reference.mp4"}}'

Step 2: Poll for Result

const status = await fetch(`https://api.yepapi.com/v1/media/status/${data.jobId}`, {
  headers: { 'x-api-key': 'YOUR_API_KEY' },
});
const { data: job } = await status.json();
// job.status — "pending" | "processing" | "completed" | "failed"
// job.result.video — { mimeType, base64 } when completed
curl https://api.yepapi.com/v1/media/status/JOB_ID \
  -H "x-api-key: YOUR_API_KEY"

Request Body

ParameterTypeRequiredDescriptionDefault
modelstringYeskwaivgi/kling-omni or alias kling-omni—
promptstringYesText description of the video to generate—
options.aspectRatiostringNoOne of: 16:9, 9:16, 1:116:9
options.durationstring or numberNo3 to 10 (seconds); 5 or 10 (seconds) in first/last-frame mode5
options.imageRolestringNofirst_frame switches to first/last-frame mode (imageData = first frame); omit to use imageData as a reference image—
options.referenceVideoUrlstringNoPublic MP4 or MOV URL of a reference video to restyle, edit or continue—
options.paramsobjectNoModel-specific parameters under their own names: elements, last_frame_url, mode. Unknown names return 400—
imageData.mimeTypestringNoMIME type of input image (image/png, image/jpeg, image/webp)—
imageData.base64stringNoBase64-encoded reference image, or the first frame with imageRole—

Options are validated when you submit: an unsupported duration, resolution or value returns 400 naming the allowed values.

Model parameters

Pass these inside options.params.

ParameterTypeAllowedDescriptionDefault
elementsarray—Kling element IDs to keep consistent across the clip (reference-image and reference-video modes)—
modestringstd, proQuality modepro
last_frame_urlstringpublic image URLPublic URL of the last frame (first/last-frame mode)—

Features

  • Reference-image video (a reference image or video is required)
  • First/last-frame mode (imageRole: 'first_frame' + options.params.last_frame_url)
  • Reference video via options.referenceVideoUrl
  • std or pro mode via options.params.mode

Pricing

Tier≈ Cost/sec5-second video
All requests$0.19$0.96

Prices shown are for a 5-second clip at the default settings; longer clips cost proportionally more. The mode parameter (std/pro) changes the price. Each job is priced when it's queued — the exact quote for your duration, resolution and options — and charged only if it succeeds. Failed or moderated jobs are free.

Info

Video jobs can take several minutes to complete. When capacity is busy, jobs wait in the queue (status stays pending or processing) — no action needed. Results retained for 1 hour.

Under the Hood

Powered by Kling's Kling Omni via our AI provider.

On this page