API Doc

API Methods

artist.search

Search for an artist by name. Returns artist matches sorted by relevance.
Original docs: artist.getTopTracks

e.g. http://lastfm-api-ext.appspot.com/2.0/?method=artist.search&artist=cher&api_key=b25b959554ed76058ac220b7b2e0a026

Params

limit (Optional) : Limit the number of artists returned at one time. Default (maximum) is 30.
page (Optional) : Scan into the results by specifying a page number. Defaults to first page.
artist (Required) : The Artist name in question
api_key (Required) : A Last.fm API key
outtype : The data output format (js, json, php). Default is XML. See supported response formats in the overview.
callback : Function name that will wrap the data if JSONP (outtype 'js') is used.

Sample Response (JSON Object Structure)

{
  "for": "Cher",
  "query": {
      "role": "request",
      "searchTerms": "cher",
      "startPage": 1,
  },
  "totalResults": 386,
  "startIndex": 0,
  "itemsPerPage": 20,
  artistmatches": [{
      "name": "Cher",
      "mbid": "bfcc6d75-a6a5-4bc6-8282-47aec8531818",
      "url": "www.last.fm/music/Cher",
      "image_small": "http://userserve-ak.last.fm/serve/50/342437.jpg",
      "image": "http://userserve-ak.last.fm/serve/160/342437.jpg",
      "streamable": true"
  },
  ...
  ]
}