A Ruby interface for Last.fm Web Services v2.0
require 'lastfm'
lastfm = Lastfm.new(api_key, api_secret)
token = lastfm.auth.get_token
# open 'http://www.last.fm/api/auth/?api_key=xxxxxxxxxxx&token=xxxxxxxx' and grant the application
lastfm.session = lastfm.auth.get_session(token: token)['key']
lastfm.track.love(artist: 'Hujiko Pro', track: 'acid acid 7riddim')
lastfm.track.scrobble(artist: 'Hujiko Pro', track: 'acid acid 7riddim')
lastfm.track.update_now_playing(artist: 'Hujiko Pro', track: 'acid acid 7riddim')
- 1.9.3
- 2.0.0
- 2.1.0
- 2.2.0
It supports methods which require authentication.
- album.addTags
- album.getBuylinks
- album.getInfo
- album.getShouts
- album.getTags
- album.getTopTags
- album.removeTag
- album.search
- album.share
artist.getsdeleted- artist.getInfo
- artist.getSimilar
- artist.getTags
- artist.getTopAlbums
- artist.getTopFans
- artist.getTopTags
- artist.getTopTracks
- artist.search
event.getInfodeleted
tasteometer.comparedeleted
- track.addTags
- track.ban
- track.getCorrection
- track.getInfo
- track.getSimilar
- track.getTags
- track.getTopFans
- track.getTopTags
- track.love
- track.removeTag
- track.scrobble
- track.search
- track.share
- track.updateNowPlaying
- track.unlove
- user.getFriends
- user.getInfo
- user.getLovedTracks
- user.getNeighbours
- user.getPersonalTags
- user.getRecentTracks
user.getRecommendedEventsdeleted- user.getRecommendedArtists
- user.getTopArtists
- user.getTopAlbums
- user.getTopTags
- user.getTopTracks
- user.getWeeklyAlbumList
- user.getWeeklyArtistList
- user.getWeeklyChartList
- user.getWeeklyTrackList
geo.getEventsdeleted
- chart.getHypedArtists
- chart.getHypedTracks
- chart.getLovedTracks
- chart.getTopArtists
- chart.getTopTags
- chart.getTopTracks
rake install
gem update --system
gem install gemcutter
gem tumble
gem install lastfm
see https://github.com/youpy/ruby-lastfm/contributors
- Fork the project.
- Make your feature addition or bug fix.
- Add tests for it. This is important so I don't break it in a future version unintentionally.
- Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
- Send me a pull request. Bonus points for topic branches.
Copyright (c) 2010 youpy. See LICENSE for details.