v1.0.0OpenAPI 3.1.1

Voice & Lip-sync API

Download OpenAPI Document

Text to speech, voice cloning, lip-sync and video processing for any clip.

Generate speech from text, clone voices from audio samples, and lip-sync videos to new speech. New here? Read Voice & Lip-sync for the whole flow.

Every request

Send your organization API key in the x-api-key header; it starts with uvk_. Create one in the Universe app under Settings → API keys. The key and organization limits count requests over a rolling minute. See Authentication and Rate limits.

Text to speech works in sessions of speech cards. Save the cards with Save a session, start each card with Generate speech, then poll Get a session until the card is done. Voice cloning creates a voice from samples with Clone a voice; once it is ready, use it in a speech card. Lip-sync re-times the lips in a video to new audio: Start a lip-sync, then poll Get a lip-sync job.

Work runs in the background, so every call returns straight away. Endpoints that charge credits say so on their page, with the current price; without enough credits they return 402 and nothing is created. See Credits.

List processes shows the history of all three in one list.

Server
{{API_BASE_URL}}
Your API environment
Authentication RequiredApiKeyAuth
Your organization API key (starts with `uvk_`). Create one in the Universe app under Settings → API keys.
x-api-key:
Client Libraries
Shell

Get a lip-sync upload URL

Auth Required

For a large video (up to 1000 MB) or audio file (up to 100 MB). Returns a presigned uploadUrl: PUT the file to it with exactly size bytes and the given headers, within 10 minutes. Then start the lip-sync with videoUploadKey / audioUploadKey set to objectKey. The file never passes through this API. An upload not used within a day is deleted.

Permission: playground.lip_sync:create. An API key acts with the role of the member who created it.

Bodyrequiredapplication/json

fileNamestringrequired

Name of the file you will upload. Its extension must be one this step takes; send the name again when you use the upload, so the job shows it.

Example: interview.mp4
contentTypestringrequired

The file's type, sent again as the Content-Type of the PUT (the URL is signed over it). application/octet-stream is accepted when the type is unknown.

Example: video/mp4
sizenumberrequired

Exact size of the file in bytes. It is part of the signed URL: storage refuses a PUT of any other length.

Example: 104857600
kindstringrequired

Which input this file is: the video or the audio.

Enum values:videoaudio
Example: video

Responses

201Created
application/json
uploadUrlstringrequired

Presigned URL. PUT the raw file bytes to it with the same Content-Type as the format (for example application/vnd.openxmlformats-officedocument.presentationml.presentation for .pptx) and exactly size bytes. Valid for expiresInSeconds.

Example: https://storage.example.com/0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c….pptx?X-Amz-Signature=…
objectKeystringrequired

Storage key of the upload. Send it as objectKey to Translate a document (or Count billable words) once the PUT has finished.

Example: 0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c7e2a-9d3f-4e5a-8b6c-1d2e3f4a5b6c.pptx
maxBytesnumberrequired

Largest file this route accepts, in bytes (500 MB).

Example: 524288000
expiresInSecondsnumberrequired

Seconds until uploadUrl expires.

Example: 600
headersobjectrequired

Headers to send with the PUT, exactly as given: the URL is signed over them, so another Content-Type is refused (403).

Example: {"Content-Type":"application/vnd.openxmlformats-officedocument.presentationml.presentation"}
400A field failed validation, the file is empty or over its limit, or it is not a video (`.mp4`, `.mov`, `.webm`, `.mkv`, `.avi`, `.m4v`) or audio file (`.mp3`, `.wav`, `.m4a`, `.ogg`, `.aac`, `.flac`).
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
401The `x-api-key` header is missing, or the key is invalid, expired or deleted.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
403Not allowed: the API key's role lacks the permission (`PermissionDenied`), the product is not enabled for your organization, or it has been turned off.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
429The member asked for 60 upload URLs in the last hour, or has 5 GB of uploads not yet used.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
500Something failed on our side. Retry with backoff; if it persists, contact support with the `X-Request-Id`.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
POST/v1/galaxy/playground/lip-sync/upload/presign
curl '{{API_BASE_URL}}/v1/galaxy/playground/lip-sync/upload/presign' \
  --request POST \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "fileName": "interview.mp4",
  "contentType": "video/mp4",
  "size": 104857600,
  "kind": "video"
}'
{
  "uploadUrl": "https://storage.example.com/0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c….pptx?X-Amz-Signature=…",
  "objectKey": "0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c7e2a-9d3f-4e5a-8b6c-1d2e3f4a5b6c.pptx",
  "maxBytes": 524288000,
  "expiresInSeconds": 600,
  "headers": {
    "Content-Type": "application/vnd.openxmlformats-officedocument.presentationml.presentation"
  }
}

List lip-sync models

Price a lip-sync

Start a lip-sync

List lip-sync jobs

Get a lip-sync job

Re-run a lip-sync

Get a lip-sync download URL

Save a lip-sync to assets

Processes

One history of every text-to-speech session, voice clone and lip-sync job in your organization, with routes to read, download, rename or delete a single clip.

List processes

Get a process

Get a process download URL

Rename a process

Models

CreateLipSyncMultipartDto
CreateLipSyncUploadDto
CreateStagedUploadDto
CreateVoiceCloneMultipartDto
DocumentUploadUrlResponseDto
DownloadUrlResponseDto
GenerateSpeechDto
GenerateSpeechResponseDto
InsufficientCreditsErrorDto
LipSyncQuoteDto
LipSyncQuoteResponseDto
LipSyncResponseDto
PlaygroundIdResponseDto
PlaygroundLipSyncModelOptionDto
RenameSessionResponseDto
RenameVideoSessionDto
SaveLipSyncToAssetsResponseDto
SavePlaygroundOutputToAssetsDto
SaveTtsSessionToAssetsResponseDto
SessionCardDto
SessionCardPronunciationDto
SessionCardVoiceDto
SessionExportUrlDto
SessionExportUrlsResponseDto
StaleSessionErrorDto
UpsertSessionDto
VideoProcessAssigneeDto
VideoProcessDto
VideoProcessGroupDto
VideoProcessListDto
VoiceCloneResponseDto