https://github.com/bencevans/sonos-cli
🎶 Command Line Interface for Sonos
https://github.com/bencevans/sonos-cli
cli music sonos
Last synced: 10 months ago
JSON representation
🎶 Command Line Interface for Sonos
- Host: GitHub
- URL: https://github.com/bencevans/sonos-cli
- Owner: bencevans
- Created: 2014-02-24T12:23:42.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2024-06-17T06:51:28.000Z (about 2 years ago)
- Last Synced: 2024-12-12T22:23:09.376Z (over 1 year ago)
- Topics: cli, music, sonos
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/sonos-cli
- Size: 582 KB
- Stars: 53
- Watchers: 7
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# sonos-cli
> CLI for controlling [Sonos](http://www.sonos.com/) zones
## Install
$ npm install --global sonos-cli
## Usage
```
Usage: sonos-cli [OPTION...] [COMMAND] [ARGS]
Options:
-V --version - displays package.json version
-T --timeout [time] - sets timeout time for sonos discovery
-Z --zone [zoneid] - sets the zone to take action on
Commands:
# General
help - display this help text
# Zone Management
list-devices - list discoverable devices
list-zones - list discoverable zones
# Playback Management
volume [new-volume] - show or set the volume
current-track - displays current track information
play [uri] - start playback or play a given track
stop - stop playback
pause - pause playback
next - skip to the next track
```
## Examples
Find a zone
$ sonos list-zones
RINCON_000E585B7C9801400:1
Living Room
Play Bananna Pancakes - Jack Johnson from Spotify
# Right click on a track on Spotify to copy the Spotify URI
$ sonos --zone=RINCON_000E585B7C9801400:1 play spotify:track:0BgbobvykXxEvxo2HhCuvM
Play an MP3 from the web
$ sonos --zone=RINCON_000E585B7C9801400:1 play
## Related
* Sonos Library - https://github.com/bencevans/node-sonos
* Sonos Official Website - http://www.sonos.com/
* Python Library - https://github.com/SoCo/SoCo
## Licence
MIT © [Ben Evans](http://bensbit.co.uk)