Get Recommendations
Deprecated
recommendations.get(RecommendationGetParams**kwargs) -> RecommendationGetResponse
GET/recommendations
Recommendations are generated based on the available information for a given seed entity and matched against similar artists and tracks. If there is sufficient information about the provided seeds, a list of tracks will be returned together with pool size details.
For artists and tracks that are very new or obscure there might not be enough data to generate a list of tracks.
Parameters
Returns
Get Recommendations
import os
from spotted import Spotted
client = Spotted(
access_token=os.environ.get("SPOTIFY_ACCESS_TOKEN"), # This is the default and can be omitted
)
recommendation = client.recommendations.get()
print(recommendation.seeds){
"seeds": [
{
"id": "id",
"afterFilteringSize": 0,
"afterRelinkingSize": 0,
"href": "href",
"initialPoolSize": 0,
"published": true,
"type": "type"
}
],
"tracks": [
{
"id": "id",
"album": {
"id": "2up3OPMp9Tb4dAKM2erWXQ",
"album_type": "compilation",
"artists": [
{
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"name": "name",
"published": true,
"type": "artist",
"uri": "uri"
}
],
"available_markets": [
"CA",
"BR",
"IT"
],
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"images": [
{
"height": 300,
"url": "https://i.scdn.co/image/ab67616d00001e02ff9ca10b55ce82ae553c8228\n",
"width": 300,
"published": true
}
],
"name": "name",
"release_date": "1981-12",
"release_date_precision": "year",
"total_tracks": 9,
"type": "album",
"uri": "spotify:album:2up3OPMp9Tb4dAKM2erWXQ",
"published": true,
"restrictions": {
"published": true,
"reason": "market"
}
},
"artists": [
{
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"name": "name",
"published": true,
"type": "artist",
"uri": "uri"
}
],
"available_markets": [
"string"
],
"disc_number": 0,
"duration_ms": 0,
"explicit": true,
"external_ids": {
"ean": "ean",
"isrc": "isrc",
"published": true,
"upc": "upc"
},
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"is_local": true,
"is_playable": true,
"linked_from": {
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"published": true,
"type": "type",
"uri": "uri"
},
"name": "name",
"popularity": 0,
"preview_url": "preview_url",
"published": true,
"restrictions": {
"published": true,
"reason": "reason"
},
"track_number": 0,
"type": "track",
"uri": "uri"
}
],
"published": true
}Returns Examples
{
"seeds": [
{
"id": "id",
"afterFilteringSize": 0,
"afterRelinkingSize": 0,
"href": "href",
"initialPoolSize": 0,
"published": true,
"type": "type"
}
],
"tracks": [
{
"id": "id",
"album": {
"id": "2up3OPMp9Tb4dAKM2erWXQ",
"album_type": "compilation",
"artists": [
{
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"name": "name",
"published": true,
"type": "artist",
"uri": "uri"
}
],
"available_markets": [
"CA",
"BR",
"IT"
],
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"images": [
{
"height": 300,
"url": "https://i.scdn.co/image/ab67616d00001e02ff9ca10b55ce82ae553c8228\n",
"width": 300,
"published": true
}
],
"name": "name",
"release_date": "1981-12",
"release_date_precision": "year",
"total_tracks": 9,
"type": "album",
"uri": "spotify:album:2up3OPMp9Tb4dAKM2erWXQ",
"published": true,
"restrictions": {
"published": true,
"reason": "market"
}
},
"artists": [
{
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"name": "name",
"published": true,
"type": "artist",
"uri": "uri"
}
],
"available_markets": [
"string"
],
"disc_number": 0,
"duration_ms": 0,
"explicit": true,
"external_ids": {
"ean": "ean",
"isrc": "isrc",
"published": true,
"upc": "upc"
},
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"is_local": true,
"is_playable": true,
"linked_from": {
"id": "id",
"external_urls": {
"published": true,
"spotify": "spotify"
},
"href": "href",
"published": true,
"type": "type",
"uri": "uri"
},
"name": "name",
"popularity": 0,
"preview_url": "preview_url",
"published": true,
"restrictions": {
"published": true,
"reason": "reason"
},
"track_number": 0,
"type": "track",
"uri": "uri"
}
],
"published": true
}