Metadata-Version: 2.3
Name: pyopensky
Version: 2.10
Summary: A Python interface for OpenSky database
Project-URL: Repository, https://github.com/open-aviation/pyopensky/
Author-email: Xavier Olive <git@xoolive.org>, Junzi Sun <j.sun-1@tudelft.nl>
License-Expression: MIT
Requires-Python: >=3.9
Requires-Dist: appdirs>=1.4.4
Requires-Dist: httpx>=0.27.2
Requires-Dist: minio>=7.2.8
Requires-Dist: pandas>=2.2.2
Requires-Dist: pyarrow>=17.0.0
Requires-Dist: pyjwt>=2.9.0
Requires-Dist: tqdm>=4.66.5
Requires-Dist: trino[sqlalchemy]>=0.329.0
Requires-Dist: typing-extensions>=4.12.2
Provides-Extra: cartes
Requires-Dist: cartes>=0.8.1; extra == 'cartes'
Provides-Extra: decoding
Requires-Dist: pymodes>=2.18; extra == 'decoding'
Requires-Dist: rs1090>=0.3.8; extra == 'decoding'
Description-Content-Type: text/markdown

# pyopensky

The `pyopensky` Python library provides functions to download data from the OpenSky Network live API and historical databases. It aims at making ADS-B and Mode S data from OpenSky easily accessible in the Python programming environment.

Full documentation on <https://open-aviation.github.io/pyopensky>

## Installation

```sh
pip install pyopensky
```

The library is also available on conda-forge:

```sh
conda install -c conda-forge pyopensky
```

Development mode (with uv):

```sh
curl -LsSf https://astral.sh/uv/install.sh | sh  # Linux and MacOS
irm https://astral.sh/uv/install.ps1 | iex  # Windows
uv sync --dev
```

## Credentials

See details in the [documentation](https://open-aviation.github.io/pyopensky/credentials.html)

## Usage

> [!IMPORTANT]
> The Impala shell is now deprecated. Please upgrade to Trino.

- from the [REST API](https://open-aviation.github.io/pyopensky/rest.html):

  ```python
  from pyopensky.rest import REST

  rest = REST()

  rest.states()
  rest.tracks(icao24)
  rest.routes(callsign)
  rest.aircraft(icao24, begin, end)
  rest.arrival(airport, begin, end)
  rest.departure(airport, begin, end)
  ```

- from the [Trino](https://open-aviation.github.io/pyopensky/trino.html) database (requires authentication):

  ```python
  from pyopensky.trino import Trino

  trino = Trino()
  # full description of the whole set of parameters in the documentation
  trino.flightlist(start, stop, *, airport, callsign, icao24)
  trino.history(start, stop, *, callsign, icao24, bounds)
  trino.rawdata(start, stop, *, callsign, icao24, bounds)
  ```
