deep-roon-mcp 0.4.8 → 0.4.9

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/README.md CHANGED
@@ -200,6 +200,9 @@ status; it holds no secrets).
200
200
  - Several clients at once (Claude Desktop and Claude Code, or ChatGPT next to them) work: Roon keeps one connection
201
201
  per extension, and the client that asks a question takes it over for that moment.
202
202
  - Album, track and artist keys stay valid between calls.
203
+ - Track artists: a track's `artist` is its album's artist (on a compilation that is often "Various Artists"). Where the
204
+ track's own main artist differs, it comes as `track_artist` — in search, `roon_tracks`, albums, playlists, the queue
205
+ and what plays now. Roon keeps it in the track's credits.
203
206
  - Covers: every `image` key comes with an `image_url` to load it from your Core. Roon has two kinds of image keys that
204
207
  aren't interchangeable. Deep Roon reads Roon's internal library, so most keys are internal ones (short, like
205
208
  `doicaaaa`): the Core serves them at `http://<core>:9330/image/<key>.jpg`, or scaled at `/image/<key>.300.jpg` (any
@@ -15525,7 +15525,7 @@ var require_lib2 = __commonJS({
15525
15525
  var version2;
15526
15526
  var init_package = __esm({
15527
15527
  "package.json"() {
15528
- version2 = "0.4.8";
15528
+ version2 = "0.4.9";
15529
15529
  }
15530
15530
  });
15531
15531
 
@@ -16033,6 +16033,7 @@ function resultRow(c, o) {
16033
16033
  if (t === "TrackLite" || t === "Track") {
16034
16034
  const al = obj(c, field2(o, "Album"));
16035
16035
  const r = { kind: "track", key: String(field2(o, "TrackId") ?? ""), title: field2(o, "Title") ?? "", artist: clean(field2(al, "PerformedBy") ?? field2(o, "PerformedBy") ?? "") };
16036
+ trackArtist(c, r, o, al);
16036
16037
  const album2 = field2(al, "Title");
16037
16038
  if (album2) r.album = album2;
16038
16039
  const ak = field2(al, "AlbumId");
@@ -16048,6 +16049,17 @@ function resultRow(c, o) {
16048
16049
  }
16049
16050
  return { kind: t, title: field2(o, "Title") ?? field2(o, "Name") ?? "" };
16050
16051
  }
16052
+ function trackArtist(c, r, tr, al) {
16053
+ const namen = [];
16054
+ for (const cr of items(c, field2(tr, "Credits"))) {
16055
+ if (field2(cr, "Type") !== 3) continue;
16056
+ const n = field2(obj(c, field2(cr, "Performer")), "Name");
16057
+ if (typeof n === "string" && n && !namen.includes(n)) namen.push(n);
16058
+ }
16059
+ const albumArtiest = clean(field2(al, "PerformedBy") ?? "");
16060
+ if (!namen.length || namen.includes(albumArtiest) || namen.every((n) => albumArtiest.includes(n))) return;
16061
+ r.track_artist = namen.join(", ");
16062
+ }
16051
16063
  var obj, clean, typeOf, items, strings, flag, yearOf, wait;
16052
16064
  var init_graph = __esm({
16053
16065
  "src/roon/graph.ts"() {
@@ -16082,6 +16094,7 @@ var init_graph = __esm({
16082
16094
  __name(sourceOf, "sourceOf");
16083
16095
  __name(albumRow, "albumRow");
16084
16096
  __name(resultRow, "resultRow");
16097
+ __name(trackArtist, "trackArtist");
16085
16098
  }
16086
16099
  });
16087
16100
 
@@ -16326,6 +16339,7 @@ async function album(key, withCredits) {
16326
16339
  const n = field2(t, "TrackNumber");
16327
16340
  if (n != null) r.n = n;
16328
16341
  r.title = field2(t, "Title");
16342
+ trackArtist(c, r, t, al);
16329
16343
  const l = field2(t, "LengthSeconds");
16330
16344
  if (typeof l === "number") {
16331
16345
  r.length = duration3(l);
@@ -49615,6 +49629,7 @@ async function nowPlaying() {
49615
49629
  r.title = field2(tr, "Title");
49616
49630
  r.artist = clean(field2(al, "PerformedBy"));
49617
49631
  r.album = field2(al, "Title");
49632
+ trackArtist(c, r, tr, al);
49618
49633
  const tk = field2(tr, "TrackId");
49619
49634
  if (tk !== void 0 && tk !== null) r.track_key = String(tk);
49620
49635
  const ak = field2(al, "AlbumId");
@@ -49870,6 +49885,7 @@ function queueRow(c, oid) {
49870
49885
  const tr = obj(c, field2(items(c, field2(c.graph.getObject(oid), "Tracks"))[0], "Track"));
49871
49886
  const al = obj(c, field2(tr, "Album"));
49872
49887
  const r = { title: field2(tr, "Title") ?? null, artist: clean(field2(al, "PerformedBy") ?? "") };
49888
+ trackArtist(c, r, tr, al);
49873
49889
  const album2 = field2(al, "Title");
49874
49890
  if (album2) r.album = album2;
49875
49891
  const l = field2(tr, "LengthSeconds");
@@ -51010,6 +51026,7 @@ async function playlist(key, limit3) {
51010
51026
  const tr = obj(c, field2(obj(c, x), "Track"));
51011
51027
  const al = obj(c, field2(tr, "Album"));
51012
51028
  const r = { n: i + 1, key: String(field2(tr, "TrackId") ?? ""), title: field2(tr, "Title") ?? null, artist: clean(field2(al, "PerformedBy") ?? ""), album: field2(al, "Title") ?? void 0 };
51029
+ trackArtist(c, r, tr, al);
51013
51030
  const ak = field2(al, "AlbumId");
51014
51031
  if (ak !== void 0 && ak !== null) r.album_key = String(ak);
51015
51032
  const im = imageKey(c, al);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "deep-roon-mcp",
3
- "version": "0.4.8",
3
+ "version": "0.4.9",
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>",