mirror of
https://github.com/spotipy-dev/spotipy.git
synced 2026-10-10 17:00:46 +00:00
Auto-refresh AuthCode flow token. (#435)
* Auto-refresh AuthCode flow token. * Reformatted. * Reformatted. * Removed invalid syntax. * Removed abstract class SpotifyAuthManager. * Fix typo on docstrings. * Optionally try to fetch main input parameters from environment. Implements the capability of trying to fetch the following parameters from the environment, when they're not directly passed to the authorization handler. The affected parameters are: client_id, client_secret, redirect_uri. An SpotifyOauthError is raised if no value gets found. * Removed f-string for Python2 compatibility. * Fix line-too-long. * Remove useless import. * Add username to docstring. * Remove redundant return. * Fix empty lines print statement for backward compatibility with Python2. * Update simple4 example. * Set optional 'as_dict' parameter on OAuth 'get_access_token'. * Update changelog. Co-authored-by: Stéphane Bruckert <stephane.bruckert@gmail.com>
This commit is contained in:
1 parent
3b0e8febc4
commit
4515446a65
5 files changed
+715
-437
No files matched your search
@@ -0,0 +1,12 @@
|
||||
import spotipy
|
||||
import os
|
||||
from pprint import pprint
|
||||
|
||||
def main():
|
||||
spotify = spotipy.Spotify(auth_manager=spotipy.SpotifyOAuth())
|
||||
me = spotify.me()
|
||||
pprint(me)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in new issue
Block a user