The Code Train

Where Neil Crosby talks about coding on the train…

RSS Entries

How to get more than the last 10 Recently Played Tracks from last.fm

Posted on December 1st, 2008 by Neil Crosby. Filed under Uncategorized.

I don’t have time for a full entry today, so here’s a quick tip for last.fm users who are making use of their “Recently Played Tracks” RSS to do cool things.

It turns out that you can increase the number of tracks returned by the feed simply by adding a limit=somenumber parameter to the URL. So, for me to grab the last 20 songs that I’ve scrobbled, I would ask for:

http://ws.audioscrobbler.com/1.0/user/NeilCrosby/recenttracks.rss?limit=20

I use this as a way of getting a decent sampling of my recent tracks to use on NeilCrosby.com, as I found the default 10 was too limiting since my “Stream of Consciousness” stream normally covers a few days worth of information, whereas my last 10 tracks would only cover an hour or so of data.

If you enjoyed this post, subscribe to The Code Train and read more when I write more.

Comments RSS

Leave a Reply

TheCodeTrain Theme by Neil Crosby, Powered by WordPress