Functions for the Last.fm Artist API methods.
Write functions take a session key obtained via Lastex.Auth.
Summary
Functions
Tags an artist with one or more tags (artist.addTags).
Returns the canonical name for a possibly misspelled artist (artist.getCorrection).
Fetches metadata and biography for an artist (artist.getInfo).
Removes a single tag from an artist (artist.removeTag). Requires a session key.
Searches for artists by name (artist.search).
Fetches artists similar to the given one (artist.getSimilar).
Fetches the tags a user has applied to an artist (artist.getTags).
Fetches an artist's top albums, ordered by popularity (artist.getTopAlbums).
Fetches the most popular tags for an artist (artist.getTopTags).
Fetches an artist's top tracks, ordered by popularity (artist.getTopTracks).
Functions
Tags an artist with one or more tags (artist.addTags).
tags is a comma-separated string of up to 10 tags. Requires a session key.
Lastex.Artist.add_tags("Opeth", "progressive metal,swedish", session_key)
Returns the canonical name for a possibly misspelled artist (artist.getCorrection).
Lastex.Artist.correction("opeth")
Fetches metadata and biography for an artist (artist.getInfo).
Pass username: "name" to include that user's playcount, lang: "es" for a
translated biography, or autocorrect: 1 to correct a misspelled name.
Lastex.Artist.info("Opeth")
Removes a single tag from an artist (artist.removeTag). Requires a session key.
Lastex.Artist.remove_tag("Opeth", "progressive metal", session_key)
Searches for artists by name (artist.search).
Returns a Lastex.Page. Supports limit and page.
Lastex.Artist.search("Opeth", limit: 5)
Fetches artists similar to the given one (artist.getSimilar).
Returns a Lastex.Page. Supports limit and autocorrect.
Lastex.Artist.similar("Opeth", limit: 10)
Fetches the tags a user has applied to an artist (artist.getTags).
Returns a Lastex.Page. Pass user: "name" to read another user's tags, or a
session key via sk to read your own.
Lastex.Artist.tags("Opeth", user: "rj")
Fetches an artist's top albums, ordered by popularity (artist.getTopAlbums).
Returns a Lastex.Page. Supports limit and page.
Lastex.Artist.top_albums("Opeth", limit: 10)
Fetches the most popular tags for an artist (artist.getTopTags).
Returns a Lastex.Page.
Lastex.Artist.top_tags("Opeth")
Fetches an artist's top tracks, ordered by popularity (artist.getTopTracks).
Returns a Lastex.Page. Supports limit and page.
Lastex.Artist.top_tracks("Opeth", limit: 10)