Assets

Create a new asset

Changed on

Registers a media URL as a reusable asset. Use the returned asset 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. A link to a single TikTok, Instagram, Facebook or YouTube video is imported instead of registered: the response is 409 import_in_progress until the video is downloaded, and sending the same request again after Retry-After returns the imported VIDEO asset, named after the video. Link imports count toward a daily per-user limit; repeating a request for a link that already finished importing does not.

post/v2/assets

Request

  • Base URL
    https://api.sync.so
  • Auth
    API key in header x-api-key

Request body

namestring
visibility'USER' | 'ORGANIZATION'
projectIdstring
urlstring uri required
type'AUDIO' | 'VIDEO' | 'IMAGE' required
inputType'UPLOAD' | 'URL' | 'RECORD' | 'TTS' | 'EXTRACT' | 'DUB' | 'DUB_SOURCE' | 'PLATFORM_IMPORT' | 'DIALOGUE_EDIT' | 'PLUGIN_PREMIERE_FILE' | 'PLUGIN_PREMIERE_TIMELINE_SELECTION' | 'PLUGIN_RESOLVE_FILE' | 'PLUGIN_RESOLVE_TIMELINE_SELECTION'
thumbnailUrlstring uri nullable
sizeinteger
formatstring
durationSecondsnumber
widthinteger
heightinteger
contentSha256string

Response

Asset created successfully

idstring required
createdAtstring date-time required
updatedAtstring date-time required
deletedAtstring date-time nullable required
namestring nullable required
urlstring nullable required
sizenumber nullable required
formatstring nullable required
type'AUDIO' | 'VIDEO' | 'IMAGE' required
inputType'UPLOAD' | 'URL' | 'RECORD' | 'TTS' | 'EXTRACT' | 'DUB' | 'DUB_SOURCE' | 'PLATFORM_IMPORT' | 'DIALOGUE_EDIT' | 'PLUGIN_PREMIERE_FILE' | 'PLUGIN_PREMIERE_TIMELINE_SELECTION' | 'PLUGIN_RESOLVE_FILE' | 'PLUGIN_RESOLVE_TIMELINE_SELECTION' nullable required
durationSecondsnumber nullable required
thumbnailUrlstring nullable required
visibility'USER' | 'ORGANIZATION' required
userIdstring nullable required
apiKeyIdstring nullable required
organizationIdstring required
widthnumber nullable required
heightnumber nullable required
proxyPathstring nullable
projectIdstring nullable

Changes

    • info

      added the optional property //// to the response with the status

    • info

      added the media type application/json for the response with the status