POST
/
asset
/
request-upload
Authorization
Body
curl --request POST \
  --url https://livepeer.studio/api/asset/request-upload \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --data '{
  "c2pa": true,
  "creatorId": {
    "type": "unverified",
    "value": "<string>"
  },
  "encryption": {
    "encryptedKey": "<string>"
  },
  "name": "filename.mp4",
  "playbackPolicy": {
    "type": "public",
    "webhookContext": {},
    "webhookId": "<string>"
  },
  "staticMp4": true,
  "storage": {
    "ipfs": {}
  },
  "url": "https://s3.amazonaws.com/my-bucket/path/filename.mp4"
}'
{
  "asset": {
    "createdAt": 1587667174725,
    "creatorId": {
      "type": "unverified",
      "value": "<string>"
    },
    "downloadUrl": "https://livepeercdn.com/asset/eaw4nk06ts2d0mzb/video",
    "hash": [],
    "id": "09F8B46C-61A0-4254-9875-F71F4C605BC7",
    "name": "filename.mp4",
    "playbackId": "eaw4nk06ts2d0mzb",
    "playbackPolicy": {
      "type": "public"
    },
    "playbackUrl": "https://livepeercdn.com/asset/ea03f37e-f861-4cdd-b495-0e60b6d753ad/index.m3u8",
    "size": 84934509,
    "source": {
      "type": "url",
      "url": "<string>"
    },
    "status": {
      "phase": "uploading",
      "updatedAt": 1587667174725
    },
    "storage": {},
    "type": "video",
    "videoSpec": {}
  },
  "task": {
    "id": "34d7618e-fd42-4798-acf5-19504616a11e"
  },
  "tusEndpoint": "https://origin.livepeer.com/api/asset/upload/tus?token=eyJhbGciOiJIUzI1NiJ9.eyJtc2ciOiJoZWxsbyBoYWNrZXIsIHRoZXJlJ3Mgbm90aGluZyBmb3IgeW91IGhlcmUg8J-YhiJ9.1YDjmXsqLcgNyMSzT4kXl_kIni46_EuGX_xfqmC7e0Q",
  "url": "https://origin.livepeer.com/api/asset/upload/direct?token=eyJhbGciOiJIUzI1NiJ9.eyJtc2ciOiJoZWxsbyBoYWNrZXIsIHRoZXJlJ3Mgbm90aGluZyBmb3IgeW91IGhlcmUg8J-YhiJ9.1YDjmXsqLcgNyMSzT4kXl_kIni46_EuGX_xfqmC7e0Q"
}

Authorizations

Authorization
string
headerrequired

Bearer api-key

Body

application/json
c2pa
boolean

Decides if the output video should include C2PA signature

creatorId
encryption
object
name
string
required

Name of the asset. This is not necessarily the filename, can be a custom name or title

playbackPolicy
object

Whether the playback policy for a asset or stream is public or signed

staticMp4
boolean

Whether to generate MP4s for the asset.

storage
object
url
string

URL where the asset contents can be retrieved. Only allowed (and also required) in the upload asset via URL endpoint. For an IPFS source, this should be similar to: ipfs://{CID}. For an Arweave source: ar://{CID}.

Response

200 - application/json
asset
object
required
task
object
required
tusEndpoint
string
required
url
string
required