lastfm-history

1.0.0 • Public • Published

node-lastfm-history

Provides an EventEmitter interface to gaining Last.fm scrobble history.

Build Status

Installation

npm install lastfm-history

Example

var getHistory = require('lastfm-history');
var worker = getHistory('bencevans', 'API_KEY');
 
worker.on('page', function(tracks, meta) {
  console.log(tracks.length + ' scrobbles just pulled');
  console.log('meta:', meta);
  // store into database or file etc.
});
 
worker.on('complete', function() {
  console.log('complete');
  // start processing knowing you've got the whole dataset
});
 
worker.on('error', function(err) {
  console.log('err:', err);
});

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.0
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.0
    0
  • 0.1.2
    1
  • 0.1.1
    0
  • 0.1.0
    0

Package Sidebar

Install

npm i lastfm-history

Weekly Downloads

1

Version

1.0.0

License

MIT

Last publish

Collaborators

  • bencevans