![]() |
What's playing Spotify Connect on display? - Printable Version +- Moode Forum (https://moodeaudio.org/forum) +-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3) +--- Forum: Feature requests (https://moodeaudio.org/forum/forumdisplay.php?fid=8) +--- Thread: What's playing Spotify Connect on display? (/showthread.php?tid=5714) Pages:
1
2
|
RE: What's playing Spotify Connect on display? - Nutul - 02-23-2024 (02-23-2024, 06:43 PM)jmguillaume Wrote: The script to retrieve the data is 12 lines :-) Spotipy is doing all the job. That is what I meant... how big and/or heavi is Spotipy My approach is also about 3 seconds, goes to open.spotify.com as if it were a browser (requests a total of 3 pages) track (https://open.spotify.com/track/<track_id>) -- extracts track title, index, duration, album_id, artist_id album (https://open.spotify.com/album/<album_id>) -- extracts album title, coverart url artist (https://open.spotify.com/artist/<artist_id>) -- extracts artist name but does not require any account, as it just filters the header block of the html and extracts the information from its <meta> tags. Find the attached script, it needs to be invoked with the track_id as parameter. You can also compare times. RE: What's playing Spotify Connect on display? - Tim Curtis - 02-23-2024 I forgot, but did I post somewhere about how to get backend data to front end? RE: What's playing Spotify Connect on display? - Nutul - 02-23-2024 (02-23-2024, 09:42 PM)Tim Curtis Wrote: I forgot, but did I post somewhere about how to get backend data to front end? Hi Tim, well, you told us that there are methods for doing so, but the details you never shared, so far ;-) RE: What's playing Spotify Connect on display? - Tim Curtis - 02-23-2024 Start with this thread to see how a renderer overlay gets displayed and then it could be a similar process for getting any external back-end data to the front-end. https://moodeaudio.org/forum/showthread.php?tid=6237&pid=52232#pid52232 A basic flow could be Code: - Spotevent.sh writes track id to some location One challenge is how to handle front-end page refresh RE: What's playing Spotify Connect on display? - Nutul - 02-23-2024 (02-23-2024, 10:19 PM)Tim Curtis Wrote: Start with this thread to see how a renderer overlay gets displayed and then it could be a similar process for getting any external back-end data to the front-end. https://moodeaudio.org/forum/showthread.php?tid=6237&pid=52232#pid52232 Excellent. Yes, you mentioned it already... need to think. For sure the UI needs to be aware that we are playing Spotify... |