Announcements
The Spotify Stars Program: Celebrating Values Week!

Help Wizard

Step 1

NEXT STEP

is_playable field returns incorrect result

is_playable field returns incorrect result

Plan

Premium

Country

Australia

My Question or Issue

My app calls the "playlists/tracks" endpoint to get a list of songs in the user's playlist. When it does this, it specifies "AU" for the market field. It then checks the "is_playable" field for each song that is returned to determine whether the song is available in Australia.

 

This system has always worked fine but in the past week, there's been a strange bug in the data returned from the endpoint. I have not modified the app at all so it is definitely an issue with the API and not with the app.

 

For a number of songs, the "is_playable" field returns false even though the song is definitely available in Australia (I am able to play it on my phone). To see an example of this, try calling the "playlists/tracks" endpoint for a playlist containing the song with id "0jIa8Bckzoy7bgURBZXxNB" (The Sweet Escape by Gwen Stephani) and set the market to "AU". This is one of the songs that the endpoint says is not available playable in Australia even though I can definitely play it on my phone in Australia.

 

I'm assuming this is a bug in the API. It would be great if this could be fixed.

Reply
13 Replies

So I'm not the only one 🙂

 

Rather, the problem is in the "linked_from" parameter for some tracks.

I noticed a change a week or two ago.

Moreover, the results of the "Get Track" request in the Console and directly using the API method are different.

In my case, available_markets is populated with a zero-length array when I don't pass market=from_token, and when I do pass market=from_token (this is for an authenticated user), is_playable is false. So the song is available nowhere on Earth but is in the Spotify database? Not likely.

Ok, so the good news is it looks like they fixed it last night. The is_playable field is working now but yes, Efremych, the linked_from had changed. I've had to rewrite some code. My code compares the user's playlists with their library so I found that when I fetch the library, I have to use the uri from linked_from but when I fetch the playlist, I'm having to use the uri from the main json object for the track otherwise I end up with two different URIs for the same track... anyway, looks like my app's working again (phew)

 

Claudio, looks like they still haven't fixed the available_markets field. Hopefully that's the next step!

is_playable field returns incorrect result again. For example this track is not available in Turkey. But is_playable field returns “True” (api Get Track, “market”=“TR”)

The bug is still not fixed.

One more time. I do the request Get Track. market=TR

curl -X "GET" "https://api.spotify.com/v1/tracks/4D8DFRrwp6PTuCJE4UDIMy?market=TR" -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Bearer BQDTwwvCH4nB8zvypqVRwUAGkRh_i4IYXnVJm7x1oPs4BRd10Kz2jtGEHlQgFUoIbLvpuuesIoDozijSO8jbC-dmiJ0p4_lCyaCJ4h3NN_ISIjvzJb8AcE8z8TvMBd_DFr6kd07WZ-k-5nvRmpA_HZdHALNkCgl4DmAiomNVOHalWv1mYJ335vJziZakzdyXovcEBQ5M"

 

response

  "is_local": false,
  "is_playable": true,
Spoiler
{
  "album": {
    "album_group": "single",
    "album_type": "single",
    "artists": [
      {
        "external_urls": {
          "spotify": "https://open.spotify.com/artist/48zUWAXpgEXfpttz23pCNQ"
        },
        "href": "https://api.spotify.com/v1/artists/48zUWAXpgEXfpttz23pCNQ",
        "id": "48zUWAXpgEXfpttz23pCNQ",
        "name": "Oceans Ate Alaska",
        "type": "artist",
        "uri": "spotify:artist:48zUWAXpgEXfpttz23pCNQ"
      }
    ],
    "external_urls": {
      "spotify": "https://open.spotify.com/album/4G9iZwlnk0tTMRYeJrGEf7"
    },
    "href": "https://api.spotify.com/v1/albums/4G9iZwlnk0tTMRYeJrGEf7",
    "id": "4G9iZwlnk0tTMRYeJrGEf7",
    "images": [
      {
        "height": 640,
        "url": "https://i.scdn.co/image/ab67616d0000b2739abaa15249bd3f9257947bfc",
        "width": 640
      },
      {
        "height": 300,
        "url": "https://i.scdn.co/image/ab67616d00001e029abaa15249bd3f9257947bfc",
        "width": 300
      },
      {
        "height": 64,
        "url": "https://i.scdn.co/image/ab67616d000048519abaa15249bd3f9257947bfc",
        "width": 64
      }
    ],
    "is_playable": true,
    "name": "Taming Lions",
    "release_date": "2012-09-10",
    "release_date_precision": "day",
    "total_tracks": 2,
    "type": "album",
    "uri": "spotify:album:4G9iZwlnk0tTMRYeJrGEf7"
  },
  "artists": [
    {
      "external_urls": {
        "spotify": "https://open.spotify.com/artist/48zUWAXpgEXfpttz23pCNQ"
      },
      "href": "https://api.spotify.com/v1/artists/48zUWAXpgEXfpttz23pCNQ",
      "id": "48zUWAXpgEXfpttz23pCNQ",
      "name": "Oceans Ate Alaska",
      "type": "artist",
      "uri": "spotify:artist:48zUWAXpgEXfpttz23pCNQ"
    }
  ],
  "disc_number": 1,
  "duration_ms": 251120,
  "explicit": false,
  "external_ids": {
    "isrc": "GBJWK1200001"
  },
  "external_urls": {
    "spotify": "https://open.spotify.com/track/4D8DFRrwp6PTuCJE4UDIMy"
  },
  "href": "https://api.spotify.com/v1/tracks/4D8DFRrwp6PTuCJE4UDIMy",
  "id": "4D8DFRrwp6PTuCJE4UDIMy",
  "is_local": false,
  "is_playable": true,
  "name": "Clocks",
  "popularity": 32,
  "preview_url": "https://p.scdn.co/mp3-preview/6f2c66798b785f90ad319e1b87b7e1e7633ff87b?cid=774b29d4f13844c495f206cafdad9c86",
  "track_number": 2,
  "type": "track",
  "uri": "spotify:track:4D8DFRrwp6PTuCJE4UDIMy"
}

Same request without "market"

curl -X "GET" "https://api.spotify.com/v1/tracks/4D8DFRrwp6PTuCJE4UDIMy" -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Bearer BQDTwwvCH4nB8zvypqVRwUAGkRh_i4IYXnVJm7x1oPs4BRd10Kz2jtGEHlQgFUoIbLvpuuesIoDozijSO8jbC-dmiJ0p4_lCyaCJ4h3NN_ISIjvzJb8AcE8z8TvMBd_DFr6kd07WZ-k-5nvRmpA_HZdHALNkCgl4DmAiomNVOHalWv1mYJ335vJziZakzdyXovcEBQ5M"

 

response. There are no "TR" in available markets. So why  "is_playable": true?

Spoiler

 

 

{
  "album": {
    "album_group": "single",
    "album_type": "single",
    "artists": [
      {
        "external_urls": {
          "spotify": "https://open.spotify.com/artist/48zUWAXpgEXfpttz23pCNQ"
        },
        "href": "https://api.spotify.com/v1/artists/48zUWAXpgEXfpttz23pCNQ",
        "id": "48zUWAXpgEXfpttz23pCNQ",
        "name": "Oceans Ate Alaska",
        "type": "artist",
        "uri": "spotify:artist:48zUWAXpgEXfpttz23pCNQ"
      }
    ],
    "available_markets": [
      "AD",
      "AG",
      "AL",
      "AO",
      "AR",
      "AT",
      "AU",
      "BA",
      "BB",
      "BE",
      "BF",
      "BG",
      "BI",
      "BJ",
      "BN",
      "BO",
      "BR",
      "BS",
      "BW",
      "BY",
      "BZ",
      "CA",
      "CD",
      "CG",
      "CH",
      "CI",
      "CL",
      "CM",
      "CO",
      "CR",
      "CV",
      "CW",
      "CY",
      "CZ",
      "DE",
      "DJ",
      "DK",
      "DM",
      "DO",
      "DZ",
      "EC",
      "EE",
      "EG",
      "ES",
      "ET",
      "FI",
      "FJ",
      "FM",
      "FR",
      "GA",
      "GB",
      "GD",
      "GE",
      "GH",
      "GM",
      "GN",
      "GQ",
      "GR",
      "GT",
      "GW",
      "GY",
      "HK",
      "HN",
      "HR",
      "HT",
      "HU",
      "IE",
      "IS",
      "IT",
      "JM",
      "KE",
      "KI",
      "KM",
      "KN",
      "LC",
      "LI",
      "LR",
      "LS",
      "LT",
      "LU",
      "LV",
      "LY",
      "MA",
      "MC",
      "MD",
      "ME",
      "MG",
      "MH",
      "MK",
      "ML",
      "MO",
      "MR",
      "MT",
      "MU",
      "MW",
      "MX",
      "MZ",
      "NA",
      "NE",
      "NG",
      "NI",
      "NL",
      "NO",
      "NR",
      "NZ",
      "PA",
      "PE",
      "PG",
      "PL",
      "PS",
      "PT",
      "PW",
      "PY",
      "RO",
      "RS",
      "RW",
      "SB",
      "SC",
      "SE",
      "SI",
      "SK",
      "SL",
      "SM",
      "SN",
      "SR",
      "ST",
      "SV",
      "SZ",
      "TD",
      "TG",
      "TL",
      "TN",
      "TO",
      "TT",
      "TV",
      "TZ",
      "UA",
      "UG",
      "US",
      "UY",
      "VC",
      "VE",
      "VU",
      "WS",
      "XK",
      "ZA",
      "ZM",
      "ZW"
    ],
    "external_urls": {
      "spotify": "https://open.spotify.com/album/4G9iZwlnk0tTMRYeJrGEf7"
    },
    "href": "https://api.spotify.com/v1/albums/4G9iZwlnk0tTMRYeJrGEf7",
    "id": "4G9iZwlnk0tTMRYeJrGEf7",
    "images": [
      {
        "height": 640,
        "url": "https://i.scdn.co/image/ab67616d0000b2739abaa15249bd3f9257947bfc",
        "width": 640
      },
      {
        "height": 300,
        "url": "https://i.scdn.co/image/ab67616d00001e029abaa15249bd3f9257947bfc",
        "width": 300
      },
      {
        "height": 64,
        "url": "https://i.scdn.co/image/ab67616d000048519abaa15249bd3f9257947bfc",
        "width": 64
      }
    ],
    "is_playable": true,
    "name": "Taming Lions",
    "release_date": "2012-09-10",
    "release_date_precision": "day",
    "total_tracks": 2,
    "type": "album",
    "uri": "spotify:album:4G9iZwlnk0tTMRYeJrGEf7"
  },
  "artists": [
    {
      "external_urls": {
        "spotify": "https://open.spotify.com/artist/48zUWAXpgEXfpttz23pCNQ"
      },
      "href": "https://api.spotify.com/v1/artists/48zUWAXpgEXfpttz23pCNQ",
      "id": "48zUWAXpgEXfpttz23pCNQ",
      "name": "Oceans Ate Alaska",
      "type": "artist",
      "uri": "spotify:artist:48zUWAXpgEXfpttz23pCNQ"
    }
  ],
  "available_markets": [
    "AR",
    "AU",
    "AT",
    "BE",
    "BO",
    "BR",
    "BG",
    "CA",
    "CL",
    "CO",
    "CR",
    "CY",
    "CZ",
    "DK",
    "DO",
    "DE",
    "EC",
    "EE",
    "SV",
    "FI",
    "FR",
    "GR",
    "GT",
    "HN",
    "HK",
    "HU",
    "IS",
    "IE",
    "IT",
    "LV",
    "LT",
    "LU",
    "MT",
    "MX",
    "NL",
    "NZ",
    "NI",
    "NO",
    "PA",
    "PY",
    "PE",
    "PL",
    "PT",
    "SK",
    "ES",
    "SE",
    "CH",
    "UY",
    "US",
    "GB",
    "AD",
    "LI",
    "MC",
    "RO",
    "ZA",
    "EG",
    "MA",
    "DZ",
    "TN",
    "PS",
    "BY",
    "MD",
    "UA",
    "AL",
    "BA",
    "HR",
    "ME",
    "MK",
    "RS",
    "SI",
    "GH",
    "KE",
    "NG",
    "TZ",
    "UG",
    "AG",
    "BS",
    "BB",
    "BZ",
    "BW",
    "BF",
    "CV",
    "CW",
    "DM",
    "FJ",
    "GM",
    "GE",
    "GD",
    "GW",
    "GY",
    "HT",
    "JM",
    "KI",
    "LS",
    "LR",
    "MW",
    "ML",
    "MH",
    "FM",
    "NA",
    "NR",
    "NE",
    "PW",
    "PG",
    "WS",
    "SM",
    "ST",
    "SN",
    "SC",
    "SL",
    "SB",
    "KN",
    "LC",
    "VC",
    "SR",
    "TL",
    "TO",
    "TT",
    "TV",
    "VU",
    "BN",
    "BI",
    "CM",
    "TD",
    "KM",
    "GQ",
    "SZ",
    "GA",
    "GN",
    "MO",
    "MR",
    "RW",
    "TG",
    "ZW",
    "BJ",
    "MG",
    "MU",
    "MZ",
    "AO",
    "CI",
    "DJ",
    "ZM",
    "CD",
    "CG",
    "LY",
    "VE",
    "ET",
    "XK"
  ],
  "disc_number": 1,
  "duration_ms": 251120,
  "explicit": false,
  "external_ids": {
    "isrc": "GBJWK1200001"
  },
  "external_urls": {
    "spotify": "https://open.spotify.com/track/4D8DFRrwp6PTuCJE4UDIMy"
  },
  "href": "https://api.spotify.com/v1/tracks/4D8DFRrwp6PTuCJE4UDIMy",
  "id": "4D8DFRrwp6PTuCJE4UDIMy",
  "is_local": false,
  "name": "Clocks",
  "popularity": 32,
  "preview_url": "https://p.scdn.co/mp3-preview/6f2c66798b785f90ad319e1b87b7e1e7633ff87b?cid=774b29d4f13844c495f206cafdad9c86",
  "track_number": 2,
  "type": "track",
  "uri": "spotify:track:4D8DFRrwp6PTuCJE4UDIMy"
}

 

A month has passed. No one is going to fix the bug…

Still not fixed…

Two months has passed. No one is going to fix the bug…

During this time, I managed to contact the support service, and Get Item's Market param not working topic also appeared. But nothing has changed.

Hello?

Three months has passed.

What needs to be done to fix the bug? Did I describe the problem incorrectly?

Are Spotify developers here? How else can I convey the essence of the issue to them?

I'm struggling with the same issue.

In my case most of the tracks obtained from Get User's Saved Tracks return "false" in the "is_playable" field. I'm passing "from_token" value for the market parameter but it was the same when passing country code.

 

It's been over a year since @Efremych reported it, why is it so difficult to get in touch with anyone from Spotify team...

I am on the brink of giving up on supporting Spotify in my app because for last two years it has been nothing but an uphill struggle with the Web API and iOS SDK both which are buggy and lack in documentation which forces us to figure everything on our own and create workarounds.

 

This is not the way to entice indie developers to create products for the platform.

Sorry for my rant but I love using Spotify for streaming but as I said, my experience with developing for it has been nightmarish.

It's been over a year since @Efremych reported it

 

This bug was fixed in February 2022. I don't know whether it was done consciously or not.

 

A year later, it turns out, the error has returned. Still relevant. It's been six months now.

Still....

  • is_playable
     
    boolean
     

    Part of the response when Track Relinking is applied. If true, the track is playable in the given market. Otherwise false.

 

1.

 

 

  "available_markets": ["CA", "MX", "US"],
  "disc_number": 1,
  "duration_ms": 221800,
  "explicit": false,
  "external_ids": {
    "isrc": "USAL51120403"
  },
  "external_urls": {
    "spotify": "https://open.spotify.com/track/24b7pcOutZz7Cdwrg539hz"
  },
  "href": "https://api.spotify.com/v1/tracks/24b7pcOutZz7Cdwrg539hz",
  "id": "24b7pcOutZz7Cdwrg539hz",
  "name": "Worlds Collide",
  "popularity": 21,
  "preview_url": null,
  "track_number": 4,
  "type": "track",
  "uri": "spotify:track:24b7pcOutZz7Cdwrg539hz",
  "is_local": false
}

 

 

 2.

 

 

curl --request GET \
  --url 'https://api.spotify.com/v1/tracks/24b7pcOutZz7Cdwrg539hz?market=US' \
  --header 'Authorization: Bearer 1POdFZRZbvb...qqillRxMr2z'

 

 

 

 

 

  "disc_number": 1,
  "duration_ms": 221800,
  "explicit": false,
  "external_ids": {
    "isrc": "USAL51120403"
  },
  "external_urls": {
    "spotify": "https://open.spotify.com/track/24b7pcOutZz7Cdwrg539hz"
  },
  "href": "https://api.spotify.com/v1/tracks/24b7pcOutZz7Cdwrg539hz",
  "id": "24b7pcOutZz7Cdwrg539hz",
  "is_playable": false,
  "restrictions": {
    "reason": "market"
  },
  "name": "Worlds Collide",
  "popularity": 21,
  "preview_url": null,
  "track_number": 4,
  "type": "track",
  "uri": "spotify:track:24b7pcOutZz7Cdwrg539hz",
  "is_local": false
}

 

 

Suggested posts