{"openapi":"3.1.0","info":{"title":"API Reference","version":"1.0.0"},"paths":{"/v2/generate":{"post":{"operationId":"generations_create-with-files","summary":"Create Generation with Files","description":"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`, `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 API-key request that passes dialogueEdit is refused with errorCode dialogue_edit_retime_required (422) when the organization's rollout lacks segment lipsync and section expansion. 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. See [Idempotent Requests](/api-reference/guides/idempotency) for key validation, conflicts, retention, and uncertain-outcome recovery.","tags":["generations"],"parameters":[{"name":"Idempotency-Key","in":"header","description":"Case-sensitive organization-scoped key, 1–128 characters matching [A-Za-z0-9._~-]+. Send exactly one header. Reuse the same key and payload for retries of one action. Retained seven days from acceptance, longer while active or unresolved. Not a JSON field.","required":false,"schema":{"type":"string"}}],"responses":{"201":{"description":"First acceptance returns 201. An equivalent keyed replay returns 200 with this same response shape and Idempotency-Replayed: true. The original generation may still be processing or may have failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Generation"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"410":{"description":"The original keyed generation was deleted. The key remains bound until expiry; an equivalent retry does not create a replacement generation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"413":{"description":"Payload Too Large - a multipart file exceeds the 5 GiB per-file limit. The body carries errorCode generation_input_validation_failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"429":{"description":"Too Many Requests - generation concurrency limit reached. Check the concurrency_limit_reached errorCode and the retry/concurrency fields.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationConcurrencyError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"504":{"description":"Gateway Timeout - A sync. labs service or provider dependency timed out. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_timeout.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"description":"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. Nested fields such as input, options, segments, 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.","content":{"multipart/form-data":{"schema":{"type":"object","properties":{"video":{"type":"string","format":"binary","description":"Input video file."},"image":{"type":"string","format":"binary","description":"Input image file. Only supported with sync-3 model."},"audio":{"type":"string","format":"binary","description":"Input audio file."},"model":{"$ref":"#/components/schemas/common_Model"},"input":{"type":"array","items":{"$ref":"#/components/schemas/common_Input"},"description":"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."},"options":{"$ref":"#/components/schemas/common_GenerationOptions","description":"Optional generation options, encoded as a JSON string in multipart requests."},"segments":{"type":"array","items":{"$ref":"#/components/schemas/common_GenerationSegment"},"description":"Optional segment definitions, encoded as a JSON string in multipart requests."},"dubParams":{"$ref":"#/components/schemas/common_DubDto","description":"Optional dubbing parameters, encoded as a JSON string in multipart requests."},"webhookUrl":{"type":"string"},"outputFileName":{"type":"string"},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"Optional project id to attach the generation to."},"dialogueEdit":{"$ref":"#/components/schemas/common_DialogueEditReference","description":"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."}},"required":["model"]}}}},"security":[{"apiKey":[]}]}},"/v2/generate/{id}":{"get":{"operationId":"generations_get","summary":"Get Generation","description":"Retrieve the current generation state. This /v2/generate/{id} route supports the wait, timeout and include options below.","tags":["generations"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_GenerationId"}},{"name":"wait","in":"query","description":"When true, long-poll: hold the request open until the generation reaches a terminal status (COMPLETED/FAILED/REJECTED) or the timeout elapses, then return the latest state. Waits are short (10s max) — treat this as a convenience for jobs about to finish, and poll again (the response includes a `Retry-After: 2` header) or use a webhook for longer jobs. wait=true responses also carry `X-Sync-Wait-Mode: long_poll` and `X-Sync-Wait-Timeout-Seconds` headers. Cannot be combined with include=progress.","required":false,"schema":{"type":"boolean"}},{"name":"timeout","in":"query","description":"Max seconds to hold a wait=true request open (default 5, max 10 — values outside 1-10 are rejected with a 400). On timeout the current (non-terminal) generation is returned with HTTP 200, so check `status` and poll again, or use a webhook for long jobs.","required":false,"schema":{"type":"number","format":"double"}},{"name":"include","in":"query","description":"Comma-separated extra fields to include. include=progress adds a progress_percent field (fetched live from the inference service).","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job status retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Generation"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/generations/{id}/download":{"get":{"operationId":"generations_download","summary":"Get Generation Download URL","description":"Obtain the available full output of a completed generation in your\norganization. Authenticate with `x-api-key`; no Studio project or user\nsession is required. Any valid API key belonging to the generation's\norganization can request the URL.\n\nThe successful response is an **unquoted URL in a text/plain body**,\nnot JSON, a redirect, or the video itself. Fetch that URL separately\nwithout forwarding your API key.\n\n```bash\ndownload_url=$(curl --fail-with-body --silent --show-error \\\n  -H \"x-api-key: $SYNC_API_KEY\" \\\n  \"https://api.sync.so/v2/generations/$GENERATION_ID/download\") &&\ncurl --fail --location \"$download_url\" --output output.mov\n```\n\nThe URL resolves an existing output using your organization's current\nplan and billing-version eligibility. Free and watermark-required plans\nreceive the watermarked derivative when present. Entitled plans (such\nas v2 Creator and v3 Starter or higher) receive the clean output when\navailable. Historical outputs can have the watermark burned in, so an\nupgrade does not guarantee every old output becomes watermark-free.\nOutputs created without a watermark can remain clean after a downgrade.\nIf no watermarked derivative exists, the resolver retains its existing\nfallback to the original output; changing plans does not rewrite files.\nThis endpoint does not generate a new render or remove burned-in watermarks.\n\nSigned S3 URLs request seven-day validity, but credential expiry,\nrevocation, access changes, or file deletion can make them unusable\nsooner. Request this endpoint again for a fresh signed URL while the\noutput is still available. The selected S3 file is checked before\nsigning; a successful response does not guarantee future availability.\nOlder URL-only records return their stored URL unchanged, without\nchecking its availability or extending its original expiration.\nThese URLs are download credentials: keep them private.\n\nErrors use the standard JSON error body and stable `errorCode`:\n\n| Status | Code | Meaning / next step |\n| --- | --- | --- |\n| 400 | — | Invalid generation UUID. |\n| 401 | — | API key missing, invalid, or revoked. |\n| 404 | `generation_not_found` | Missing, deleted, or outside your organization. |\n| 404 | `generation_output_unavailable` | No eligible output reference or the selected file is missing; contact support. |\n| 409 | `generation_not_ready` | Pending or processing; poll Get Generation until COMPLETED. |\n| 422 | `generation_not_downloadable` | Failed or rejected; inspect the generation error. |\n| 503 | `generation_download_unavailable` | Storage lookup or signing failed; retry with backoff. |\n\nAuthentication also returns 422 for draft organizations. Requesting a\ndownload URL does not create a project, incur a generation charge, or\nrestore deleted files.","tags":["generations"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_GenerationId"}},{"name":"fileName","in":"query","description":"Optional download filename. Its extension is replaced with the output's format. Ignored for URL-only outputs.","required":false,"schema":{"type":"string"}},{"name":"x-sync-accelerate","in":"header","description":"Send true to request transfer acceleration; falls back to the standard endpoint when acceleration is disabled.","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Unquoted download URL. Read as text and fetch separately.","content":{"application/json":{"schema":{"type":"object","properties":{}}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/generations":{"get":{"operationId":"generations_list","summary":"List Generations","tags":["generations"],"parameters":[{"name":"status","in":"query","description":"Filter generations by status. Accepts multiple statuses as a comma-separated list.","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_GenerationStatus"}}},{"name":"ids","in":"query","description":"Filter generations by ID. Accepts multiple IDs as a comma-separated list.","required":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"source","in":"query","description":"Filter generations by source. Accepts multiple sources as a comma-separated list.","required":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"projectId","in":"query","description":"Return only generations in this project. Must be a UUID. A project you can't access returns an empty list.","required":false,"schema":{"$ref":"#/components/schemas/common_ProjectId"}},{"name":"limit","in":"query","description":"Maximum number of generations to return (1-100). When set, results are ordered newest first and can be paged with `cursor`.","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"ID of the last generation on the previous page. Requires `limit`.","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Generations retrieved successfully","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_Generation"}}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/generations/estimate":{"post":{"operationId":"generations_estimate_cost","summary":"Estimate Cost","description":"Estimate a generation from its model and billable duration in seconds. Supply a finite positive duration and, optionally, a finite positive fps (defaults to 30). No media is fetched and no generation is created. POST /v2/generate/estimate-cost is an alias of this endpoint. Invalid request fields return 400. If the billing calculation rejects the duration or frame rate, it returns 422 cost_estimate_unavailable without price fields.","tags":["generations"],"responses":{"200":{"description":"A single estimate; estimatedCredits is null for dollar-billed organizations.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_EstimatedGenerationCost"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_EstimateCostRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/generations/{id}":{"delete":{"operationId":"generations_delete","summary":"Delete Generation","description":"Delete a generation. Generations are organization-scoped, so any member — or an API key for the organization — can delete one. Only generations in a terminal state can be deleted; deleting one that is still processing returns 409 (errorCode `generation_not_deletable_while_processing`).","tags":["generations"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_GenerationId"}}],"responses":{"200":{"description":"Generation deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Generation"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/transcriptions":{"post":{"operationId":"transcriptions_create","summary":"Transcribe a video for dialogue editing","description":"Starts a word-level transcription of a window of a video, the first step of a dialogue edit. Provide exactly one of `sourceVideoUrl` or `sourceAudioUrl`, both hosted in sync. storage (upload via `POST /v2/assets/upload`). Passing pre-extracted audio skips the server-side download and transcode. Poll `GET /v2/transcriptions/{id}` until `status` is `COMPLETED`, then pass the `transcript` and your edits to `POST /v2/dialogue-edits`. An identical source and window returns the existing job instead of starting a new one. Transcription is not billed.","tags":["transcriptions"],"responses":{"201":{"description":"Transcription job created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_TranscriptionJob"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"429":{"description":"Too Many Requests - Batch concurrency limit reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_BatchConcurrencyError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateTranscriptionDto"}}}},"security":[{"apiKey":[]}]}},"/v2/transcriptions/{id}":{"get":{"operationId":"transcriptions_get","summary":"Get a transcription job","description":"Returns the job status and, once `status` is `COMPLETED`, the word-level transcript. `COMPLETED` and `FAILED` are terminal; `error.code` says why a job failed.","tags":["transcriptions"],"parameters":[{"name":"id","in":"path","description":"Transcription job id.","required":true,"schema":{"$ref":"#/components/schemas/common_TranscriptionJobId"}}],"responses":{"200":{"description":"Transcription job retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_TranscriptionJob"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/dialogue-edits":{"post":{"operationId":"dialogueEdits_create","summary":"Edit dialogue and preview the result as audio","description":"Applies word-level edits to a transcript from `POST /v2/transcriptions` and synthesizes preview audio for the same window: only the edited spans are re-spoken in a voice cloned from the source, everything else stays the original recording. Poll `GET /v2/dialogue-edits/{id}` until `status` is `COMPLETED`, `COMPLETED_PARTIAL` or `FAILED`; a completed or partially completed job carries `previewAudioUrl`, the retimed `resultTranscript` and the edited regions as `resultSlots`. Edits that cannot be applied to the transcript are refused with a 400 before a job exists. An API-key request is admitted only for the whole video (leave startMs and endMs unset) and only when the organization's rollout enables segment lipsync and section expansion: a partial window is refused with errorCode `dialogue_edit_unsupported` (422), a rollout without both flags with `dialogue_edit_retime_required` (422), and a rollout that cannot be evaluated with `generation_infra_service_unavailable` (503; retry with backoff). Studio sessions may select a window. Normal billing, planning, duration and rate limits still apply.","tags":["dialogue-edits"],"responses":{"201":{"description":"Dialogue edit job created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_DialogueEditJob"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"429":{"description":"Too Many Requests - Batch concurrency limit reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_BatchConcurrencyError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateDialogueEditDto"}}}},"security":[{"apiKey":[]}]}},"/v2/dialogue-edits/{id}":{"get":{"operationId":"dialogueEdits_get","summary":"Get a dialogue edit job","description":"Returns the job status and, once it completed, the preview audio url, the retimed transcript and the edited regions. `COMPLETED`, `COMPLETED_PARTIAL` and `FAILED` are terminal; `error.code` says why a job failed.","tags":["dialogue-edits"],"parameters":[{"name":"id","in":"path","description":"Dialogue edit job id.","required":true,"schema":{"$ref":"#/components/schemas/common_DialogueEditJobId"}}],"responses":{"200":{"description":"Dialogue edit job retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_DialogueEditJob"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/batch":{"post":{"operationId":"batch_create","summary":"Create Batch","description":"Create a batch processing job from a JSONL file. Requires the Scale plan. Send the file in multipart field `input` (or the accepted `file` alias); it must be 5 MB or smaller and contain 20-500 records by default. Each line must contain `request_id`, endpoint exactly `/v2/generate`, and a generation `payload`.","tags":["batch"],"responses":{"200":{"description":"Response with status 200","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateBatchResponse"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"429":{"description":"Too Many Requests - Batch concurrency limit reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_BatchConcurrencyError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"input":{"type":"string","format":"binary","description":"JSONL file containing batch requests. Send it in multipart field `input` (or `file` alias). Each non-empty line must contain `request_id`, endpoint exactly `/v2/generate`, and `payload` as a CreateGenerationDto object. Minimum 20 records required, maximum 500 records by default, no duplicate request_id values, and maximum file size 5 MB."},"webhook_url":{"type":"string","description":"Optional webhook URL to receive batch completion notifications. A POST request will be sent when the batch completes or fails, with a Sync-Signature header (`t=<unix>,v1=<hmac_sha256>`) signed with the organization webhook secret."},"dry_run":{"type":"boolean","default":false,"description":"When true, validates the JSONL file and returns `{ \"status\": \"VALIDATED\" }` without creating a batch."}},"required":["input"]}}}},"security":[{"apiKey":[]}]},"get":{"operationId":"batch_list","summary":"List Batches","description":"List all batches for your organization with optional filtering by status and creation date. Results are ordered by creation date (newest first).","tags":["batch"],"parameters":[{"name":"status","in":"query","description":"Filter batches by status","required":false,"schema":{"$ref":"#/components/schemas/common_BatchStatus"}},{"name":"created_after","in":"query","description":"Filter batches created after this datetime (ISO 8601 format)","required":false,"schema":{"type":"string","format":"date-time"}},{"name":"created_before","in":"query","description":"Filter batches created before this datetime (ISO 8601 format)","required":false,"schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"Response with status 200","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_BatchResponse"}}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/batch/{id}":{"get":{"operationId":"batch_get","summary":"Get Batch","description":"Retrieve details about a specific batch, including its current status, processing metrics, and output file URL when available.","tags":["batch"],"parameters":[{"name":"id","in":"path","description":"The unique identifier of the batch","required":true,"schema":{"$ref":"#/components/schemas/common_BatchId"}}],"responses":{"200":{"description":"Response with status 200","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_BatchResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/tts":{"post":{"operationId":"tts_create","summary":"Generate Text-to-Speech","description":"Synthesize speech from a script and get back a hosted audio URL. The returned url can be reused as an audio input in POST /v2/generate to lip sync the synthesized take. voiceId accepts an ElevenLabs voice id (discover via GET /v2/voices) or the id of a voice cloned via POST /v2/voices. Free-tier keys share the monthly ElevenLabs allowance; paid plans are billed per use.\n\nA voiceId that does not resolve returns a 422 with errorCode voice_not_found. If a voice from your own ElevenLabs account stops resolving, the connected API key may be invalid — provider failures surface errorCode elevenlabs_api_key_invalid (reconnect it in Settings > Integrations) or elevenlabs_quota_exceeded (402) when your own ElevenLabs quota is exhausted. Temporary ElevenLabs provider failures return errorCode elevenlabs_service_unavailable: 504 for provider timeouts and 503 for other provider outages. Retry those requests with backoff and include the requestId if you contact support. A voice with an unresolved ElevenLabs restriction returns errorCode voice_verification_required or voice_blocked (both normally 422, or 400 when the pre-synthesis check was unavailable), or voice_access_denied (400). The required action depends on the code and on whether the voice is from your own connected ElevenLabs account — see the Error Handling guide.","tags":["tts"],"responses":{"200":{"description":"TTS audio generated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_TtsGenerationResponse"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"504":{"description":"Gateway Timeout - A sync. labs service or provider dependency timed out. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_timeout.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateTtsRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/tts/jobs":{"post":{"operationId":"tts_create-job","summary":"Submit Text-to-Speech Job","description":"Submit a job for asynchronous speech synthesis. Returns 202 with the accepted job and a `Location` header pointing at GET /v2/tts/jobs/{id}; poll that endpoint for the result. Accepts the same body as POST /v2/tts. API-key requests require your organization to be enabled for the asynchronous TTS rollout; otherwise the request returns 503.","tags":["tts"],"parameters":[{"name":"Idempotency-Key","in":"header","description":"Optional idempotency key, 1–128 characters after trimming. Reusing the same key within your organization returns the original job; reusing it with a different request body returns 409.","required":false,"schema":{"type":"string"}}],"responses":{"202":{"description":"Job accepted successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_TtsJob"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateTtsRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/tts/jobs/{id}":{"get":{"operationId":"tts_get-job","summary":"Get Text-to-Speech Job","description":"Retrieve a text-to-speech job by id. While the job is PENDING or PROCESSING, the response carries a `Retry-After: 3` header. The header is absent once the job reaches a terminal state (SUCCESS or FAILED).","tags":["tts"],"parameters":[{"name":"id","in":"path","description":"The job id returned when the job was submitted.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Job retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_TtsJob"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/voices":{"get":{"operationId":"voices_list","summary":"List Voices","description":"List the voices available to your organization — built-in ElevenLabs voices plus any you have cloned. Use a voice's id as voiceId in POST /v2/tts and in generation text inputs. A voice that carries a `restriction` cannot currently synthesize speech — check `restriction` and choose another voice. Voice availability can change over time, so re-check it rather than assuming a voice stays usable.","tags":["voices"],"parameters":[{"name":"provider","in":"query","description":"Filter voices by provider. Currently `elevenlabs`.","required":false,"schema":{"$ref":"#/components/schemas/common_VoiceProvider"}}],"responses":{"200":{"description":"Voices retrieved successfully","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_Voice"}}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]},"post":{"operationId":"voices_clone","summary":"Clone Voice","description":"Clone a custom voice from an audio or video sample and get back its id for use in POST /v2/tts and generation text inputs.\n\nThe exact sequence for a local file: (1) request a presigned URL via POST /v2/assets/upload, (2) PUT the file bytes to the returned uploadUrl, (3) clone from the returned url (or register it via POST /v2/assets and clone from the assetId). Samples must be hosted in sync. labs storage — external URLs are rejected with errorCode voice_sample_upload_required. Video sources have their audio track extracted automatically (first 2 minutes). Video sources staged for extraction are limited to 1 GiB (1,073,741,824 bytes); larger sources return 413 voice_sample_source_too_large. This endpoint allows 10 requests per hour per API key (or per signed-in user).\n\nFor best results use 30 seconds to 2 minutes of clear, single-speaker speech without background music or noise. Samples that are too short are rejected with errorCode voice_sample_too_short. Clone slots are limited per plan (403 voice_clone_limit_reached) and voice names must be unique within your organization (409 voice_name_conflict). Sample source problems return 422 (voice_sample_not_accessible, voice_sample_type_unsupported, voice_sample_upload_required, voice_sample_extraction_failed); invalid or too-short samples return 400 (voice_sample_invalid, voice_sample_too_short). A 429 may mean the request-rate limit was exceeded or shared provider capacity is busy (voice_clone_busy); follow the response retry guidance. Provider outages return 503 (elevenlabs_service_unavailable).","tags":["voices"],"responses":{"201":{"description":"Voice cloned successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_ClonedVoiceResponse"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"402":{"description":"Payment Required - Feature requires higher plan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"403":{"description":"Forbidden - The authenticated caller cannot perform this action on the resource (e.g. modifying an asset owned by another member, or the plan's voice clone limit is reached). Check the errorCode.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"413":{"description":"Payload Too Large - a multipart file exceeds the 5 GiB per-file limit. The body carries errorCode generation_input_validation_failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"429":{"description":"Voice-clone request-rate limit or shared-provider capacity reached. Check errorCode and retry guidance.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_VoiceCloneRateLimitError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"503":{"description":"Service Unavailable - A sync. labs service or provider dependency is temporarily unavailable. The body carries a stable errorCode such as elevenlabs_service_unavailable or controller_dependency_error. Keyed generation creates may return IDEMPOTENCY_OUTCOME_UNKNOWN when acceptance needs reconciliation, or IDEMPOTENCY_UNAVAILABLE when new keyed admission is disabled. Preserve the same key and payload; do not bypass protection. generation_admission_paused means new generation requests are paused for maintenance; generation_admission_unavailable means the API can't confirm it is accepting them. Retry after Retry-After.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateVoiceRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/voices/{id}":{"get":{"operationId":"voices_get","summary":"Get Voice","description":"Retrieve a single voice by the same id values GET /v2/voices exposes — a built-in ElevenLabs voice id or the UUID of a voice cloned by your organization. A missing or foreign-organization id returns a 404 with errorCode voice_not_found.","tags":["voices"],"parameters":[{"name":"id","in":"path","description":"The voice id — a built-in provider voice id or a cloned voice UUID.","required":true,"schema":{"type":"string"}},{"name":"provider","in":"query","description":"Provider to resolve the voice against. Currently `elevenlabs`.","required":false,"schema":{"$ref":"#/components/schemas/common_VoiceProvider"}}],"responses":{"200":{"description":"Voice retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Voice"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]},"delete":{"operationId":"voices_delete","summary":"Delete Voice","description":"Delete a cloned voice, freeing a clone slot. Unknown ids return 404 with errorCode `voice_not_found`.","tags":["voices"],"parameters":[{"name":"id","in":"path","description":"The Sync UUID returned as id when the voice was cloned.","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Voice deleted successfully","content":{"application/json":{"schema":{"type":"boolean"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/assets":{"get":{"operationId":"assets_list","summary":"List Assets","description":"List all assets in your organization's media library.","tags":["assets"],"parameters":[{"name":"projectId","in":"query","description":"Filter assets by project ID.","required":false,"schema":{"type":"string"}},{"name":"limit","in":"query","description":"Maximum number of assets to return (1-100).","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Cursor for pagination.","required":false,"schema":{"type":"string"}},{"name":"searchQuery","in":"query","description":"Search assets by name.","required":false,"schema":{"type":"string"}},{"name":"sortBy","in":"query","description":"Sort order for the results.","required":false,"schema":{"$ref":"#/components/schemas/common_AssetSort"}},{"name":"types","in":"query","description":"Filter by asset types. Accepts multiple types as a comma-separated list (AUDIO, VIDEO, IMAGE).","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_AssetType"}}}],"responses":{"200":{"description":"Assets retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_PaginatedAssetsResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]},"post":{"operationId":"assets_create","summary":"Create Asset","description":"Register a media URL as a reusable asset and get back its id. Use the id in generation inputs (input[].assetId) or as a voice clone sample. To upload a local file, first request a presigned URL via POST /v2/assets/upload, PUT the file there, then register the returned url here. Registration verifies the upload happened and enforces plan limits on the actual file size.\n\nprojectId is optional. When provided it must reference a project in your organization — a stale or foreign id is rejected with a 422 and errorCode project_not_found; omit the field if you don't need the asset attached to a project.","tags":["assets"],"responses":{"201":{"description":"Asset registered successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Asset"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateAssetRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/assets/{id}":{"get":{"operationId":"assets_get","summary":"Get Asset","description":"Retrieve a specific asset by ID.","tags":["assets"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_AssetId"}}],"responses":{"200":{"description":"Asset retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Asset"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]},"patch":{"operationId":"assets_update","summary":"Update Asset","description":"Update an asset's name or visibility. With API-key auth the asset must be owned by the key owner; organization-shared assets can only be updated from an admin/owner session. An asset you can view but not edit returns a 403 with errorCode asset_forbidden; an unknown id returns a 404 with errorCode asset_not_found.","tags":["assets"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_AssetId"}}],"responses":{"200":{"description":"Asset updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Asset"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"403":{"description":"Forbidden - The authenticated caller cannot perform this action on the resource (e.g. modifying an asset owned by another member, or the plan's voice clone limit is reached). Check the errorCode.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_UpdateAssetRequest"}}}},"security":[{"apiKey":[]}]},"delete":{"operationId":"assets_delete","summary":"Delete Asset","description":"Delete an asset. With API-key auth the asset must be owned by the key owner; organization-shared assets can only be deleted from an admin/owner session. An asset you can view but not delete returns a 403 with errorCode asset_forbidden; an unknown id returns a 404 with errorCode asset_not_found.","tags":["assets"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_AssetId"}}],"responses":{"200":{"description":"Asset deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_DeleteAssetResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"403":{"description":"Forbidden - The authenticated caller cannot perform this action on the resource (e.g. modifying an asset owned by another member, or the plan's voice clone limit is reached). Check the errorCode.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/assets/upload":{"post":{"operationId":"assets_create-upload","summary":"Create Upload URL","description":"Request a presigned URL to upload a local file. PUT the file bytes to the returned uploadUrl with the same Content-Type, then register the file as an asset via POST /v2/assets using the returned url. Single uploads are capped at 5GB.","tags":["assets"],"responses":{"201":{"description":"Presigned upload URL created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_AssetUploadResponse"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateAssetUploadRequest"}}}},"security":[{"apiKey":[]}]}},"/v2/projects":{"post":{"operationId":"projects_create","summary":"Create Project","description":"Create a project to group related generations and assets. Pass the returned id as projectId on POST /v2/generate or POST /v2/assets to file them under this project so they show up together in Studio. Only name is required — visibility defaults to USER and mode to CREATOR. Supply a client-generated UUID as id for idempotent creation. A retry with the same id returns the existing project and ignores other request fields; an id owned by another user/organization or a deleted project returns 409.","tags":["projects"],"responses":{"201":{"description":"Project created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Project"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_CreateProjectRequest"}}}},"security":[{"apiKey":[]}]},"get":{"operationId":"projects_list","summary":"List Projects","description":"List the projects in your organization, most recently updated first.","tags":["projects"],"parameters":[{"name":"limit","in":"query","description":"Maximum number of projects to return (1-100). Defaults to 10.","required":false,"schema":{"type":"integer"}},{"name":"cursor","in":"query","description":"Cursor for pagination.","required":false,"schema":{"type":"string"}},{"name":"searchQuery","in":"query","description":"Search projects by name.","required":false,"schema":{"type":"string"}},{"name":"sortBy","in":"query","description":"Sort order for the results. Defaults to updatedAt.","required":false,"schema":{"$ref":"#/components/schemas/common_ProjectSort"}}],"responses":{"200":{"description":"Projects retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_PaginatedProjectsResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/projects/{id}":{"get":{"operationId":"projects_get","summary":"Get Project","description":"Retrieve a project by id.","tags":["projects"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_ProjectId"}}],"responses":{"200":{"description":"Project retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Project"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]},"patch":{"operationId":"projects_update","summary":"Update Project","description":"Update a project's name, description, visibility, or mode. Only the fields you provide are changed.","tags":["projects"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_ProjectId"}}],"responses":{"200":{"description":"Project updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_Project"}}}},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_UpdateProjectRequest"}}}},"security":[{"apiKey":[]}]},"delete":{"operationId":"projects_delete","summary":"Delete Project","description":"Delete a project. A project can't be deleted while any of its generations are queued or processing — wait for those to finish, then retry. Deletion soft-deletes the project and its generations, removes its asset links, and soft-deletes assets with no other active project. Assets linked to another active project are retained.","tags":["projects"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_ProjectId"}}],"responses":{"200":{"description":"Project deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_DeleteProjectResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"409":{"description":"Conflict - The resource is in a state that does not allow the requested action (e.g. deleting a generation that is still processing). For creation, generation_conflict indicates a duplicate internal backend submission. Keyed creates return IDEMPOTENCY_KEY_CONFLICT for a changed payload or IDEMPOTENCY_IN_PROGRESS while the original request prepares (Retry-After: 2). Retry only with the same key and original inputs after an ambiguous network failure. See [Idempotent Requests](/api-reference/guides/idempotency).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/projects/{id}/assets/{assetId}":{"delete":{"operationId":"projects_detachAsset","summary":"Detach Asset from Project","description":"Detach an asset from the project's draft content, such as its thumbnail. The asset remains in the project's asset library and keeps its access grants. Attaching it again restores the link. This operation is idempotent, including when the link is already detached or absent. Returns 204 No Content. An inaccessible project returns 404. An API key without an owner returns 422.","tags":["projects"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_ProjectId"}},{"name":"assetId","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_AssetId"}}],"responses":{"200":{"description":"Successful response"},"400":{"description":"Bad Request - Invalid input or unsupported model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/organizations/webhook/secret":{"get":{"operationId":"organizations_get-webhook-secret","summary":"Get Webhook Secret","description":"Retrieve your organization's webhook signing secret. This is a public, authenticated endpoint you can use to verify the `Sync-Signature` header on generation and batch webhook deliveries: Sync signs the raw JSON request body as HMAC-SHA256 over `${timestamp}.${rawBody}` and sends it as `Sync-Signature: t=<unix>,v1=<hmac_sha256>`. Store the full `whsec_...` value securely. `masked=true` returns a display-only value; do not use it as a verification secret. The same secret is available on the [webhooks settings page](https://sync.so/settings/webhooks).","tags":["organizations"],"parameters":[{"name":"masked","in":"query","description":"When true, returns a display-only masked version of the secret that must not be used as a verification secret. Omit or set false when configuring a webhook verifier so you get the usable value.","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"Webhook secret retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/organizations_WebhookSecretResponse"}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/models":{"get":{"operationId":"models_list","summary":"List Models","description":"List all available models for the authenticated user. Returns active (non-deprecated) models the user has access to, including any feature-flagged models enabled for their account.","tags":["models"],"responses":{"200":{"description":"List of available models","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_ModelInfo"}}}}},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"security":[{"apiKey":[]}]}},"/v2/errors":{"get":{"operationId":"errors_list","summary":"List Error Codes","description":"Returns the full catalog of machine-readable error codes — each with a human-readable message and a suggested fix. It covers generation failures plus the coded errors returned by the assets, voices, and TTS endpoints (e.g. project_not_found, voice_not_found, asset_forbidden). This endpoint is unauthenticated. Pair it with the errorCode field returned on a failed generation or on a coded 4xx/5xx response so an agent can look up what went wrong and how to correct it without hard-coding error strings.","tags":["errors"],"responses":{"200":{"description":"Error catalog retrieved successfully","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/common_ErrorCatalogEntry"}}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}}}},"/v2/projects/{id}/assets":{"post":{"operationId":"projects_attachAsset","summary":"Attach Asset to Project","description":"Attach an existing asset to a project so it is grouped under the project alongside its generations. The asset must belong to your organization and not be deleted. This is idempotent — re-attaching an asset that is already linked succeeds without creating a duplicate. Returns 204 No Content on success.","tags":["projects"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/common_ProjectId"}}],"responses":{"200":{"description":"Successful response"},"401":{"description":"Unauthorized - Invalid or missing authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"404":{"description":"Job not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"422":{"description":"Unprocessable Entity - The requested generation is not downloadable (generation_not_downloadable), or submit-time validation failed (e.g. inaccessible media, invalid segments, a projectId/voiceId/assetId that does not resolve in your organization, or a file exceeding the plan size limit). The body carries a stable errorCode and, where applicable, the failing field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}},"500":{"description":"Internal Server Error - An unexpected failure on our side. The body carries errorCode internal_error and a requestId; include the requestId when contacting support.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_GenerationError"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_AttachProjectAssetRequest"}}}},"security":[{"apiKey":[]}]}}},"tags":[{"name":"generations"},{"name":"transcriptions"},{"name":"dialogue-edits"},{"name":"batch"},{"name":"tts"},{"name":"voices"},{"name":"assets"},{"name":"projects"},{"name":"organizations"},{"name":"models"},{"name":"errors"}],"servers":[{"url":"https://api.sync.so","description":"Default"},{"url":"https://dev-api.sync.so","description":"dev"},{"url":"http://localhost:3001","description":"local"}],"webhooks":{"webhooks_GenerationStatusUpdate":{"post":{"operationId":"webhooks_GenerationStatusUpdate","summary":"Generation Status Update","description":"Receive a notification when a generation changes status","parameters":[{"name":"X-Signature-Primary","in":"header","description":"An HMAC signature of the payload","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Webhook received successfully"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/webhooks_GenerationNotification"}}}}}},"webhooks_BatchStatusUpdate":{"post":{"operationId":"webhooks_BatchStatusUpdate","summary":"Batch Status Update","description":"Receive a notification when a batch completes or fails","parameters":[{"name":"X-Signature-Primary","in":"header","description":"An HMAC signature of the payloadd","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Webhook received successfully"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/common_BatchResponse"}}}}}}},"components":{"schemas":{"common_Model":{"type":"string","enum":["sync-3","lipsync-2","lipsync-1.9.0-beta","lipsync-2-pro","react-1"],"description":"name of the model to use for generation.","title":"Model"},"common_AssetId":{"type":"string","description":"A unique identifier for an asset.","title":"AssetId"},"common_SegmentSecs":{"type":"array","items":{"type":"array","items":{"type":"number","format":"double"}},"description":"start and end times (in seconds) of the video segment to apply generation to","title":"SegmentSecs"},"common_SegmentFrames":{"type":"array","items":{"type":"array","items":{"type":"integer"}},"description":"start and end frames of the video segment to apply generation to","title":"SegmentFrames"},"common_Video":{"type":"object","properties":{"type":{"type":"string","enum":["video"]},"refId":{"type":"string","description":"Optional reference identifier for segment definitions. Use this when a segment needs to refer back to a specific visual input item."},"url":{"type":"string","description":"URL of the video to be used for generation. Either `url` or `assetId` must be provided."},"assetId":{"$ref":"#/components/schemas/common_AssetId","description":"ID of a video asset from your media library. Either `url` or `assetId` must be provided."},"segments_secs":{"$ref":"#/components/schemas/common_SegmentSecs","description":"[DEPRECATED] Use the top-level [segments](/api-reference/api/generate-api/create#request.body.segments) array instead for multi-segment support.","deprecated":true},"segments_frames":{"$ref":"#/components/schemas/common_SegmentFrames","description":"[DEPRECATED] Use the top-level [segments](/api-reference/api/generate-api/create#request.body.segments) array instead for multi-segment support. frames 100 and 200 of the video","deprecated":true}},"required":["type"],"description":"Video input for generation. Provide either `url` or `assetId` (one is required).","title":"Video"},"common_Image":{"type":"object","properties":{"type":{"type":"string","enum":["image"]},"refId":{"type":"string","description":"Optional reference identifier for segment definitions. Use this when a segment needs to refer back to a specific visual input item."},"url":{"type":"string","description":"URL of the image to be used for generation. Either `url` or `assetId` must be provided."},"assetId":{"$ref":"#/components/schemas/common_AssetId","description":"ID of an image asset from your media library. Either `url` or `assetId` must be provided."}},"required":["type"],"description":"Image input for sync-3 model. Use instead of video when generating from a static image. Provide either `url` or `assetId` (one is required).","title":"Image"},"common_Audio":{"type":"object","properties":{"type":{"type":"string","enum":["audio"]},"url":{"type":"string","description":"URL of the audio to be used for generation. Either `url` or `assetId` must be provided."},"assetId":{"$ref":"#/components/schemas/common_AssetId","description":"ID of an audio asset from your media library. Either `url` or `assetId` must be provided."},"refId":{"type":"string","description":"Reference identifier for this audio input, used to link audio inputs to specific segments when using [segments](/api-reference/api/generate-api/create#request.body.segments). Required when using segments array."}},"required":["type"],"description":"Recorded/Captured audio input","title":"Audio"},"common_ElevenLabs":{"type":"object","properties":{"name":{"type":"string","enum":["elevenlabs"]},"voiceId":{"type":"string","description":"sync voice id (copied from cloned voices in the Studio) or ElevenLabs voice ID. Required."},"script":{"type":"string","description":"script to be used for generation"},"stability":{"type":"number","format":"double","minimum":0,"maximum":1,"default":0.5,"description":"determines how stable the voice is and the randomness between each generation. lower values introduce broader emotional range for the voice. higher values can result in a monotonous voice with limited emotion."},"similarityBoost":{"type":"number","format":"double","minimum":0,"maximum":1,"default":0.75,"description":"determines how closely the ai should adhere to the original voice when attempting to replicate it."}},"required":["name","voiceId","script"],"title":"ElevenLabs"},"common_TTSProviderConfig":{"oneOf":[{"$ref":"#/components/schemas/common_ElevenLabs"}],"title":"TTSProviderConfig"},"common_TTS":{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"provider":{"$ref":"#/components/schemas/common_TTSProviderConfig","description":"Integration provider configuration"},"refId":{"type":"string","description":"Reference identifier for this audio input, used to link audio inputs to specific segments when using [segments](/api-reference/api/generate-api/create#request.body.segments). Required when using segments array."}},"required":["type","provider"],"description":"Text to speech input","title":"TTS"},"common_Input":{"oneOf":[{"$ref":"#/components/schemas/common_Video"},{"$ref":"#/components/schemas/common_Image"},{"$ref":"#/components/schemas/common_Audio"},{"$ref":"#/components/schemas/common_TTS"}],"description":"An input item for a generation.","title":"Input"},"common_SyncMode":{"type":"string","enum":["bounce","loop","cut_off","silence","remap"],"default":"bounce","description":"Defines how to handle duration mismatches between video and audio inputs. Each mode applies different strategies when the video and audio lengths don't match.","title":"SyncMode"},"common_ModelMode":{"type":"string","enum":["lips","face","head"],"description":"mode of the model to use for generation. only works with react-1 model","title":"ModelMode"},"common_ActiveSpeaker":{"type":"object","properties":{"auto_detect":{"type":"boolean","default":false,"description":"Whether to automatically detect and apply generation to the active speaker"},"v3":{"type":"boolean","description":"Whether to use ASD v3"},"frame_number":{"type":"integer","description":"Frame index that corresponds to the provided coordinates for manual speaker selection"},"coordinates":{"type":"array","items":{"type":"integer"},"description":"Pixel coordinates [x, y] in the source video frame identified by frame_number. They are forwarded as-is to active speaker selection; they are not normalized ratios."},"bounding_boxes":{"type":"array","items":{"type":"array","items":{"type":"integer"}},"description":"Per-frame array of bounding boxes [x1, y1, x2, y2] for the detected face, or null if no box for that frame. Use instead of frame_number + coordinates when you already have detection data."},"bounding_boxes_url":{"type":"string","description":"URL to a JSON file containing bounding boxes. Use instead of inline bounding_boxes to avoid large payloads. The JSON must have a \"bounding_boxes\" array with one entry per frame."},"face_image":{"type":"string","description":"Base64-encoded reference face image (128x128 WebP) for selected-speaker detection."}},"description":"Active speaker detection configuration","title":"ActiveSpeaker"},"common_BlendingMode":{"type":"string","enum":["default","advanced","disabled"],"title":"BlendingMode"},"common_OutputFormat":{"type":"string","enum":["mp4","mov"],"title":"OutputFormat"},"common_GenerationOptions":{"type":"object","properties":{"sync_mode":{"$ref":"#/components/schemas/common_SyncMode","default":"bounce","description":"Defines how to handle duration mismatches between video and audio inputs. Ignored for image inputs (images have no intrinsic duration). See the [Sync Mode](/developer-guides/sync-mode) guide for the full behavior matrix."},"model_mode":{"$ref":"#/components/schemas/common_ModelMode","default":"face","description":"edit region for the model. only works with react-1. defaults to face, which affects lipsync + emotions in the face region. Available options are lips/face/head. When head is selected, model generates natural talking head movements along with emotions + lipsync."},"prompt":{"type":"string","default":"neutral","description":"Prompt for the generation. React-1 accepts emotion prompts; the appearance model accepts a free-form appearance edit instruction."},"prompt_image_uris":{"type":"array","items":{"type":"string"},"description":"Reference image URLs for appearance editing generations."},"i2v_prompt":{"type":"string","description":"Prompt for image-to-video generation."},"temperature":{"type":"number","format":"double","default":0.5,"description":"option to control how expressive lipsync can be. 0 -> least expressive, 1 -> most expressive. default:0.5"},"active_speaker_detection":{"$ref":"#/components/schemas/common_ActiveSpeaker","description":"Active speaker detection configuration. When enabled, automatically detects and applies lipsync only to the active speaker in videos with multiple people. Not supported for image inputs."},"occlusion_detection_enabled":{"type":"boolean","default":false,"description":"Whether to detect occlusion during generation, slows down generation speed."},"face_boxes_url":{"type":"string","description":"URL for precomputed face bounding boxes."},"refinement_enabled":{"type":"boolean","description":"Whether to enable the refinement pass for the generation."},"blending_mode":{"$ref":"#/components/schemas/common_BlendingMode","description":"Controls how generated frames blend into the source media."},"output_format":{"$ref":"#/components/schemas/common_OutputFormat","default":"mp4","description":"Deprecated output container setting; defaults to mp4.","deprecated":true},"fps":{"type":"number","format":"double","description":"Deprecated output frame-rate setting.","deprecated":true},"output_resolution":{"type":"array","items":{"type":"number","format":"double"},"description":"Deprecated output resolution setting, as exactly [width, height]. Each value must be finite and between 180 and 4096 inclusive. Invalid values are discarded and the option is treated as omitted.","deprecated":true}},"title":"GenerationOptions"},"common_SegmentAudioInput":{"type":"object","properties":{"refId":{"type":"string","description":"Reference ID of the audio/text-to-speech input to use for this segment"},"startTime":{"type":"number","format":"double","description":"Optional start time (in seconds) to crop the referenced audio. When specified, endTime must also be provided, and startTime must be less than or equal to endTime."},"endTime":{"type":"number","format":"double","description":"Optional end time (in seconds) to crop the referenced audio. When specified, startTime must also be provided, and must be greater than or equal to startTime."}},"required":["refId"],"description":"Audio input configuration for a specific segment. References an audio input by refId and optionally crops the audio to a specific time range.","title":"SegmentAudioInput"},"common_SegmentOptionsOverride":{"type":"object","properties":{"sync_mode":{"$ref":"#/components/schemas/common_SyncMode","description":"Override the sync mode for this segment."},"temperature":{"type":"number","format":"double","description":"Override temperature (0-1) for this segment."},"occlusion_detection_enabled":{"type":"boolean","description":"Override occlusion detection for this segment."},"active_speaker_detection":{"$ref":"#/components/schemas/common_ActiveSpeaker","description":"Override active speaker detection for this segment. Useful when different segments have different speakers."}},"description":"Override generation options for a specific segment. Any options set here will override the top-level generation options for this segment only.","title":"SegmentOptionsOverride"},"common_GenerationSegment":{"type":"object","properties":{"startTime":{"type":"number","format":"double","description":"Segment start time in seconds. Must be less than or equal to endTime."},"endTime":{"type":"number","format":"double","description":"Segment end time in seconds. Must be greater than or equal to startTime."},"startFrame":{"type":"number","format":"double","description":"Segment start frame. Use with endFrame instead of time bounds."},"endFrame":{"type":"number","format":"double","description":"Segment end frame. Use with startFrame instead of time bounds."},"audioInput":{"$ref":"#/components/schemas/common_SegmentAudioInput","description":"Audio configuration for this segment"},"optionsOverride":{"$ref":"#/components/schemas/common_SegmentOptionsOverride","description":"Override generation options for this specific segment."}},"required":["audioInput"],"description":"Defines a video segment with its corresponding audio input. Used for multi-segment lipsync generations where different audio tracks can be applied to different video segments.","title":"GenerationSegment"},"common_DubProviderName":{"type":"string","enum":["elevenlabs"],"description":"Dubbing provider used to translate the source audio.","title":"DubProviderName"},"common_DubLanguage":{"type":"string","enum":["en","gu","no","sl","pa","ta","az","gl","is","sw","my","fi","el","he","lt","ms","sv","fr","ca","hr","lv","ro","sd","th","tn","pl","ceb","da","hu","mr","tl","ug","wo","zu","zh","hi","as","ha","kk","ki","rn","ky","st","te","war","ak","be","cs","ka","mn","bo","ts","ar","ss","nl","tr","af","bs","et","rw","ne","ko","it","es","sq","eu","kn","sk","su","ve","pt","am","hy","doi","de","jv","mk","ja","vi","cy","nso","uk","bg","id","lg","yo","ml","fa","tg","ur","uz","ru","fil"],"description":"Target language code supported for dubbing (backed by ElevenLabs Dubbing v2).","title":"DubLanguage"},"common_DubSourceLanguage":{"type":"string","enum":["auto","en","gu","no","sl","pa","ta","az","gl","is","sw","my","fi","el","he","lt","ms","sv","fr","ca","hr","lv","ro","sd","th","tn","pl","ceb","da","hu","mr","tl","ug","wo","zu","zh","hi","as","ha","kk","ki","rn","ky","st","te","war","ak","be","cs","ka","mn","bo","ts","ar","ss","nl","tr","af","bs","et","rw","ne","ko","it","es","sq","eu","kn","sk","su","ve","pt","am","hy","doi","de","jv","mk","ja","vi","cy","nso","uk","bg","id","lg","yo","ml","fa","tg","ur","uz","ru","fil"],"description":"Source language code for dubbing (backed by ElevenLabs Dubbing v2). Use \"auto\" to let the dubbing engine detect the source language.","title":"DubSourceLanguage"},"common_DubDto":{"type":"object","properties":{"providerName":{"$ref":"#/components/schemas/common_DubProviderName","description":"Provider to use for dubbing."},"targetLang":{"$ref":"#/components/schemas/common_DubLanguage","description":"Target language code for dubbing (e.g., \"es\" for Spanish, \"fr\" for French)."},"sourceLang":{"$ref":"#/components/schemas/common_DubSourceLanguage","default":"auto","description":"Source language code. Defaults to \"auto\" for automatic detection."},"numSpeakers":{"type":"integer","description":"[DEPRECATED] Ignored. Dubbing v2 detects speakers automatically.","deprecated":true}},"required":["providerName","targetLang"],"description":"Dubbing parameters attached to a generate request.","title":"DubDto"},"common_ProjectId":{"type":"string","description":"A unique identifier for a project.","title":"ProjectId"},"common_DialogueEditJobId":{"type":"string","description":"A unique identifier for a dialogue edit job.","title":"DialogueEditJobId"},"common_DialogueEditReference":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_DialogueEditJobId","description":"Id of a completed dialogue edit from POST /v2/dialogue-edits."}},"required":["id"],"description":"Reference to a completed dialogue edit to generate a video from.","title":"DialogueEditReference"},"common_CreateGenerationDto":{"type":"object","properties":{"model":{"$ref":"#/components/schemas/common_Model","description":"name of the model to use for generation."},"input":{"type":"array","items":{"$ref":"#/components/schemas/common_Input"},"description":"Normal lipsync requests must include exactly one visual input (video or image) and one audio or text input. Dubbed lipsync requests using dubParams must include exactly one video input and no audio or text input, because Sync extracts the dubbing source audio from that video. Image inputs are only supported with the sync-3 model. When using segments, audio or text inputs can carry unique refId values."},"options":{"$ref":"#/components/schemas/common_GenerationOptions","description":"additional options available for generation."},"segments":{"type":"array","items":{"$ref":"#/components/schemas/common_GenerationSegment"},"description":"segments definition list. When provided, allows defining one or more video segments with different audio inputs for each segment. Each segment specifies a time range and references an audio input by refId."},"webhookUrl":{"type":"string","description":"Webhook URL for generation status updates. When the generation reaches a terminal state, Sync sends a POST request with the generation payload and a Sync-Signature header. Verify the header with the organization webhook secret from GET /v2/organizations/webhook/secret. HTTPS is strongly recommended."},"outputFileName":{"type":"string","description":"Base filename for the generated output without extension. The .mp4 extension will be added automatically. Only alphanumeric characters, underscores, and hyphens are allowed, up to 255 characters."},"dubParams":{"$ref":"#/components/schemas/common_DubDto","description":"Dubbing parameters. When present, audio is extracted from the single video input, dubbed via ElevenLabs into the target language, and then lipsync is run with the dubbed audio. Do not include audio or text inputs with dubParams; requests that send both are rejected."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"Optionally attach this generation to a project (created via POST /v2/projects) so it appears in Studio under that project. Must reference a project in your organization — otherwise the request is rejected with 422."},"dialogueEdit":{"$ref":"#/components/schemas/common_DialogueEditReference","description":"Use the id of a completed dialogue edit from POST /v2/dialogue-edits to supply the audio and edited regions. Requires a preview that ran segment lipsync and section expansion (see the job's segmentLipsyncEnabled and sectionExpansionEnabled). Send exactly one video input, the same video the dialogue edit was made from, and no audio input, segments or dubParams. Billing, status, wait and webhooks work as for any generation."}},"required":["model","input"],"title":"CreateGenerationDto"},"common_GenerationId":{"type":"string","description":"A unique identifier for the generation.","title":"GenerationId"},"common_GenerationStatus":{"type":"string","enum":["PENDING","PROCESSING","COMPLETED","FAILED","REJECTED"],"description":"The status of the generation.","title":"GenerationStatus"},"common_GenerationEstimateConfidence":{"type":"string","enum":["measured","approximate","fallback"],"description":"The estimate's confidence level.","title":"GenerationEstimateConfidence"},"common_GenerationEstimateSource":{"type":"string","enum":["cohort","duration_neighbor","resolution_neighbor","model_pool","global_pool","fallback"],"description":"The data source the estimate was derived from.","title":"GenerationEstimateSource"},"common_GenerationEstimateScope":{"type":"string","enum":["studio","non_studio"],"description":"Whether the generation is a Studio or non-Studio generation. Generations from sync's other apps use the `studio` scope.","title":"GenerationEstimateScope"},"common_GenerationEstimateResolutionSource":{"type":"string","enum":["input","requested_output","unknown"],"description":"Where the resolution used for the estimate came from.","title":"GenerationEstimateResolutionSource"},"common_GenerationEstimate":{"type":"object","properties":{"estimatedDurationSeconds":{"type":"number","format":"double","description":"Estimated generation duration in seconds."},"estimatedFinishAt":{"type":"string","format":"date-time","description":"Estimated completion timestamp a client shows for the remaining wait."},"delayedAt":{"type":"string","format":"date-time","description":"Timestamp after which the generation is considered delayed relative to the estimate."},"supportAt":{"type":"string","format":"date-time","description":"Timestamp after which contacting support is suggested."},"estimatedAt":{"type":"string","format":"date-time","description":"When the estimate was computed."},"serverTime":{"type":"string","format":"date-time","description":"Current server time, stamped when the response was built."},"calibrationAsOf":{"type":"string","format":"date-time","description":"When the calibration snapshot behind the estimate was last refreshed."},"estimatorVersion":{"type":"string","description":"Version of the estimator that produced the estimate."},"confidence":{"$ref":"#/components/schemas/common_GenerationEstimateConfidence","description":"The estimate's confidence level."},"source":{"$ref":"#/components/schemas/common_GenerationEstimateSource","description":"The data source the estimate was derived from."},"sampleCount":{"type":"integer","description":"Number of historical samples that informed the estimate."},"scope":{"$ref":"#/components/schemas/common_GenerationEstimateScope","description":"Whether the generation is a Studio or non-Studio generation."},"durationBand":{"type":"string","description":"Duration bucket used to match the estimate against similar past generations."},"resolutionBand":{"type":"string","description":"Resolution bucket used to match the estimate against similar past generations."},"resolutionSource":{"$ref":"#/components/schemas/common_GenerationEstimateResolutionSource","description":"Whether the resolution came from the requested output, the input asset, or is unknown."}},"required":["estimatedDurationSeconds","estimatedFinishAt","delayedAt","supportAt","estimatedAt","serverTime","calibrationAsOf","estimatorVersion","confidence","source","sampleCount","scope","durationBand","resolutionBand","resolutionSource"],"description":"A completion-time estimate produced when a generation is accepted.","title":"GenerationEstimate"},"common_Generation":{"type":"object","properties":{"createdAt":{"type":"string","format":"date-time","description":"The date and time the generation was created."},"error":{"type":"string","description":"The error message if the generation failed."},"errorCode":{"type":"string","description":"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."},"id":{"$ref":"#/components/schemas/common_GenerationId"},"input":{"type":"array","items":{"$ref":"#/components/schemas/common_Input"},"description":"An array of input objects used for generation."},"model":{"$ref":"#/components/schemas/common_Model","description":"The name of the model used for generation."},"options":{"$ref":"#/components/schemas/common_GenerationOptions","description":"Options for the generation."},"outputDuration":{"type":"number","format":"double","description":"The duration of the output media."},"outputUrl":{"type":"string","description":"The URL of the output media."},"outputFileName":{"type":"string","description":"The sanitized filename applied to the output media. Characters outside letters, numbers, dashes and underscores are stripped and spaces become underscores, so this can differ from the value submitted. Null when no name was provided."},"segments":{"type":"array","items":{"$ref":"#/components/schemas/common_GenerationSegment"},"description":"The segments of the generation."},"segmentOutputUrl":{"type":"string","description":"The URL of the segment output media."},"synthesizedAudioUrl":{"type":"string","description":"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."},"status":{"$ref":"#/components/schemas/common_GenerationStatus","description":"The status of the generation."},"webhookUrl":{"type":"string","description":"The URL to the webhook endpoint."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"The id of the project this generation is attached to, or null when it belongs to no project. Set via the projectId field on the create request."},"generationEstimate":{"$ref":"#/components/schemas/common_GenerationEstimate","description":"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."}},"required":["createdAt","id","input","model","status"],"title":"Generation"},"common_GenerationErrorMessage":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"A message describing the error.","title":"GenerationErrorMessage"},"common_DialogueEditRetimeFailureSection":{"type":"object","properties":{"slotIndex":{"type":"integer","description":"Zero-based index of the section in the preview's `resultSlots`."},"sourceStartMs":{"type":"integer","description":"Start of the section in the source video, in absolute milliseconds."},"sourceDurationMs":{"type":"integer","description":"Length of the section in the source video, in milliseconds."}},"required":["slotIndex"],"description":"The dialogue-edit section that removes too much speech to stay in sync.","title":"DialogueEditRetimeFailureSection"},"common_GenerationError":{"type":"object","properties":{"message":{"$ref":"#/components/schemas/common_GenerationErrorMessage","description":"A message describing the error."},"statusCode":{"type":"number","format":"double","description":"The type of error that occurred."},"errorCode":{"type":"string","description":"Stable, machine-readable error code (e.g. project_not_found, voice_not_found, concurrency_limit_reached). Branch your error handling on this, not on the message text. The full catalog of codes with messages and suggested fixes is served unauthenticated at GET /v2/errors."},"suggestion":{"type":"string","description":"A suggested fix an agent can act on."},"field":{"type":"string","description":"The request field the error refers to, when the failure is tied to a specific field (e.g. projectId, voiceId, input[].assetId)."},"docsUrl":{"type":"string","description":"Link to the documentation page for the failing operation."},"requestId":{"type":"string","description":"Present on unexpected 500 responses. Include it when contacting support so the failing request can be located directly."},"generationId":{"$ref":"#/components/schemas/common_GenerationId","description":"Original generation ID when available for an uncertain keyed submission. Poll this ID; do not create another action to bypass IDEMPOTENCY_OUTCOME_UNKNOWN."},"dialogueEditSection":{"$ref":"#/components/schemas/common_DialogueEditRetimeFailureSection","description":"For dialogue_edit_removal_too_large: the section to change, when it can be identified. Create a new dialogue edit preview before submitting again."}},"required":["message","statusCode"],"title":"GenerationError"},"common_GenerationConcurrencyError":{"type":"object","properties":{"statusCode":{"type":"number","format":"double","description":"The HTTP status code (429)."},"errorCode":{"type":"string","description":"Machine-readable error code (`concurrency_limit_reached`)."},"message":{"$ref":"#/components/schemas/common_GenerationErrorMessage","description":"A human-readable description of the error."},"activeGenerations":{"type":"number","format":"double","description":"The number of generations you currently have in progress."},"concurrencyLimit":{"type":"number","format":"double","description":"The maximum number of concurrent generations allowed on your plan."},"retryAfterSeconds":{"type":"number","format":"double","description":"Suggested number of seconds to wait before retrying. Mirrors the `Retry-After` header."}},"required":["statusCode","message"],"description":"Returned with a 429 when you are already running the maximum number of generations allowed by your plan. The response also carries Retry-After, X-Sync-Concurrency-Limit, and X-Sync-Active-Generations headers.","title":"GenerationConcurrencyError"},"common_EstimateCostRequest":{"type":"object","properties":{"model":{"type":"string","description":"Model to estimate, for example lipsync-2 or sync-3."},"duration":{"type":"number","format":"double","description":"Finite, positive billable duration in seconds."},"fps":{"type":"number","format":"double","description":"Finite, positive frame rate. Defaults to 30."},"reasoningEnabled":{"type":"boolean","description":"Include reasoning pricing when supported by the model."}},"required":["model","duration"],"title":"EstimateCostRequest"},"common_EstimatedGenerationCost":{"type":"object","properties":{"estimatedFrameCount":{"type":"number","format":"double","description":"The estimated frame count for the generation."},"estimatedGenerationCost":{"type":"number","format":"double","description":"The estimated cost of the generation in USD."},"estimatedCredits":{"type":["number","null"],"format":"double","description":"Estimated credits for credit-billed organizations; null for dollar-billed organizations."}},"required":["estimatedFrameCount","estimatedGenerationCost","estimatedCredits"],"title":"EstimatedGenerationCost"},"common_CreateTranscriptionDto":{"type":"object","properties":{"sourceVideoUrl":{"type":"string","description":"URL of the source video, hosted in sync. storage (upload it via POST /v2/assets/upload first). Provide exactly one of sourceVideoUrl or sourceAudioUrl."},"sourceAudioUrl":{"type":"string","description":"URL of audio already extracted from the source, hosted in sync. storage. Skips the server-side audio extraction. Provide exactly one of sourceVideoUrl or sourceAudioUrl."},"startMs":{"type":"integer","description":"Start of the window to transcribe, in milliseconds from the start of the source. Defaults to 0."},"endMs":{"type":"integer","description":"End of the window to transcribe, in milliseconds from the start of the source. Omit to transcribe to the end. The window cannot exceed 60 minutes."},"maxSourceSeconds":{"type":"integer","description":"Refuse the source if it is longer than this many seconds. Useful when a later step, such as a dialogue edit (10 minute window), cannot consume a longer transcript. Cannot exceed the endpoint ceiling of 3600 seconds."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"Optional id of a project in your organization to file the job under."}},"description":"Request to transcribe a window of a source. Provide exactly one of sourceVideoUrl or sourceAudioUrl.","title":"CreateTranscriptionDto"},"common_TranscriptionJobId":{"type":"string","description":"A unique identifier for a transcription job.","title":"TranscriptionJobId"},"common_TranscriptionJobStatus":{"type":"string","enum":["PENDING","PROCESSING","COMPLETED","FAILED"],"description":"The status of a transcription job. COMPLETED and FAILED are terminal.","title":"TranscriptionJobStatus"},"common_TranscriptWord":{"type":"object","properties":{"id":{"type":"string","description":"The word id. Dialogue edits name words by this id."},"text":{"type":"string","description":"The transcribed text of the word."},"startMs":{"type":"integer","description":"Start of the word, in milliseconds from the start of the source."},"endMs":{"type":"integer","description":"End of the word, in milliseconds from the start of the source."}},"required":["id","text","startMs","endMs"],"description":"A single transcribed word with its timing in the source.","title":"TranscriptWord"},"common_TranscriptSegment":{"type":"object","properties":{"id":{"type":"string","description":"The segment id."},"words":{"type":"array","items":{"$ref":"#/components/schemas/common_TranscriptWord"},"description":"The words in the segment, in order."}},"required":["id","words"],"description":"A run of words attributed to one speaker turn.","title":"TranscriptSegment"},"common_Transcript":{"type":"object","properties":{"segments":{"type":"array","items":{"$ref":"#/components/schemas/common_TranscriptSegment"},"description":"The transcript segments, in order."},"speakerCount":{"type":"integer","description":"The number of distinct speakers detected."}},"required":["segments","speakerCount"],"description":"A word-level transcript. Word timings are in milliseconds from the start of the source video.","title":"Transcript"},"common_TranscriptionDifficultyTier":{"type":"string","enum":["green","yellow","red"],"description":"A coarse estimate of how hard a source is to edit cleanly.","title":"TranscriptionDifficultyTier"},"common_TranscriptionDifficultyReason":{"type":"string","enum":["MULTI_SPEAKER","LOW_ASR_CONFIDENCE","LOW_SPLICE_OPPORTUNITY","FAST_VARIABLE_RATE","LOW_AUDIO_QUALITY","VERY_SHORT_SOURCE","VERY_LONG_SOURCE","LOW_AUDIO_BANDWIDTH"],"description":"A reason contributing to the difficulty estimate.","title":"TranscriptionDifficultyReason"},"common_TranscriptionDifficulty":{"type":"object","properties":{"tier":{"$ref":"#/components/schemas/common_TranscriptionDifficultyTier","description":"The overall difficulty tier."},"reasons":{"type":"array","items":{"$ref":"#/components/schemas/common_TranscriptionDifficultyReason"},"description":"The reasons behind the tier."}},"required":["tier","reasons"],"description":"Informational estimate of how hard the source is to edit cleanly, with the reasons behind it. Do not gate behaviour on it.","title":"TranscriptionDifficulty"},"common_TranscriptionErrorCode":{"type":"string","enum":["NO_AUDIO","NO_AUDIO_TRACK","SOURCE_TOO_LONG","EXTRACTION_FAILED","PROVIDER_FAILED","TIMEOUT","UNKNOWN"],"description":"Machine-readable failure code. NO_AUDIO, NO_AUDIO_TRACK and SOURCE_TOO_LONG describe the source and will not succeed on retry.","title":"TranscriptionErrorCode"},"common_TranscriptionError":{"type":"object","properties":{"code":{"$ref":"#/components/schemas/common_TranscriptionErrorCode","description":"Machine-readable failure code. NO_AUDIO, NO_AUDIO_TRACK and SOURCE_TOO_LONG describe the source and will not succeed on retry."},"message":{"type":"string","description":"Human-readable summary of the failure."}},"required":["code","message"],"description":"Why a transcription job failed. Present only when status is FAILED.","title":"TranscriptionError"},"common_TranscriptionJob":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_TranscriptionJobId","description":"Job id. Poll GET /v2/transcriptions/{id} with it."},"status":{"$ref":"#/components/schemas/common_TranscriptionJobStatus","description":"Job status. COMPLETED and FAILED are terminal."},"sourceVideoUrl":{"type":"string","description":"The source video the job was created from. Null for jobs created from sourceAudioUrl."},"sourceStartMs":{"type":"integer","description":"Start of the transcribed window, in source milliseconds."},"sourceEndMs":{"type":"integer","description":"End of the transcribed window, in source milliseconds. Null when the job transcribes to the end of the source."},"transcript":{"$ref":"#/components/schemas/common_Transcript","description":"Word-level transcript. Word timings are in milliseconds from the start of the source video, not the window. Null until status is COMPLETED."},"speakerCount":{"type":"integer","description":"Number of distinct speakers detected. Dialogue edits currently support a single speaker; a count above 1 completes the job but a dialogue edit of that source is unsupported. Null until status is COMPLETED."},"difficulty":{"$ref":"#/components/schemas/common_TranscriptionDifficulty","description":"Informational estimate of how hard the source is to edit cleanly, with the reasons behind it. Null while the job is running and for some older jobs. Do not gate behaviour on it."},"error":{"$ref":"#/components/schemas/common_TranscriptionError","description":"Why the job failed. Null unless status is FAILED."},"createdAt":{"type":"string","format":"date-time","description":"When the job was created."},"startedAt":{"type":"string","format":"date-time","description":"When the job started processing. Null until it starts."},"finishedAt":{"type":"string","format":"date-time","description":"When the job reached a terminal status. Null until it finishes."}},"required":["id","status","sourceStartMs","createdAt"],"description":"A transcription job.","title":"TranscriptionJob"},"common_BatchConcurrencyError":{"type":"object","properties":{"statusCode":{"type":"number","format":"double","description":"The HTTP status code (429)."},"errorCode":{"type":"string","description":"Machine-readable error code (`concurrency_limit_reached`)."},"message":{"$ref":"#/components/schemas/common_GenerationErrorMessage","description":"A human-readable description of the error."},"activeBatches":{"type":"number","format":"double","description":"The number of batches you currently have in progress."},"concurrencyLimit":{"type":"number","format":"double","description":"The maximum number of concurrent batches allowed on your plan."},"retryAfterSeconds":{"type":"number","format":"double","description":"Suggested number of seconds to wait before retrying. Mirrors the `Retry-After` header."}},"required":["statusCode","message"],"description":"Returned with a 429 when you are already running the maximum number of concurrent batches allowed by your plan. The response also carries a `Retry-After` header (seconds) and an `X-Sync-Concurrency-Limit` header.","title":"BatchConcurrencyError"},"common_DialogueEditOperation":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","enum":["change"],"description":"Discriminator value: change"},"wordId":{"type":"string","description":"The id of the word to replace, from the submitted transcript."},"replacement":{"type":"string","description":"The text to speak in place of the word."}},"required":["kind","wordId","replacement"]},{"type":"object","properties":{"kind":{"type":"string","enum":["remove"],"description":"Discriminator value: remove"},"wordIds":{"type":"array","items":{"type":"string"},"description":"The ids of the words to cut, from the submitted transcript."}},"required":["kind","wordIds"]}],"discriminator":{"propertyName":"kind"},"description":"A single edit: change replaces one word, remove cuts a contiguous run of words.","title":"DialogueEditOperation"},"common_CreateDialogueEditDto":{"type":"object","properties":{"transcript":{"$ref":"#/components/schemas/common_Transcript","description":"The transcript the edits refer to, as returned by GET /v2/transcriptions/{id}. Edits name words by their id in this transcript. Word timings are in milliseconds from the start of the source video."},"edits":{"type":"array","items":{"$ref":"#/components/schemas/common_DialogueEditOperation"},"description":"The edits to apply: change replaces one word (wordId, replacement), remove cuts a contiguous run of words (wordIds). Between 1 and 100 edits per job."},"sourceVideoUrl":{"type":"string","description":"URL of the source video the transcript was made from, hosted in sync. storage (upload it via POST /v2/assets/upload first)."},"startMs":{"type":"integer","description":"Start of the edited window, in milliseconds from the start of the source. Use the same window the transcript was made for. Defaults to 0. An API-key request must leave startMs and endMs unset; the edit then covers the whole video."},"endMs":{"type":"integer","description":"End of the edited window, in milliseconds from the start of the source. Omit to run to the end. The window cannot exceed 10 minutes. An API-key request must leave startMs and endMs unset to edit the whole video."},"voiceId":{"type":"string","description":"Opaque voice id returned as voiceId by an earlier dialogue-edit job of the same source. Reusing it skips cloning the voice again. Omit on the first job for a source. Ids your organization has not used before are ignored."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"Optional id of a project in your organization to file the job under."},"rerunOfJobId":{"$ref":"#/components/schemas/common_DialogueEditJobId","description":"Id of the completed dialogue-edit job this request revises, when regenerating a preview after adjusting the edits. Informational lineage only; unknown ids are ignored."}},"required":["transcript","edits","sourceVideoUrl"],"description":"Request to apply word-level edits to a transcript and synthesize preview audio.","title":"CreateDialogueEditDto"},"common_DialogueEditJobStatus":{"type":"string","enum":["PENDING","PROCESSING","COMPLETED","COMPLETED_PARTIAL","FAILED"],"description":"The status of a dialogue edit job. COMPLETED, COMPLETED_PARTIAL and FAILED are terminal.","title":"DialogueEditJobStatus"},"common_DialogueEditResultSlotKind":{"type":"string","enum":["change","removal","silence"],"description":"The kind of edited region a result slot represents.","title":"DialogueEditResultSlotKind"},"common_DialogueEditResultSlot":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/common_DialogueEditResultSlotKind","description":"The kind of edit this region represents."},"outputStartMs":{"type":"integer","description":"Start of the region on the preview timeline, in milliseconds."},"outputDurationMs":{"type":"integer","description":"Length of the region on the preview timeline, in milliseconds; 0 for a pure cut."},"sourceStartMs":{"type":"integer","description":"Start of the region in the source video, in absolute milliseconds."},"sourceDurationMs":{"type":"integer","description":"Length of the region in the source video, in milliseconds."}},"required":["kind","outputStartMs","outputDurationMs"],"description":"An edited region, located on the preview timeline and in the source video. Everything between two slots is untouched source.","title":"DialogueEditResultSlot"},"common_DialogueEditErrorCode":{"type":"string","enum":["EXTRACTION_FAILED","VOICE_CLONE_FAILED","VOICE_SAMPLE_TOO_SHORT","SYNTHESIS_FAILED","EDIT_TOO_LONG","SOURCE_TOO_LONG","PLAN_FAILED","TIMEOUT","UNKNOWN"],"description":"Machine-readable failure code. EDIT_TOO_LONG, SOURCE_TOO_LONG, VOICE_SAMPLE_TOO_SHORT and PLAN_FAILED describe the request and will not succeed on retry.","title":"DialogueEditErrorCode"},"common_DialogueEditError":{"type":"object","properties":{"code":{"$ref":"#/components/schemas/common_DialogueEditErrorCode","description":"Machine-readable failure code. EDIT_TOO_LONG, SOURCE_TOO_LONG, VOICE_SAMPLE_TOO_SHORT and PLAN_FAILED describe the request and will not succeed on retry."},"message":{"type":"string","description":"Human-readable summary of the failure."},"spanText":{"type":"string","description":"For EDIT_TOO_LONG: the replacement text that does not fit the time its span has to occupy. Shorten it and resubmit."}},"required":["code","message"],"description":"Why a dialogue edit job failed. Present only when status is FAILED.","title":"DialogueEditError"},"common_DialogueEditJob":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_DialogueEditJobId","description":"Job id. Poll GET /v2/dialogue-edits/{id} with it."},"status":{"$ref":"#/components/schemas/common_DialogueEditJobStatus","description":"Job status. COMPLETED, COMPLETED_PARTIAL and FAILED are terminal. COMPLETED_PARTIAL means the preview is playable but shipped without something that was requested; treat it as completed."},"sourceVideoUrl":{"type":"string","description":"The source video the job was created from."},"sourceStartMs":{"type":"integer","description":"Start of the edited window, in source milliseconds."},"sourceEndMs":{"type":"integer","description":"End of the edited window, in source milliseconds. Null when the job runs to the end of the source."},"previewAudioUrl":{"type":"string","description":"Hosted WAV of the edited audio for the whole window: the original recording with only the edited spans re-synthesized. Null until the job completes."},"previewAssetId":{"$ref":"#/components/schemas/common_AssetId","description":"Asset id of the registered preview after completion, when available. Null or absent before completion or for an unregistered preview. To lipsync the edit, pass the job id as `dialogueEdit: { id }` on `POST /v2/generate`."},"previewDurationMs":{"type":"integer","description":"Length of the preview audio in milliseconds. Differs from the window length by however much the edits grew or shrank it. Null until the job completes."},"sourceTranscript":{"$ref":"#/components/schemas/common_Transcript","description":"The transcript the edits were made against, exactly as submitted. Returned in every status."},"edits":{"type":"array","items":{"$ref":"#/components/schemas/common_DialogueEditOperation"},"description":"The edits that were applied, exactly as submitted."},"resultTranscript":{"$ref":"#/components/schemas/common_Transcript","description":"The transcript as it reads after the edits, with every word timed against the preview audio. Null until the job completes."},"resultSlots":{"type":"array","items":{"$ref":"#/components/schemas/common_DialogueEditResultSlot"},"description":"The edited regions in order, each located on the preview timeline (outputStartMs, outputDurationMs) and in the source video (sourceStartMs, sourceDurationMs). Everything between two slots is untouched source. Null until the job completes."},"segmentLipsyncEnabled":{"type":"boolean","description":"Whether the preview was cut for per-region lipsync (true) or for re-lipsyncing the whole window (false). Decided when the job is created and fixed for its lifetime. For jobs created with an API key, the rollout is evaluated against the organization's members."},"sectionExpansionEnabled":{"type":"boolean","description":"Whether the preview was made under the section-expansion policy. Decided when the job is created and fixed for its lifetime. For jobs created with an API key, the rollout is evaluated against the organization's members."},"voiceId":{"type":"string","description":"Opaque id of the voice cloned from the source and used for synthesis. Pass it as voiceId on the next dialogue-edit job of the same source to skip cloning. Null until the voice exists."},"error":{"$ref":"#/components/schemas/common_DialogueEditError","description":"Why the job failed. Null unless status is FAILED."},"createdAt":{"type":"string","format":"date-time","description":"When the job was created."},"startedAt":{"type":"string","format":"date-time","description":"When the job started processing. Null until it starts."},"finishedAt":{"type":"string","format":"date-time","description":"When the job reached a terminal status. Null until it finishes."}},"required":["id","status","sourceVideoUrl","sourceStartMs","edits","segmentLipsyncEnabled","sectionExpansionEnabled","createdAt"],"description":"A dialogue edit job.","title":"DialogueEditJob"},"common_BatchId":{"type":"string","description":"A unique identifier for the batch.","title":"BatchId"},"common_BatchStatus":{"type":"string","enum":["PENDING","JOBS_CREATED","PROCESSING","COMPLETED","FAILED"],"description":"The status of the batch processing.","title":"BatchStatus"},"common_BatchMetrics":{"type":"object","properties":{"total_generations":{"type":"integer","description":"Total number of generation requests in the batch."},"success_count":{"type":"integer","description":"Number of successfully completed generations."},"failed_count":{"type":"integer","description":"Number of failed generations."},"pending_count":{"type":"integer","description":"Number of generations still pending or processing."}},"required":["total_generations","success_count","failed_count","pending_count"],"title":"BatchMetrics"},"common_BatchResponse":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_BatchId"},"created_at":{"type":"string","format":"date-time","description":"The date and time the batch was created."},"status":{"$ref":"#/components/schemas/common_BatchStatus","description":"The current status of the batch."},"metrics":{"$ref":"#/components/schemas/common_BatchMetrics","description":"Metrics about the batch processing progress."},"webhookUrl":{"type":"string","description":"The webhook URL for batch status notifications. Deliveries include a Sync-Signature header signed with the organization webhook secret."},"outputUrl":{"type":"string","description":"The URL to download the batch results file when completed. A GET request follows a 302 redirect to a signed JSONL result URL."}},"required":["id","created_at","status","metrics","outputUrl"],"title":"BatchResponse"},"common_ValidationResponse":{"type":"object","properties":{"status":{"type":"string","enum":["VALIDATED"],"description":"Validation status for dry run requests."}},"required":["status"],"title":"ValidationResponse"},"common_CreateBatchResponse":{"oneOf":[{"$ref":"#/components/schemas/common_BatchResponse"},{"$ref":"#/components/schemas/common_ValidationResponse"}],"title":"CreateBatchResponse"},"common_VoiceProvider":{"type":"string","enum":["elevenlabs"],"description":"The provider that hosts a voice.","title":"VoiceProvider"},"common_CreateTtsRequest":{"type":"object","properties":{"script":{"type":"string","minLength":1,"maxLength":5000,"description":"The text to synthesize into speech (1–5,000 characters)."},"voiceId":{"type":"string","description":"A voice id to synthesize with — either an ElevenLabs voice id (discover via GET /v2/voices) or the id of a voice cloned via POST /v2/voices."},"provider":{"$ref":"#/components/schemas/common_VoiceProvider","description":"The voice provider to synthesize with. Currently `elevenlabs`."},"stability":{"type":"number","format":"double","minimum":0,"maximum":1,"description":"Voice stability (0-1). Higher is more consistent, lower is more expressive."},"similarityBoost":{"type":"number","format":"double","minimum":0,"maximum":1,"description":"How closely the synthesized audio matches the original voice (0-1)."}},"required":["script","voiceId","provider"],"description":"Request body for synthesizing text-to-speech audio.","title":"CreateTtsRequest"},"common_TtsGenerationResponse":{"type":"object","properties":{"id":{"type":"string","description":"A unique identifier for the synthesized audio."},"url":{"type":"string","description":"The hosted URL of the synthesized audio. Reuse it as an audio input in POST /v2/generate to keep the same take across generations."},"duration":{"type":"number","format":"double","description":"Duration of the synthesized audio in seconds."}},"required":["id","url","duration"],"description":"A synthesized text-to-speech result.","title":"TtsGenerationResponse"},"common_TtsJobStatus":{"type":"string","enum":["PENDING","PROCESSING","SUCCESS","FAILED"],"description":"Lifecycle status of a text-to-speech job. Terminal states are SUCCESS and FAILED.","title":"TtsJobStatus"},"common_TtsJobErrorCode":{"type":"string","enum":["CREATE_FAILED","PROVIDER_FAILED","PROVIDER_TIMEOUT","PROVIDER_RESULT_UNKNOWN","UPLOAD_FAILED","TIMEOUT","UNKNOWN"],"description":"Machine-readable reason a text-to-speech job failed.","title":"TtsJobErrorCode"},"common_TtsJobError":{"type":"object","properties":{"code":{"$ref":"#/components/schemas/common_TtsJobErrorCode","description":"The machine-readable error code."},"message":{"type":"string","description":"A human-readable description of the failure."}},"required":["code","message"],"description":"Error detail for a failed text-to-speech job.","title":"TtsJobError"},"common_TtsJob":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the job."},"status":{"$ref":"#/components/schemas/common_TtsJobStatus","description":"The current lifecycle status of the job."},"url":{"type":"string","description":"The hosted URL of the synthesized audio. Null unless status is SUCCESS."},"duration":{"type":"number","format":"double","description":"Duration of the synthesized audio in seconds. Null unless status is SUCCESS."},"error":{"$ref":"#/components/schemas/common_TtsJobError","description":"Error detail. Null unless status is FAILED."},"createdAt":{"type":"string","format":"date-time","description":"When the job was created."},"startedAt":{"type":"string","format":"date-time","description":"When synthesis started. Null until synthesis starts."},"finishedAt":{"type":"string","format":"date-time","description":"When the job reached a terminal state. Null until the job is SUCCESS or FAILED."}},"required":["id","status","createdAt"],"description":"An asynchronous text-to-speech job and its result.","title":"TtsJob"},"common_VoiceRestriction":{"type":"string","enum":["verification_required","blocked"],"description":"A restriction that prevents a voice from being used for synthesis (ElevenLabs).","title":"VoiceRestriction"},"common_Voice":{"type":"object","properties":{"id":{"type":"string","description":"The voice id to pass as voiceId in TTS and generation text inputs."},"internalVoiceId":{"type":"string","description":"The internal id of a cloned voice, when applicable."},"voiceId":{"type":"string","description":"The provider (ElevenLabs) voice id."},"name":{"type":"string","description":"The display name of the voice."},"provider":{"$ref":"#/components/schemas/common_VoiceProvider","description":"The voice provider."},"previewUrl":{"type":"string","description":"A URL to a short preview sample of the voice, when available."},"restriction":{"$ref":"#/components/schemas/common_VoiceRestriction","description":"Present when the voice cannot currently be used for synthesis (ElevenLabs). `verification_required` means the voice needs verification in ElevenLabs — complete it there if the voice is from your own connected ElevenLabs account, otherwise choose another voice. `blocked` means ElevenLabs has blocked the voice — choose another voice. Null or absent means the voice is unrestricted."}},"required":["provider"],"description":"A voice available for text-to-speech and generation text inputs.","title":"Voice"},"common_CreateVoiceRequest":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100,"description":"A name for the cloned voice, 1–100 characters. Names starting with edit-dialogue- after trimming whitespace and ignoring case are reserved."},"provider":{"$ref":"#/components/schemas/common_VoiceProvider","description":"The provider to clone the voice with. Currently `elevenlabs`."},"url":{"type":"string","description":"A sync. labs-hosted url of the audio or video sample to clone from. Provide exactly one of `url` or `assetId`."},"assetId":{"type":"string","description":"The id of a previously uploaded audio or video asset to clone from. Provide exactly one of `url` or `assetId`."}},"required":["name","provider"],"description":"Request body for cloning a voice. Required validation: provide exactly one of a sync. labs-hosted url or an assetId (audio or video) — upload local files via POST /v2/assets/upload first. Video sources have their audio track extracted automatically.","title":"CreateVoiceRequest"},"common_ClonedVoiceResponse":{"type":"object","properties":{"id":{"type":"string","description":"Sync's UUID for the clone; use it to retrieve or delete the voice."},"voiceId":{"type":"string","description":"Provider voice id, also accepted in TTS and generation text inputs."},"name":{"type":"string","description":"The name of the cloned voice."}},"required":["id","voiceId","name"],"description":"The result of cloning a voice.","title":"ClonedVoiceResponse"},"common_VoiceCloneRateLimitError":{"type":"object","properties":{"message":{"$ref":"#/components/schemas/common_GenerationErrorMessage","description":"A message describing the error."},"statusCode":{"type":"number","format":"double","description":"The type of error that occurred."},"errorCode":{"type":"string","description":"Stable, machine-readable error code (e.g. project_not_found, voice_not_found, concurrency_limit_reached). Branch your error handling on this, not on the message text. The full catalog of codes with messages and suggested fixes is served unauthenticated at GET /v2/errors."},"suggestion":{"type":"string","description":"A suggested fix an agent can act on."},"field":{"type":"string","description":"The request field the error refers to, when the failure is tied to a specific field (e.g. projectId, voiceId, input[].assetId)."},"docsUrl":{"type":"string","description":"Link to the documentation page for the failing operation."},"requestId":{"type":"string","description":"Present on unexpected 500 responses. Include it when contacting support so the failing request can be located directly."},"generationId":{"$ref":"#/components/schemas/common_GenerationId","description":"Original generation ID when available for an uncertain keyed submission. Poll this ID; do not create another action to bypass IDEMPOTENCY_OUTCOME_UNKNOWN."},"dialogueEditSection":{"$ref":"#/components/schemas/common_DialogueEditRetimeFailureSection","description":"For dialogue_edit_removal_too_large: the section to change, when it can be identified. Create a new dialogue edit preview before submitting again."},"retryAfterSeconds":{"type":"number","format":"double","description":"Retry delay for voice_clone_busy, also sent in Retry-After."},"retryAfter":{"type":"number","format":"double","description":"Retry delay for rate_limit_exceeded."},"resetTime":{"type":"string","format":"date-time","description":"End of the request-rate window."},"limit":{"type":"number","format":"double","description":"Maximum requests per window."},"remaining":{"type":"number","format":"double","description":"Requests remaining in the window."}},"required":["message","statusCode"],"title":"VoiceCloneRateLimitError"},"common_AssetSort":{"type":"string","enum":["nameAsc","nameDesc","dateAsc","dateDesc","durationAsc","durationDesc","sizeAsc","sizeDesc","kindAsc","kindDesc"],"description":"Sorting options for listing assets.","title":"AssetSort"},"common_AssetType":{"type":"string","enum":["AUDIO","VIDEO","IMAGE"],"description":"The type of asset file.","title":"AssetType"},"common_AssetInputType":{"type":"string","enum":["UPLOAD","URL","RECORD","TTS","EXTRACT","PLATFORM_IMPORT","DIALOGUE_EDIT"],"description":"The source type of the asset.","title":"AssetInputType"},"common_AssetVisibility":{"type":"string","enum":["USER","ORGANIZATION"],"description":"Visibility scope for the asset.","title":"AssetVisibility"},"common_Asset":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_AssetId"},"createdAt":{"type":"string","format":"date-time","description":"The date and time the asset was created."},"updatedAt":{"type":"string","format":"date-time","description":"The date and time the asset was last updated."},"name":{"type":"string","description":"The filename of the asset."},"url":{"type":"string","description":"The URL to access the asset media."},"size":{"type":"integer","format":"int64","description":"File size in bytes."},"format":{"type":"string","description":"File format/extension (e.g., \"mp4\", \"wav\")."},"type":{"$ref":"#/components/schemas/common_AssetType","description":"The type of asset file."},"inputType":{"$ref":"#/components/schemas/common_AssetInputType","description":"The source type of the asset."},"durationSeconds":{"type":"number","format":"double","description":"Duration of the media in seconds (for audio/video)."},"thumbnailUrl":{"type":"string","description":"URL to the asset's thumbnail image."},"visibility":{"$ref":"#/components/schemas/common_AssetVisibility","description":"Visibility scope for the asset."},"width":{"type":"integer","description":"Width in pixels (for video/image)."},"height":{"type":"integer","description":"Height in pixels (for video/image)."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"The id of the project this asset is attached to, or null when it belongs to no project."},"proxyPath":{"type":["string","null"],"description":"Stable API proxy path for authenticated media playback."}},"required":["id","createdAt","updatedAt","type","visibility"],"description":"An asset stored in your organization's media library.","title":"Asset"},"common_PaginatedAssetsResponse":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/common_Asset"},"description":"Array of assets."},"nextCursor":{"type":"string","description":"Cursor for fetching the next page of results."},"totalCount":{"type":"integer","description":"Total number of assets matching the query."}},"required":["items"],"description":"Paginated list of assets.","title":"PaginatedAssetsResponse"},"common_CreateAssetUploadRequest":{"type":"object","properties":{"fileName":{"type":"string","description":"The name of the file to upload."},"contentType":{"type":"string","description":"The MIME content type of the file (e.g. video/mp4)."},"size":{"type":"integer","description":"The size of the file in bytes. Single uploads are capped at 5GB."}},"required":["fileName","contentType","size"],"description":"Request a presigned URL to upload a local file.","title":"CreateAssetUploadRequest"},"common_AssetUploadResponse":{"type":"object","properties":{"uploadUrl":{"type":"string","description":"The presigned S3 URL to PUT the file bytes to (with the same Content-Type)."},"url":{"type":"string","description":"The final public URL of the file. Register it as an asset via POST /v2/assets once the upload completes."},"expiresIn":{"type":"integer","description":"Seconds until the presigned uploadUrl expires."}},"required":["uploadUrl","url","expiresIn"],"description":"A presigned upload target.","title":"AssetUploadResponse"},"common_CreateAssetRequest":{"type":"object","properties":{"url":{"type":"string","description":"The public URL of the media to register — e.g. the url returned by POST /v2/assets/upload. Registration verifies the upload happened and enforces plan limits on the actual file size."},"type":{"$ref":"#/components/schemas/common_AssetType","description":"The type of asset."},"name":{"type":"string","description":"An optional display name for the asset."},"visibility":{"$ref":"#/components/schemas/common_AssetVisibility","default":"USER","description":"Who can see the asset. Defaults to USER."},"projectId":{"$ref":"#/components/schemas/common_ProjectId","description":"Optionally attach the asset to a project (created via POST /v2/projects) so it appears in Studio under that project's media. Must reference a project in your organization — otherwise the request is rejected with 422."},"inputType":{"$ref":"#/components/schemas/common_AssetInputType","description":"The source of the asset."},"thumbnailUrl":{"type":["string","null"],"description":"Optional thumbnail URL for the asset."},"size":{"type":"integer","format":"int64","description":"File size in bytes."},"format":{"type":"string","description":"File format or extension."},"durationSeconds":{"type":"number","format":"double","description":"Media duration in seconds."},"width":{"type":"integer","description":"Width in pixels for video or image assets."},"height":{"type":"integer","description":"Height in pixels for video or image assets."}},"required":["url","type"],"description":"Register a media URL as a reusable asset. Use the returned asset id in generation inputs (input[].assetId) or as a voice clone sample.","title":"CreateAssetRequest"},"common_UpdateAssetRequest":{"type":"object","properties":{"name":{"type":"string","description":"A new display name for the asset."},"visibility":{"$ref":"#/components/schemas/common_AssetVisibility","description":"Update who can see the asset."},"durationSeconds":{"type":"number","format":"double","description":"Updated media duration in seconds."},"size":{"type":"integer","format":"int64","description":"Updated file size in bytes."},"format":{"type":"string","description":"Updated file format or extension."},"width":{"type":"integer","description":"Updated width in pixels."},"height":{"type":"integer","description":"Updated height in pixels."}},"description":"Update an asset. Only the fields you provide are changed.","title":"UpdateAssetRequest"},"common_DeleteAssetResponse":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_AssetId","description":"The id of the deleted asset."}},"required":["id"],"description":"Confirmation that an asset was deleted.","title":"DeleteAssetResponse"},"common_ProjectVisibility":{"type":"string","enum":["USER","ORGANIZATION"],"description":"Who can see the project.","title":"ProjectVisibility"},"common_ProjectMode":{"type":"string","enum":["CREATOR","DEVELOPER"],"description":"The project mode.","title":"ProjectMode"},"common_CreatorWorkflow":{"type":"string","enum":["lipsync","translate_and_dub","change_appearance","image_to_video","edit_dialogue","assistant","timeline"],"description":"The default top-level creator workflow a project opens into in Studio.","title":"CreatorWorkflow"},"common_CreateProjectRequest":{"type":"object","properties":{"id":{"type":"string","description":"Optional client-supplied project id (UUID) for idempotent creation. Re-sending the same id returns the existing project instead of creating a duplicate; the other request fields are ignored on such a replay. Fails with 409 if the id already belongs to a different user or organization, or to a deleted project."},"name":{"type":"string","description":"A name for the project."},"description":{"type":"string","description":"An optional description for the project."},"visibility":{"$ref":"#/components/schemas/common_ProjectVisibility","default":"USER","description":"Who can see the project. Defaults to USER (visible only to the owner)."},"mode":{"$ref":"#/components/schemas/common_ProjectMode","default":"CREATOR","description":"The project mode. Defaults to CREATOR."},"defaultWorkflow":{"$ref":"#/components/schemas/common_CreatorWorkflow","description":"The default top-level creator workflow for this project."}},"required":["name"],"description":"Create a project to group related generations and assets.","title":"CreateProjectRequest"},"common_Project":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_ProjectId"},"createdAt":{"type":"string","format":"date-time","description":"The date and time the project was created."},"updatedAt":{"type":"string","format":"date-time","description":"The date and time the project was last updated."},"name":{"type":"string","description":"The display name of the project."},"description":{"type":"string","description":"An optional description of the project."},"visibility":{"$ref":"#/components/schemas/common_ProjectVisibility","description":"Who can see the project."},"mode":{"$ref":"#/components/schemas/common_ProjectMode","description":"The project mode."},"defaultWorkflow":{"oneOf":[{"$ref":"#/components/schemas/common_CreatorWorkflow"},{"type":"null"}],"description":"The default top-level creator workflow for this project. Null for projects created outside the creator-workflows surface."}},"required":["id","createdAt","updatedAt","visibility","mode"],"description":"A project groups related generations and assets so they appear together in Studio. Attach to a project by passing its id as projectId on POST /v2/generate or POST /v2/assets.","title":"Project"},"common_ProjectSort":{"type":"string","enum":["updatedAt","name"],"description":"Sort order for listing projects.","title":"ProjectSort"},"common_ProjectGenerationModel":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":["string","null"]},"type":{"type":"string"},"version":{"type":"string"},"features":{"type":"array","items":{"type":"string"}},"deprecatedAt":{"type":["string","null"],"format":"date-time"}},"required":["id","name","description","type","version","features","deprecatedAt"],"title":"ProjectGenerationModel"},"common_ProjectGenerationProvider":{"type":"object","properties":{"name":{"type":"string"},"script":{"type":"string"},"voiceId":{"type":"string"},"stability":{"type":"number","format":"double","minimum":0,"maximum":1},"similarityBoost":{"type":"number","format":"double","minimum":0,"maximum":1}},"required":["name","script","voiceId"],"title":"ProjectGenerationProvider"},"common_ProjectGenerationInput":{"type":"object","properties":{"type":{"type":"string"},"url":{"type":"string"},"assetId":{"$ref":"#/components/schemas/common_AssetId"},"refId":{"type":"string"},"generatedBy":{"type":"string","enum":["tts"]},"segments_secs":{"type":"array","items":{"type":"array","items":{"type":"number","format":"double"}}},"segments_frames":{"type":"array","items":{"type":"array","items":{"type":"number","format":"double"}}},"trim_secs":{"type":"array","items":{"type":"number","format":"double"}},"provider":{"$ref":"#/components/schemas/common_ProjectGenerationProvider"}},"required":["type"],"description":"Stored input metadata. Fields generated by the server are response-only.","title":"ProjectGenerationInput"},"common_ProjectGenerationSegment":{"type":"object","properties":{"startTime":{"type":"number","format":"double"},"endTime":{"type":"number","format":"double"},"startFrame":{"type":"number","format":"double"},"endFrame":{"type":"number","format":"double"},"audioInput":{"$ref":"#/components/schemas/common_SegmentAudioInput"},"optionsOverride":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Stored segment-specific options, including server-owned fields."}},"title":"ProjectGenerationSegment"},"common_ProjectGenerationError":{"type":"object","properties":{"status":{"type":"number","format":"double"},"message":{"type":"string"},"errorCode":{"type":"string"},"docsLink":{"type":"string"}},"required":["message"],"title":"ProjectGenerationError"},"common_ProjectGeneration":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_GenerationId"},"organizationId":{"type":"string"},"userId":{"type":["string","null"]},"apiKeyId":{"type":["string","null"]},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"startedAt":{"type":["string","null"],"format":"date-time"},"finishedAt":{"type":["string","null"],"format":"date-time"},"status":{"$ref":"#/components/schemas/common_GenerationStatus"},"model":{"$ref":"#/components/schemas/common_ProjectGenerationModel"},"modelName":{"type":"string"},"inputs":{"type":"array","items":{"$ref":"#/components/schemas/common_ProjectGenerationInput"}},"webhookUrl":{"type":["string","null"]},"thumbnailUrl":{"type":["string","null"]},"frameCount":{"type":["number","null"],"format":"double"},"options":{"type":"object","additionalProperties":{"description":"Any type"},"description":"Persisted generation options, including server-owned fields. This is not a create-request options contract."},"segments":{"type":["array","null"],"items":{"$ref":"#/components/schemas/common_ProjectGenerationSegment"}},"outputMediaUrl":{"type":["string","null"]},"segmentOutputMediaUrl":{"type":["string","null"]},"segmentOutputBucketPath":{"type":["string","null"]},"creatorName":{"type":["string","null"]},"outputMediaLength":{"type":["number","null"],"format":"double"},"potentialError":{"oneOf":[{"$ref":"#/components/schemas/common_ProjectGenerationError"},{"type":"null"}]},"isPublic":{"type":["boolean","null"]},"deletedAt":{"type":["string","null"],"format":"date-time"},"projectId":{"oneOf":[{"$ref":"#/components/schemas/common_ProjectId"},{"type":"null"}]},"outputFileName":{"type":["string","null"]},"outputExtension":{"type":["string","null"]},"generationEstimate":{"oneOf":[{"$ref":"#/components/schemas/common_GenerationEstimate"},{"type":"null"}]}},"required":["id","organizationId","userId","apiKeyId","createdAt","updatedAt","startedAt","finishedAt","status","model","modelName","inputs","webhookUrl","thumbnailUrl","frameCount","options","outputMediaUrl","segmentOutputMediaUrl","segmentOutputBucketPath","outputMediaLength","potentialError","isPublic","deletedAt","projectId"],"description":"The latest undeleted generation on a project-list item, using the stored-generation response shape.","title":"ProjectGeneration"},"common_ProjectListItem":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_ProjectId"},"createdAt":{"type":"string","format":"date-time","description":"The date and time the project was created."},"updatedAt":{"type":"string","format":"date-time","description":"The date and time the project was last updated."},"name":{"type":"string","description":"The display name of the project."},"description":{"type":"string","description":"An optional description of the project."},"visibility":{"$ref":"#/components/schemas/common_ProjectVisibility","description":"Who can see the project."},"mode":{"$ref":"#/components/schemas/common_ProjectMode","description":"The project mode."},"defaultWorkflow":{"oneOf":[{"$ref":"#/components/schemas/common_CreatorWorkflow"},{"type":"null"}],"description":"The default top-level creator workflow for this project. Null for projects created outside the creator-workflows surface."},"organizationId":{"type":"string"},"userId":{"type":["string","null"]},"deletedAt":{"type":["string","null"],"format":"date-time"},"generations":{"type":"array","items":{"$ref":"#/components/schemas/common_ProjectGeneration"},"description":"Zero or one item, the most recent undeleted generation."},"generationsCount":{"type":"number","format":"double","description":"Number of undeleted generations in the project."},"completedGenerationsCount":{"type":"number","format":"double","description":"Completed undeleted generations with an output file."},"lastGenerationSource":{"type":["string","null"],"description":"Source metadata of the most recent generation; null when absent."},"assets":{"type":"array","items":{"description":"Any type"},"description":"Deprecated compatibility field; always an empty array in project listings.","deprecated":true},"generationPresets":{"type":"array","items":{"description":"Any type"},"description":"Deprecated compatibility field; always an empty array in project listings.","deprecated":true},"latestAssetThumbnailUrl":{"type":["string","null"],"description":"Preview for the project's most recent visual asset: a video's thumbnail, or an image's own URL. Null when the project has no video with a thumbnail or image."},"latestAssetAttachedAt":{"type":["string","null"],"format":"date-time","description":"When the project's most recent visual asset was attached, so clients can rank it against the latest generation by recency. Null when the project has no such asset."}},"required":["id","createdAt","updatedAt","visibility","mode","organizationId","userId","deletedAt","generations","generationsCount","completedGenerationsCount","lastGenerationSource","assets","generationPresets","latestAssetThumbnailUrl","latestAssetAttachedAt"],"description":"A project as returned in the list-projects response.","title":"ProjectListItem"},"common_PaginatedProjectsResponse":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/common_ProjectListItem"},"description":"Array of projects."},"nextCursor":{"type":"string","description":"Cursor for fetching the next page of results."}},"required":["items"],"description":"Paginated list of projects.","title":"PaginatedProjectsResponse"},"common_UpdateProjectRequest":{"type":"object","properties":{"name":{"type":"string","description":"A new name for the project."},"description":{"type":"string","description":"A new description for the project."},"visibility":{"$ref":"#/components/schemas/common_ProjectVisibility","description":"Update who can see the project."},"mode":{"$ref":"#/components/schemas/common_ProjectMode","description":"Update the project mode."},"defaultWorkflow":{"$ref":"#/components/schemas/common_CreatorWorkflow","description":"Update the project's default top-level creator workflow."}},"description":"Update a project. Only the fields you provide are changed.","title":"UpdateProjectRequest"},"common_DeleteProjectResponse":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/common_ProjectId","description":"The id of the deleted project."}},"required":["id"],"description":"Confirmation that a project was deleted.","title":"DeleteProjectResponse"},"organizations_WebhookSecretResponse":{"type":"object","properties":{"secret":{"type":"string","description":"The webhook signing secret, prefixed with `whsec_`. When the request sets `masked=true`, this is a display-only masked value and must not be used to verify signatures."}},"required":["secret"],"description":"The organization's webhook signing secret.","title":"WebhookSecretResponse"},"common_ModelInfo":{"type":"object","properties":{"id":{"type":"string","description":"Unique model identifier."},"name":{"type":"string","description":"Model name (e.g., lipsync-2, react-1)."},"type":{"type":"string","description":"The type of model."},"version":{"type":"string","description":"Model version string."},"description":{"type":"string","description":"Model description."},"deprecatedAt":{"type":"string","format":"date-time","description":"Deprecation timestamp. Models with this field set are excluded from the list endpoint response."}},"required":["id","name","type","version"],"description":"Information about an available Sync model.","title":"ModelInfo"},"common_ErrorCatalogEntry":{"type":"object","properties":{"code":{"type":"string","description":"The stable error code (e.g. generation_input_video_inaccessible)."},"message":{"type":"string","description":"A human-readable description of the error."},"suggestion":{"type":"string","description":"A suggested fix an agent can act on."}},"required":["code","message","suggestion"],"description":"A single entry in the machine-readable error catalog.","title":"ErrorCatalogEntry"},"common_AttachProjectAssetRequest":{"type":"object","properties":{"assetId":{"$ref":"#/components/schemas/common_AssetId","description":"The id of the asset to attach. The asset must belong to your organization and not be deleted."}},"required":["assetId"],"description":"Attach an existing asset to a project.","title":"AttachProjectAssetRequest"},"webhooks_webhookStatus":{"type":"string","enum":["COMPLETED","FAILED"],"description":"The status of the webhook","title":"webhookStatus"},"webhooks_GenerationNotification":{"type":"object","properties":{"status":{"$ref":"#/components/schemas/webhooks_webhookStatus","description":"The status of the generation"},"createdAt":{"type":"string","format":"date-time","description":"The date and time the generation was created"},"id":{"$ref":"#/components/schemas/common_GenerationId"},"input":{"type":"array","items":{"$ref":"#/components/schemas/common_Input"},"description":"The input items for the generation"},"model":{"$ref":"#/components/schemas/common_Model"},"error":{"type":"string","description":"error message if the generation failed"},"error_code":{"type":"string","description":"error code if the generation failed"},"options":{"$ref":"#/components/schemas/common_GenerationOptions","description":"options used for the generation"},"outputDuration":{"type":"number","format":"double","description":"generated output media duration in seconds"},"outputUrl":{"type":"string","description":"url of the generated output media"},"segmentOutputUrl":{"type":"string","description":"url of the segment output media"},"webhookUrl":{"type":"string","description":"url of the webhook server"}},"required":["status","createdAt","id","input","model"],"title":"GenerationNotification"}},"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"x-api-key"}}}}