diff --git a/README.md b/README.md index 1907c37..14f2ed9 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,5 @@ # ecotraks Slash22 Berlin Project + +is this merging +? \ No newline at end of file diff --git a/get_plane_data.py b/get_plane_data.py new file mode 100644 index 0000000..8c91745 --- /dev/null +++ b/get_plane_data.py @@ -0,0 +1,7 @@ +import requests + +req = requests.get('https://api.flightapi.io/onewaytrip/632ddcfccaa6ed253fcf9e6e/BER/CDG/2022-10-03/2/0/1/Economy/EUR') + +data = req.json() +for flight in data['legs']: + print(u"day:[%s]\tduration:[%s]\tairline:[%s]\tstopOverDur[%s]" % (flight['departureDateTime'], flight['duration'], flight['airlineCodes'], flight['stopoverDurationMinutes']) ) \ No newline at end of file