# Lastfm

{% hint style="info" %}
Replace `[prefix]` with your server's prefix.
{% endhint %}

## Setup

Last.fm is a way to show what you're listening to. Setting up your last.fm account with serenity is simple! First, make sure you have a last.fm account. If you don't, go to <https://last.fm/join>.

Once you're ready, run the following command:

```
[prefix]lastfm set (username)
// Replace (username) with your last.fm username.
```

#### Logging in

Once that is done, serenity will connect your last.fm account.

<figure><img src="/files/8XMrPtLVkEXQTuzGAheG" alt=""><figcaption></figcaption></figure>

#### Unlinking your last.fm account

To remove your last.fm account from the bot, simply run `[prefix]lastfm unset`. All of your last.fm data will be removed from the bot's database.

### What now?

That's all to it! Run the **fm** or **nowplaying** command to share what you're listening to. This works by taking the music statistics from your last.fm account. You can connect your Spotify account and start scrobbling from there by going to <https://last.fm/settings/applications>.

{% hint style="info" %}
If this command does not show the correct song, either your last.fm library is not updated or you are not currently scrobbling anything.
{% endhint %}

<figure><img src="/files/7ObLy49vcA54FicQDlVF" alt=""><figcaption></figcaption></figure>

### Last.fm Errors

Most last.fm errors come from the last.fm API being broken. We have **no control** over these errors, you would have to wait for last.fm to fix it. If you encounter another error, please let us know in <https://discord.gg/mullencord>.

{% hint style="info" %}
You can also set **custom** nowplaying embeds! Go to the page below to learn more.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.serenity.wtf/get-started/lastfm.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
