···8- ๐ See your recent scrobbles
9- ๐ค Manually scrobble tracks
10- ๐ ๏ธ Useful developer tools for integrating Rocksky into your workflows
00000000000000000001112## Installation
13···96```bash
97rocksky scrobble "Karma Police" "Radiohead"
98```
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
···8- ๐ See your recent scrobbles
9- ๐ค Manually scrobble tracks
10- ๐ ๏ธ Useful developer tools for integrating Rocksky into your workflows
11+- ๐ค MCP Server
12+13+## Table of Contents
14+- [Installation](#installation)
15+- [Run in development](#run-in-development)
16+- [Usage](#usage)
17+- [Available Commands](#available-commands)
18+ - [login](#login)
19+ - [nowplaying](#nowplaying)
20+ - [scrobbles](#scrobbles)
21+ - [search](#search)
22+ - [stats](#stats)
23+ - [artists](#artists)
24+ - [albums](#albums)
25+ - [tracks](#tracks)
26+ - [scrobble](#scrobble)
27+ - [mcp](#mcp)
28+- [Rocksky MCP Server Tools](#rocksky-mcp-server-tools)
29+3031## Installation
32···115```bash
116rocksky scrobble "Karma Police" "Radiohead"
117```
118+119+`whoami` - Displays the current user's information.
120+121+```bash
122+rocksky whoami
123+```
124+125+`mcp` - Starts the Rocksky MCP server.
126+127+```bash
128+rocksky mcp
129+```
130+131+## Rocksky MCP Server Tools
132+133+Here is a list of tools provided by the Rocksky MCP server:
134+135+### whoami
136+137+Get the current user's information.
138+139+### nowplaying
140+141+Get the currently playing track.
142+143+**Parameters:**
144+145+- `did` (optional): The DID or handle of the user to get the now playing track for. If not provided, it defaults to the current user.
146+147+**Example:**
148+```json
149+{
150+ "name": "nowplaying",
151+ "args": {
152+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
153+ }
154+}
155+```
156+157+**Returns:**
158+The currently playing track for the specified user.
159+160+### scrobbles
161+162+Display recently played tracks (recent scrobbles).
163+164+**Parameters:**
165+- `did` (optional): The DID or handle of the user to get scrobbles for. If not provided, it returns all recent scrobbles from Rocksky.
166+167+**Example:**
168+```json
169+{
170+ "name": "scrobbles",
171+ "args": {
172+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
173+ }
174+}
175+```
176+177+**Returns:**
178+A list of recently played tracks for the specified user.
179+180+### my-scrobbles
181+182+Display recently played tracks (recent scrobbles) for the current user.
183+184+**Example:**
185+```json
186+{
187+ "name": "my-scrobbles"
188+}
189+```
190+191+**Returns:**
192+A list of recently played tracks for the current user.
193+194+### search
195+Search for tracks, albums, artists, or Rocksky users.
196+197+**Parameters:**
198+- `query`: The search query string.
199+- `limit` (optional): The maximum number of results to return. Defaults to 10.
200+- `albums` (optional): If true, search for albums. Defaults to false.
201+- `artists` (optional): If true, search for artists. Defaults to false.
202+- `tracks` (optional): If true, search for tracks. Defaults to false.
203+- `users` (optional): If true, search for Rocksky users. Defaults to false.
204+205+**Example:**
206+```json
207+{
208+ "name": "search",
209+ "args": {
210+ "query": "Radiohead",
211+ "limit": 5,
212+ "albums": false,
213+ "artists": false,
214+ "tracks": false,
215+ "users": false
216+ }
217+}
218+```
219+220+**Returns:**
221+A list of search results based on the specified query and filters.
222+223+### artists
224+List the user's top artists or current user's top artists if no `did` is provided.
225+226+**Parameters:**
227+- `did` (optional): The DID or handle of the user to get top artists for. If not provided, it defaults to the current user.
228+- `limit` (optional): The maximum number of artists to return. Defaults to 20.
229+230+**Example:**
231+```json
232+{
233+ "name": "artists",
234+ "args": {
235+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
236+ "limit": 20
237+ }
238+}
239+```
240+241+**Returns:**
242+A list of the user's top artists, including their names and play counts.
243+244+### albums
245+List the user's top albums or current user's top albums if no `did` is provided.
246+247+**Parameters:**
248+- `did` (optional): The DID or handle of the user to get top albums for. If not provided, it defaults to the current user.
249+- `limit` (optional): The maximum number of albums to return. Defaults to 20.
250+251+**Example:**
252+```json
253+{
254+ "name": "albums",
255+ "args": {
256+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
257+ "limit": 20
258+ }
259+}
260+```
261+262+**Returns:**
263+A list of the user's top albums, including their names and play counts.
264+265+### tracks
266+List the user's top tracks or current user's top tracks if no `did` is provided.
267+268+**Parameters:**
269+- `did` (optional): The DID or handle of the user to get top tracks for. If not provided, it defaults to the current user.
270+- `limit` (optional): The maximum number of tracks to return. Defaults to 20.
271+272+**Example:**
273+```json
274+{
275+ "name": "tracks",
276+ "args": {
277+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
278+ "limit": 20
279+ }
280+}
281+```
282+283+**Returns:**
284+A list of the user's top tracks, including their names and play counts.
285+286+### stats
287+Display the user's Rocksky account statistics or current user's statistics if no `did` is provided.
288+289+**Parameters:**
290+- `did` (optional): The DID or handle of the user to get statistics for. If not provided, it defaults to the current user.
291+292+**Example:**
293+```json
294+{
295+ "name": "stats",
296+ "args": {
297+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
298+ }
299+}
300+```
301+302+### create-apikey
303+Create a new API key for the current user.
304+305+**Parameters:**
306+- `name`: The name of the API key.
307+- `description` (optional): A description of the API key.
308+309+**Example:**
310+```json
311+{
312+ "name": "create-apikey",
313+ "args": {
314+ "name": "My API Key",
315+ "description": "This is my API key."
316+ }
317+}
318+```
319+320+**Returns:**
321+A confirmation message indicating that the API key was created successfully.
322+323+324+
···1+# Rocksky MCP Tools
2+3+This document provides a comprehensive list of all tools available in the Rocksky MCP server.
4+5+## whoami
6+7+Get the current user's information.
8+9+## nowplaying
10+11+Get the currently playing track.
12+13+**Parameters:**
14+15+- `did` (optional): The DID or handle of the user to get the now playing track for. If not provided, it defaults to the current user.
16+17+**Example:**
18+```json
19+{
20+ "name": "nowplaying",
21+ "args": {
22+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
23+ }
24+}
25+```
26+27+**Returns:**
28+The currently playing track for the specified user.
29+30+## scrobbles
31+32+Display recently played tracks (recent scrobbles).
33+34+**Parameters:**
35+- `did` (optional): The DID or handle of the user to get scrobbles for. If not provided, it returns all recent scrobbles from Rocksky.
36+37+**Example:**
38+```json
39+{
40+ "name": "scrobbles",
41+ "args": {
42+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
43+ }
44+}
45+```
46+47+**Returns:**
48+A list of recently played tracks for the specified user.
49+50+## my-scrobbles
51+52+Display recently played tracks (recent scrobbles) for the current user.
53+54+**Example:**
55+```json
56+{
57+ "name": "my-scrobbles"
58+}
59+```
60+61+**Returns:**
62+A list of recently played tracks for the current user.
63+64+## search
65+Search for tracks, albums, artists, or Rocksky users.
66+67+**Parameters:**
68+- `query`: The search query string.
69+- `limit` (optional): The maximum number of results to return. Defaults to 10.
70+- `albums` (optional): If true, search for albums. Defaults to false.
71+- `artists` (optional): If true, search for artists. Defaults to false.
72+- `tracks` (optional): If true, search for tracks. Defaults to false.
73+- `users` (optional): If true, search for Rocksky users. Defaults to false.
74+75+**Example:**
76+```json
77+{
78+ "name": "search",
79+ "args": {
80+ "query": "Radiohead",
81+ "limit": 5,
82+ "albums": false,
83+ "artists": false,
84+ "tracks": false,
85+ "users": false
86+ }
87+}
88+```
89+90+**Returns:**
91+A list of search results based on the specified query and filters.
92+93+## artists
94+List the user's top artists or current user's top artists if no `did` is provided.
95+96+**Parameters:**
97+- `did` (optional): The DID or handle of the user to get top artists for. If not provided, it defaults to the current user.
98+- `limit` (optional): The maximum number of artists to return. Defaults to 20.
99+100+**Example:**
101+```json
102+{
103+ "name": "artists",
104+ "args": {
105+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
106+ "limit": 20
107+ }
108+}
109+```
110+111+**Returns:**
112+A list of the user's top artists, including their names and play counts.
113+114+## albums
115+List the user's top albums or current user's top albums if no `did` is provided.
116+117+**Parameters:**
118+- `did` (optional): The DID or handle of the user to get top albums for. If not provided, it defaults to the current user.
119+- `limit` (optional): The maximum number of albums to return. Defaults to 20.
120+121+**Example:**
122+```json
123+{
124+ "name": "albums",
125+ "args": {
126+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
127+ "limit": 20
128+ }
129+}
130+```
131+132+**Returns:**
133+A list of the user's top albums, including their names and play counts.
134+135+## tracks
136+List the user's top tracks or current user's top tracks if no `did` is provided.
137+138+**Parameters:**
139+- `did` (optional): The DID or handle of the user to get top tracks for. If not provided, it defaults to the current user.
140+- `limit` (optional): The maximum number of tracks to return. Defaults to 20.
141+142+**Example:**
143+```json
144+{
145+ "name": "tracks",
146+ "args": {
147+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr",
148+ "limit": 20
149+ }
150+}
151+```
152+153+**Returns:**
154+A list of the user's top tracks, including their names and play counts.
155+156+## stats
157+Display the user's Rocksky account statistics or current user's statistics if no `did` is provided.
158+159+**Parameters:**
160+- `did` (optional): The DID or handle of the user to get statistics for. If not provided, it defaults to the current user.
161+162+**Example:**
163+```json
164+{
165+ "name": "stats",
166+ "args": {
167+ "did": "did:plc:7vdlgi2bflelz7mmuxoqjfcr"
168+ }
169+}
170+```
171+172+## create-apikey
173+Create a new API key for the current user.
174+175+**Parameters:**
176+- `name`: The name of the API key.
177+- `description` (optional): A description of the API key.
178+179+**Example:**
180+```json
181+{
182+ "name": "create-apikey",
183+ "args": {
184+ "name": "My API Key",
185+ "description": "This is my API key."
186+ }
187+}
188+```
189+190+**Returns:**
191+A confirmation message indicating that the API key was created successfully.
192+193+194+
···1+import { rockskyMcpServer } from "mcp";
2+3+export function mcp() {
4+ rockskyMcpServer.run().catch((error) => {
5+ console.error("Failed to run Rocksky MCP server", { error });
6+ process.exit(1);
7+ });
8+}
+10-1
src/index.ts
···1#!/usr/bin/env node
203import { albums } from "cmd/albums";
4import { artists } from "cmd/artists";
5import { createApiKey } from "cmd/create";
06import { nowplaying } from "cmd/nowplaying";
7import { scrobble } from "cmd/scrobble";
8import { scrobbles } from "cmd/scrobbles";
···19program
20 .name("rocksky")
21 .description(
22- "Command-line interface for Rocksky โ scrobble tracks, view stats, and manage your listening history."
0023 )
24 .version(version.version);
25···108 .option("-d, --description <description>", "the description of the API key")
109 .description("create a new API key.")
110 .action(createApiKey);
00000111112program.parse(process.argv);
···1#!/usr/bin/env node
23+import chalk from "chalk";
4import { albums } from "cmd/albums";
5import { artists } from "cmd/artists";
6import { createApiKey } from "cmd/create";
7+import { mcp } from "cmd/mcp";
8import { nowplaying } from "cmd/nowplaying";
9import { scrobble } from "cmd/scrobble";
10import { scrobbles } from "cmd/scrobbles";
···21program
22 .name("rocksky")
23 .description(
24+ `Command-line interface for Rocksky (${chalk.underline(
25+ "https://rocksky.app"
26+ )}) โ scrobble tracks, view stats, and manage your listening history.`
27 )
28 .version(version.version);
29···112 .option("-d, --description <description>", "the description of the API key")
113 .description("create a new API key.")
114 .action(createApiKey);
115+116+program
117+ .command("mcp")
118+ .description("Starts an MCP server to use with Claude or other LLMs.")
119+ .action(mcp);
120121program.parse(process.argv);