MCPcopy
hub / github.com/spicetify/cli / fetchArtistLikedTracks

Function fetchArtistLikedTracks

Extensions/shuffle+.js:428–436  ·  view source on GitHub ↗
(uri)

Source from the content-addressed store, hash-verified

426 }
427
428 async function fetchArtistLikedTracks(uri) {
429 const artistRes = await Spicetify.CosmosAsync.get(`sp://core-collection/unstable/@/list/tracks/artist/${uri}?responseFormat=protobufJson`);
430
431 const allTracks = artistRes.item?.map((artistTrack) => {
432 if (artistTrack.trackMetadata.playable) return artistTrack.trackMetadata.link;
433 });
434
435 return allTracks ?? [];
436 }
437
438 async function fetchArtistTopTenTracks(uri) {
439 const { queryArtistOverview } = Spicetify.GraphQL.Definitions;

Callers 1

fetchAndPlayFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected