Mopidy extension for playing music from Spotify.
Spotify have recently disabled username and password login for playback (#394) and we now utilise access-token login. You no longer need to provide your Spotify account username or password.
Mopidy-Spotify currently has no support for the following:
- Seeking
- Gapless playback
- Volume normalization
- Saving items to My Music (#108) - possible via web API
- Podcasts (#201) - now possible
- Radio (#9) - unavailable?
- Spotify Connect (#14)
Working support for the following features is currently available:
- Playback
- Search
- Playlists (read-only)
- Top lists and Your Music (read-only)
- Lookup by URI
A Spotify Premium subscription. Mopidy-Spotify will not work with Spotify Free, just Spotify Premium.
Mopidy
>= 3.4. The music server that Mopidy-Spotify extends.gst-plugins-spotify
, the GStreamer Rust Plugin for Spotify playback, based on librespot. This plugin is not yet available from apt.mopidy.com. It must be either built from source or Debian packages are available for some platforms.We currently require a forked version of this plugin which supports token-based login. This can be found here.
Verify the GStreamer spotify plugin is correctly installed:
gst-inspect-1.0 spotify
Install by running:
sudo python3 -m pip install --break-system-packages Mopidy-Spotify==5.0.0a2
Before starting Mopidy, you must add your Spotify Premium username and password to your Mopidy configuration file and also visit https://mopidy.com/ext/spotify/#authentication to authorize this extension against your Spotify account:
[spotify] client_id = ... client_id value you got from mopidy.com ... client_secret = ... client_secret value you got from mopidy.com ...
The following configuration values are available:
spotify/enabled
: If the Spotify extension should be enabled or not. Defaults totrue
.spotify/username
: Your Spotify Premium username. Obsolete.spotify/password
: Your Spotify Premium password. Obsolete.spotify/client_id
: Your Spotify application client id. You must provide this.spotify/client_secret
: Your Spotify application secret key. You must provide this.spotify/bitrate
: Audio bitrate in kbps.96
,160
, or320
. Defaults to160
.spotify/volume_normalization
: Whether volume normalization is active or not. Defaults totrue
.spotify/timeout
: Seconds before giving up waiting for search results, etc. Defaults to10
.spotify/allow_cache
: Whether to allow caching. The cache is stored in a "spotify" directory within Mopidy'score/cache_dir
. Defaults totrue
.spotify/cache_size
: Maximum cache size in MiB. Set to0
for unlimited. Defaults to8192
.spotify/allow_playlists
: Whether or not playlists should be exposed. Defaults totrue
.spotify/search_album_count
: Maximum number of albums returned in search results. Number between 0 and 50. Defaults to 20.spotify/search_artist_count
: Maximum number of artists returned in search results. Number between 0 and 50. Defaults to 10.spotify/search_track_count
: Maximum number of tracks returned in search results. Number between 0 and 50. Defaults to 50.
- Original author: Stein Magnus Jodal
- Current maintainer: Nick Steel
- Contributors