add main AM api routes in todo
This commit is contained in:
parent
dec21c6650
commit
2d6ac28227
1 changed files with 74 additions and 6 deletions
|
@ -14,13 +14,81 @@
|
||||||
// &fields[artists]=name,url&extend[stations]=airDate,supportsAirTimeUpdates&meta[stations]=inflectionPoints
|
// &fields[artists]=name,url&extend[stations]=airDate,supportsAirTimeUpdates&meta[stations]=inflectionPoints
|
||||||
// &types=artists,albums,editorial-items,library-albums,library-playlists,music-movies,music-videos,playlists,stations,uploaded-audios,uploaded-videos,activities,apple-curators,curators,tv-shows,social-profiles,social-upsells
|
// &types=artists,albums,editorial-items,library-albums,library-playlists,music-movies,music-videos,playlists,stations,uploaded-audios,uploaded-videos,activities,apple-curators,curators,tv-shows,social-profiles,social-upsells
|
||||||
// &l=en-gb&platform=web
|
// &l=en-gb&platform=web
|
||||||
// How Apple is kinda doing it :
|
|
||||||
// MusicKit.getInstance().api.recommendations({extend: ["editorialArtwork", "artistUrl"],
|
await app.mk.api.personalRecommendations("",
|
||||||
// "fields[artists]": ["name", "url", "artwork", "editorialArtwork", "genreNames", "editorialNotes"],
|
{
|
||||||
// "art[url]": "f"});
|
name: "listen-now",
|
||||||
|
with: "friendsMix,library,social",
|
||||||
|
"art[social-profiles:url]":"c",
|
||||||
|
"art[url]": "c,f",
|
||||||
|
"omit[resource]": "autos",
|
||||||
|
"relate[editorial-items]": "contents",
|
||||||
|
extend: ["editorialCard", "editorialVideo"],
|
||||||
|
"extend[albums]": ["artistUrl"],
|
||||||
|
"extend[library-albums]": ["artistUrl"],
|
||||||
|
"extend[playlists]": ["artistNames", "editorialArtwork"],
|
||||||
|
"extend[library-playlists]": ["artistNames", "editorialArtwork"],
|
||||||
|
"extend[social-profiles]": "topGenreNames",
|
||||||
|
"include[albums]": "artists",
|
||||||
|
"include[songs]": "artists",
|
||||||
|
"include[music-videos]": "artists",
|
||||||
|
"fields[albums]": ["artistName", "artistUrl", "artwork", "contentRating", "editorialArtwork", "editorialVideo", "name", "playParams", "releaseDate", "url"],
|
||||||
|
"fields[artists]": ["name", "url"],
|
||||||
|
"extend[stations]": ["airDate", "supportsAirTimeUpdates"],
|
||||||
|
"meta[stations]": "inflectionPoints",
|
||||||
|
types: "artists,albums,editorial-items,library-albums,library-playlists,music-movies,music-videos,playlists,stations,uploaded-audios,uploaded-videos,activities,apple-curators,curators,tv-shows,social-profiles,social-upsells",
|
||||||
|
l:"en-gb",
|
||||||
|
platform:"web"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
includeResponseMeta: !0,
|
||||||
|
reload: !0
|
||||||
|
});
|
||||||
|
|
||||||
|
// Browse page
|
||||||
|
await app.mk.api.groupings("",
|
||||||
|
{
|
||||||
|
platform: "web",
|
||||||
|
name: "music",
|
||||||
|
l: "en-gb",
|
||||||
|
"omit[resource:artists]": "relationships",
|
||||||
|
"include[albums]": "artists",
|
||||||
|
"include[songs]": "artists",
|
||||||
|
"include[music-videos]": "artists",
|
||||||
|
extend: "editorialArtwork,artistUrl",
|
||||||
|
"fields[artists]": "name,url,artwork,editorialArtwork,genreNames,editorialNotes",
|
||||||
|
"art[url]": "f"
|
||||||
|
});
|
||||||
|
|
||||||
|
// Radio page
|
||||||
|
await app.mk.api.recentRadioStations("",
|
||||||
|
{l: "en-gb",
|
||||||
|
"platform": "web",
|
||||||
|
"art[url]": "f"});
|
||||||
|
|
||||||
|
// Songs
|
||||||
|
await app.mk.api.library.songs({limit: 100}).then((data)=>{
|
||||||
|
console.log(data)
|
||||||
|
})
|
||||||
|
|
||||||
|
// Artists
|
||||||
|
await app.mk.api.library.artists({limit: 100}).then((data)=>{
|
||||||
|
console.log(data)
|
||||||
|
})
|
||||||
|
|
||||||
|
// Artists
|
||||||
|
await app.mk.api.library.albums({limit: 100}).then((data)=>{
|
||||||
|
console.log(data)
|
||||||
|
})
|
||||||
|
|
||||||
|
// Albums
|
||||||
|
// does not like limit = 100 for some reason
|
||||||
|
await app.mk.api.library.albums({limit: 50}).then((data)=>{
|
||||||
|
console.log(data)
|
||||||
|
})
|
||||||
|
|
||||||
// Made For You
|
// Made For You
|
||||||
app.mk.api.recommendations({extend: "editorialArtwork,artistUrl"})
|
app.mk.api.recommendations("",{extend: "editorialArtwork,artistUrl"})
|
||||||
|
|
||||||
// Library with library length
|
// Library with library length
|
||||||
/** This will return 100 tracks in an array, however
|
/** This will return 100 tracks in an array, however
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue