mirror of
https://github.com/spotipy-dev/spotipy.git
synced 2026-04-27 00:25:54 +03:00
[GH-ISSUE #92] Login issue #45
Labels
No labels
api-bug
bug
dependencies
documentation
duplicate
enhancement
external-ide
headless-mode
implicit-grant-flow
invalid
missing-endpoint
pr-welcome
private-api
pull-request
question
spotipy3
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotipy#45
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @freiermuth on GitHub (Apr 25, 2016).
Original GitHub issue: https://github.com/spotipy-dev/spotipy/issues/92
I've been trying countless different methods, and getting the code and callback, but my application keeps saying "bad request". See below:
# set environment variablesos.environ["SPOTIPY_CLIENT_ID"] = c_idos.environ["SPOTIPY_CLIENT_SECRET"] = c_secretos.environ["SPOTIPY_REDIRECT_URI"] = callback_uritoken = util.prompt_for_user_token(username, scope)and the output:
Opening https://accounts.spotify.com/...output_omitted...
Enter the URL you were redirected to: http://localhost:8888/...output_omitted...
Traceback (most recent call last):
File "./HotUnity.py", line 24, in
token = util.prompt_for_user_token(username, scope)
File "build/bdist.macosx-10.11-intel/egg/spotipy/util.py", line 86, in prompt_for_user_token
File "build/bdist.macosx-10.11-intel/egg/spotipy/oauth2.py", line 210, in get_access_token
spotipy.oauth2.SpotifyOauthError: Bad Request
@jdwilkin commented on GitHub (May 13, 2016):
I was also just having this problem and in my case I discovered after some inspection that my callback url had a "#" at the end followed by "=". When pasting the callback url into the console I omitted that portion of the url and it worked! Spotipy needs to be able to properly parse out the code from the callback url
@stephanebruckert commented on GitHub (Jan 1, 2020):
Yes check the
redirect_uriis correct