Livepeer Studio

The session object

The session object is a single live streaming session. It is an especially important Livepeer Studio API object if need to reference recorded live stream sessions.

All session objects have a stream object parent. The session's parentId is the same string as its parent stream's id.

All session objects are read-only. Many session parameter values are inherited directly from its stream parent, for example profiles, record, streamKey and playbackId (all sessions with the same parentId use the same streamKey and have the same .m3u8 playback URL).

Other session parameter values are unique to it, for example id, ingested sourceSegments, duration data, and recordingUrl among others.

parametertypedescription
createdAtnumberTimestamp when the session was created. Reported in Unix epoch time.
createdByTokenNamestringLivepeer Studio user-assigned name for the API key that created the stream object.
idstringUnique identifier for the session.
isActivebooleantrue while the session is active and up to about five minutes after it has ended. false after that."
kindstringLivepeer Studio API object type.
lastSeennumberTimestamp when video was last ingested for the session. Reported in Unix epoch time.
namestringAdditional identifier for the asset. Not customizable.
parentIdstringPoints to a parent stream object. The session's parentId is the same string as its parent stream's id.
playbackIdstringUnique identifier used to form the live stream playback URL. All sessions with the same parentId have the same .m3u8 playback URL.
profilesarrayTranscoding rendition settings, inherited from the parent stream profiles. The source will be delivered with the renditions in the HLS and does not need to be redefined in the profiles parameter. If no profiles are defined, only the source will be delivered for playback.
recordbooleantrue means the session is being recorded or was recorded. false means the session is not being recorded or was not recorded. IMPORTANT: If you change the parent stream record value, the new setting will only apply to future sessions, but not the active session.
recordingStatusstringAppears only if record is true. It is either ready when the recorded live stream is available for playback or waiting while the livestream is still active or just recently completed.
recordingURLstringAppears only if record is true and when recordingStatus changes to ready. Its value is the .m3u8 URL to stream the recorded session.
sourceSegmentsnumberNumber of source segments processed.
sourceSegmentsDurationnumberDuration in seconds of session source processed.
streamKeystringUnique secret key used to form the RTMP ingest URL. All sessions with the same parentId use the same streamKey.
transcodedSegmentsnumberNumber of transcoded rendition segments processed. Should be (sourceSegments * number of profiles).
transcodedSegmentsDurationnumberDuration in seconds of transcoded renditions processed. Should be (sourceSegmentsDuration * number of profiles).
userIdstringUnique identifier for the Livepeer Studio user account that created the parent stream object.