gmusicapi: an unofficial API for Google Play Music¶
This library allows control of Google Music with Python.
from gmusicapi import Api api = Api() api.login('email@example.com', 'my-password') # => True library = api.get_all_songs() sweet_tracks = [track for track in library if track['artist'] == 'The Cat Empire'] playlist_id = api.create_playlist('Rad muzak') api.change_playlist(playlist_id, sweet_tracks)
This project is not supported nor endorsed by Google. Use common sense (protocol compliance, reasonable load, etc) and don’t ruin the fun for everyone else.
All major functionality is supported:
- Library management: list, create, delete, and modify songs and playlists
- Web-client streaming and single-song downloading
- Music Manager uploading/scan-and-match of all Google-supported file formats
Other features are on the way:
See the changelog for changes by version.
For help getting started, check out the usage section.
The reference has details on specific features, as well as the format of the Google Music data you’ll see:
If you don’t want to use Python, or you want to create a port, see the ports section.
Lastly, feel free to drop by
#gmusicapi on Freenode to ask questions or just hang out.