06-18-2025, 12:53 PM
Hi, I don't know if I've "reinvented the wheel," but based on the experiences mentioned above and needing to reload some Italian stations, I wrote a Python script that automates a few tasks:
I was going to ask for the third functionality! Is it possible to add it to moodeaudio. As we write the website of a station, when storing a new one, it is nice to grab the icon from the site automatically. Thank you.
- It downloads the configuration using the Station Manager utility.
- It retrieves a list of radio stations via the Radio-Browser API (I filtered n Italian radios and m Tuscan radios within the script).
- It attempts to download the station logo if available, converting it from PNG to three JPG formats; if no logo is provided, it assigns a default.jpg (which I took from Moode).
- It merges the data with the Moode backup, avoiding duplicates, and generates both a JSON file and an icon folder.
- It creates a ZIP file and reuploads it using the radio_station utility.
I was going to ask for the third functionality! Is it possible to add it to moodeaudio. As we write the website of a station, when storing a new one, it is nice to grab the icon from the site automatically. Thank you.