Abstract Spotify App Compat Implicit Login Activity
Wrapper around spotify-auth's LoginActivity that allows configuration of the authentication process, along with callbacks on successful and failed authentication. Pair this with SpotifyDefaultCredentialStore to easily store credentials. Inherits from AppCompatActivity. If instead you want to inherit from Activity, please use AbstractSpotifyAppImplicitLoginActivity.
Properties
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.
Disable if you will not be using useDefaultRedirectHandler but will be setting SpotifyDefaultImplicitAuthHelper.activityBackOnImplicitAuth.
Functions
Return the scopes that you are going to request from the user here.
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.
Override this to define what to do after authentication has failed. You may want to use SpotifyDefaultCredentialStore to remove any stored token.
Override this to define what to do after authentication has been successfully completed. A valid, usable spotifyApi is provided to you. You may likely want to use SpotifyDefaultCredentialStore to store/retrieve this token.
Processes the result of LoginActivity, invokes callbacks, then finishes.
Override this to define what to do after onSuccess has run. The default behavior is to finish the activity, and redirect the user back to the activity set on SpotifyDefaultCredentialStore.activityBackOnImplicitAuth only if guardValidImplicitSpotifyApi has been used or if SpotifyDefaultCredentialStore.activityBackOnImplicitAuth has been set.
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.
Trigger the actual spotify-auth login activity to authenticate the user.