Skip to main content

Usage

Please note that this won't work without Spotify Premium because Spotify limits web API access to non-free accounts.

This also requires you to have set up mopidy-spotify in order to play spotify tracks.

  • Install from PyPI with pip3 install --user spotify-mpd-sync

  • Go to https://developer.spotify.com/dashboard/applications and create an application. Call it whatever you want.

  • Go to "Edit Settings" in your newly created app, then add http://localhost:8080 as a redirect URI and hit "Save" (You may choose a different one by setting SPOTIPY_REDIRECT_URI in your environment if localhost:8080 is unavailable)

  • Find your spotify username here

  • You will have to set up some environment variables in order to run the app.

export SPOTIFY_USERNAME="The username you got above"
export SPOTIPY_CLIENT_ID="Your app's client ID"
export SPOTIPY_CLIENT_SECRET="Your app's client secret"
export SPOTIPY_REDIRECT_URI="http://localhost:8080"
  • Now you can run spotsync -H my_mpd_host -P 6600 where my_mpd_host is the host you are running MPD on (host defaults to localhost and port defaults to 6600 if you do not include it)

  • If this is the first time you are running it, it will direct you to a page in your browser to grant permission for the app you just created to access your private spotify playlist. You only need to do this once, and then your credentials will be cached.

  • You will be prompted to grant permission to the app, once that's done, it will cache the credentials locally and you should be able to just run spotsync.

Metadata

Release files for spotify-mpd-sync 1.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spotify-mpd-sync 1.0.2
File Size Uploaded Provenance Actions
spotify-mpd-sync-1.0.2.tar.gz 4.6 kB Without provenance Details for spotify-mpd-sync-1.0.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for spotify-mpd-sync 1.0.2
File Interpreter ABI Platform Actions
spotify_mpd_sync-1.0.2-py3-none-any.whl Python 3 none any Details for spotify_mpd_sync-1.0.2-py3-none-any.whl

Total release size: 11.2 kB

Release files / spotify-mpd-sync-1.0.2.tar.gz

Download URL spotify-mpd-sync-1.0.2.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
82c427a60225fd6e93e52c3f0f4f2121f32c66282ed629b0baf8e87de1dea162
BLAKE2b-256 checksum
How to use checksums
fc345a2f7e22bf4b9e9ebbd9b4f45f5b4e85f7e7b33f02860791428bf58f3e6f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Release files / spotify_mpd_sync-1.0.2-py3-none-any.whl

Download URL spotify_mpd_sync-1.0.2-py3-none-any.whl
Size 6.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f70117e9fc682cf21df8bbd403e7e9cbfe1e53885a215702be614003e4acf6d2
BLAKE2b-256 checksum
How to use checksums
bcb8b115d9547be5a9abc1fb94332c0d5fcf854ccbc066d8381c950bcf627f62
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Security for spotify-mpd-sync 1.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page