PHPackages                             lookyman/flightradar24 - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. lookyman/flightradar24

ActiveLibrary[API Development](/categories/api)

lookyman/flightradar24
======================

PHP SDK for the Flightradar24 API.

1.0.0(1mo ago)00MITPHPPHP ~8.5.0

Since Jun 6Pushed 1mo agoCompare

[ Source](https://github.com/lookyman/flightradar24)[ Packagist](https://packagist.org/packages/lookyman/flightradar24)[ RSS](/packages/lookyman-flightradar24/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (12)Versions (2)Used By (0)

lookyman/flightradar24
======================

[](#lookymanflightradar24)

PHP SDK for the [Flightradar24 API](https://fr24api.flightradar24.com/docs), built on [PSR-18](https://www.php-fig.org/psr/psr-18/). Bring your own PSR-18 HTTP client and PSR-17 request factory; all API responses are mapped into immutable `readonly` DTOs.

Requirements
------------

[](#requirements)

- PHP 8.5+
- A Flightradar24 API token
- Any [PSR-18](https://packagist.org/providers/psr/http-client-implementation) HTTP client and [PSR-17](https://packagist.org/providers/psr/http-factory-implementation) request factory (e.g. `guzzlehttp/guzzle`, or `symfony/http-client` + `nyholm/psr7`)

Installation
------------

[](#installation)

```
composer require lookyman/flightradar24
# plus an HTTP client + factory, for example:
composer require guzzlehttp/guzzle guzzlehttp/psr7
```

Authentication
--------------

[](#authentication)

A token is **required** — there is no environment-variable fallback. Pass it to the `Transport` constructor. A blank token throws `Lookyman\Flightradar24\Exception\MissingApiTokenException`.

Usage
-----

[](#usage)

```
use GuzzleHttp\Client as GuzzleClient;
use GuzzleHttp\Psr7\HttpFactory;
use Lookyman\Flightradar24\Client;
use Lookyman\Flightradar24\Query\Boundary;
use Lookyman\Flightradar24\Query\FlightPositionsQuery;
use Lookyman\Flightradar24\Transport\Transport;

$client = new Client(new Transport($token, new GuzzleClient(), new HttpFactory()));

// Single object:
$airport = $client->airports->getFull('WAW');
echo $airport->name; // "Warsaw Chopin"

// List:
$positions = $client->livePositions->getLight(new FlightPositionsQuery(
    new Boundary(52.5, 52.0, 20.8, 21.3),
));
printf("Found %d aircraft.\n", count($positions));
```

Every call is synchronous and returns the DTO (or `list`) directly. See [`examples/basic_usage.php`](examples/basic_usage.php).

Endpoint coverage
-----------------

[](#endpoint-coverage)

Resource methodHTTP request`livePositions->getLight(FlightPositionsQuery)` → `list``GET /api/live/flight-positions/light``livePositions->getFull(FlightPositionsQuery)` → `list``GET /api/live/flight-positions/full``livePositions->getCount(FlightPositionsQuery)` → `CountResult``GET /api/live/flight-positions/count``airports->getLight(string $code)` → `AirportLight``GET /api/static/airports/{code}/light``airports->getFull(string $code)` → `AirportFull``GET /api/static/airports/{code}/full``airlines->getLight(string $icao)` → `AirlineLight``GET /api/static/airlines/{icao}/light``usage->get(UsagePeriod = P24H)` → `list``GET /api/usage``historic->positions->getLight/getFull/getCount(HistoricFlightPositionsQuery)``GET /api/historic/flight-positions/{light,full,count}``historic->events->getLight/getFull(FlightEventsQuery)``GET /api/historic/flight-events/{light,full}``flightSummary->getLight/getFull/getCount(FlightSummaryQuery)``GET /api/flight-summary/{light,full,count}``flightTracks->get(string $flightId)` → `list``GET /api/flight-tracks`Query value objects
-------------------

[](#query-value-objects)

- `FlightPositionsQuery` — all live-position filters (`bounds`, `callsigns`, `categories`, `altitudeRanges`, `gspeed`, `limit`, …); serialises to the API's CSV query format.
- `Boundary` — `north`, `south`, `west`, `east`; validates latitude/longitude ranges and `north > south`.
- `AltitudeRange` — `minAltitude`, `maxAltitude`.
- `HistoricFlightPositionsQuery` — like `FlightPositionsQuery` plus a required `timestamp`(`int` unix seconds or `\DateTimeInterface`).
- `FlightSummaryQuery` — flight filters plus `flightDatetimeFrom`/`flightDatetimeTo`(`string`|`\DateTimeInterface`), `sort`, `limit`.
- `FlightEventsQuery` — required `flightIds` and `eventTypes` (`FlightEventType`|`string`).
- Enums: `UsagePeriod` (`24h`, `7d`, `30d`, `1y`), `FlightCategory` (service-type codes), `FlightEventType` (`takeoff`, `landed`, …).

Error handling
--------------

[](#error-handling)

```
Fr24Exception (extends \RuntimeException)
├── MissingApiTokenException   blank API token passed to the Transport constructor
├── TransportException         PSR-18 client failure (network/timeout) or JSON decode error
└── ApiException               non-2xx response
    ├── BadRequestException        400
    ├── AuthenticationException    401
    ├── PaymentRequiredException   402
    ├── NotFoundException          404
    └── RateLimitException         429

```

Any unmapped 4xx/5xx status surfaces as the base `ApiException`, which exposes the PSR-7 response:

```
use Lookyman\Flightradar24\Exception\ApiException;

try {
    $airport = $client->airports->getFull('ZZZ');
} catch (ApiException $e) {
    $status = $e->response->getStatusCode();
    $body = json_decode((string) $e->response->getBody(), true);
}
```

License
-------

[](#license)

MIT. See [LICENSE](LICENSE).

###  Health Score

38

—

LowBetter than 83% of packages

Maintenance90

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

48d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f068d60b6e86ba2222bff60b7b27dea830d666a3e2f86eb50d6c1c1c1c8167ad?d=identicon)[lookyman](/maintainers/lookyman)

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/lookyman-flightradar24/health.svg)

```
[![Health](https://phpackages.com/badges/lookyman-flightradar24/health.svg)](https://phpackages.com/packages/lookyman-flightradar24)
```

###  Alternatives

[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k16](/packages/tempest-framework)[telnyx/telnyx-php

Official Telnyx PHP SDK — APIs for Voice, SMS, MMS, WhatsApp, Fax, SIP Trunking, Wireless IoT, Call Control, and more. Build global communications on Telnyx's private carrier-grade network.

36789.4k2](/packages/telnyx-telnyx-php)[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

85036.3k](/packages/flow-php-flow)[mollie/mollie-api-php

Mollie API client library for PHP. Mollie is a European Payment Service provider and offers international payment methods such as Mastercard, VISA, American Express and PayPal, and local payment methods such as iDEAL, Bancontact, SOFORT Banking, SEPA direct debit, Belfius Direct Net, KBC Payment Button and various gift cards such as Podiumcadeaukaart and fashioncheque.

60316.0M89](/packages/mollie-mollie-api-php)[getbrevo/brevo-php

Official Brevo provided RESTFul API V3 php library

1003.9M50](/packages/getbrevo-brevo-php)[laudis/neo4j-php-client

Neo4j-PHP-Client is the most advanced PHP Client for Neo4j

185702.8k44](/packages/laudis-neo4j-php-client)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
