Saltar al cuntegna

Kling O1 First Frame Last Frame to Video [Pro]

Integrar

ID dal model kling-video/o1/image-to-video
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://vit.doitong.com/api/v1/run/kling-video/o1/image-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",
    "image": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

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

Questa dumonda: $0,56 560 credits API Lantschar sin questa pagina

Obtegna ina clav API
Kling · Video

Tes emprim resultat vegn qua

Construis ina dumonda sutvart e l'exequescha cun tia clav API. Outputs vegnan copiads en nossa memorisaziun, conservads per adina u 7 dis gratuitamain.

Construir ina dumonda

Ils controls vegnan generads dal schema dal model. Il code e ​​il pretsch s'actualiseschan durant che ti als midas.

•obligatori 88 / 2500

Referenzas da frame: @Image1 identifitgescha il frame da partenza, entant che @Image2 identifitgescha il frame final.

•obligatori start_image_url
Trametta in datoteca u

Maletg che furnescha il frame d’avertura dal video, limità a 50 MB. Ladezza ed autezza ston avair mintgina almain 300 px, cun ina proporziun da 0.40 fin 2.50. Il timeout è 20 secundas.

duration 5 s

Lunghezza dal video mesirada en secundas.

Avanzà end_image · enable_safety_checker
end_image_url
Trametta in datoteca u

Maletg che furnescha il frame final dal video, limità a 50 MB. Ladezza ed autezza ston avair mintgina almain 300 px, cun ina proporziun da 0.40 fin 2.50.

POST /run/kling-video/o1/image-to-video?wait=20 calculaziun → $0,56
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://vit.doitong.com/api/v1/run/kling-video/o1/image-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",
    "image": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

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

Executar questa dumonda

Tia clav resta en quest browser: ella vegn tramessa mo al Doitong API e memorisada (localStorage) mo sch'ella scheccas Tiar a memoria. Obtegnair ina clav API

Davart Kling O1 First Frame Last Frame to Video [Pro]

Animescha ina transiziun tranter in'imatg da partenza obligatorica (`start_image_url`) ed ina finala opziunala (`end_image_url`), guidada d'in prompt da fin a 2500 caracters. En il prompt, @Image1 sa referescha al frame da partenza ed @Image2 al frame final. `duration` po vegnir fixà da 3 fin 10 secundas en pass d'ina secunda. Questa è la versiun Pro dal model.

Parameters

Invia u il num canonic u il num nativ, betg omaduas. Nums canonics

NumTip StandardPermess Descripziun
enable_safety_checkeropziunal
Tipboolean
Standardtrue
Ils controlls da segirezza pon vegnir deactivads mo cun l’autorisaziun dal conto; dumondas senza autorisaziun vegnan adina controlladas.
promptobligatori
Tipstring
≤ 2 500 caracters
Referenzas da frame: @Image1 identifitgescha il frame da partenza, entant che @Image2 identifitgescha il frame final.
start_image_urlobligatori image
Tipurl · image
Maletg che furnescha il frame d’avertura dal video, limità a 50 MB. Ladezza ed autezza ston avair mintgina almain 300 px, cun ina proporziun da 0.40 fin 2.50. Il timeout è 20 secundas.
end_image_urlopziunal end_image
Tipurl · image
Maletg che furnescha il frame final dal video, limità a 50 MB. Ladezza ed autezza ston avair mintgina almain 300 px, cun ina proporziun da 0.40 fin 2.50.
durationopziunal
Tipenum
Standard5
345678910
Lunghezza dal video mesirada en secundas.
obligatori Num canonic, er acceptà

Ils parameters da datotecas acceptan ina URL publica https://, ina URI data: fin a 10 MB u il file_url d'ina chargiada. Datotecas

Output

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "kling-video/o1/image-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": 560,
    "usd": "0.56",
    "charged": 560,
    "refunded": 0
  },
  "input": {
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field",
    "start_image_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  },
  "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://vit.doitong.com/api/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://vit.doitong.com/api/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Tias datotecas, tia decisiunMintga outputs[].url è ina copia en nossa memorisaziun: conservada per adina (pajà per GB-mes) u 7 dis gratuitamain, tenor la configuraziun dal conto u ?storage=.
La medema structura per mintga modeltype, url, content_type, width, height e duration, tant per maletgs sco per video e audio. output è l'object da resultat dal model sez.
Champs da l'output
video
object {url, content_type, file_name, file_size}Video producì dal model.

Dapli models: Maletg a video

Per agents AI: questa pagina sco Markdown è disponibla sut https://doitong.com/rm/developers/models/kling-video/o1/image-to-video.md. Tut ils models e las guidas: https://doitong.com/developers/llms.txt