GENRE through the Spotify iOS SDK - spotify

Does anyone know whether Genre can be obtained through the Spotify iOS SDK?
It doesn't seem to be listed in the documentation.

According to feature request #31 dated Apr 20, 2015 on spotify web API on GitHub
Spotify doesn't expose genres for tracks, the closest you can get is
to check the genre of the album the track is on. Genre is however only
part of the full album object, and not the simple album object. To get
the album's genre, first requesting the Track metadata to get the
album URI, and continue to request Album metadata. You can also
get an artist's genres by calling the Artist metadata endpoint.

Related

Getting Spotify-generated artist playlists using Web API

When Siri is asked "play music by ARTIST_NAME on Spotify" she starts playing music from a playlist that is generated by Spotify, with no displayed name, and the description "ARTIST_NAME songs picked just for you". I cannot find a way to find this playlist. Its name, according to the https://api.spotify.com/v1/me/player endpoint, is ARTIST_NAME, and its owner is Spotify. How can I find this playlist for a given artist using the Web API?
Ultimately, I am trying to work around the fact that if there is no available device (i.e. Spotify is idle or closed) an artist cannot be played by setting a context-uri in the https://api.spotify.com/v1/me/player/play endpoint. To work around this issue in the case of playing a playlist that the user of my program searches for, I have simply opened the URL of the first track in the album or playlist. This doesn't work in the case of artists, since the list of top tracks by an artists gives the tracks' URLs in the context of the respective tracks's album.
If there is no way to access this Siri exclusive playlist, I would appreciate feedback suggesting alternate routes. It is not sufficient to simply create a playlist, since they would be static and have to be recreated for each request.
Thank you.

How to get artist, album, or track metrics from Spotify API, if possible

I have been looking into the Spotify API over the last few days, and it's not clear to me whether any of the following information is available:
For artists, either their stream counts or album sales or any other metrics that indicate how popular an artist is.
Same for albums and tracks, any indication of popularity of the album or track
Here's output from their /get-artist endpoint for Kanye West:
We only receive a followers count of 16011935, which I assume is their Spotify followers, and a popularity of 95 that appears to be on a 0 - 100 scale and is presumably derived from the followers metric. As far as metrics for albums are concerned, from their /get-album endpoint:
Here we receive a popularity for Kanye's Donda album, but no other metrics associated with the album. And from their /get-track endpoint, there are no metrics at all associated with the track.
Am I missing something? Going into this, I sort of assumed that the Spotify web API would have some additional metrics on artists, albums, and tracks, but perhaps not?
Unfortunately you're correct in your analysis, as in Spotify APIs do not directly give access to any kind of streaming metrics. Also note that the popularity is a dynamic metric which changes over time, not only related to follower counts. An alternative way to get some kind of streaming info would be to look at external data sources, such as last.fm, but of course this requires you to match the two APIs.

On what basis music apps categories the trending songs?

I am designing a music web app.
In that, I want to display the trending songs
Are there any criteria to display the trending songs as Spotify or Gaana does?
Are you using the Spotify Web API? What language are your coding in? You should add more info/code samples so people aren't guessing.
There isn't an API endpoint to specifically 'get the top tracks on Spotify'.
But...you could use the ID of their Top 50 playlist and pull in the tracks from that: https://open.spotify.com/playlist/37i9dQZEVXbMDoHDwVN2tF
The Id is 37i9dQZEVXbMDoHDwVN2tF so,
GET https://api.spotify.com/v1/playlists/37i9dQZEVXbMDoHDwVN2tF
source: https://developer.spotify.com/documentation/web-api/reference/playlists/get-playlist/

Instagram - Get Recently updated media (photos or videos)

Is there any API to get id's of ALL images or videos that are commented or liked after a certain timestamp.
Is there any API to get all comments of the profile without including the 'media-id' (image or video id)
Currently there is no API to directly access the comments by time for a user profile.
You have first get all the media for a user:
https://api.instagram.com/v1/users/{user-id}/media/recent/?access_token=ACCESS-TOKEN
Then for each media, get comments:
https://api.instagram.com/v1/media/{media-id}/comments?access_token=ACCESS-TOKEN
use the created_time in the comments to filter out the latest comments, note that you only get the latest 150 comments for each of the media.

Is it possible to generate a playlist from two users liked music or playlists, through Spotify or Apple Music?

I am trying to generate a playlist from two users different playlists. I know you can get a public playlist from a Spotify users id, hopefully their most played,but i am not sure if you can combine it with another user's playlist?
Sure. First read both of the users Spotify playlists. You'll have to use the iTunes Search API to find the respective track on iTunes and it's product ID. You can then use the music API's added in 9.3+ to make a playlist and add the product ID's for the songs in the two playlists.

Resources