Kuaishoukling-4.0-flash
Kuaishou Kling 4.0 Flash: the quicker Kling 4.0, 3 to 20 second clips at 720p from a prompt, a first frame, or fino a 10 reference images and 5 reference videos, with a soundtrack of its own
$0.07536/ secondo-20%$0.0942prezzo ufficialeNessun addebito per le generazioni non riuscite
- 3–20 second clips
- 720p
- Fino a 10 images, 5 videos
- Soundtrack on by default
- Modalità
- Video
- Endpoint
- /v1/videos/generations
- ID del modello
- kling-4.0-flash
- Provider
- Kuaishou
Kling 4.0 Flash API: panoramica
Endpoint documentato
Le richieste video vanno a /v1/videos/generations. La tabella dei parametri qui sotto elenca i campi documentati per questa interfaccia.
Sviluppatore del modello
Kling 4.0 Flash è pubblicato da Kuaishou e nell'API si invoca con l'ID del modello kling-4.0-flash.
Output e limiti
3–20 seconds; 720p only; one output per request; text: 21:9, 16:9, 1:1 or 9:16, and references may also use adaptive; a first frame sets the shape (adaptive), and no last frame is taken; an edit (omni_reference_task_type edit) changes reference_videos[0] and keeps its length, the other references steering it; fino a 10 images and 5 videos, 15 in totale, and no reference audio; reference videos 3–20 secondi ciascuno and 20 in totale, 700–4553 pixels a side at 24–60 fps; reference images at least 300 pixels a side with a width to height ratio from 0.4 to 2.5; with a reference video, the billed seconds are twice the output, or the reference videos and the output together when the reference videos run longer; prompt obbligatorio, fino a 26,000 English or 11,000 other characters; name references as @image1 or @video1; a soundtrack is generated unless generate_audio is false
Kling 4.0 Flash API: prezzi
Kling 4.0 Flash è fatturato il 20% in meno del prezzo di listino ufficiale su ogni voce qui sotto.
| Voce | Tariffa ArgoLink | Prezzo ufficiale | Risparmi |
|---|---|---|---|
| 720p | $0.07536 / secondo | -20% | |
| 720p con input video | $0.0502 / secondo | -20% |
3–20 seconds; 720p only; one output per request; text: 21:9, 16:9, 1:1 or 9:16, and references may also use adaptive; a first frame sets the shape (adaptive), and no last frame is taken; an edit (omni_reference_task_type edit) changes reference_videos[0] and keeps its length, the other references steering it; fino a 10 images and 5 videos, 15 in totale, and no reference audio; reference videos 3–20 secondi ciascuno and 20 in totale, 700–4553 pixels a side at 24–60 fps; reference images at least 300 pixels a side with a width to height ratio from 0.4 to 2.5; with a reference video, the billed seconds are twice the output, or the reference videos and the output together when the reference videos run longer; prompt obbligatorio, fino a 26,000 English or 11,000 other characters; name references as @image1 or @video1; a soundtrack is generated unless generate_audio is false
Kling 4.0 Flash API: riferimento
Avvio rapido
Crea una chiave API nella console, poi usa l’URL di base, l’endpoint e il corpo della richiesta indicati in questa pagina.
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "A slow aerial shot over a foggy pine forest at sunrise"
}'
curl https://argolink.io/v1/videos/$REQUEST_ID \
-H "Authorization: Bearer $ARGOLINK_API_KEY"
curl -L https://argolink.io/v1/videos/$REQUEST_ID/content \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-o output.mp4
import os
import time
import requests
headers = {"Authorization": f"Bearer {os.environ['ARGOLINK_API_KEY']}"}
job = requests.post(
"https://argolink.io/v1/videos/generations",
headers=headers,
json={"model": "kling-4.0-flash", "prompt": "A slow aerial shot over a foggy pine forest at sunrise"},
timeout=600,
)
job.raise_for_status()
request_id = job.json()["request_id"]
while True:
status = requests.get(f"https://argolink.io/v1/videos/{request_id}", headers=headers, timeout=60).json()
if status["status"] in ("done", "failed", "expired"):
break
time.sleep(5)
if status["status"] == "done":
video = requests.get(f"https://argolink.io/v1/videos/{request_id}/content", headers=headers, timeout=600)
open("output.mp4", "wb").write(video.content)
Modalità
Da testo a video
Solo un prompt
La chiamata più breve possibile: è obbligatorio solo prompt, e con i campi omessi vengono generati e fatturati 5 secondi a 720p 16:9.
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "Lenta ripresa aerea su una pineta avvolta nella nebbia al sorgere del sole",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "16:9"
}'
| Campo | Valore |
|---|---|
prompt | obbligatorio, fino a 26,000 characters; describe the camera move, the subject and the mood |
duration | 3–20 secondi interi, predefinito 5 |
resolution | 720p |
aspect_ratio | 21:9 · 16:9 · 1:1 · 9:16, predefinito 16:9 |
size | pixel al posto di resolution più aspect_ratio, quindi 1280x720 è 720p 16:9 |
Una richiesta genera un solo video; seed e watermark non sono supportati, e il risultato ha una traccia audio generata a meno che generate_audio non sia false.
Riferimento
Segue le immagini, i video o l'audio che fornisci
Il risultato segue il soggetto, il movimento o il ritmo degli asset che invii. Richiamane uno dal prompt con @Image 1, @Video 1 o @Audio 1; anche gli asset che non nomini vengono usati.
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "Fai camminare @Image 1 in una strada piovosa di notte",
"duration": 5,
"resolution": "720p",
"reference_images": [{"url": "https://example.com/subject.png"}]
}'
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "La ragazza in @Image 1 balla al ritmo di @Audio 1, muovendosi come chi balla in @Video 1",
"duration": 10,
"resolution": "720p",
"reference_images": [{"url": "https://example.com/girl.png"}],
"reference_videos": [{"url": "https://example.com/dance.mp4"}],
"reference_audios": [{"url": "https://example.com/beat.mp3"}]
}'
| Campo | Valore |
|---|---|
prompt | obbligatorio; richiama un asset come @Image 1, @Video 1 o @Audio 1 |
reference_images | fino a 10 immagini HTTPS, JPEG o PNG |
reference_videos | fino a 5 clip, ciascuna 3–20 seconds and 20 secondi in totale |
reference_audios | non supportato su questa route |
duration | 3–20 secondi interi, predefinito 5 |
resolution | 720p |
aspect_ratio | 21:9 · 16:9 · 1:1 · 9:16 · adaptive, predefinito 16:9 |
Immagini e video si combinano liberamente, fino a 15 assets in total. Reference videos are billed at the output rate; le immagini di riferimento sono gratuite.
Primo e ultimo fotogramma
Fissa l'inizio e, se vuoi, la fine
start_image da solo è un primo fotogramma; aggiungi end_image e il modello genera la parte intermedia tra i due.
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "La camera avanza lentamente mentre le foglie volteggiano attraverso la scena",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "adaptive",
"start_image": {"url": "https://example.com/first-frame.png"}
}'
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"prompt": "Il giorno diventa notte sullo stesso skyline mentre si accendono le luci",
"duration": 5,
"resolution": "720p",
"aspect_ratio": "adaptive",
"start_image": {"url": "https://example.com/day.png"},
"end_image": {"url": "https://example.com/night.png"}
}'
| Campo | Valore |
|---|---|
prompt | obbligatorio; descrivi il movimento dell'inquadratura |
start_image | un'immagine HTTPS, che determina l'inquadratura del risultato |
end_image | facoltativo; un'immagine HTTPS su cui termina il video |
duration | 3–20 secondi interi, predefinito 5 |
resolution | 720p |
aspect_ratio | solo adaptive; segue il primo fotogramma |
Nessuno dei due campi si può combinare con asset di riferimento. Il risultato prende il rapporto più vicino a quello del primo fotogramma.
Modifica un video
Riscrivi un filmato che hai già
L'unica modalità che parte da un video: il risultato mantiene durata e rapporto di quel video, e scegli il livello con resolution.
curl https://argolink.io/v1/videos/generations \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-4.0-flash",
"omni_reference_task_type": "edit",
"prompt": "Rendi i colori più caldi e lascia invariato tutto il resto",
"resolution": "720p",
"reference_videos": [{"url": "https://example.com/street.mp4"}]
}'
| Campo | Valore |
|---|---|
omni_reference_task_type | edit |
reference_videos | la prima clip è il video da modificare, 3–20 secondi di durata |
reference_images | fino a 10 images and 4 more videos steer the edit |
prompt | obbligatorio, fino a 26,000 characters; say what to change |
resolution | 720p |
duration · aspect_ratio | presi dal video modificato, quindi omettili entrambi |
Il video modificato viene fatturato sia come output sia come video di riferimento: modificare un video di 5 secondi comporta 10 secondi fatturati. start_image ed end_image non si possono inviare qui.
Come caricare e usare gli asset di riferimento
Un tuo link, oppure un file locale caricato prima
The url of start_image, end_image and every entry of reference_images and reference_videos is an HTTPS address. Un link che ospiti già si usa così com'è, purché si possa scaricare senza effettuare l'accesso e ogni reindirizzamento resti su HTTPS. Un file locale va prima caricato, e il media_url che ricevi va inserito nella richiesta.
FILE=dance.mp4
TICKET=$(curl -fsS https://argolink.io/v1/media/uploads \
-H "Authorization: Bearer $ARGOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"model\":\"kling-4.0-flash\",\"type\":\"video\",\"content_type\":\"video/mp4\",\"size_bytes\":$(wc -c < "$FILE" | tr -d ' ')}")
curl -fsS -X PUT "$(jq -r .upload_url <<<"$TICKET")" \
-H "Content-Type: video/mp4" --data-binary @"$FILE"
# Put this media_url in reference_videos[].url
jq -r .media_url <<<"$TICKET"
Richiedere un ticket è gratuito e non crea alcun job: upload_url è valido per 15 minuti e la richiesta PUT deve avere il Content-Type che hai dichiarato; il media_url che ottieni in cambio resta leggibile per sette giorni.
| Campo | Formato | Dimensione | Durata |
|---|---|---|---|
reference_images · start_image · end_image | JPEG o PNG | ≤ 20 MiB | — |
reference_videos | MP4 o MOV | ≤ 100 MiB | 3–20 secondi ciascuno |
reference_videos[0] (il video da modificare) | MP4 o MOV | ≤ 100 MiB | 3–20 seconds |
Un asset fuori da questi limiti fa fallire il job con invalid_input prima che inizi la generazione, e non viene addebitato nulla.
Come richiamare i tuoi file nel prompt
Richiama un file dal prompt
Indica ogni riferimento con @, tipo e numero. Il numero è la sua posizione in reference_images, reference_videos o reference_audios, e ogni elenco parte da 1.
| Nel prompt | Indica |
|---|---|
@Immagine 1 | 1° elemento di reference_images |
@Video 1 | 1° elemento di reference_videos |
{
"model": "kling-4.0-flash",
"prompt": "La ragazza di @Immagine 1 balla al ritmo di @Audio 1 e si muove come la ballerina di @Video 1",
"reference_images": [
{
"url": "https://example.com/girl.png"
}
],
"reference_videos": [
{
"url": "https://example.com/dance.mp4"
}
],
"reference_audios": [
{
"url": "https://example.com/beat.mp3"
}
]
}
È la forma che inserisce l’area di lavoro della console quando scegli un riferimento dopo @. Sono riconosciuti anche immagine 1 senza @, <immagine 1>, @Image 1 e le stesse parole in altre lingue, come @图片1. Nominarli è facoltativo: tutti i riferimenti vengono usati comunque. Con @ o < >, un numero oltre la lunghezza dell’elenco viene rifiutato. Quando modifichi un video (omni_reference_task_type edit), @Video 1 è il video da modificare e non serve nominarlo; gli altri riferimenti mantengono il loro numero.
Kling 4.0 Flash API: parametri completi della richiesta
| Parametro | Tipo | Requisito | Funzione |
|---|---|---|---|
model | string | obbligatorio | The catalog identifier for this page: kling-4.0-flash. |
prompt | string | obbligatorio | Describes the video: camera motion, subject action and mood. This model needs one in every mode, assets or not. Name a reference in the prompt as @Image 1 or @Video 2. It holds al massimo 26,000 characters. |
duration | integer | facoltativo | Output length in whole seconds, 3 to 20; predefinito 5. An edit keeps the length of the video it edits, so leave it out there. |
resolution | string | facoltativo | Output resolution. This model accepts 720p only, which is also the default. |
aspect_ratio | string | facoltativo | Output aspect ratio: 21:9, 16:9, 1:1 or 9:16; predefinito 16:9. A reference request may also send adaptive, which follows the references. In first-frame and first-and-last-frame modes, send adaptive only; the result follows the first frame and uses the ratio closest to its first frame. An edit keeps its video's ratio, so leave it out there too. |
size | string | facoltativo | Pixels instead of resolution plus aspect_ratio, written WIDTHxHEIGHT: the short side picks the tier (720 for 720p) and the shape picks the ratio, so 1280x720 è 720p 16:9. It picks a tier and a ratio, not exact pixels; a resolution or aspect_ratio sent with it must match, or the request is rejected with 400. An edit takes a resolution name only. |
start_image | object | modalità con primo fotogramma | HTTPS URL del primo fotogramma. Da solo genera un video da primo fotogramma, con end_image un video da primo e ultimo fotogramma; non si può combinare con asset di riferimento. |
end_image | object | solo primo e ultimo fotogramma | HTTPS URL dell'ultimo fotogramma; invialo insieme a start_image. Il rapporto dell'immagine sorgente può essere diverso, perché il risultato lo adatta al primo fotogramma. |
reference_images | array | modalità riferimento e modifica | HTTPS URLs of reference images, fino a 10. Images, videos and audio together are limited to 15 per request. |
reference_videos | array | modalità riferimento e modifica | HTTPS URLs of reference videos, fino a 5 clip, ciascuna 3–20 seconds and 20 secondi in totale. Their seconds are billed like the output's. In an edit the first video is the one edited, 3–20 secondi di durata. |
reference_audios | array | non supportato | This model takes no reference audio: sending reference_audios is rejected with 400. |
omni_reference_task_type | string | solo modifica | Set it to edit to edit the first entry of reference_videos, 3–20 secondi di durata. Left out, auto and reference all make an ordinary request. |
seconds · ratio | — | nomi compatibili | Alias di duration e aspect_ratio; usa un solo nome per ciascun valore, mai entrambi. |
image_url · image_urls · video_urls · audio_urls · frame_images · input_references | — | nomi compatibili | Funzionano anche i nomi dei campi delle richieste fal e OpenRouter: image_url equivale a start_image; image_urls, video_urls e audio_urls sono le tre liste di riferimenti; gli elementi di frame_images con frame_type first_frame o last_frame sono start_image ed end_image; gli elementi di input_references di tipo image_url, video_url o audio_url sono riferimenti. Usa un solo nome per ogni input. |
n | integer | facoltativo | Deve essere 1 o omesso; ogni richiesta produce esattamente un video. |
generate_audio | boolean | facoltativo | Defaults to true: Kling 4.0 Flash scores the video itself. Send false for a silent result. |
seed · watermark | — | non supportato | Non disponibile su questo modello: qualsiasi seed, o watermark: true, viene rifiutato con 400. |
request_id | string | campo della risposta | Restituito dalla chiamata di invio; è l'unico identificativo accettato dagli endpoint di stato e di contenuto. |
progress · estimated_seconds_remaining | integer | campo della risposta | Restituiti dall'endpoint di stato mentre status è pending: progress stima l'avanzamento del job, da 0 a 99, ed estimated_seconds_remaining quanti secondi mancano; quest'ultimo viene omesso finché non c'è una stima. progress vale 100 quando status è done. |
video.url | string | campo della risposta | Link di download dell'MP4 finito quando status è done: un link ArgoLink che chiunque può aprire senza la chiave API, per 30 giorni. |
usage | object | campo della risposta | Restituito quando status è done: output_seconds, reference_video_seconds e billed_seconds, la loro somma, su cui viene fatturato il job. |
Kling 4.0 Flash API a confronto con modelli simili
| Modello | ID del modello | Provider | Tariffa | Ideale per |
|---|---|---|---|---|
| Kling 4.0 Flash | kling-4.0-flash | Kuaishou | $0.07536 / secondo | Kuaishou Kling 4.0 Flash: the quicker Kling 4.0, 3 to 20 second clips at 720p from a prompt, a first frame, or fino a 10 reference images and 5 reference videos, with a soundtrack of its own |
| Seedance 2.5 | seedance-2.5 | ByteDance Seed | $0.0874 / secondo | Il modello video Seedance più capace finora: clip da 30 secondi, fino a 50 asset di riferimento e supporto nativo per riferimenti con persone reali, senza approvazione manuale né verifiche aggiuntive |
| Grok Imagine Video 1.5 | grok-imagine-video-1.5 | xAI | $0.032 / secondo | Generazione video a 480p, 720p e 1080p, fatturata per secondo di output |
| Gemini Omni 1.2 Flash | gemini-omni-1.2-flash | $0.0215 / secondo | Google Gemini Omni 1.2 Flash: 3 to 15 second clips with native sound at 720p, 1080p or 4K, from a prompt, a first and last frame, fino a 10 reference images and 3 reference videos, or as an edit of a video |
Altri modelli dello stesso sviluppatore
- Kling 3.0Kuaishou Kling 3.0: 3 to 15 second clips at 720p, 1080p or 4K from a prompt, a first frame, or a first and a last frame, with or without a soundtrack$0.1134 / secondo
- Kling 4.0Kuaishou Kling 4.0: 3 to 30 second clips at 720p or 1080p from a prompt, or from fino a 10 reference images and 5 reference videos, with a soundtrack of its own$0.1256 / secondo
Altri modelli della stessa modalità
- Seedance 2.5Il modello video Seedance più capace finora: clip da 30 secondi, fino a 50 asset di riferimento e supporto nativo per riferimenti con persone reali, senza approvazione manuale né verifiche aggiuntive$0.0874 / secondo
- Grok Imagine Video 1.5Generazione video a 480p, 720p e 1080p, fatturata per secondo di output$0.032 / secondo
- Gemini Omni 1.2 FlashGoogle Gemini Omni 1.2 Flash: 3 to 15 second clips with native sound at 720p, 1080p or 4K, from a prompt, a first and last frame, fino a 10 reference images and 3 reference videos, or as an edit of a video$0.0215 / secondo
- MAGI-2Sand AI's MAGI-2: 4 to 30 second 1080p clips with native sound, from a prompt or from fino a 10 reference images, 5 reference videos and 5 audio clips$0.072 / secondo
Kling 4.0 Flash API: domande frequenti
Come effettuo una chiamata a Kling 4.0 Flash?
Create an API key in the console and POST https://argolink.io/v1/videos/generations con il campo model impostato su kling-4.0-flash. The response carries request_id, the only job identifier: poll GET https://argolink.io/v1/videos/{request_id}, which reports progress and estimated_seconds_remaining while the job is pending, until status is done, then download the MP4 from GET https://argolink.io/v1/videos/{request_id}/content, l'indirizzo che la risposta di stato restituisce in video.url.
Quanto costa Kling 4.0 Flash?
Si paga per secondo di output, a partire da $0.07536 al secondo nel livello più basso; ogni livello della tabella dei prezzi ha la propria tariffa al secondo, moltiplicata per la durata del video. Ogni livello costa il 20% in meno rispetto al prezzo di listino ufficiale al secondo ($0.0942 al secondo nel livello più basso). I video di riferimento, e il video da cui parte una modifica, sono fatturati come li conta il prezzo ufficiale di Kling: il doppio dei secondi di output se non durano più dell’output, altrimenti la loro durata esatta più l’output. Quindi un video di 5 secondi con un video di riferimento di 3 secondi viene fatturato per 10 secondi, e uno con un video di riferimento di 7.3 secondi per 12.3 secondi. Le immagini di riferimento sono gratuite. Viene fatturato solo un video completato; un job non riuscito o rifiutato non costa nulla. Con un input video, cioè un video di riferimento o il video da cui parte una modifica, ogni secondo fatturato viene addebitato alla tariffa «con input video» indicata nella tabella dei prezzi.
Quali modalità di input supporta Kling 4.0 Flash?
Tutto sullo stesso endpoint: reference (a prompt alone, or with images, videos and audio as references: fino a 10 reference_images, 5 reference_videos e 0 reference_audios, 15 in totale, in qualsiasi combinazione that includes an image or a video); first frame (start_image); first and last frames (start_image plus end_image on one aspect ratio); video editing (omni_reference_task_type edit, which edits the first entry of reference_videos). First-frame and first-and-last-frame videos take their aspect ratio from the first frame. Every asset is an HTTPS URL.
Cosa non supporta Kling 4.0 Flash?
Più di un video per richiesta (n deve essere 1 o omesso), qualsiasi seed oppure watermark: true; in questi casi viene restituito 400. L'output è un video H.264 in formato MP4 con una traccia audio generata, a meno che generate_audio non sia false.
Come viene scelto il rapporto d’aspetto di un video di Kling 4.0 Flash generato da un primo fotogramma?
Leave aspect_ratio out, or send adaptive, and the first frame decides: the video takes the closest of 21:9, 16:9, 1:1, 9:16, so the frame is cropped as little as possible. The two frame modes take no fixed ratio; naming one is rejected. With first and last frames, the source images may have different ratios; the result adapts the last frame to the first.
I video di Kling 4.0 Flash hanno l’audio?
Per impostazione predefinita sì: Kling 4.0 Flash scores the video itself. Send generate_audio: false for a silent result.