Reputation: 1030
Using the advice in this post I have been able to access the spotify users data for their playlists with
sp = getSpotifyApi(1); console.log (sp.core.library.getAlbums());
I want to access the spotify user data for the user logged into the app, specifically the spotify uri for the user.
sp = getSpotifyApi(1); console.log (sp.core.user); // is undefined console.log (sp.social.relations); // is undefined
How can I do this?
Upvotes: 1
Views: 1059
Reputation: 18776
This information is not available in the Spotify Apps API for privacy reasons. There is a unique user ID, but it is not the user's username.
If you need the user's friends list, you'll need to connect to (say) Facebook yourself and get it that way.
Upvotes: 2