deep-roon-mcp 0.5.1 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/deep-roon-mcp.js +23 -11
- package/package.json +1 -1
package/dist/deep-roon-mcp.js
CHANGED
|
@@ -15538,7 +15538,7 @@ var require_lib2 = __commonJS({
|
|
|
15538
15538
|
var version2;
|
|
15539
15539
|
var init_package = __esm({
|
|
15540
15540
|
"package.json"() {
|
|
15541
|
-
version2 = "0.5.
|
|
15541
|
+
version2 = "0.5.2";
|
|
15542
15542
|
}
|
|
15543
15543
|
});
|
|
15544
15544
|
|
|
@@ -49497,7 +49497,7 @@ init_library();
|
|
|
49497
49497
|
var PAGE = 500;
|
|
49498
49498
|
var BUDGET_MS = 45e3;
|
|
49499
49499
|
var at = /* @__PURE__ */ __name((e) => Date.parse(e.playedAt), "at");
|
|
49500
|
-
async function history(limit3, offset2 = 0, before) {
|
|
49500
|
+
async function history(limit3, offset2 = 0, before, since) {
|
|
49501
49501
|
return withCore(async (first) => {
|
|
49502
49502
|
const c = first.graph.findByType("HistoryPlay").length > 0 ? await fresh() : first;
|
|
49503
49503
|
const n = Math.min(Math.max(0, limit3), 500), skip = Math.max(0, offset2);
|
|
@@ -49507,7 +49507,8 @@ async function history(limit3, offset2 = 0, before) {
|
|
|
49507
49507
|
pageSize: PAGE,
|
|
49508
49508
|
timeoutMs: 15e3,
|
|
49509
49509
|
deadline: Date.now() + BUDGET_MS,
|
|
49510
|
-
maxDate: cutoff === null ? void 0 : new Date(cutoff)
|
|
49510
|
+
maxDate: cutoff === null ? void 0 : new Date(cutoff),
|
|
49511
|
+
minDate: since ? new Date(Date.parse(since)) : void 0
|
|
49511
49512
|
});
|
|
49512
49513
|
const picked = (cutoff === null ? all.events : all.events.filter((e) => at(e) < cutoff)).slice(skip, skip + n);
|
|
49513
49514
|
const out = { ...all, events: picked };
|
|
@@ -49539,7 +49540,7 @@ async function history(limit3, offset2 = 0, before) {
|
|
|
49539
49540
|
});
|
|
49540
49541
|
}
|
|
49541
49542
|
__name(history, "history");
|
|
49542
|
-
async function top(what, limit3, since) {
|
|
49543
|
+
async function top(what, limit3, since, until) {
|
|
49543
49544
|
return withCore(async (first) => {
|
|
49544
49545
|
const c = first.graph.findByType("HistoryPlay").length > 0 ? await fresh() : first;
|
|
49545
49546
|
const from = since ? Date.parse(since) : null;
|
|
@@ -49548,7 +49549,8 @@ async function top(what, limit3, since) {
|
|
|
49548
49549
|
pageSize: PAGE,
|
|
49549
49550
|
timeoutMs: 15e3,
|
|
49550
49551
|
deadline: Date.now() + BUDGET_MS,
|
|
49551
|
-
minDate: from === null ? void 0 : new Date(from)
|
|
49552
|
+
minDate: from === null ? void 0 : new Date(from),
|
|
49553
|
+
maxDate: until ? new Date(Date.parse(until)) : void 0
|
|
49552
49554
|
});
|
|
49553
49555
|
closeSoon("after the history");
|
|
49554
49556
|
const count = /* @__PURE__ */ new Map();
|
|
@@ -50610,16 +50612,26 @@ function registerReadTools(server, internal = true) {
|
|
|
50610
50612
|
}, ({ category, genre, limit: n }) => run(() => radio(category, genre, n ?? 40)));
|
|
50611
50613
|
reg("roon_history", {
|
|
50612
50614
|
title: "Play history",
|
|
50613
|
-
description: 'What was played in Roon, newest first \u2014 Roon\'s own play history, with how much of each track was heard. Goes back as far as Roon\'s history does: `before` (YYYY-MM-DD)
|
|
50614
|
-
inputSchema: {
|
|
50615
|
+
description: 'What was played in Roon, newest first \u2014 Roon\'s own play history, with how much of each track was heard. Goes back as far as Roon\'s history does \u2014 Roon filters by date itself: `since` and `before` (YYYY-MM-DD) give the plays in that window (e.g. "what did I play in March 2019": since 2019-03-01, before 2019-04-01; up to 500 per call, `offset` for the next ones). For "most played" questions use roon_top instead of counting this.',
|
|
50616
|
+
inputSchema: {
|
|
50617
|
+
limit: limit(500, 30),
|
|
50618
|
+
offset: external_exports.number().int().min(0).optional(),
|
|
50619
|
+
since: external_exports.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional().describe("Only plays from this date on (YYYY-MM-DD)."),
|
|
50620
|
+
before: external_exports.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional().describe("Only plays before this date (YYYY-MM-DD).")
|
|
50621
|
+
},
|
|
50615
50622
|
annotations: READ
|
|
50616
|
-
}, ({ limit: n, offset: offset2, before }) => run(() => history(n ?? 30, offset2 ?? 0, before)));
|
|
50623
|
+
}, ({ limit: n, offset: offset2, since, before }) => run(() => history(n ?? 30, offset2 ?? 0, before, since)));
|
|
50617
50624
|
reg("roon_top", {
|
|
50618
50625
|
title: "Most played",
|
|
50619
|
-
description: 'The most played albums, artists or tracks in Roon, counted over the WHOLE play history (a play counts when at least half the track was heard). Use this for "most listened" questions \u2014 don\'t tally roon_history yourself. `since` (YYYY-MM-DD)
|
|
50620
|
-
inputSchema: {
|
|
50626
|
+
description: 'The most played albums, artists or tracks in Roon, counted over the WHOLE play history (a play counts when at least half the track was heard). Use this for "most listened" questions \u2014 don\'t tally roon_history yourself. `since` and `until` (YYYY-MM-DD) limit the period \u2014 Roon filters by date itself, however far back: "what did I play most in March 2019" is since 2019-03-01, until 2019-04-01.',
|
|
50627
|
+
inputSchema: {
|
|
50628
|
+
what: external_exports.enum(["albums", "artists", "tracks"]).optional(),
|
|
50629
|
+
limit: limit(100, 20),
|
|
50630
|
+
since: external_exports.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional().describe("Only plays from this date on (YYYY-MM-DD)."),
|
|
50631
|
+
until: external_exports.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional().describe("Only plays before this date (YYYY-MM-DD).")
|
|
50632
|
+
},
|
|
50621
50633
|
annotations: READ
|
|
50622
|
-
}, ({ what, limit: n, since }) => run(() => top(what ?? "albums", n ?? 20, since)));
|
|
50634
|
+
}, ({ what, limit: n, since, until }) => run(() => top(what ?? "albums", n ?? 20, since, until)));
|
|
50623
50635
|
}
|
|
50624
50636
|
__name(registerReadTools, "registerReadTools");
|
|
50625
50637
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "deep-roon-mcp",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.2",
|
|
4
4
|
"description": "An MCP server for Roon that reaches the parts the official API doesn't: reviews, biographies, Qobuz's and TIDAL's shelves, TIDAL's playlists, your history, search across your library and the streaming services",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "René Bouwmeester <21277119+renebouwmeester@users.noreply.github.com>",
|