Issue displaying metadata (cover artwork) when song changes

Read 12831 times
We are trying to display song metadata info (track title, artwork, artist name). We are using the result from JSON returned from this URL:
https://radio.coldream.com/rpc/testacct/streaminfo.get
We can successfully display the needed data on our react native app. Our dev wrote a background job that checks / reloads the data every 15sec. However the issue is that sometimes it takes long to display the current song info when song changes. The new song starts playing well but the metadata is taking time to change to match the song.
I reached out to support who advised me I should try and call XML from ShoutCast streaming server directly.
The problem with that is, shoutcast doesn't return track cover artwork (or at least don't know where to get it). Can someone please advise best way to return metadata in real time when song changes?
The JSON body is as follows:
{
"type": "result",
"data": [
{
"title": "example",
"song": "Amara Tari - Home",
"track": {
"artist": "Amara Tari",
"title": "Home",
"album": "Home",
"royaltytrackid": 0,
"started": 1660052580,
"id": 23,
"length": 0,
"playlist": {
"id": 2,
"title": "Standard Rotation"
},
"buyurl": "",
"imageurl": "https://radio.coldream.com/static/testacct/covers/rsz_Home_3f4473d7.jpg"
},
"bitrate": "128 Kbps",
"server": "Online",
"autodj": "Online",
"source": "Yes",
"offline": false,
"summary": "<a href=\"https://radio.coldream.com/tunein/-stream/testacct.pls\">example - Amara Tari - Home</a>",
"listeners": 0,
"maxlisteners": 10000,
"reseller": 0,
"serverstate": true,
"sourcestate": true,
"sourceconn": 1,
"date": "Aug 09, 2022",
"time": "01:46 PM",
"rawmeta": "Amara Tari - Home",
"mountpoint": "/stream",
"tuneinurl": "http://radio.coldream.com:8000/stream",
"tuneinurltls": "",
"directtuneinurl": "",
"proxytuneinurl": "http://radio.coldream.com/proxy/testacct/stream",
"proxytuneinurltls": "https://radio.coldream.com/proxy/testacct/stream",
"tuneinformat": "mp3",
"webplayer": "centova",
"servertype": "ShoutCast2",
"listenertotal": 0,
"url": "https://radio.coldream.com/rpc"
}
]
}