Ruka hadi kwenye maudhui

Vidu · Reference to Image

Unganisha

Kitambulisho cha modeli vidu/reference-to-image
# 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/vidu/reference-to-image?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",
    "images": [
      "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
    ]
  }'

# 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"

Ombi hili: $ 0.10 salio za API 100 Iendeshe kwenye ukurasa huu

Pata ufunguo wa API
Vidu Uhariri wa Picha Ingizo za marejeleo #images-to-image

Hutengeneza picha tulivu kutoka kwa kidokezo na picha za marejeo zinazohifadhi mwonekano wa mhusika

Vidu · Picha

Tokeo lako la kwanza linaonekana hapa

Unda ombi hapa chini na uliendeshe kwa ufunguo wako wa API. Matokeo yanakiliwa kwenye hifadhi yetu, yakihifadhiwa milele au 7 siku bila malipo.

Unda ombi

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

•inahitajika 88 / 1500

Maandishi ya kidokezo cha uundaji wa video, yenye kikomo cha herufi 1500.

•inahitajika reference_image_urls
Dondosha faili, au

URL za picha za rejeleo zinazotumika kudumisha mwonekano thabiti wa mhusika.

aspect_ratio chaguomsingi 16:9

Uwiano wa kipengele wa video ya tokeo.

Ya kina seed

Mbegu inayodhibiti nasibu wakati wa uzalishaji.

POST /run/vidu/reference-to-image?wait=20 makadirio → $ 0.10
# 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/vidu/reference-to-image?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",
    "images": [
      "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
    ]
  }'

# 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 Vidu · Reference to Image

Huchanganya `prompt` yenye hadi vibambo 1500 na picha kadhaa katika `reference_image_urls` ili kuunda picha mpya yenye vitu thabiti. `aspect_ratio` inaweza kuwa 16:9, 9:16 au 1:1, na `seed` inapatikana. Hutoa picha, si video.

Vigezo

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

JinaAina ChaguomsingiInaruhusiwa Maelezo
promptinahitajika
Ainastring
≤ herufi 1,500
Maandishi ya kidokezo cha uundaji wa video, yenye kikomo cha herufi 1500.
reference_image_urlsinahitajika images
Ainaurl[] · image
URL za picha za rejeleo zinazotumika kudumisha mwonekano thabiti wa mhusika.
aspect_ratiosi lazima
Ainaenum
Chaguomsingi16:9
16:99:161:1
Uwiano wa kipengele wa video ya tokeo.
seedsi lazima
Ainainteger | null
Mbegu inayodhibiti nasibu wakati wa uzalishaji.
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": "vidu/reference-to-image",
  "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": 100,
    "usd": "0.10",
    "charged": 100,
    "refunded": 0
  },
  "input": {
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field",
    "reference_image_urls": [
      "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
    ]
  },
  "output": {
    "image": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_name": "0-output.jpeg",
      "file_size": 1843200,
      "width": 1024,
      "height": 768
    }
  },
  "outputs": [
    {
      "type": "image",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "width": 1024,
      "height": 768,
      "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
image
object {url, content_type, file_name, file_size, width, height}Picha inayotokana na uhariri.

Miundo zaidi: Uhariri wa Picha

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