Class: RoonApiTransport

RoonApiTransport(core)

new RoonApiTransport(core)

Roon API Transport Service
Parameters:
Name Type Description
core Core The Core providing the service
Source:

Methods

change_settings(zone, settings, cbopt)

Change zone settings
Parameters:
Name Type Attributes Description
zone Zone | Output The zone or output
settings object The settings to change
Properties
Name Type Attributes Description
shuffle boolean <optional>
If present, sets shuffle mode to the specified value
auto_radio boolean <optional>
If present, sets auto_radio mode to the specified value
loop 'loop' | 'loop_one' | 'disabled' | 'next' <optional>
If present, sets loop mode to the specified value. 'next' will cycle between the settings.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

change_volume(output, how, value, cbopt)

Change the volume of an output. Grouped zones can have differently behaving volume systems (dB, min/max, steps, etc..), so you have to change the volume different for each of those outputs.
Parameters:
Name Type Attributes Description
output Output The output to change the volume on.
how 'absolute' | 'relative' | 'relative_step' How to interpret the volume
value number The new volume value, or the increment value or step
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

control(zone, control, cbopt)

Execute a transport control on a zone.

Be sure that `is__allowed` is true on your {Zone} before allowing the user to operate controls

Parameters:
Name Type Attributes Description
zone Zone | Output The zone or output
control 'play' | 'pause' | 'playpause' | 'stop' | 'previous' | 'next' The control desired
"play" - If paused or stopped, start playback
"pause" - If playing or loading, pause playback
"playpause" - If paused or stopped, start playback. If playing or loading, pause playback.
"stop" - Stop playback and release the audio device immediately
"previous" - Go to the start of the current track, or to the previous track
"next" - Advance to the next track
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

convenience_switch(output, opts, cbopt)

Cconvenience switch an output, taking it out of standby if needed.
Parameters:
Name Type Attributes Description
output Output The output that should be convenience-switched.
opts object Options. If none, specify empty object ({}).
Properties
Name Type Attributes Description
control_key string <optional>
The control_key that identifies the source_control that is to be switched. If omitted, then all controls on this output will be convenience switched.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

group_outputs(outputs, cbopt)

Create a group of synchronized audio outputs
Parameters:
Name Type Attributes Description
outputs Array.<Output> The outputs to group. The first output's zone's queue is preserved.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

mute(output, how, cbopt)

Mute/unmute an output.
Parameters:
Name Type Attributes Description
output Output The output to mute.
how 'mute' | 'unmute' The action to take
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

mute_all(how, cbopt)

Mute/unmute all zones (that are mutable).
Parameters:
Name Type Attributes Description
how 'mute' | 'unmute' The action to take
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

pause_all(cbopt)

Pause all zones.
Parameters:
Name Type Attributes Description
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

seek(zone, how, seconds, cbopt)

Seek to a time position within the now playing media
Parameters:
Name Type Attributes Description
zone Zone | Output The zone or output
how 'relative' | 'absolute' How to interpret the target seek position
seconds number The target seek position
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

standby(output, opts, cbopt)

Standby an output.
Parameters:
Name Type Attributes Description
output Output The output to put into standby
opts object Options. If none, specify empty object ({}).
Properties
Name Type Attributes Description
control_key string <optional>
The control_key that identifies the source_control that is to be put into standby. If omitted, then all source controls on this output that support standby will be put into standby.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

toggle_standby(output, opts, cbopt)

Toggle the standby state of an output.
Parameters:
Name Type Attributes Description
output Output The output that should have its standby state toggled.
opts object Options. If none, specify empty object ({}).
Properties
Name Type Attributes Description
control_key string <optional>
The control_key that identifies the source_control that is to have its standby state toggled.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

transfer_zone(fromzone, tozone, cbopt)

Transfer the current queue from one zone to another
Parameters:
Name Type Attributes Description
fromzone Zone | Output The source zone or output
tozone Zone | Output The destination zone or output
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source:

ungroup_outputs(outputs, cbopt)

Ungroup outputs previous grouped
Parameters:
Name Type Attributes Description
outputs Array.<Output> The outputs to ungroup.
cb RoonApiTransport~resultcallback <optional>
Called on success or error
Source: