import { ClipPayload } from "livepeer/models/components";
let value: ClipPayload = {
playbackId: "eaw4nk06ts2d0mzb",
startTime: 1587667174725,
endTime: 1587667174725,
name: "My Clip",
sessionId: "de7818e7-610a-4057-8f6f-b785dc1e6f88",
};
Field |
Type |
Required |
Description |
Example |
playbackId |
string |
✔️ |
The playback ID of the stream or stream recording to clip. Asset playback IDs are not supported yet. |
eaw4nk06ts2d0mzb |
startTime |
number |
✔️ |
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). |
1587667174725 |
endTime |
number |
➖ |
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). |
1587667174725 |
name |
string |
➖ |
The optional friendly name of the clip to create. |
My Clip |
sessionId |
string |
➖ |
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. |
de7818e7-610a-4057-8f6f-b785dc1e6f88 |