TapLast.fm API

Having tried some calls to the Last.fm API, I am wondering if some of the calls are flawed or if there is something wrong with my account.

You access the data using the address http://ws.audioscrobbler.com/2.0/? and supplying certain parameters separated by &.

Two are required with all calls…
method=<the data table you want>
api_key=<a hex key which you sign up for>
and other parameters for the data table requested.

I am looking at the method user.getTopAlbums which requires…

This seems to work fine for period=overall returning a list of albums in descending order of number of tracks played but if I use, say, period=3month then I get a very short list of albums with a playcount of just 1. The same happens for the other periods and also user.getTopArtists.

I have only been signed up for a few weeks so I would have expected to get the same list—or is it that it doesn’t like so little data? Update: looking at the results carefully, I think it has got stuck at the first tracks I listened to on the system when I was trying it out. Could it be some sort of cache stuck somewhere? It can’t be on my system as it does the same from wherever I look.

What I would really like is user.getRecentAlbums but that one doesn’t exist. If I use user.getRecentTracks then, because we play whole albums at a time, the list gets flooded with tracks from the same album. You can probably see the effect towards the bottom of the sidebar, unless I have found a way to fix it.

Comments are closed.

^ Top