Provide Spotify OAuth 2.0 authorization using PKCE. More...
Public Member Functions | |
| str | redirect_uri (self) |
| Return the configured OAuth redirect URI. | |
| str | get_access_token (self) |
| Return a valid Spotify access token, authorizing when needed. | |
| SpotifyAuthorizationRequest | begin_authorization (self) |
| Create a transport-independent Spotify authorization request. | |
| OAuthTokens | complete_authorization (self, SpotifyAuthorizationRequest request, *, str|None code, str|None state, str|None error=None, str|None error_description=None) |
| Validate an OAuth callback, exchange its code, and store tokens. | |
| OAuthTokens | login (self, *, Callable[[], bool] is_current=lambda:True) |
| Run the desktop flow while its owner remains active. | |
| OAuthTokens | refresh (self, str refresh_token) |
| Refresh and persist a Spotify access token. | |
Provide Spotify OAuth 2.0 authorization using PKCE.
| OAuthTokens spotify.spotify_auth.SpotifyAuth.login | ( | self, | |
| * | , | ||
| Callable[[], bool] | is_current = lambda: True ) |
Run the desktop flow while its owner remains active.
| is_current | Whether authorization is still wanted. |