create generation with files
The multipart/form-data form of POST /v2/generate — the same endpoint as “Create Generation”, for uploading local files directly instead of passing URLs. Send each file under a field named for its type (video, image, audio), at most one of each. The application parser allows up to 5 GiB (5 × 1024³ bytes) per file, 3 files, 32 fields, 35 total parts, and 1 MiB per field. A file over the parser limit returns 413 generation_input_validation_failed, and a file over your plan limit returns 422 file_size_exceeds_plan_limit. Proxy limits may be lower; this ceiling does not guarantee a 5 GiB direct transfer. Each file is saved as an asset in your organization and passed to the generation by assetId. For large files, upload via POST /v2/assets/upload first and pass the assetId, so retries don’t resend the file. Nested fields such as input, options, segments, outputAudio, dubParams, and dialogueEdit must be sent as JSON strings in multipart requests. Image inputs are sync-3 only. If a text input requires speech synthesis and the ElevenLabs provider is temporarily unavailable, the request returns errorCode elevenlabs_service_unavailable: 504 for provider timeouts and 503 for other provider outages for unkeyed requests. Keyed uncertain outcomes return 503 IDEMPOTENCY_OUTCOME_UNKNOWN instead. An older dialogueEdit preview without segment lipsync and section expansion returns dialogue_edit_retime_required (422). Create a new preview from the same transcript and edits. A dialogueEdit that removes more speech than the surrounding footage can absorb returns errorCode dialogue_edit_removal_too_large (422). When the failing section can be identified, dialogueEditSection on the error names it; change it and create a new preview before submitting again. Retrying the same preview fails again. Send the optional Idempotency-Key header on the first request and reuse it with the same payload on retries. An accepted replay returns 200 with the original generation’s current state and Idempotency-Replayed: true. A retry after that generation ended FAILED or REJECTED starts a new generation instead (201). An API-key request without the header that is identical to one your organization sent in the last 60 seconds returns 409 DUPLICATE_SUBMISSION with the original generationId; send a unique Idempotency-Key with each generation you intend. See Idempotent Requests for key validation, conflicts, retention, duplicates, and uncertain-outcome recovery.
Autenticación
Solicitud
Use content type multipart/form-data to upload local files directly. The application parser caps each file at 5 GiB; plan and proxy limits also apply. Combining file and URL inputs is supported; a file replaces any input items of the same type. An uploaded audio file has no refId, so segments can’t reference it; send audio that segments use in input by url, assetId, or text. Nested fields such as input, options, segments, outputAudio, dubParams, and dialogueEdit must be sent as JSON strings. With dialogueEdit, supply the original video by URL or assetId; uploaded video, audio and image files are rejected. This form also accepts the Idempotency-Key header; with the SDKs, send it through request options (see Idempotent Requests).
Input image file. Only supported with sync-3 model.
Array of input objects, encoded as a JSON string in multipart requests. Can be used to provide URLs or assetIds for larger files. Each input should either have a file, a url, or an assetId. Audio input items can be provided as either recorded/captured audio URL or a text-to-speech input with TTS provider configuration.
Optional audio input that plays over the whole finished output, encoded as a JSON string in multipart requests, for example {"refId":"dub"}. Use with segments. The refId must name an audio input sent by url or assetId: an uploaded audio file has no refId.
Optional reference to a completed dialogue edit (its id from POST /v2/dialogue-edits) to render its preview into a video, encoded as a JSON string in multipart requests. Send one video input from the same source and no audio, segments or dubParams.
Respuesta
First acceptance returns 201, as does a keyed retry that starts a new generation after the original ended FAILED or REJECTED. An equivalent keyed replay of an active or completed generation returns 200 with this same response shape and Idempotency-Replayed: true.
Stable, machine-readable error code if the generation failed (e.g. generation_input_video_inaccessible). The full catalog of codes, messages and suggested fixes is served unauthenticated at GET /v2/errors.
Dubbed audio URL. Omitted for generations without dubParams; null until the dubbed track is available.
Reusable AUDIO asset for the dubbed track. Omitted without dubParams; null until available, or when retention settings or a custom output bucket prevent saving an asset.
The URL of the audio synthesized from a text (TTS) input. Only present for generations created with a TTS text input; reuse it as an audio input to keep the same take across generations.
A completion-time estimate captured once when the generation is accepted. Populated only for generations created in sync’s own apps, such as Sync Studio; the field is absent for generations created through the API today. To get an expected finish time for any generation, request it with include=progress and read progress.estimatedFinishAt.
Render progress and expected finish. Only included when the generation is requested with include=progress.

