openskynetwork / opensky-api

Python and Java bindings for the OpenSky Network REST API
GNU General Public License v3.0
339 stars 120 forks source link

`get_states` does not seem to work on historical time points #54

Closed bdnorman closed 1 year ago

bdnorman commented 1 year ago

api.get_states() works as expected however if I provide it a prior timepoint (even an hour back) it returns None (example: api.get_states(time_secs=1682089728)).

Digging into it a bit:

r = requests.get(
            "{0:s}{1:s}".format(api._api_url, '/states/all'),
            auth=api._auth,
            params=params,
            timeout=15.00,
        )

returns a 400 with no reason.

Am I doing something wrong or is this expected behavior?

bdnorman commented 1 year ago

Ah I'm seeing Historical data more than 1 hour ago can only be retrieved with /states/own

BastiaanGrisel commented 1 year ago

So, is there a way to access this historical data?

masorx commented 1 year ago

https://opensky-network.org/data/impala