Overview
APIs
- Asset
- Livestream
- Generate
- Multistream target
- Session
- Access control
- Webhook
- Task
- Playback
- Transcode
- Viewership
Create a clip
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
The playback ID of the stream or stream recording to clip. Asset playback IDs are not supported yet.
The start timestamp of the clip in Unix milliseconds. See the ClipTrigger in the UI Kit for an example of how this is calculated (for HLS, it uses Program Date-Time
tags, and for WebRTC, it uses the latency from server to client at stream startup).
The end timestamp of the clip in Unix milliseconds. See the ClipTrigger in the UI Kit for an example of how this is calculated (for HLS, it uses Program Date-Time
tags, and for WebRTC, it uses the latency from server to client at stream startup).
The optional friendly name of the clip to create.
The optional session ID of the stream to clip. This can be used to clip recordings - if it is not specified, it will clip the ongoing livestream.
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
The playback ID of the stream or stream recording to clip. Asset playback IDs are not supported yet.
The start timestamp of the clip in Unix milliseconds. See the ClipTrigger in the UI Kit for an example of how this is calculated (for HLS, it uses Program Date-Time
tags, and for WebRTC, it uses the latency from server to client at stream startup).
The end timestamp of the clip in Unix milliseconds. See the ClipTrigger in the UI Kit for an example of how this is calculated (for HLS, it uses Program Date-Time
tags, and for WebRTC, it uses the latency from server to client at stream startup).
The optional friendly name of the clip to create.
The optional session ID of the stream to clip. This can be used to clip recordings - if it is not specified, it will clip the ongoing livestream.
Response
The name of the asset. This is not necessarily the filename - it can be a custom name or title.
Type of the asset.
video
, audio
The playback ID to use with the Playback Info endpoint to retrieve playback URLs.
URL for HLS playback. It is recommended to not use this URL, and instead use playback IDs with the Playback Info endpoint to retrieve the playback URLs - this URL format is subject to change (e.g. https://livepeercdn.com/asset/ea03f37e-f861-4cdd-b495-0e60b6d753ad/index.m3u8).
The URL to directly download the asset, e.g. https://livepeercdn.com/asset/eawrrk06ts2d0mzb/video
. It is not recommended to use this for playback.
Whether the playback policy for an asset or stream is public or signed
public
, jwt
, webhook
ID of the webhook to use for playback policy
User-defined webhook context
Interval (in seconds) at which the playback policy should be refreshed (default 600 seconds)
List of allowed origins for CORS playback (<scheme>://<hostname>:<port>, <scheme>://<hostname>)
Requested profiles for the asset to be transcoded into. Configured
on the upload APIs payload or through the stream.recordingSpec
field for recordings. If not specified, default profiles are derived
based on the source input. If this is a recording, the source will
not be present in this list but will be available for playback.
x > 128
1 - 500
x > 128
x > 400
Restricts the size of the output video using the constant quality feature. Increasing this value will result in a lower quality video. Note that this parameter might not work if the transcoder lacks support for it.
0 < x < 44
x > 0
x > 1
H264Baseline
, H264Main
, H264High
, H264ConstrainedHigh
H.264
, HEVC
, VP8
, VP9
Name of the NFT metadata template to export. 'player' will embed the Livepeer Player on the NFT while 'file' will reference only the immutable MP4 files.
file
, player
Additional data to add to the NFT metadata exported to IPFS. Will be deep merged with the default metadata exported.
Timestamp (in milliseconds) at which IPFS export task was updated
Phase of the asset storage
waiting
, processing
, ready
, failed
, reverted
ID of any currently running task that is exporting this asset to IPFS.
ID of the last task to run successfully, that created the currently saved data.
ID of the last task to fail execution.
Current progress of the task updating the storage.
Error message if the last storage changed failed.
Status of the asset
Phase of the asset
uploading
, waiting
, processing
, ready
, failed
, deleting
, deleted
Timestamp (in milliseconds) at which the asset was last updated
Current progress of the task creating this asset.
Error message if the asset creation failed.
The ID of the project
Timestamp (in milliseconds) at which asset was created
Name of the token used to create this object
Size of the asset in bytes
Video metadata
Format of the asset
Duration of the asset in seconds (float)
Bitrate of the video in bits per second
List of tracks associated with the asset when the format contemplates them (e.g. mp4)
type of track
video
, audio
Codec of the track
Start time of the track in seconds
Duration of the track in seconds
Bitrate of the track in bits per second
Width of the track - only for video tracks
Height of the track - only for video tracks
Pixel format of the track - only for video tracks
Frame rate of the track - only for video tracks
Amount of audio channels in the track
Sample rate of the track in samples per second - only for audio tracks
Bit depth of the track - only for audio tracks
Was this page helpful?