Functions for the Last.fm User API methods.
Functions returning a user's top items accept a period option — one of
"overall", "7day", "1month", "3month", "6month", or "12month".
Summary
Functions
Fetches a user's friends (user.getFriends).
Fetches a user's profile (user.getInfo).
Fetches the tracks a user has loved (user.getLovedTracks).
Fetches the items a user has tagged with a given tag (user.getPersonalTags).
Fetches a user's recent scrobbles (user.getRecentTracks).
Fetches a user's most listened-to albums (user.getTopAlbums).
Fetches a user's most listened-to artists (user.getTopArtists).
Fetches a user's most used tags (user.getTopTags).
Fetches a user's most listened-to tracks (user.getTopTracks).
Fetches a user's album chart for a week (user.getWeeklyAlbumChart).
Fetches a user's artist chart for a week (user.getWeeklyArtistChart).
Fetches the weekly chart periods available for a user (user.getWeeklyChartList).
Fetches a user's track chart for a week (user.getWeeklyTrackChart).
Functions
Fetches a user's friends (user.getFriends).
Returns a Lastex.Page. Supports limit, page, and recenttracks: 1 to
include each friend's latest scrobble.
Lastex.User.friends("rj", limit: 50)
Fetches a user's profile (user.getInfo).
Lastex.User.info("rj")
Fetches the tracks a user has loved (user.getLovedTracks).
Returns a Lastex.Page. Supports limit and page.
Lastex.User.loved_tracks("rj", limit: 50)
Fetches the items a user has tagged with a given tag (user.getPersonalTags).
taggingtype is one of "artist", "album", or "track", and determines the
shape of the returned data. Returns a Lastex.Page.
Lastex.User.personal_tags("rj", "progressive metal", "artist")
Fetches a user's recent scrobbles (user.getRecentTracks).
Returns a Lastex.Page. Supports limit (up to 200), page, and from/to
Unix timestamps to bound the range. A currently playing track, if any, is
included with a "@attr" => %{"nowplaying" => "true"} marker.
Lastex.User.recent_tracks("rj", limit: 200)
Fetches a user's most listened-to albums (user.getTopAlbums).
Returns a Lastex.Page. Supports period, limit, and page.
Lastex.User.top_albums("rj", period: "6month", limit: 10)
Fetches a user's most listened-to artists (user.getTopArtists).
Returns a Lastex.Page. Supports period, limit, and page.
Lastex.User.top_artists("rj", period: "overall", limit: 10)
Fetches a user's most used tags (user.getTopTags).
Returns a Lastex.Page. Supports limit.
Lastex.User.top_tags("rj", limit: 10)
Fetches a user's most listened-to tracks (user.getTopTracks).
Returns a Lastex.Page. Supports period, limit, and page.
Lastex.User.top_tracks("rj", period: "1month", limit: 10)
Fetches a user's album chart for a week (user.getWeeklyAlbumChart).
Returns a Lastex.Page. Pass from and to Unix timestamps from
weekly_chart_list/1; the most recent week is used when omitted.
Lastex.User.weekly_album_chart("rj")
Fetches a user's artist chart for a week (user.getWeeklyArtistChart).
Returns a Lastex.Page. Pass from and to Unix timestamps from
weekly_chart_list/1; the most recent week is used when omitted.
Lastex.User.weekly_artist_chart("rj")
Fetches the weekly chart periods available for a user (user.getWeeklyChartList).
Each entry carries the from and to Unix timestamps accepted by the
weekly_*_chart functions.
Lastex.User.weekly_chart_list("rj")
Fetches a user's track chart for a week (user.getWeeklyTrackChart).
Returns a Lastex.Page. Pass from and to Unix timestamps from
weekly_chart_list/1; the most recent week is used when omitted.
Lastex.User.weekly_track_chart("rj")