Jose M. Perez
1,638 supporters
Dedup and Spotify's Breaking Changes in ...

Dedup and Spotify's Breaking Changes in their API

May 08, 2024

Update May 8th: Yet another fix deployed to bring back the previous behaviour.

João Vitor, author of Skiley, reached out and told me that it was possible to remove tracks by position alone ﹣ not combined with the song id ﹣ even though it's not documented. I have tested it and it works like a charm, meaning that the we won't need to reset the added time for the duplicated song.

So finally I can consider this issue as fixed!

Thanks a ton to João, and I invite you all to check out his project Skiley


Update May 7th: A solution for adding back the song to its original position has been deployed.

After thorough testing, I have deployed a change to put back the song to its original position instead of at the end of the playlist. This keeps the song in its original position, relative to the rest of songs (the position itself will have shifted due to the removal of other songs and its own duplicates).

Since the song is removed and added back due to Spotify's recent breaking changes in their API, it means that the added time for the song is reset. Thus, it will indicate that it was just added, even if it was added some time in the past. Unfortunately, there is no workaround for this unless Spotify puts back the support for deleting songs at a certain position and not entirely by their Spotify ID.


Update May 4th: A fix has been deployed.

The tool should be able to remove duplicates in playlists. For the time being, when there is a duplicate due to songs with the same id, the duplicates will be removed and the same song will be added at the end of the playlist. This means that the original position of the duplicated song in the playlist won't be maintained.


Spotify has made some unexpected breaking changes in their API that are affecting a number of integrations, including Spotify Dedup.

Right now, the tool fails when trying to remove duplicates in playlists.

The good news is that we are working on a fix.

The geeky details

Spotify has dropped the support for an old endpoint that is used to remove songs from a playlist, supporting only a newer one that has changed its URL. As a result, the outgoing requests to remove songs are failing.

In addition, the newer endpoint has dropped support for the "positions" option. If 2 songs have the same id, Spotify will remove both instances since they don't let us specify anymore which song, indicated by a list of "positions", should be removed. This means that the tool will need to add back a new instance of the song.

Fortunately, it is possible to specify a position where the new song should be added. The minor caveat is that the date when the song was added would change.

The plan

A fix should land during the weekend, so hold tight! I really appreciate your support and I know lots of you would like to continue using the tool to clean up your libraries.

In the meanwhile, I also reported the issue to Spotify. I got DMs through Twitter from a number of developers that are having similar issues due to unannounced changes in Spotify's Web API, which is also clear from the amount of posts in the Spotify's Community site informing about issues.

The bad news is that nobody is replying to these posts, and Spotify Platform's Twitter/X account has gone radio-silence since November 2023, so it's unclear what the long term strategy for Spotify is to support the API and enable 3rd party integrations. Spotify applications are not longer being reviewed when applying for scope extensions, meaning that developers can't add new functionality to their Spotify apps.

Fingers crossed!

Meanwhile, I want to take the opportunity to appreciate your patience and your support, which encourages me to continue working on this tool and helping other folks that are working on making their Spotify accounts more useful, and extending the functionality provided by Spotify's mobile apps and web/desktop player.

Enjoy this post?

Buy Jose M. Perez a coffee

1 comment

More from Jose M. Perez