Videos SDK
Guides

The asset lifecycle

Five canonical statuses that every provider's states collapse into.

Every provider reports upload and encoding progress differently. Videos SDK collapses them into five canonical states on Asset.status:

type AssetStatus =
  | 'waiting_upload' // asset created, bytes not received yet
  | 'uploading'      // bytes are being received / fetched from a URL
  | 'processing'     // transcoding / packaging
  | 'ready'          // playable
  | 'errored';       // upload or processing failed

Reading it is the same on every adapter:

const { status } = await videos.get(id);
if (status === 'ready') {
  const { hls } = await videos.playback(id);
}

How providers map

CanonicalReheliosMuxCloudflare StreamBunny Stream
waiting_uploadwaiting_uploadpendingupload0 Created
uploadinguploadingdownloading1 Uploaded
processingprocessingpreparingqueued · inprogress2 Processing · 3 Transcoding
readyreadyreadyready4 Finished
errorederrorederrorederror5 Error · 6 UploadFailed

Rehelios returns the canonical statuses natively; the other adapters normalize their provider-specific codes into them. An unknown or new provider status falls back to processing, so your app never sees a value outside the five canonical states.

On this page