Fix: adjust timestamp for fr24 data retrieval
This commit is contained in:
parent
7e7d1fff1e
commit
e6825248dd
|
@ -27,7 +27,7 @@ def remote_fr24() -> T.Text:
|
||||||
"""
|
"""
|
||||||
Returns the url to retrieve data from flightradar24.
|
Returns the url to retrieve data from flightradar24.
|
||||||
"""
|
"""
|
||||||
yesterday_ts = int((datetime.now() - timedelta(days=1)).timestamp())
|
yesterday_ts = int((datetime.now() - timedelta(hours=12)).timestamp())
|
||||||
url = f"https://api.flightradar24.com/common/v1/airport.json?code=cia&plugin[]=&plugin-setting[schedule][mode]=arrivals&plugin-setting[schedule][timestamp]={yesterday_ts}&page=-1&limit=100&fleet=&token=" # noqa: E501
|
url = f"https://api.flightradar24.com/common/v1/airport.json?code=cia&plugin[]=&plugin-setting[schedule][mode]=arrivals&plugin-setting[schedule][timestamp]={yesterday_ts}&page=-1&limit=100&fleet=&token=" # noqa: E501
|
||||||
return url
|
return url
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user