spotify

How to get info of what user listens currently in Spotify app [closed]

☆樱花仙子☆ 提交于 2019-12-02 06:25:46
Can an Android app (runs on background and uses Spotify SDK) get info of which track the user listens currently at exact time in Spotify Android app? I think you'd be interested in the Android Media Notifications . If you are developing an Android application and want to know what is happening in the Spotify app, you can subscribe to broadcast notifications from it. 来源: https://stackoverflow.com/questions/26301113/how-to-get-info-of-what-user-listens-currently-in-spotify-app

Spotify iOS SDK Swift display all (!) playlists (20+)

依然范特西╮ 提交于 2019-12-02 00:54:41
I'm able to get the first 20 playlists fairly easily in Swift. func getPlaylists() { //DispatchQueue.global(qos: .userInitiated).async { let playListRequest = try! SPTPlaylistList.createRequestForGettingPlaylists(forUser: session.canonicalUsername, withAccessToken: session.accessToken) Alamofire.request(playListRequest) .response { response in let list = try! SPTPlaylistList(from: response.data, with: response.response) for playList in list.items { if let playlist = playList as? SPTPartialPlaylist { let currentPlaylist: PlaylistItem = PlaylistItem(playlistName: playlist.name, playlistURL:

Extract token from response url - Spotify API

↘锁芯ラ 提交于 2019-12-01 23:24:29
I'm using this code to get a token from Spotify's Web API: <?php $url = 'https://accounts.spotify.com/api/token'; $method = 'POST'; $credentials = "{Client ID}:{Client Secret}"; $headers = array( "Accept: */*", "Content-Type: application/x-www-form-urlencoded", "User-Agent: runscope/0.1", "Authorization: Basic " . base64_encode($credentials)); $data = 'grant_type=client_credentials'; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); $response = curl_exec($ch); ?

How to create a playlist and get the URI of it in a spotify apps API?

末鹿安然 提交于 2019-12-01 20:20:54
问题 It is possible to create a playlist (new Playlist(name)) with the spotify apps API, but the URI field of the new playlist is always null. Anyone know how to get around this, or otherwise reference the new playlist? Without an URI I can't create a "share" button within the app, since I need the URI in order to reference it. Anyone know if this is a bug or feature? I just discovered that spotify removed the ability to read user playlists for privacy reasons[1], so now I'm wondering if this is a

How to create a playlist and get the URI of it in a spotify apps API?

一笑奈何 提交于 2019-12-01 18:55:09
It is possible to create a playlist (new Playlist(name)) with the spotify apps API, but the URI field of the new playlist is always null. Anyone know how to get around this, or otherwise reference the new playlist? Without an URI I can't create a "share" button within the app, since I need the URI in order to reference it. Anyone know if this is a bug or feature? I just discovered that spotify removed the ability to read user playlists for privacy reasons[1], so now I'm wondering if this is a design decision or simply a bug. After all, the playlist in question was created in our app, so I

Integrating the Spotify Android library

戏子无情 提交于 2019-12-01 17:42:49
So I wanted to integrate the spotify library into an android app. I went to https://developer.spotify.com/technologies/libspotify/ and downloaded their lib libspotify-12.1.51-Android-arm-release.tar.gz Problem is that the "Android" samples bundled with the lib aren't actually android projects, they are C code, the lib is a .so file. I have basic knowledge of android ndk and jni but the documentation out there about integrating the library with android is non-existent. Can anyone provide a sample of just playing a track? or point me to where i can find a sample. Nik Reiman Unfortunately,

Unsupported grant type error when requesting access_token on Spotify API with Meteor HTTP

青春壹個敷衍的年華 提交于 2019-12-01 17:35:47
I've been unable to solve a problem while requesting an access_token on Spotify API with Meteor HTTP. Indeed, when I make a POST call to the Spotify https://accounts.spotify.com/api/token . I get the following response : {"statusCode":400,"content":"{\"error\":\"unsupported_grant_type\",\"error_description\":\"grant_type must be client_credentials, authorization_code or refresh_token\"}" I think this may have something to do with the Content-Type header and the encoding of the BODY parameter but I haven't been able to solve this issue. I tried to use both data and params and none of these

Obtaining a lists of artists using cocoalibspotify for iOS

房东的猫 提交于 2019-12-01 13:35:44
I'd like to quickly get a list of artist names in a user's "library" or playlists. Is there an easy / asynchronous way to do this? Take a look at the example project "Guess the Intro" included with CocoaLibSpotify. The method waitAndFillTrackPool in that project shows how to get a list of all the tracks in the user's playlists. Once you have that list, you can do the following to get the artists from them, put them through a set to thin out duplicates, then wait until they're loaded. NSArray *artists = [theTrackPool valueForKeyPath:@"@unionOfArrays.artists"]; NSArray *uniqueArtists = [[NSSet

Spotify API for ios: download , save , access tracks from ios spotify api

最后都变了- 提交于 2019-12-01 12:44:19
I would like to know whether downloading tracks to the iphone / ipod / ipad devices is possible using the spotify ios api (CocoaLibSpotify IOS Library). If so I also need to access them and play anytime I want. I will be using them in my app later. I think we can check the offline status of the track that is being played by using sp_track_offline_status. But I am unable to get through that. Any sample code snippet would be of great help. Simplifying the requirement : download and save the spotify tracks into iOS devices As an update, in response to iKenndac's answer, the offlineStatus property

Spotify Apps API: Library-class won't return users Playlists

一个人想着一个人 提交于 2019-12-01 12:26:38
问题 I'm trying to get an array containing all Playlists in the users Library (http://developer.spotify.com/download/spotify-apps-api/reference/dcdebc652c.html). No problems with the other class properties (albums, artists, starredPlaylist, tracks), but somehow the "Playlists" property won't work using var allPlaylists = models.library.playlists; whereas var allArtists= models.library.artists; works just fine!( Both using document.write(var) ) Any suggestions? thank you! 回答1: Here's the official