gpmdp-cli
is a CLI client for
Google Play Music Desktop Player. The client interfaces with the
Playback Websocket API
of GPMDP.
gpmdp-cli
requires python 3.5 or greater to run.
dependencies can be found in requirements.txt
and can be installed with the
following command:
pip install -r requirements.txt
You must check the Enable Playback API
checkbox in the GENERAL section of GPMDP's
Settings.
When you first use the client a UI will popup in GPMDP containing a 4 digit
code. This code must be entered into gpmdp-cli
when prompted to authorize the
client to control GPMDP. A message should pop up in GPMDP when gpmdp-cli
has taken control.
usage: gpmdp-cli [-h] [--token-file TOKEN_FILE]
[--socket-server SOCKET_SERVER]
commands
Google Play Desktop Music Player CLI client
positional arguments:
commands API commands that will be sent to the socket server
optional arguments:
-h, --help show this help message and exit
--token-file TOKEN_FILE
Path to token file
--socket-server SOCKET_SERVER
URL to socket server
Here are some examples of commands
./gpmdp-cli.py playback playPause
./gpmdp-cli.py playback forward
./gpmdp-cli.py playback rewind
./gpmdp-cli.py playback setCurrentTime 0
./gpmdp-cli.py rating toggleThumbsUp
./gpmdp-cli.py volume increaseVolume 5
./gpmdp-cli.py playback isPlaying
True
./gpmdp-cli.py rating getRating
0
Further documentation of the API can be found Here
- Glitch [email protected]