apilayer / aviationstack

Free, Real-Time Flight Tracker & Status REST API
https://aviationstack.com
85 stars 8 forks source link

same name for api end point Real-Time Flights and Historical Flights make issue on free plan #8

Open drepou opened 9 months ago

drepou commented 9 months ago

Real-Time Flights Available on: All plans so all the option sould work using a free plan key like the optional flight_date parameter

cf api documemention Real-Time Flights Available on: All plans flight_date [Optional] Filter your results by providing a flight date in the format YYYY-MM-DD. Example: 2019-02-31

https://api.aviationstack.com/v1/flights ? access_key = XXXX

but if we provide the flight_date parameter we get the error :
"error": { "code": "function_access_restricted", "message": "Your current subscription plan does not support this API function."

Because the api end on Historical Flights Available point because the name for both are same '/v1/flights' and Historical Flights is not free plan !

Historical Flights Available on: Basic Plan and higher

https://api.aviationstack.com/v1/flights ? access_key = XXXX & flight_date = 2019-12-11

solution => change api enpoint for one off them or change the Real-Time Flights response to return only flight off the day ( not the case actualy seem to return also J-1 flight may be more