metabrainz/listenbrainz-android

Authorize listenbrainz android in order to play songs from spotify

CoderWithaBoner opened this issue · 8 comments

I don't under what does this mean?

Usually spotify should popup a dialog that asks "let LB Android connect to Spotify". The message you mentioned indicates that you might have not authorised the app to connect to spotify.

Hey 07jasjeet . you mean that when we open Spotify , Spotify ask user to let LB Android connect to Spotify in a Alert box where the user can authorize it .

Hey 07jasjeet . you mean that when we open Spotify , Spotify ask user to let LB Android connect to Spotify in a Alert box where the user can authorize it .

No @Aman03913 , when you open ListenBrainz Android (not Spotify App), the authorization flow should pop up. Rest of your statement is true.

You mean that you are authorizing the user of ListenBrainz Android by the POP Up with the help of Spotify . Is it correct ?

Somewhat yes. ListenBrainz Android can only access the Spotify account for which authorization or access has been given. How is this authorization tracked you may ask? A unique API key (assigned to us by spotify) for LB Android app gets linked to user's(your) Spotify account in Spotify's database which determines the access.

In ListenBrainz Android implement one of the OAuth 2.0 flows and Use the Spotify API's authorization endpoint to redirect the user to Spotify for authentication. Upon successful login and user consent, the user will be redirected back to your application with an authorization code.

No @Aman03913, LB Android has onboard Spotify SDK tailor made to handle remote playback and connect to Spotify. We just prompt the sdk to connect to Spotify app and rest is done by the SDK. You can check out Spotify's docs for the same. OAuth flow is handled by the SDK itself.

Okay Now i Understood ,thanks for clearing my Doubt and I think i can work on it .