Skip to main content
POST
cURL
Usa questo endpoint per avviare un task video Veo 3.1. L’API restituisce immediatamente un task ID, quindi salva l’id restituito e interroga il task finché non raggiunge uno stato terminale. POST /v1/videos usa multipart/form-data; passa i controlli scalari come campi del form e gli input multimediali come campi file input_reference.

Scegliere un modello

Scegliere una modalità di input

Impostare durata e dimensione

Per il percorso compatibile con OpenAI, usa seconds per la durata e size per la dimensione dell’output. Invia i valori come campi del form. Imposta size su uno dei valori WxH riportati di seguito.

Flusso del task

1

Creare il task

Invia la richiesta multipart form e salva l’id restituito.
2

Interrogare il task

Usa Veo3 Retrieve finché status non è completed, failed o error.
3

Scaricare il risultato

Quando il task è completed, scarica il file MP4 dalla risposta del task completato.

Autorizzazioni

Authorization
string
header
obbligatorio

Bearer authentication. Use your CometAPI API key.

Corpo

multipart/form-data
model
enum<string>
obbligatorio

Veo 3.1 model ID. Use veo3.1-fast for the default route or veo3.1 when you specifically need the standard model.

Opzioni disponibili:
veo3.1-fast,
veo3.1
Esempio:

"veo3.1-fast"

prompt
string
obbligatorio

Text prompt for the video job.

Esempio:

"A paper kite floats above a field."

seconds
enum<string>
predefinito:4

Requested clip duration. Use 4, 6, or 8. Send the value as a form field string.

Opzioni disponibili:
4,
6,
8
Esempio:

"4"

size
string

Supported WxH size values: 1280x720, 720x1280, 1920x1080, 3840x2160. Default is 1280x720.

Esempio:

"1280x720"

input_reference
file

Optional first-frame image file for image-to-video.

Risposta

Task created. Store the returned id and poll GET /v1/videos/{task_id}.

id
string
obbligatorio

Task ID. Use this value with retrieve and content endpoints.

Esempio:

"task_example"

object
string
obbligatorio

Object type. Video tasks return video.

Esempio:

"video"

model
string
obbligatorio

Model ID used for the task.

Esempio:

"veo3.1-fast"

status
enum<string>
obbligatorio

Task lifecycle status. Poll until the value is completed, failed, or error.

Opzioni disponibili:
queued,
in_progress,
completed,
failed,
error
Esempio:

"queued"

progress
integer
obbligatorio

Task progress as a coarse percentage.

Intervallo richiesto: 0 <= x <= 100
Esempio:

0

created_at
integer
obbligatorio

Task creation time as a Unix timestamp in seconds.

Esempio:

1779938152

task_id
string

Compatibility alias for id when present.

Esempio:

"task_example"

completed_at
integer

Task completion time as a Unix timestamp in seconds. This field appears on completed tasks.

Esempio:

1779938219

video_url
string

Temporary video delivery URL. This field appears on completed tasks.

Esempio:

"<temporary-video-url>"

error
object

Failure details. This field appears when the task fails.