LivepeerContact UsDocumentationLog inSign up

Documentation

Understanding RTMP ingest vs segment based transcoding
How to live stream with RTMP ingest
How to live transcode with .ts segment based ingest
How do you manage API keys

How to create a stream and define renditions

The first step to live transcoding .ts segments is creating a stream.

Create a stream by sending POST to https://livepeer.com/api/stream with name and profiles.

You can define the stream name parameter and the rendition profiles.

Each rendition profile includes name, bitrate, fps, width and height. If you need guidance setting up your rendition profiles, Apple's recommended settings for HLS ladders is a good starting point.

Here is an request example:

{
"name": "my-stream",
"profiles": [
{
"name": "1080p",
"bitrate": 6000000,
"fps": 30,
"width": 1920,
"height": 1080
},
{
"name": "720p",
"bitrate": 2000000,
"fps": 30,
"width": 1280,
"height": 720
},
{
"name": "360p",
"bitrate": 500000,
"fps": 30,
"width": 640,
"height": 360
}
]
}

The json response includes the stream id parameter. You'll need that later.

Here is an example response.

{
"name":"my-stream",
"profiles": [
{
"name":"1080p",
"bitrate":6000000,
"fps":30,
"width":1920,
"height":1080
},
{
"name":"720p",
"bitrate":2000000,
"fps":30,
"width":1280,
"height":720
},
{
"name":"360p",
"bitrate":500000,
"fps":30,
"width":640,
"height":360
}
],
"kind":"stream",
"userId":"47b70bb7-4887-4481-8ec5-f2ee6b623a00",
"renditions":{},
"id":"cb433497-7947-4859-9606-f46c7d5ee89e",
"createdAt":1592272441370
}
Livepeer
16 Vestry St, Floor 4
New York, NY
10013
TeamJobsPrivacy Policy