upload_asset
Add a video file to the asset library (mp4, mov, avi, webm, mkv, m4v; max 500 MB). Two modes. (1) With source_url: the server downloads the file from that public URL itself and creates the asset in one call (needs a Content-Length; large or slow files may time out, then use mode 2). (2) Without source_url: returns an upload_url; PUT the raw file bytes to it with the returned Content-Type header (e.g. curl -X PUT -H 'Content-Type: video/mp4' --data-binary @file.mp4 ''), then call confirm_asset_upload with the upload_id and the name/notes/category/tags. A video already in the library (same name and size, or same exact size) is not imported twice: its existing asset is returned with duplicate=true. The asset is then analyzed automatically.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Asset name. Empty = the file name without its extension. | |
| tags | No | Custom tags | |
| notes | No | Internal notes saved on the asset (e.g. the caption or brief that came with the file) | |
| category | No | Category (id or name). Empty = none. | |
| file_name | No | Presigned mode only: file name with its extension (e.g. clip.mp4), required. | |
| source_url | No | Public URL of the video to import. Empty = presigned upload mode. | |
| file_size_bytes | No | Presigned mode only: file size, used to check the storage quota up front (0 = checked at confirm). |