Microservice to fetch last song scrobbled on Last.fm
- Clone the repository.
- Copy
.env_example
to.env
and fill in your Last.fm API key. - Run
npm start
to start the service.
Load /:user
to get the most recently played track (or the currently playing track) from a Last.fm user. A JSON object with these properties will be returned:
title
: song name.artist
: artist name.album
: album name.live
:true
if the user is currently listening to this song.date
: timestamp at which user listened to this song, ornull
if they're currently listening.
git clone https://github.com/gakimball/micro-lastfm
cd micro-lastfm
npm install
To run the service in development mode, use npm run dev
. To run the linter and unit tests, run npm test
.
MIT © Geoff Kimball