Reset

Reset a generic live stream. This is required if a previously used live stream will be used again with different streaming settings than the previous time. Whenever a sub-stream is added, removed, or changed, the live stream must be reset. This ensures that the server will forget the information about the old sub-streams and can correctly handle the new ones.

A pull stream (type ‘generic live stream (pull)’) will disconnect and reconnect to the source when it is reset.

It is only possible to reset a generic live stream if it is currently active, and its current availability is either ‘offline’ or ‘interrupted’. For pull-streams, it is also possible to reset a live stream with a current availability of ‘online’, This will reconnect to the stream source.

This action requires a request with an active account.

Tokens

This action requires the following tokens:

  • livestream-play

Arguments

Required arguments are marked in bold, and optional arguments are marked in italics.

Argument Type Default Description
livestream Hash   ID of the live stream to reset

Output

This action produces the following output on success:

An object containing the following fields:

Name Type Description
id Hash Livestream ID
title String Title of the live stream
description String Description of the live stream
type

The type of this live stream

The value of this field is an object containing the following fields:

Name Type Description
label Label Livestream type label
name String The name of this livestream type
protected Boolean True if authentication must be applied to viewing links for this live stream, otherwise false
accessuser String Username to access this livestream
accesspassword String Password to access this livestream
datecreated DateTime When this livestream was created
datemodified DateTime When this livestream was last updated
source String Source URL of this live stream if it must be retrieved from an external source
sourceproxy String The proxy to get to the live strem source, if any
active Boolean True if the live stream is active; if active, it is possible for a source to start streaming to the publishing point for this live stream
securityprofile

Security profile

The value of this field is an object containing the following fields:

Name Type Description
id Hash Security profile ID
name String The name of this security profile
state

Current state of this live stream

The value of this field is an object containing the following fields:

Name Type Description
isstreaming Boolean Whether this live stream is currently streaming
nrconnectedusers Integer The total number of currently connected users; not set if isstreaming is false
currenttitle String Current or last known title, if one has ever been set
currentbitrate Integer Current or last known bitrate, if this stream has ever been used
datestatemodified DateTime When the state of this live stream was last changed
availability String The current availability of the live stream, as one of ‘offline’, ‘starting’, ‘online’, or ‘interrupted’. This field will always be included for generic live streams (both push and pull), and never for other types.
thumbnail String Path of the thumbnail of this livestream
medialink

The URLs at which this livestream is available for streaming

The value of this field is an object containing the following fields:

Name Type Description
http String The URL at which this livestream can be streamed using HTTP streaming (ICEcast), if this livestream supports it
rtmp String The URL at which this livestream can be streamed using RTMP, if this livestream supports it
hls String The URL at which this livestream can be streamed using HLS (HTTP Live Streaming), if this livestream supports it
dash String The URL at which this livestream can be streamed using MPEG-DASH, if this livestream supports it
smooth String The URL at which this livestream can be streamed using Smooth Streaming, if this livestream supports it
hds String The URL at which this livestream can be streamed using HTTP Dynamic Streaming, if this livestream supports it
publishlink

The URLs to which one should publish this livestream

The value of this field is an object containing the following fields:

Name Type Description
http String The URL to which can be published using HTTP streaming (ICEcast), if this livestream supports it
rtmp String The URL to which can be published using RTMP, if this livestream supports it
smooth String The URL to which can be published using Fragmented MP4 (ISMV / Smooth Streaming), if this livestream supports it
externallink String A link to an external page, such as a page containing more information about this livestream, or the page where this livestream is embedded
fallbackitem

Fallback item of this livestream, if any

The value of this field is an object containing the following fields:

Name Type Description
id Hash Item ID
title String Title of the item
description String Description of the item
type Label The type of this item; for available item types, refer to the documentation of the Item command
account

The account that created this item

The value of this field is an object containing the following fields:

Name Type Description
id Hash Account ID
name String Account name
datecreated DateTime When this item was created; for recordings of live-events, this is the date when the item finished recording
account

Account for this live stream

The value of this field is an object containing the following fields:

Name Type Description
id Hash Account ID
name String Account name
archiving Boolean Whether archiving is enabled for this live stream. This field will always be included for generic live streams (both push and pull), and never for other types.
archivingsegmentduration Duration The duration of each archive segment. This field will always be included if the field ‘archiving’ is present and true, and never otherwise.
dvr Boolean Whether DVR is enabled for this live stream. This field will always be included for generic live streams (both push and pull), and never for other types.
dvrwindowlength Duration The period available for rewinding playback in DVR. This field will always be included if the field ‘dvr’ is present and true, and never otherwise.

Errors

This action can return one of the default status codes, or one of the following status codes on error:

STATUS_LIVESTREAM_NOT_FOUND (240)
If the live stream specified by “ID” can not be found
STATUS_LIVESTREAM_NOT_YET_STARTED (242)
If the live stream is not currently active (via start)
STATUS_LIVESTREAM_TYPE_INVALID (244)
If the live stream is not a generic live stream
STATUS_LIVESTREAM_INVALID_STATE (245)
If the availability of the live stream is not ‘offline’ or ‘interrupted’, or ‘online’ for pull live streams.