Retrieve an asset

This method retrieves details about the specified asset.

Authentication

x-api-keystring
Your API key. <Note title="Note"> You can find your API key on the <a href="https://playground.twelvelabs.io/dashboard/api-keys" target="_blank">API Keys</a> page. </Note>

Path parameters

asset_idstringRequired
The unique identifier of the asset to retrieve.

Response

The asset has been successfully retrieved.
_idstring
The unique identifier of the asset.
created_atstringformat: "date-time"

The date and time, in RFC 3339 format (“YYYY-MM-DDTHH:mm:ssZ”), when the asset was created.

durationdouble
The duration of the asset in seconds. Only present for video and audio assets. This field is absent for image assets or while the asset is still being processed.
file_typestring
The MIME type of the asset file.
filenamestring
The name of the file used to create the asset.
hlsobject
HLS streaming details for the asset. Present only when HLS generation has been requested. Omitted otherwise.
methodenum

Indicates how you uploaded the asset.

Values:

  • direct: Uploaded from your local file system
  • url: Uploaded from a publicly accessible URL
  • multipart: Uploaded using the multipart upload flow
Allowed values:
sizeinteger
The file size of the asset in bytes. This field is absent while the asset is still being processed.
statusenum

Indicates the current status of the asset.

Values:

  • failed: The platform failed to process the upload
  • processing: The platform is processing the uploaded file
  • ready: The asset is ready to use
Allowed values:
thumbnailobject
Thumbnail details for the asset. Present only when thumbnail generation has been requested. Omitted otherwise.

Errors

400
Bad Request Error