mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Lower scan interval for OpenSky (#92593)
* Lower scan interval for opensky to avoid hitting rate limit * Lower scan interval for opensky to avoid hitting rate limit * Update homeassistant/components/opensky/sensor.py Co-authored-by: epenet <6771947+epenet@users.noreply.github.com> * Update homeassistant/components/opensky/sensor.py Co-authored-by: epenet <6771947+epenet@users.noreply.github.com> --------- Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
This commit is contained in:
parent
9a589a3a54
commit
6d1e607756
@ -38,7 +38,8 @@ DEFAULT_ALTITUDE = 0
|
||||
|
||||
EVENT_OPENSKY_ENTRY = f"{DOMAIN}_entry"
|
||||
EVENT_OPENSKY_EXIT = f"{DOMAIN}_exit"
|
||||
SCAN_INTERVAL = timedelta(seconds=12) # opensky public limit is 10 seconds
|
||||
# OpenSky free user has 400 credits, with 4 credits per API call. 100/24 = ~4 requests per hour
|
||||
SCAN_INTERVAL = timedelta(minutes=15)
|
||||
|
||||
OPENSKY_API_URL = "https://opensky-network.org/api/states/all"
|
||||
OPENSKY_API_FIELDS = [
|
||||
|
Loading…
x
Reference in New Issue
Block a user