# Last.fm MCP

> Last.fm MCP gives you full control over your music profile and listening history using natural conversation. Connect it to any agent to scrobble songs, fetch deep track metadata (like playcounts), update what you're playing right now, and pull user stats—all without opening a separate app. It’s your command center for all things audio.

## Overview
- **Category:** audio-music
- **Price:** Free
- **Tags:** music-tracking, scrobbling, lastfm, audio-metadata, listening-history

## Description

Need to manage music data from anywhere? This MCP lets your agent talk directly to your Last.fm account. You can log every track you hear with the scrobbling tool, keeping your profile accurate automatically. Need details on a specific song? Fetch everything—play counts, artist background, and more—with a simple prompt. It also keeps tabs on what friends are listening to via the 'now playing' status. Whether you’re a developer needing rich metadata for an app or just a music lover who hates opening another app, this connection works. You get access to all these functions through Vinkius, keeping your entire catalog of connected services in one place.

## Tools

### update_now_playing
Changes and updates the public status showing what track you are currently listening to.

### scrobble_track
Logs a song to your listening history, updating your official scrobbling record.

### get_tag_info
Retrieves metadata associated with a specific music genre or tag.

### get_track_info
Fetches detailed statistics and information for any given song, using an artist name, track name, or MBID.

### get_user_info
Gathers comprehensive data about a specific user's profile activity on the platform.

## Prompt Examples

**Prompt:** 
```
Get metadata for the track 'Blinding Lights' by The Weeknd.
```

**Response:** 
```
I've fetched the info for 'Blinding Lights'. It has over 500 million plays on Last.fm and is part of the album 'After Hours'. Would you like to see the artist's top tags?
```

**Prompt:** 
```
Update my now playing status to 'Levitating' by Dua Lipa.
```

**Response:** 
```
Successfully updated your status! Your Last.fm profile now shows you are listening to 'Levitating' by Dua Lipa.
```

**Prompt:** 
```
Show me the profile details for user 'music_fan_123'.
```

**Response:** 
```
I've retrieved the profile for 'music_fan_123'. They have been a member since 2015 and have a total playcount of 45,000 tracks. Their top artist is Radiohead.
```

## Capabilities

### Log Listening History
Automatically record tracks you listen to so they show up on your profile.

### Retrieve Song Details
Pull specific data points about any song, including how many times it has been played globally.

### Update Status
Change your public profile to show what you're streaming right now.

### Read User Profiles
Get a summary of another user’s activity, like how long they’ve been on the platform or their top artists.

### Explore Music Tags
Look up genre tags associated with specific music to discover new sounds and contexts.

## Use Cases

### Analyzing a friend's taste profile
You want to know what 'music_fan_123' listens to most. Your agent calls `get_user_info` and reports back that their top artist is Radiohead, which immediately tells you where to start recommending music.

### Documenting a concert setlist
After seeing a band live, your agent uses `get_track_info` for each song played. It compiles a detailed list of metadata—artist, play count, etc.—that you can copy straight into a report.

### Updating public status in real-time
You just started listening to Dua Lipa's 'Levitating.' Instead of going through the app, your agent uses `update_now_playing` and broadcasts your new status instantly.

### Researching genre trends for a client
A client needs ideas for a mood playlist. Your agent calls `get_tag_info` for 'chill' to pull related genres, giving the curator fresh context and sound recommendations.

## Benefits

- Stop manually checking song stats. Use `get_track_info` to get deep metadata, including total play counts and artist background details, without leaving your agent's window.
- Keep your digital footprint accurate. Run `scrobble_track` whenever you listen to music; it logs the activity directly into your profile history automatically.
- Maintain a consistent presence by setting your status. The `update_now_playing` tool lets you change what people see, instantly.
- Understand user behavior quickly. Use `get_user_info` to pull key stats and profile data on any user, perfect for market research or trend spotting.
- Discover niche music context. Query specific genres using `get_tag_info` to find related artists and tags you never knew existed.

## How It Works

The bottom line is: You authorize your AI client once, and it handles all the messy API calls for you.

1. First, subscribe to this MCP on Vinkius and enter your Last.fm API Key and Shared Secret.
2. Next, you tell your AI agent what data you need—for example, 'Show me the stats for that song.'
3. Your agent calls the specific tool (like `get_track_info`), retrieves the raw metadata, and presents it to you in plain language.

## Frequently Asked Questions

**How do I use Last.fm MCP to find out how many times a song was played?**
Use `get_track_info` and provide the artist and track name. This tool pulls detailed metadata that includes global play counts, which is much more reliable than searching Google.

**Is Last.fm MCP good for tracking my own listening history?**
Yes, use `scrobble_track`. It logs your current song to your profile and keeps your scrobbling record up-to-date automatically when you ask the agent to do it.

**What if I want to know about a user's top artists?**
Run `get_user_info`. This tool gathers specific profile data and stats for any given user, letting you know who they are and what their favorite acts are.

**Can Last.fm MCP help me discover new genres?**
Yes, call `get_tag_info`. It retrieves metadata for music tags, allowing you to explore related genres and find new contexts for your musical tastes.

**What credentials do I need to use `scrobble_track`?**
You must provide a Last.fm API Key and Shared Secret for authentication. The MCP uses these key pairs to authorize actions, ensuring your listening history is tied to the correct account.

**What are the requirements when running `scrobble_track`?**
The tool requires that the track played be longer than 30 seconds. For reliable logging, you need the track played for at least half its total duration or four full minutes.

**How do I use `update_now_playing` to manage my status?**
It immediately updates your profile to show what you're currently listening to. This is useful for notifying your followers in real-time without opening the dedicated Last.fm application.

**What detailed data does `get_user_info` provide?**
This tool fetches comprehensive profile data, including when a user joined and their total playcount across all tracks. It gives you deeper insights into community activity.

**Can I manually scrobble a track I just finished listening to?**
Yes! Use the `scrobble_track` tool by providing the artist, track name, and a Unix timestamp. The agent will log the play to your Last.fm history immediately.

**How do I update my 'Now Playing' status for my followers?**
Simply use the `update_now_playing` tool with the artist and track name. This notifies Last.fm that you have started listening to the song.

**Can I get information about a specific music genre or tag?**
Yes, use the `get_tag_info` tool with the tag name (e.g., 'rock' or 'synthwave') to fetch metadata and descriptions for that specific tag.