mirror of
https://github.com/spotipy-dev/spotipy.git
synced 2026-04-27 00:25:54 +03:00
[GH-ISSUE #336] Get users id #193
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#193
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 @AlessandroMinervini on GitHub (Oct 25, 2018).
Original GitHub issue: https://github.com/spotipy-dev/spotipy/issues/336
Hi everyone, my question:
is possible get a user id in any way? I would search a user from his name and print his recently artist played
Thanks
@Pizza-slice commented on GitHub (Nov 14, 2018):
ya using the
mefunctiontoken = util.prompt_for_user_token(username, scop, SPOTIPY_CLIENT_ID, SPOTIPY_CLIENT_SECRET, SPOTIPY_REDIRECT_URI) if token:the return will be a dictionary(the python to equivalent to JSON)
in the dictionary there is more info just then user id (email , Birth-Day,profile photo etc... ) i think it depend on your scop you ask with your token
@AlessandroMinervini commented on GitHub (Nov 15, 2018):
Ok thank you for my current user,
but if i want the id of my friend?
Thank you
@mckinly commented on GitHub (Nov 29, 2019):
@AlessandroMinervini If you know the username of your friend you can pass that as a string into this method.
github.com/plamere/spotipy@4c2c1d763a/spotipy/client.py (L346)Also see the Web Api docs for more information Get user's profile
@stephanebruckert commented on GitHub (Jan 12, 2020):
It's unclear what you are really asking but if you are looking to search a user by display name in order to get the ID, it doesn't seem possible. Probably this is for security/privacy reasons. As @mckinly suggested, you need the user ID to find a user.