Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scrobbling support #2

Open
tjkirch opened this issue Feb 21, 2024 · 0 comments
Open

Scrobbling support #2

tjkirch opened this issue Feb 21, 2024 · 0 comments

Comments

@tjkirch
Copy link

tjkirch commented Feb 21, 2024

There's an issue on the Tangara repo discussing scrobbling support, i.e. submitting played tracks to last.fm and similar services. You mentioned that you were open to the companion app handling the "client side" of this process - taking the play data from Tangara and submitting it to last.fm. I wanted to make an issue to discuss what that might look like.

This comment gives some info about the last.fm API; upstream docs are here. In short, the one-time setup process per user involves a few REST calls, opening a browser to let the user authorize the app to scrobble on their behalf, and saving the API key, secret, and session key to sign future calls. (Signing is a simple md5. Session keys don't expire by default.) Then plays can be scrobbled in batches of up to 50 per call.

I think last.fm's API is on the simpler side, but there are a number of crates that can help, if you prefer a dependency.

Part of the discussion on the Tangara issue is the data format. It could be simple text - key/value pairs with known keys and simple data. I don't expect this to be a challenging part in the companion, regardless. I imagine it will read and parse the file(s), submit the data, and then delete/clean the source data; the order of the last two steps is debatable :)

I'm imagining another tab in the companion app, like Lua Console and Firmware Update, perhaps called Scrobbler, which would own this process. It could show the recent scrobble data it found on the Tangara, and the preferences.

Perhaps there could be an option to scrobble automatically at startup/connection. There aren't really any required settings, though - the first time you scrobble, it could open the browser to authorize, and that's kind of it. It's nice to have an option for the user to enter their own API key and secret, though, in case something goes wrong with the project's.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant