Audio
Management API audio allows you to check and set your devices current audio volume setting.
All methods
Method | Description | Supported since |
---|---|---|
getVolume() | Get current volume level | 2.0 |
setVolume() | Set volume level | 2.0 |
getVolume()
Method getVolume()
lets you check for current level of volume set on the device.
Javascript example
await sos.management.audio.getVolume(); // Returns number e.g. 39
setVolume()
Method setVolume()
lets you set level of volume on your device.
Param | Type | Required | Value | Description |
---|---|---|---|---|
volume | Number | Yes | 0 - 100 | Volume level |
Javascript example
await sos.management.audio.setVolume(90);