rustfm-scrobble-proxy

Latest Version


rustfm-scrobble-proxy is a fork of rustfm-scrobble. Its API is identical, but it replaces the internal ureq HTTP client with attohttpc. This allows the library to be used behind a proxy seamlessly, as attohttpc picks up proxy settings automatically, unlike ureq.

rustfm-scrobble is licensed under the MIT license. See the LICENSE file for more information. Below is the original README.


rustfm-scrobble is a Last.fm Scrobble API 2.0 crate for Rust. It allows easy acccess to the "scrobble" and "now playing" notification endpoints through a simple Rust API. It can be used to record song-plays from music players, build analog scrobbling tools similar to VinylScrobbler or work with IoT Devices. It was initially built to implement a Spotify scrobbling service using the Spotify Connect Protocol when the Alexa Spotify client did not support scrobbling plays to Last.fm.

Features

Install

Add rustfm-scrobble to your Cargo.toml.

[dependencies] rustfm-scrobble="1.1"

Usage

```rust extern crate rustfmscrobble; use rustfmscrobble::{Scrobble, Scrobbler};

let username = "last-fm-username"; let password = "last-fm-password"; let apikey = "client-api-key"; let apisecret = "client-api-secret";

let mut scrobbler = Scrobbler::new(apikey, apisecret); scrobbler.authenticatewithpassword(username, password);

let song = Scrobble::new("Example Artist", "Example Song", "Example Album"); scrobbler.scrobble(song); ```

In Use

rustfm-scrobble is used in several projects including polaris, connectr, rescrobbled and rb-scrobbler.

Status

The API is stable & backwards compatibility will be guaranteed for all 1.0 releases.

License

MIT license, see ./LICENSE.