[READ-ONLY] Mirror of https://github.com/FoxxMD/multi-scrobbler. Scrobble plays from multiple sources to multiple clients docs.multi-scrobbler.app
deezer docker jellyfin koito lastfm listenbrainz maloja mopidy mpris music music-assistant plex scrobble self-hosted spotify subsonic tautulli youtube-music
0

Configure Feed

Select the types of activity you want to include in your feed.

docs: Update Spotify docs and usage due to Redirect URI changes

As of April 2025 Spotify no longer allows insecure redirect URIs which complicates initial Spotify setup.

* Improve spotify App creation instructions
* Add several approaches to creating a valid redirect URI
* Remove Spotify as the default Source example in docs due to complexity of Redirect URI requirements

Closes #330

FoxxMD (Aug 1, 2025, 5:28 PM UTC) 06b23d62 38a15d64

+101 -26
+3 -3
docker-compose.yml
··· 4 4 container_name: multi-scrobbler 5 5 environment: 6 6 - TZ=Etc/GMT # Specify timezone from TZ Database name found here https://en.wikipedia.org/wiki/List_of_tz_database_time_zones 7 - #- SPOTIFY_CLIENT_ID= 8 - #- SPOTIFY_CLIENT_SECRET= 9 - #- SPOTIFY_REDIRECT_URI=http://multi-scrobbler-host-IP:9078/callback ## Need to be whitelisted in Spotify dashboard and is used for creating the connection first time 7 + #- JELLYFIN_APIKEY= 8 + #- JELLYFIN_URL= 9 + #- JELLYFIN_USER= 10 10 #- MALOJA_URL=http://maloja:42010 11 11 #- MALOJA_API_KEY= 12 12 #- PUID=1000 # required if running docker on linux host, see main README Docker setup instructions
+81 -5
docsite/docs/configuration/configuration.mdx
··· 1806 1806 1807 1807 ### [Spotify](https://www.spotify.com) 1808 1808 1809 - To access your Spotify history you must [register an application](https://developer.spotify.com/dashboard) to get a 1810 - Client ID/Secret. Make sure to also whitelist your redirect URI in the application settings. 1809 + <details> 1811 1810 1812 - :::note 1811 + <summary>Spotify and Automix</summary> 1813 1812 1814 1813 If your Spotify player has [Automix](https://community.spotify.com/t5/FAQs/What-is-Automix/ta-p/5257278) enabled and Spotify uses it for your playlist/queue then MS cannot accurately determine when a track will end. This is because the track is "mixed" in your queue with a shorter play time than its actual length and [Spotify does not report this modified play time in its API.](https://community.spotify.com/t5/Spotify-for-Developers/Wrong-duration-ms-of-track-with-Automix/m-p/5429147) This **does not affect MS's ability to scrobble** from Spotify but it will affect the accuracy of the duration MS reports was played. 1815 1814 1816 - ::: 1815 + </details> 1816 + 1817 + #### Authenticate Spotify with Multi-Scrobbler 1818 + 1819 + To access your Spotify history you must [create a Spotify App](https://developer.spotify.com/dashboard) to get a 1820 + Client ID/Secret. 1821 + 1822 + 1. **Login to https://developer.spotify.com** with your existing Spotify account and accept Developer Terms 1823 + 1824 + 2. Navigate to your Spotify Developer [Dashboard](https://developer.spotify.com/dashboard) and start the **Create App** process 1825 + 1826 + 3. Determine the correct **Redirect URI** to use and set it in your App settings 1827 + 1828 + <details> 1829 + 1830 + <summary>Redirect URI Instructions</summary> 1831 + 1832 + A Redirect URI is the URL that Spotify will navigate your **browser** to after you complete authorization. The URL will contain the code necessary for multi-scrobbler to get a Spotify access token. 1833 + 1834 + Spotify [**no longer allows insecure URIs**](https://developer.spotify.com/documentation/web-api/tutorials/migration-insecure-redirect-uri) (start with `http://`) unless the address is `127.0.0.1` -- so `localhost` and internal IPs (`192.168.0.xxx`) no longer work. 1835 + 1836 + Use **one** of the following methods to specify a valid Redirect URI and complete Spotify authentication with multi-scrobbler: 1837 + 1838 + <Tabs groupId="spotifyRedirect" queryString> 1839 + <TabItem value="https" label="HTTPS"> 1840 + **Use a domain you control, with SSL certificates/HTTPS enabled, to create a valid redirect URI.** 1841 + 1842 + For example, if you are already running multi-scrobbler behind a reverse proxy (nginx/traefik/caddy) at `https://scrobbler.mydomain.com` then set the Spotify Redirect URI for your Spotify App, and multi-scrobbler `SPOTIFY_REDIRECT_URI` ENV, to `https://scrobbler.mydomain.com/callback` 1817 1843 1818 - #### Configuration 1844 + Alternatively, if multi-scrobbler is not accessible behind your domain, then use the [**Echo**](./?spotifyRedirect=echo#spotify) method with your own domain instead of 127.0.0.1. 1845 + </TabItem> 1846 + <TabItem value="local" label="Run MS Locally"> 1847 + **Run multi-scrobbler, configured for a Spotify Source, from the same machine as your browser in order to get credentials.** 1848 + 1849 + In this scenario you can use `http://127.0.0.1:9078/callback` as the Spotify Redirect URI and multi-scrobbler `SPOTIFY_REDIRECT_URI` ENV. 1850 + 1851 + After completing authentication, copy the contents of local multi-scrobbler's [configuration folder](../installation/installation.mdx#storage) to the final location of where multi-scrobbler will be run. 1852 + </TabItem> 1853 + <TabItem value="echo" label="Echo"> 1854 + **Use a docker container on the same machine your browser is on to "intercept" the callback URL from Spotify authentication, then manually finish the process by changing the domain to your multi-scrobbler instance.** 1855 + 1856 + 1857 + 1. Create a container on the same machine as your browser using the [`mendhak/http-https-echo:36`](https://github.com/mendhak/docker-http-https-echo) image. This container runs a simple HTTP server that echos back any request it recieves. 1858 + 1859 + ```shell 1860 + docker run --rm -p 127.0.0.1:5079:8080 mendhak/http-https-echo:36 1861 + ``` 1862 + 1863 + 2. Set the Spotify Redirect URI and multi-scrobbler `SPOTIFY_REDIRECT_URI` ENV as `http://127.0.0.1:5079/callback` 1864 + 1865 + 3. In [Authenticate Spotify with Multi-Scrobbler](#authenticate-spotify-with-multi-scrobbler) (outside these Redirect Instructions) go to **Step 4** and continue the instructions 1866 + 1867 + Eventually, Spotify will redirect you to a web page with a URL like `http://127.0.0.1:5079/callback?code=xxxxxx...` 1868 + 1869 + ![echo](echo.png) 1870 + 1871 + 4. In the URL, replace `127.0.0.1:5079` with the address/IP for your multi-scrobbler instance so the URL is similar to `http://192.168.0.101:9078/callback?code=xxxxxx...`. Then navigate to this URL to complete authentication. 1872 + 1873 + </TabItem> 1874 + 1875 + <TabItem value="msEcho" label="Echo from echo.multi-scrobbler.app"> 1876 + For your convenience, I run the [`mendhak/http-https-echo:36`](https://github.com/mendhak/docker-http-https-echo) container from the [**Echo**](./?spotifyRedirect=echo#spotify) approach on a domain I, the multi-scrobbler developer [FoxxMD](https://github.com/FoxxMD), control and self-host. Please be aware: 1877 + 1878 + * I **do not collect personal data** or any querystrings/data sent in requests to this site 1879 + * It's **not possible** for me to use the code sent by Spotify to this URL without also having your Client ID/Secret 1880 + * However, there is **always** risk involved with trusting a service you do not control. Evaluate the risk of using this site for yourself. 1881 + 1882 + Use the [**Echo**](./?spotifyRedirect=echo#spotify) approach, starting from **Step 2**, with **https://echo.multi-scrobbler.app/callback** as Spotify Redirect URI and multi-scrobbler `SPOTIFY_REDIRECT_URI` ENV. 1883 + </TabItem> 1884 + </Tabs> 1885 + 1886 + </details> 1887 + 1888 + 4. Save your new App, then copy the Client ID/Secret from the App's Basic Information page. 1889 + 1890 + 5. Add the Client ID, Secret, and Redirect URI to the respective field/ENV in the [configuration section below](#spotify-config) 1891 + 1892 + 6. Start multi-scrobbler, then visit the Web Dashboard and click **(Re)authenticate** on the Spotify card to start the auth process 1893 + 1894 + #### Configuration {#spotify-config} 1819 1895 1820 1896 <Tabs groupId="configType" queryString> 1821 1897 <TabItem value="env" label="ENV">
docsite/docs/configuration/echo.png

This is a binary file and will not be displayed.

+11 -9
docsite/docs/installation/installation.mdx
··· 172 172 173 173 The example scenario: 174 174 175 - * [Spotify **Source**](../configuration/configuration.mdx#spotify) 175 + * [Jellyfin **Source**](../configuration/configuration.mdx#jellyfin) 176 176 * [Maloja **Client**](../configuration/configuration.mdx#maloja) 177 177 * Serving app on port `9078` 178 178 * Docker container located on a different IP (`192.168.0.100`) so use [Base URL](../configuration/configuration.mdx#base-url) ··· 184 184 <Tabs groupId="configType" queryString> 185 185 <TabItem value="env" label="ENV"> 186 186 ```bash 187 - docker run --name multi-scrobbler -e "SPOTIFY_CLIENT_ID=yourId" -e "SPOTIFY_CLIENT_SECRET=yourSecret" -e "BASE_URL=192.168.0.100" -e "MALOJA_URL=http://domain.tld" -e "MALOJA_API_KEY=1234" -e "PUID=1000" -e "PGID=1000" -p 9078:9078 -v /home/myUser/ms:/config foxxmd/multi-scrobbler 187 + docker run --name multi-scrobbler -e "JELLYFIN_APIKEY=c9fae8756fbf481ebd9c5bb56bd6540c" -e "JELLYFIN_URL=192.168.0.101:8096" -e "JELLYFIN_USER=MyUser" -e "BASE_URL=192.168.0.100" -e "MALOJA_URL=http://domain.tld" -e "MALOJA_API_KEY=1234" -e "PUID=1000" -e "PGID=1000" -p 9078:9078 -v /home/myUser/ms:/config foxxmd/multi-scrobbler 188 188 ``` 189 189 </TabItem> 190 190 <TabItem value="file" label="File"> ··· 204 204 container_name: multi-scrobbler 205 205 environment: 206 206 - TZ=Etc/GMT # Specify timezone from TZ Database name found here https://en.wikipedia.org/wiki/List_of_tz_database_time_zones 207 - - SPOTIFY_CLIENT_ID=yourId 208 - - SPOTIFY_CLIENT_SECRET=yourSecret 207 + - JELLYFIN_APIKEY=c9fae8756fbf481ebd9c5bb56bd6540c 208 + - JELLYFIN_URL=192.168.0.101:8096 209 + - JELLYFIN_USER=MyUser 209 210 - BASE_URL=http://192.168.0.100:9078 210 211 - MALOJA_URL=http://domain.tld:42010 211 212 - MALOJA_API_KEY=1234 ··· 261 262 <Tabs groupId="configType" queryString> 262 263 <TabItem value="env" label="ENV"> 263 264 ```shell 264 - SPOTIFY_CLIENT_ID=yourId SPOTIFY_CLIENT_SECRET=yourSecret MALOJA_URL="http://domain.tld" node src/index.js 265 + JELLYFIN_APIKEY=c9fae8756fbf481ebd9c5bb56bd6540c JELLYFIN_URL=192.168.0.101:8096 JELLYFIN_USER=MyUser MALOJA_URL="http://domain.tld" node src/index.js 265 266 ``` 266 267 </TabItem> 267 268 <TabItem value="file" label="File"> ··· 273 274 { 274 275 "sources": [ 275 276 { 276 - "type": "spotify", 277 + "type": "jellyfin", 277 278 "clients": ["myConfig"], 278 - "name": "mySpotifySource", 279 + "name": "myJellyfinSource", 279 280 "data": { 280 - "clientId": "a89cba1569901a0671d5a9875fed4be1", 281 - "clientSecret": "ec42e09d5ae0ee0f0816ca151008412a", 281 + "apiKey": "a89cba1569901a0671d5a9875fed4be1", 282 + "url": "http://192.168.0.101:8096", 283 + "user": "MyUser" 282 284 } 283 285 } 284 286 ],
+6 -9
docsite/docs/quickstart.mdx
··· 57 57 ``` 58 58 </TabItem> 59 59 <TabItem value="spotify" label="Spotify"> 60 - To access your Spotify activity you must [register a Spotify application](https://developer.spotify.com/dashboard) to get a 61 - **Client ID/Secret**. 60 + To access your Spotify activity you must [create a Spotify App](https://developer.spotify.com/dashboard) to get a 61 + **Client ID/Secret** and set a valid **Redirect URI**. 62 + 63 + Refer to the [Spotify Authentication instructions in the docs.](./configuration/configuration.mdx#authenticate-spotify-with-multi-scrobbler) 62 64 63 - When creating the application add this to **Redirect URIs** 64 - 65 - ``` 66 - http://192.168.0.100:9078/callback 67 - ``` 68 - 69 - After the application is created add these values to the `environment` section in the [`docker-compose.yml` you created.](#create-docker-compose-file) 65 + Assuming you used the **HTTPS** method for your **Redirect URI** from the instructions above...after the application is created add these values to the `environment` section in the [`docker-compose.yml` you created.](#create-docker-compose-file) 70 66 71 67 ```yaml title="~/msData/docker-compose.yml" 72 68 - SPOTIFY_CLIENT_ID=yourClientId 73 69 - SPOTIFY_CLIENT_SECRET=yourClientSecret 70 + - SPOTIFY_REDIRECT_URI=https://multi-scrobbler.mydomain.com/callback 74 71 ``` 75 72 76 73 Later, after [starting multi-scrobbler](#start-multi-scrobbler), visit the dashboard at `http://192.168.0.100:9078` and click **(Re)authenticate** on the Spotify card to authorize multi-scrobbler to use your account. Monitoring will begin automatically after authorization is complete.