Closed Bastilms closed 2 years ago
Hey, first can you hide your SPOTIFY_SECRET key. Its must be secret, but you shared it here 😄 . Did you register in spotify dashboard your redirect URL? Must be something like that: ( Edit Settings inside )
Hey, yes, I added the redirect URL already to the Spotify dashboard.
Nevermind! I deleted the last part of the redirect URL inside my docker compose file (/oauth/spotify/callback
). Now it works fine. I Still don't know why I have these two //
when I try to connect my Spotify for the first time. Maybe I have still a typo. Who knows.
My Problem is now solved
I get redirected to
https://<my domain>.de//oauth/spotify
. I'm not sure why it uses the two//
. However, I fix it by deleting on.
I am also facing the issue with https://spotapi.DOMAIN//oauth/spotify
when I try to authorize.
I have to manually remove one /
to be able to continue
My compose
spotify_server:
image: yooooomi/your_spotify_server
container_name: spotify_server
restart: always
ports:
- "5555:8080" #https://spotapi.DOMAIN.eu/
links:
- mongo
depends_on:
- mongo
environment:
- API_ENDPOINT=https://spotapi.DOMAIN.eu # This MUST be included as a valid URL in the spotify dashboard
- CLIENT_ENDPOINT=https://spotify.justsky.eu
- SPOTIFY_PUBLIC=$SPOTIFY_KEY
- SPOTIFY_SECRET=$SPOTIFY_SECRET
- CORS=all
- MONGO_ENDPOINT=mongodb://spotify_mongo:27017/your_spotify
mongo:
container_name: spotify_mongo
image: arm64v8/mongo:4.4
restart: always
volumes:
- $DOCKERDIR/your_spotify_db:/data/db
spotify_web:
image: yooooomi/your_spotify_client
container_name: spotify_web
restart: always
ports:
- "3003:3000" #https://spotify.DOMAIN.eu
environment:
- API_ENDPOINT=https://spotapi.DOMAIN.eu
I was not sure which domain to add, so I added both
Rest everything works, just waiting for axios and npm update.
Hey,
I have a few issues with the API. When I try to connect my Spotify, I get redirected to
https://<my domain>.de//oauth/spotify
. I'm not sure why it uses the two//
. However, I fix it by deleting on. After this, I get redirected to the Spotify API. Unfortunately, the next errorINVALID_CLIENT: Invalid redirect URI
. The reason for this is the following part in the URL:&redirect_uri=https%3A%2F%2F<my domain>%2Foauth%2Fspotify%2Fcallback%2Foauth%2Fspotify%2Fcallback
. I Also solved this by deleting the last%2Foauth%2Fspotify%2Fcallback
because it didn't make that much sense to me. After the next redirect, I'm back on my server's API with a 401 Error on the following URL:https://<my domain>/oauth/spotify/callback?code=<Authorized Key>
. Now I'm stuck and not quite sure why this happens.Does anyone have a solution? Maybe it's because I'm using an internal domain to access the Dashboard, and only the API is on a public domain.