rspotify icon indicating copy to clipboard operation
rspotify copied to clipboard

Client method to sync playlist content efficiently using multible api calls.

Open blueforesticarus opened this issue 2 years ago • 3 comments

Is your feature request related to a problem? Please describe. I am working on a program which synchronizes spotify playlists. For this I often need to make the content of a playlist equal to a list of tracks. Similar issue to #296.

Describe the solution you'd like A client function that replaces the content of a playlist with a list of tracks. (using the minimum number of inserts and deletes).

Describe alternatives you've considered You can of course clear the playlist and add all the tracks, but for large playlists it is very slow as only 100 items can be added per API call. This could reasonably mean 30+ api calls, even when you are only adding/deleting a few things.

Additional context I actually already have to write this logic (I am porting this function from this project).

Is this something you would be interested in me upstreaming?

blueforesticarus avatar May 26 '23 14:05 blueforesticarus

This is essentially the logic part btw https://github.com/blueforesticarus/goontunes2/commit/034994bffbe3270ab9e812ac981e22c43c25d7cd

blueforesticarus avatar May 26 '23 19:05 blueforesticarus

Message to comment on stale issues. If none provided, will not mark issues stale

github-actions[bot] avatar Nov 23 '23 02:11 github-actions[bot]