audio-band icon indicating copy to clipboard operation
audio-band copied to clipboard

Issues with setting up Spotify Audio Source

Open jonoyay opened this issue 4 years ago • 7 comments

I tried following all the steps and right after I put all my Spotify secrets and client id I get sent into a google chrome tab but the only says. INVALID_CLIENT: Invalid redirect URI the URL is ((down there)) a lot of it has been cut out for privacy. (https://accounts.spotify.com/authorize/?client_id=)

jonoyay avatar Feb 05 '20 07:02 jonoyay

That usually happens when you did not save the correct Redirect URI on your Spotify App settings. Say you changed Audio-Band Callback port to 1234 then your callback URI should be saved as http://localhost:1234

snormonster avatar Feb 11 '20 08:02 snormonster

I have a similar issue, after choosing Spotify as audio source and complete setup, my browser ask me to sign in into Spotify and after it redirects me to something like: http://localhost/?code=####&state=####

which is "not found" I guess I'm missing something in settings or maybe my proxy settings do not allow me to use audio band.

AlexFrancoMx avatar Feb 20 '20 14:02 AlexFrancoMx

Loving this so much, thank you for all the effort you're putting into this. Has worked flawlessly for me for several months but for the past 2 weeks i can't use previous track/next track buttons anymore. It does not do anything, nothing happening. Can only do it directly from spotify website.

ghost avatar Feb 22 '20 06:02 ghost

I fixed this by choosing a different port to 80; for whatever reason when chrome opened up the callback it would drop the :80 extension to the URL even if I manually added it back in. I changed it to 1234 on the Redirect URI and the Audio Band callback port and it works! I don't know if this is a chrome specific issue, it's hard to test now it's working!

zakkarimjee avatar May 21 '20 12:05 zakkarimjee

For me the issue was caused by the "/" at the end of the Redirect URI parameter in the Spotify App settings. In the settings it was written as

http://localhost:80/

After changing it to

http://localhost:80

I got redirected to the screen prompting me to authorise the app and everything seems to be working now.

PaulMolochko avatar Apr 28 '21 14:04 PaulMolochko

I struggled a bit with this myself. It was quite annoying, every 10 minutes a new popup, but I wrote here what I found worked for me.

https://community.spotify.com/t5/Spotify-for-Developers/INVALID-CLIENT-Invalid-redirect-URI/m-p/5338762/highlight/true#M4036

MarijnPessers avatar Feb 05 '22 00:02 MarijnPessers

I fixed this by choosing a different port to 80; for whatever reason when chrome opened up the callback it would drop the :80 extension to the URL even if I manually added it back in. I changed it to 1234 on the Redirect URI and the Audio Band callback port and it works! I don't know if this is a chrome specific issue, it's hard to test now it's working!

To offer some context as to why this is happening; Port 80 is the default http port. If you do not add anything and your prefix is http it will connect to port 80. Since these are the same your browser does not display the port name. https has something similar; that is by default port 443.

Whenever you choose a different port for your own configurable application make sure it is a random (not too obvious) port. Some applications you install will by default use port numbers that are easy to remember like 8181, 8123, 8888. These can be configured for these apps but there is no need if you have no conflict. Using a completely random port like 8289 is more likely to never give a conflict.

MarijnPessers avatar Feb 05 '22 00:02 MarijnPessers