alaingilbert / Turntable-API

Allows you to create bots for turntable.fm
http://alaingilbert.github.com/Turntable-API/
MIT License
317 stars 98 forks source link

playlistRemove not functioning correctly? #70

Closed homeski closed 12 years ago

homeski commented 12 years ago

I am trying to run the following code to clear a bot's entire playlist.

This doesn't clear all the songs out though. It will only clear a couple every time it is run.

bot.playlistAll(function (data) { for(var i = 0; i < data.list.length; i++) bot.playlistRemove(); });

alaingilbert commented 12 years ago

The function works properly. But, Turntable.fm limit (on their side) the number of queries that a single user can make in a certain laps of time.

For example, they consider that an average user will make 10 queries/minutes.

This is purely fictional ! It was just to illustrate the problem.

A suggestion I made to them was to create a function on their servers that would let you remove many songs at once. But they never did it. ( bot.playlistRemove([id1, id2, id3, id4, ...]); )

homeski commented 12 years ago

bummer :(

So there is no good way to clear a playlist at the moment..

alaingilbert commented 12 years ago

The only good way that I know, is a feature request on turntable.fm ! :P

homeski commented 12 years ago

Submitted a request :)

Is there a list of all API calls somewhere?

alaingilbert commented 12 years ago

There is no public turntable api. This lib is probably the most complete "api" that you can find.

homeski commented 12 years ago

Thanks for the info!