Documentation Index
Fetch the complete documentation index at: https://docs.roughy.ai/llms.txt
Use this file to discover all available pages before exploring further.
What is an asset
Assets are the binary inputs and outputs of a pipeline. Source assets are uploaded by you; output assets are produced by processors. Both are addressable by ID across the API.Types and states
Assets carry a type (what’s in them) and a state (where they are in their lifecycle).| Type | Meaning |
|---|---|
AUDIO | Uploaded audio source. |
VIDEO | Uploaded video source. |
CUT_FILE | SRT output from the cut processor. |
RENDERED_VIDEO | MP4 output from the render processor. |
AUDIO and VIDEO; the other types are
processor-generated.
| State | Meaning |
|---|---|
PENDING_UPLOAD | Asset row exists; bytes not yet uploaded. |
READY | Bytes uploaded and stored. |
DELETED | Soft-deleted; bytes purged after a 30-day grace. |
Upload flow
Roughy uses the TUS resumable upload protocol for uploads. There is no pre-signed URL step — the client streams chunks directly to the TUS endpoint, which proxies to Supabase Storage server-side. The shape:POST /api/v1/assets/upload-resumable— create an upload session plus an asset row inPENDING_UPLOAD. The session ID is returned in theLocationresponse header.PATCH /api/v1/assets/upload-resumable/{session_id}— upload one or more chunks. Resumable on connection drop.HEAD /api/v1/assets/upload-resumable/{session_id}— returns the current byte offset; use to resume after an interruption.- When the final chunk lands, the asset transitions to
READY. DELETE /api/v1/assets/upload-resumable/{session_id}— cancels an in-flight upload.
Listing
GET /api/v1/assets lists your assets (filterable by state).
Reading
GET /api/v1/assets/{id} returns the asset detail. For READY
assets the response includes a short-lived download_url. Hand
that to your HTTP client to fetch the bytes; the URL expires after
a short window, so don’t cache it.
Deleting
DELETE /api/v1/assets/{id} soft-deletes the asset. Bytes are
hard-deleted by a background cron after a 30-day grace period.