I have my Sosnos integrated and often use it to listen to Radio. But the cover aert supplied by sonos / the station is non existent.
The artist and song are shwoing though the integration of Sonos however. So i was checking https://rapidapi.com/ if there is a way to get my own artist and cover art…
const axios = require("axios");
const options = {
method: 'GET',
url: 'https://shazam.p.rapidapi.com/search',
params: {term: 'Foals - Wake Me Up', locale: 'nl-NL', limit: '1'},
headers: {
'X-RapidAPI-Key': 'xxxxxxxxxx',
'X-RapidAPI-Host': 'shazam.p.rapidapi.com'
}
};
axios.request(options).then(function (response) {
console.log(response.data);
}).catch(function (error) {
console.error(error);
});
Would be very nice to have an integration/add-on etc… that provides this…(mainly because I am not good enough at this to do it myself…i have to admit)
In the reponse the images are turning up
{
"tracks": {
"hits": [
{
"track": {
"layout": "5",
"type": "MUSIC",
"key": "588646301",
"title": "Wake Me Up",
"subtitle": "Foals",
"share": {
"subject": "Wake Me Up - Foals",
"text": "Ik heb Wake Me Up door Foals ontdekt met Shazam.",
"href": "https://www.shazam.com/track/588646301/wake-me-up",
"image": "https://is2-ssl.mzstatic.com/image/thumb/Music116/v4/f3/bc/df/f3bcdf5e-4a18-d699-b47e-3cfe9fb2684d/190296242441.jpg/400x400cc.jpg",
"twitter": "Ik heb Wake Me Up door Foals ontdekt met @Shazam.",
"html": "https://www.shazam.com/snippets/email-share/588646301?lang=nl-NL&country=NL",
"avatar": "https://is4-ssl.mzstatic.com/image/thumb/Music112/v4/c5/3d/30/c53d30f3-5c49-deab-678c-31b22367bdb4/pr_source.png/800x800cc.jpg",
"snapchat": "https://www.shazam.com/partner/sc/track/588646301"
},
"images": {
"background": "https://is4-ssl.mzstatic.com/image/thumb/Music112/v4/c5/3d/30/c53d30f3-5c49-deab-678c-31b22367bdb4/pr_source.png/800x800cc.jpg",
"coverart": "https://is2-ssl.mzstatic.com/image/thumb/Music116/v4/f3/bc/df/f3bcdf5e-4a18-d699-b47e-3cfe9fb2684d/190296242441.jpg/400x400cc.jpg",
"coverarthq": "https://is2-ssl.mzstatic.com/image/thumb/Music116/v4/f3/bc/df/f3bcdf5e-4a18-d699-b47e-3cfe9fb2684d/190296242441.jpg/400x400cc.jpg",
"joecolor": "b:ffffffp:000000s:333333t:333333q:5c5c5c"
},
"hub": {
"type": "APPLEMUSIC",
"image": "https://images.shazam.com/static/icons/hub/ios/v5/applemusic_{scalefactor}.png",
"actions": [
{
"name": "apple",
"type": "applemusicplay",
"id": "1608050744"
},
{
"name": "apple",
"type": "uri",
"uri": "https://audio-ssl.itunes.apple.com/itunes-assets/AudioPreview122/v4/12/30/c7/1230c7c0-a834-5afb-691f-00a7a13959b3/mzaf_14227478163175615895.plus.aac.ep.m4a"
}
],
"options": [
{
"caption": "OPEN",
"actions": [
{
"name": "hub:applemusic:deeplink",
"type": "applemusicopen",
"uri": "https://music.apple.com/nl/album/wake-me-up/1608050741?i=1608050744&mttnagencyid=s2n&mttnsiteid=125115&mttn3pid=Apple-Shazam&mttnsub1=Shazam_ios&mttnsub2=5348615A-616D-3235-3830-44754D6D5973&itscg=30201&app=music&itsct=Shazam_ios"
},
{
"name": "hub:applemusic:deeplink",
"type": "uri",
"uri": "https://music.apple.com/nl/album/wake-me-up/1608050741?i=1608050744&mttnagencyid=s2n&mttnsiteid=125115&mttn3pid=Apple-Shazam&mttnsub1=Shazam_ios&mttnsub2=5348615A-616D-3235-3830-44754D6D5973&itscg=30201&app=music&itsct=Shazam_ios"
}
],
"beacondata": {
"type": "open",
"providername": "applemusic"
},
"image": "https://images.shazam.com/static/icons/hub/ios/v5/overflow-open-option_{scalefactor}.png",
"type": "open",
"listcaption": "Open in Apple Music",
"overflowimage": "https://images.shazam.com/static/icons/hub/ios/v5/applemusic-overflow_{scalefactor}.png",
"colouroverflowimage": false,
"providername": "applemusic"
},
{
"caption": "KOPEN",
"actions": [
{
"type": "uri",
"uri": "https://itunes.apple.com/nl/album/wake-me-up/1608050741?i=1608050744&mttnagencyid=s2n&mttnsiteid=125115&mttn3pid=Apple-Shazam&mttnsub1=Shazam_ios&mttnsub2=5348615A-616D-3235-3830-44754D6D5973&itscg=30201&app=itunes&itsct=Shazam_ios"
}
],
"beacondata": {
"type": "buy",
"providername": "itunes"
},
"image": "https://images.shazam.com/static/icons/hub/ios/v5/itunes-overflow-buy_{scalefactor}.png",
"type": "buy",
"listcaption": "Koop op iTunes",
"overflowimage": "https://images.shazam.com/static/icons/hub/ios/v5/itunes-overflow-buy_{scalefactor}.png",
"colouroverflowimage": false,
"providername": "itunes"
}
],
"providers": [
{
"caption": "Open in Spotify",
"images": {
"overflow": "https://images.shazam.com/static/icons/hub/ios/v5/spotify-overflow_{scalefactor}.png",
"default": "https://images.shazam.com/static/icons/hub/ios/v5/spotify_{scalefactor}.png"
},
"actions": [
{
"name": "hub:spotify:searchdeeplink",
"type": "uri",
"uri": "spotify:search:Wake%20Me%20Up%20Foals"
}
],
"type": "SPOTIFY"
},
{
"caption": "Open in Deezer",
"images": {
"overflow": "https://images.shazam.com/static/icons/hub/ios/v5/deezer-overflow_{scalefactor}.png",
"default": "https://images.shazam.com/static/icons/hub/ios/v5/deezer_{scalefactor}.png"
},
"actions": [
{
"name": "hub:deezer:searchdeeplink",
"type": "uri",
"uri": "deezer-query://www.deezer.com/play?query=%7Btrack%3A%27Wake+Me+Up%27%20artist%3A%27Foals%27%7D"
}
],
"type": "DEEZER"
}
],
"explicit": false,
"displayname": "APPLE MUSIC"
},
"artists": [
{
"id": "42",
"adamid": "192738057"
}
],
"url": "https://www.shazam.com/track/588646301/wake-me-up"
},
"snippet": "Wake me up!"
}
]
},
"artists": {
"hits": [
{
"artist": {
"avatar": "https://is2-ssl.mzstatic.com/image/thumb/Music112/v4/c5/3d/30/c53d30f3-5c49-deab-678c-31b22367bdb4/pr_source.png/800x800bb.jpg",
"name": "Foals",
"verified": false,
"weburl": "https://music.apple.com/nl/artist/foals/192738057",
"adamid": "192738057"
}
}
]
}
}