Ruka hadi kwenye maudhui

Kling 4.0 Reference to Video

Unganisha

Kitambulisho cha modeli kling/v4/reference-to-video
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/kling/v4/reference-to-video?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Faili kama mfano: $ 1.175 salio za API 1,175 faili zako hupimwa kabla ya kuendesha Iendeshe kwenye ukurasa huu

Pata ufunguo wa API
Kling Rejeleo hadi Video Ingizo za marejeleo3–30 shadi 1080p #reference-to-video#multi-shot#image-reference#video-reference

Hutengeneza video za sekunde 3-30 zinazohifadhi mwonekano wa hadi picha 10 za marejeleo, video 5 za marejeleo na vipengele 7

Imetengenezwa kwenye Doitong

Kazi za umma zilizotengenezwa kwa Kling 4.0 na jumuiya ya Doitong. Tumia tena kidokezo kwa kubofya mara moja.

Kazi za umma zilizoonyeshwa: 16
Ultra-realistic cinematic video of a young adult woman walking naturally toward the camera while ... Video

Ultra-realistic cinematic video of a young adult woman walking naturally toward the camera while speaking, with realistic facial expressions and synchronized lip movements, as if she is promoting something to the viewer. She maintains eye contact with the camera, smiles slightly, and uses subtle...

Slow, subtle push-in on the woman's face. The light from the laptop flickers softly across her ey... Video

Slow, subtle push-in on the woman's face. The light from the laptop flickers softly across her eyes and cheeks, as if the blurry image on the screen is changing. Her eyes move slightly as she studies the screen, and she takes one slow, tense breath. Behind her, shadows of the snowstorm move...

The enormous ancient dragon descends slowly toward the snowy cliff and lands at the cave mouth. I... Video

The enormous ancient dragon descends slowly toward the snowy cliff and lands at the cave mouth. Its huge dark leathery wings beat twice with slow, heavy strokes, sending snow swirling off the cliff in big clouds. Then it folds its wings and settles on the rock, the giant elk still held in its...

**Duration: 5 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animat... Video

**Duration: 5 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animate the provided image into a bright, magical, energetic, professional YouTube intro for a children's entertainment channel, with perfectly synchronized sound effects, cheerful music, and a cute child's...

Authentic 1990s wide-angle film footage. The left man slowly pulls one wooden block from the Jeng... Video

Authentic 1990s wide-angle film footage. The left man slowly pulls one wooden block from the Jenga tower. As the block comes out, the tower naturally loses balance and realistically collapses onto the table. Frustrated, he angrily sweeps all the fallen wooden blocks off the table with both hands....

Thermal-camera view of a snowy mountain cliff at night in false-color, deep blue and violet cold ... Video

Thermal-camera view of a snowy mountain cliff at night in false-color, deep blue and violet cold rock, a huge orange-white heat shape hidden inside a rock crevice, two small bright amber spots glowing like eyes, faint noise grain. Cinematic videorealistic, ultra detailed, 16:9, volumetric light,...

**Duration: 4 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animat... Video

**Duration: 4 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animate the provided image into a bright, magical, energetic, professional YouTube intro for a children's entertainment channel, with perfectly synchronized sound effects, cheerful music, and a cute child's...

**Duration: 4 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animat... Video

**Duration: 4 seconds | Aspect ratio: 16:9 | Children's YouTube Intro | Video with Audio** Animate the provided image into a bright, magical, energetic, professional YouTube intro for a children's entertainment channel, with perfectly synchronized sound effects, cheerful music, and a cute child's...

Unda ombi

Vidhibiti vinazalishwa kutoka kwenye schema ya modeli. Msimbo na bei husasishwa unapovibadilisha.

88 / 2500

Maagizo ya uzalishaji yanayotimiza sharti la kutoa `prompt` au `multi_prompt`. Ili kurejelea maingizo yaliyotolewa, tumia @Image1, @Video1, @Element1, na kuendelea.

video_urls
Dondosha faili, au · hadi 5

Hadi video 5 za marejeleo, zinazorejelewa kwa kutumia @Video1, @Video2, na kuendelea; kila moja ina urefu wa sekunde 3–30 (sekunde 30.05 kwa kiwango cha juu), na muda wake wa pamoja pamoja na video za vipengele hauwezi kuzidi sekunde 30. Kila faili lazima isiwe kubwa kuliko 300 MB, huku upana na urefu kila kimoja kikiwa kati ya 700 px na 4553 px. Uwiano wa pande lazima uwe kati ya 0.40 na 2.50, na kasi ya fremu kati ya 23.9 na 60.05 FPS.

resolution chaguomsingi 1080p

Mwonekano wa tokeo.

aspect_ratio chaguomsingi 16:9

Uwiano wa video, unaochaguliwa wazi au kutolewa kutoka kwenye marejeleo kwa kuchagua 'auto'.

chaguomsingi 5

Urefu wa video kwa sekunde, kutoka 3 hadi 30.

Ya kina image · images · multi_prompt · elements
start_image_url
Dondosha faili, au

Picha ya hiari ya fremu ya kwanza inayohesabiwa katika kikomo cha picha za marejeleo. Ukubwa wa juu wa faili ni 30.0 MB; upana na urefu lazima kila kimoja kifikie 300 px, na uwiano wa pande uwe kati ya 0.40 na 2.50.

image_urls
Dondosha faili, au · hadi 10

Marejeleo ya picha yanayorejelewa kwa kutumia @Image1, @Image2, na kuendelea, yakiwa na picha zisizozidi 10. Kila faili ina kikomo cha 30.0 MB, inahitaji angalau 300 px katika vipimo vyote viwili, na lazima iwe na uwiano wa pande kati ya 0.40 na 2.50.

Maagizo ya uzalishaji ya picha kwa picha, ambapo kila kidokezo hufafanua picha moja na muda wake huchangia urefu wa jumla wa video.

Mkusanyiko wa hadi wahusika au vitu 7, ambapo visivyozidi 3 vinaweza kujumuisha `voice_id` na visivyozidi 3 vinaweza kutumia video. Rejelea vipengele hivi kama @Element1, @Element2, na kuendelea.

POST /run/kling/v4/reference-to-video?wait=20 makadirio → $ 1.175
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/kling/v4/reference-to-video?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Endesha ombi hili

Key yako inabaki kwenye kivinjari hiki: inatumwa kwa Doitong API pekee na kuhifadhiwa (localStorage) tu ukiweka tiki kwenye Kumbuka. Pata ufunguo wa API

Kuhusu Kling 4.0 Reference to Video

Huunda video kutoka kwa `prompt` ya maandishi pamoja na picha za marejeleo, video za marejeleo na vipengele vya wahusika au vitu, ambavyo vinatajwa kwenye kidokezo kama @Image1, @Video1 au @Element1. Muda ni kuanzia sekunde 3 hadi 30 (chaguomsingi ni 5), huku tokeo likiwa na mwonekano wa 720p au 1080p na uwiano wa pande auto, 16:9, 9:16, 1:1 au 21:9. Tumia `multi_prompt` kwa vidokezo vya kila picha, ambapo urefu wa jumla ni jumla ya muda wa picha hizo. Vikomo ni picha 10, video 5 za sekunde 3-30 kila moja, na vipengele 7, ambapo hadi 3 vinaweza kuwa na sauti.

Vigezo

Tuma jina rasmi au jina asilia, si yote mawili. Majina rasmi

JinaAina ChaguomsingiInaruhusiwa Maelezo
promptsi lazima
Ainastring | null
≤ herufi 2,500
Maagizo ya uzalishaji yanayotimiza sharti la kutoa `prompt` au `multi_prompt`. Ili kurejelea maingizo yaliyotolewa, tumia @Image1, @Video1, @Element1, na kuendelea.
multi_promptsi lazima
Ainaobject[]
Maagizo ya uzalishaji ya picha kwa picha, ambapo kila kidokezo hufafanua picha moja na muda wake huchangia urefu wa jumla wa video.
multi_prompt[].promptinahitajika
Ainastring
1 – 512 characters
Maagizo ya maandishi ya picha ya sasa.
multi_prompt[].durationsi lazima
Ainainteger
Chaguomsingi5
1 – 30
Muda wa picha moja, unaopimwa kwa sekunde.
durationsi lazima
Ainainteger
Chaguomsingi5
3 – 30
Urefu wa video kwa sekunde, kutoka 3 hadi 30.
start_image_urlsi lazima image
Ainaurl · image
Picha ya hiari ya fremu ya kwanza inayohesabiwa katika kikomo cha picha za marejeleo. Ukubwa wa juu wa faili ni 30.0 MB; upana na urefu lazima kila kimoja kifikie 300 px, na uwiano wa pande uwe kati ya 0.40 na 2.50.
image_urlssi lazima images
Ainaurl[] · image
≤ vipengee 10
Marejeleo ya picha yanayorejelewa kwa kutumia @Image1, @Image2, na kuendelea, yakiwa na picha zisizozidi 10. Kila faili ina kikomo cha 30.0 MB, inahitaji angalau 300 px katika vipimo vyote viwili, na lazima iwe na uwiano wa pande kati ya 0.40 na 2.50.
video_urlssi lazima videos
Ainaurl[] · video
≤ vipengee 5
Hadi video 5 za marejeleo, zinazorejelewa kwa kutumia @Video1, @Video2, na kuendelea; kila moja ina urefu wa sekunde 3–30 (sekunde 30.05 kwa kiwango cha juu), na muda wake wa pamoja pamoja na video za vipengele hauwezi kuzidi sekunde 30. Kila faili lazima isiwe kubwa kuliko 300 MB, huku upana na urefu kila kimoja kikiwa kati ya 700 px na 4553 px. Uwiano wa pande lazima uwe kati ya 0.40 na 2.50, na kasi ya fremu kati ya 23.9 na 60.05 FPS.
elementssi lazima
Ainaobject[]
≤ vipengee 7
Mkusanyiko wa hadi wahusika au vitu 7, ambapo visivyozidi 3 vinaweza kujumuisha `voice_id` na visivyozidi 3 vinaweza kutumia video. Rejelea vipengele hivi kama @Element1, @Element2, na kuendelea.
elements[].frontal_image_urlsi lazima
Ainaurl · image
Picha ya mbele inayoonyesha mwonekano mkuu wa kipengele. Ukubwa wa juu wa faili ni 30.0 MB; vipimo vyote viwili lazima viwe angalau 300 px, na uwiano wa pande lazima uwe kati ya 0.40 na 2.50.
elements[].reference_image_urlssi lazima
Ainaurl[] · image
≤ 3 items
Picha za ziada zinazoonyesha pembe tofauti za kipengele, zikiwa na mitazamo 1 hadi 3. Kila faili inaweza kuwa na ukubwa wa juu wa 30.0 MB, lazima iwe na angalau 300 px katika vipimo vyote viwili, na lazima iwe na uwiano wa pande kati ya 0.40 na 2.50.
elements[].video_urlsi lazima
Ainaurl · video
Uwakilishi wa video wa kipengele badala ya picha, wenye urefu wa sekunde 3–30 (sekunde 30.05 kwa kiwango cha juu). Faili lazima isizidi 300 MB; upana na urefu vyote viwili lazima viwe ndani ya 700–4553 px. Uwiano unaoauniwa wa pande ni 0.40–2.50, kwa kasi za fremu za 23.9–60.05 FPS.
elements[].voice_idsi lazima
Ainastring | null
Sauti iliyotolewa kwa kipengele.
resolutionsi lazima
Ainaenum
Chaguomsingi1080p
720p1080p
Mwonekano wa tokeo.
aspect_ratiosi lazima
Ainaenum
Chaguomsingi16:9
auto16:99:161:121:9
Uwiano wa video, unaochaguliwa wazi au kutolewa kutoka kwenye marejeleo kwa kuchagua 'auto'.
inahitajika Jina rasmi, pia linakubalika

Vigezo vya faili vinakubali URL ya umma ya https://, data: URI ya hadi 10 MB, au file_url ya upakiaji. Faili

Tokeo

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "kling/v4/reference-to-video",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 1175,
    "usd": "1.175",
    "charged": 1175,
    "refunded": 0
  },
  "input": {
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  },
  "output": {
    "video": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp4",
      "content_type": "video/mp4",
      "file_name": "0-output.mp4",
      "file_size": 1843200
    }
  },
  "outputs": [
    {
      "type": "video",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp4",
      "content_type": "video/mp4",
      "file_size": 1843200,
      "width": 1280,
      "height": 720,
      "duration": 5,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Faili zako, chaguo lakoKila outputs[].url ni nakala kwenye hifadhi yetu: huhifadhiwa milele (hutozwa kwa GB kwa mwezi) au 7 siku bila malipo, kulingana na mpangilio wa akaunti yako au ?storage=.
Muundo uleule kwenye kila modelitype, url, content_type, width, height na duration, kwa picha, video na sauti. output ni kitu cha matokeo cha modeli yenyewe.
Sehemu za tokeo
video
object {url, content_type, file_name, file_size}Video iliyozalishwa na modeli.

Miundo zaidi: Rejeleo hadi Video

Kwa mawakala wa AI: ukurasa huu katika Markdown unapatikana kwenye https://doitong.com/sw/developers/models/kling/v4/reference-to-video.md. Modeli na miongozo yote: https://doitong.com/developers/llms.txt