Python script to generate random flights data.
I've created this script to generate flights because unfortunately no company provides for free REST API with flight data. I uses this generator in my Flight search engine project. It sends data by POST request directly to Flight API. Generator uses Airport API to get distance between airports and calculate price and time utilizing how many kilometers there are.
- Python 3
You need to run Flight API and Airport API.
usage: generator.py --number <n> --ip_distance <ip_distance_api> --ip_flight <ip_flight_api> --environment
<n>
number of flights you want to generate<ip_distance_api>
ip of Airport API<ip_flight_api>
ip of Flight API--environment
use it if you want set rest parameters by environmental variables