You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After about an hour of listening to music, the spotify credentials will expire, and will only refresh if the user refreshes the page.
Possible solutions
Set a timer for less than 1h to auto refresh the token
When spotify web player throws an unauthorized error, make a request to refresh the token
Use the preexisting api route defined in Network.sendGetSpotifyToken, this will always return an updated token
Task
Automatically refresh the spotify credentials when/before the token expires
Note: You will need to run the project in network mode, I recommend setting the servers like this: https://github.com/ufosc/Jukebox-Server/blob/main/docs/Network-Mode.md, then running npm run network in the terminal. Alternatively, you can run docker-compose -f docker-compose.network.yml up, but this makes logs harder to read in the terminal.
The text was updated successfully, but these errors were encountered:
Problem
After about an hour of listening to music, the spotify credentials will expire, and will only refresh if the user refreshes the page.
Possible solutions
Network.sendGetSpotifyToken
, this will always return an updated tokenTask
Note: You will need to run the project in network mode, I recommend setting the servers like this: https://github.com/ufosc/Jukebox-Server/blob/main/docs/Network-Mode.md, then running
npm run network
in the terminal. Alternatively, you can rundocker-compose -f docker-compose.network.yml up
, but this makes logs harder to read in the terminal.The text was updated successfully, but these errors were encountered: