Skip to main content
References go into the references field of the POST /api/v1/generate body. There are two ways to provide them.
Then paste the whole asset object into references:
The model field at upload time is not required but it matters: the server uses the target model to decide the duration rules (for example the extra leeway for motion control) and how the file is stored. If you omit it, the file is handled with the general rules.
The filename in the response is the name in server storage, not the name of the file you sent. Keep id and url exactly as returned; do not build paths yourself.

Method 2 — public URL

Send an object containing url and let the server download it:
  • The server uses a 20 second timeout. Slow URLs, or ones that protect themselves against bots, fail with 400.
  • type may be omitted; the server detects it from the file contents (not from the extension). Stating type explicitly makes the behavior easier to predict.
  • The downloaded file is kept in Vidgen’s temporary storage, so you do not need to upload it a second time.
For URLs that need private headers (signed URLs, tokens), make sure the link is still valid when the request is made. The server sends no headers at all while downloading.

Limits enforced by the server

Maximum counts per model

These are defaults; each model can declare its own limits through capabilities.maxReferenceImages, maxReferenceVideos, and maxReferenceAudios in the catalog. Read them from there, not from this table.
Sending video or audio to an image model is always rejected with 400, whatever the count.

Practices that prevent failures

An uploaded asset can be used in many jobs as long as the file still exists. While you keep using the same reference, do not upload it again — the 60 files/hour limit runs out fast if every job resends an identical image.
If the reference image is 1:1 but you request ratio: "16:9", the model fills in the extra space. The most stable results come from references whose ratio already resembles the requested output.
Photos with a turned, covered, or poorly lit face are the most common cause of results that do not resemble the subject, or of jobs that fail at the alignment stage.
Text burned into the reference video tends to be reproduced by the model. Clean it up first, then upload.