Metadata-Version: 2.1
Name: aeroapi-python
Version: 1.1.4
Summary: FlightAware AeroAPI Caller for Python
Home-page: https://github.com/derens99/aeroapi-python
Author: Deren S
Author-email: derens9999@gmail.com
License: MIT
Keywords: python aeroapi flightaware flightaware-api flightaware-aeroapi flightaware-aeroapi-python flightaware-aeroapi-python3 flightaware-aeroapi-python3.5 flightaware-aeroapi-python3.6 flightaware-aeroapi-python3.7 flightaware-aeroapi-python3.8 flightaware-aeroapi-python3.9
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Natural Language :: English
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Topic :: Education :: Testing
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Utilities
Requires-Python: >=3.5
Description-Content-Type: text/markdown
License-File: LICENSE


# AeroApi Python

Python wrapper for the FlightAware's AeroAPI

## Description

AeroAPI (formerly FlightXML) is FlightAware's live flight data API that provides powerful, reliable information about real-time and historical flight information. This Python wrapper allows for easier interaction with the AeroAPI from Python applications.

## FlightAware AeroAPI Reference
[AeroAPI](https://flightaware.com/aeroapi)

## Installation

```bash
pip install aeroapi-python
```
    
### Using test pypi, install with this command.
```bash
pip install --index-url https://pypi.org/simple/ --extra-index-url https://test.pypi.org/simple/ aeroapi-python
```

## Usage

### AeroAPI Class
The AeroAPI class is the main class for interacting with the FlightAware AeroAPI. It provides access to various resources such as airports, operators, flights, and more.

#### Initialization
To use the AeroAPI class, you need to create an instance of it by passing your API key as an argument to the constructor:

```python
from AeroAPI import AeroAPI

api_key = 'your-api-key'
aeroapi = AeroAPI(api_key)
```

### Airports
The Airports class provides methods for retrieving information about airports. You can access an instance of the Airports class through the airports attribute of the AeroAPI instance:

```python
airports = aeroapi.airports
```

#### Methods

- get_airport_info(airport_code: str) -> dict: Returns information about the specified airport.
    
    ```python
    airport_info = airports.get_airport_info('KLAX')
    ```

- search_airports(query: str) -> list: Searches for airports that match the specified query.
    
    ```python
    airport_list = airports.search_airports('Los Angeles')
    ```

- get_nearby_airports(latitude: float, longitude: float, radius: int) -> list: Returns a list of airports near the specified latitude and longitude within the specified radius.
    
    ```python
    airport_list = airports.get_nearby_airports(33.9425, -118.408056, 10)
    ```

#### Example Usage

```python 
from AeroAPI import AeroAPI

api_key = 'your-api-key'
aeroapi = AeroAPI(api_key)

airports = aeroapi.airports
airport_info = airports.get_airport_info('KLAX')

print(airport_info)
```

## License

[MIT](https://choosealicense.com/licenses/mit/)

## Authors

- [@derens99](https://www.github.com/derens99)
