A friendly wrapper library for the Deezer API
Deezer Python Client
A friendly wrapper around the Deezer API.
The package is published on PyPI and can be installed by running:
pip install deezer-python
So far you can only retrieve the data for the public objects, for which no login is required. The objects are translated to python resources, which are basically python objects encapsulating the json dictionary returned by the API.
>>> client = deezer.Client() >>> client.get_album(12).title 'Monkey Business'
You also can use an AsyncClient with tornado, which requires an optional dependency. You should install with pip install deezer-python[tornado]. Then, making requests look like:
>>> from tornado.gen import coroutine >>> from tornado.ioloop import IOLoop >>> from deezer.contrib.tornado import AsyncClient >>> >>> >>> @coroutine ... def main(): ... client = AsyncClient() ... album = yield client.get_album(12) ... print(album.title) ... >>> IOLoop.instance().run_sync(main) Monkey Business
Not supported by this package. There are excellent other python modules to handle that. There is the excellent Python Social Auth, which supports Deezer authentication.
- Breaking: drop support for Python 2.
- Add Client.advanced_search.
- Added index and limit to Client.search & Client.get_charts. Defaults are set to Deezer API defaults.
- Changed tornado to be an optional requirement. If you want to use the asynchronous client, you need to install the library as follow pip install deezer-python[tornado].
- Simplified a couple of things to rely more on six for Python compatibility.
- Auto-format code using black.
- Breaking: the async module has been renamed asynchronous as it was breaking under Python 3.7, thanks Matheus Horstmann for the patch
- Optimisation: the session is now stored internally by the client
- Python 3.6 support
- Remove Python 3.2 classifier, support was dropped since 0.2.3
- Updated docs and testing setup
- Enriching the API for resources to get related resources as iterators. Thanks to Pascal.
- Drop support for Python 3.2. It should still work, but we are not testing it anymore, as this version as reached end of life.
- Python 3.5 support
- Various doc updates
- Enriching the API for resources to get artists for a genre, top tracks of an artist, etc… Thanks to Misuzu.
- Initial release.
“deezer-python” is written and maintained by Bruno Alla.
Release history Release notifications
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size deezer_python-1.0.0-py3-none-any.whl (9.4 kB)||File type Wheel||Python version py3||Upload date||Hashes View hashes|
|Filename, size deezer-python-1.0.0.tar.gz (18.6 kB)||File type Source||Python version None||Upload date||Hashes View hashes|
Hashes for deezer_python-1.0.0-py3-none-any.whl