VirtualLineIn service
The VirtualLineIn service is available on these models: v2-S1
/ v2-S13
/ v2-S14
/ v2-S18
/ v2-S21
/ v2-S27
/ v2-S3
/ v2-S33
/ v2-S38
/ v2-S6
/ v2-S9
/ v2-Sub
.
const SonosDevice = require('@svrooij/sonos').SonosDevice
const sonos = new SonosDevice('192.168.x.x')
sonos.VirtualLineInService.OneOfTheMethodsBelow({...})
All actions that require input expect an object with the specified parameters, even if it only requires one parameter.
- Next
- Pause
- Play
- Previous
- SetVolume
- StartTransmission
- Stop
- StopTransmission
- VirtualLineInService event
Next
const result = await sonos.VirtualLineInService.Next({ InstanceID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number |
This actions returns a boolean whether or not the requests succeeded.
Pause
const result = await sonos.VirtualLineInService.Pause({ InstanceID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number |
This actions returns a boolean whether or not the requests succeeded.
Play
const result = await sonos.VirtualLineInService.Play({ InstanceID:..., Speed:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number | |
Speed | string |
This actions returns a boolean whether or not the requests succeeded.
Previous
const result = await sonos.VirtualLineInService.Previous({ InstanceID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number |
This actions returns a boolean whether or not the requests succeeded.
SetVolume
const result = await sonos.VirtualLineInService.SetVolume({ InstanceID:..., DesiredVolume:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number | |
DesiredVolume | number |
This actions returns a boolean whether or not the requests succeeded.
StartTransmission
const result = await sonos.VirtualLineInService.StartTransmission({ InstanceID:..., CoordinatorID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number | |
CoordinatorID | string |
Output object:
property | type | description |
---|---|---|
CurrentTransportSettings | string |
Stop
const result = await sonos.VirtualLineInService.Stop({ InstanceID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number |
This actions returns a boolean whether or not the requests succeeded.
StopTransmission
const result = await sonos.VirtualLineInService.StopTransmission({ InstanceID:..., CoordinatorID:... });
Input object:
property | type | description |
---|---|---|
InstanceID | number | |
CoordinatorID | string |
This actions returns a boolean whether or not the requests succeeded.
VirtualLineInService event
const SonosDevice = require('@svrooij/sonos').SonosDevice
const sonos = new SonosDevice('192.168.x.x')
sonos.VirtualLineInService.Events('serviceEvent', (data) => {
console.log(data);
});
The VirtualLineInService emits events with these properties. Not all properties are emitted every time.
parameter | type | possible values |
---|---|---|
AVTransportURIMetaData | Track | string | |
CurrentTrackMetaData | Track | string | |
CurrentTransportActions | string | |
EnqueuedTransportURIMetaData | Track | string | |
LastChange | string |
This file is automatically generated with @svrooij/sonos-docs, do not edit manually.