1
0
Fork 0
mirror of https://github.com/Findus23/RadioStats.git synced 2024-09-19 16:03:48 +02:00
RadioStats/parser/kronehit.py
2019-02-04 22:11:03 +01:00

11 lines
353 B
Python

from utils import *
URL = "https://www.kronehit.at/alles-ueber-kronehit/hitsuche/?format=json&channel=1"
def get(channel):
for track in fetch(URL, True)["items"]:
artist = track["ArtistName"]
title = track["TrackName"]
time = time_to_date(string_to_time(track["PlayTime"],seconds=False))
yield time, artist, title