Abstract Spotify Pkce Login Activity
This class hooks into spotify-web-api-kotlin to provide PKCE authorization for Android application. Paired with SpotifyDefaultCredentialStore to easily store credentials. To use, you must extend this class and follow the instructions in the spotify-web-api-kotlin README.
Properties
Provide if you would like to customize the returned SpotifyClientApi.
The code verifier generated that the client will be authenticated with (using its code challenge). Must be between 43-128 alphanumeric characters
Your application's Spotify redirect id - NOTE that this should be an android scheme (such as spotifyapp://authback) and that this must be registered in your manifest.
the scopes that you are going to request from the user here.
Functions
Get the authorization url that the client will be redirected to during PKCE authorization.
Get the code challenge for the pkceCodeVerifier that will be used to confirm token identity.
Basic implicit authentication guard - verifies that the user is logged in to Spotify and uses SpotifyDefaultImplicitAuthHelper to handle re-authentication and redirection back to the activity.
The callback that will be executed after successful PKCE authorization.
Register a Spotify broadcast receiver (receiving notifications from the Spotify app) for the specified notification types.
Start Spotify PKCE login activity within an existing activity.
Start Spotify implicit login activity within an existing activity.