ADS-B Exchange v2 compatibility
Use FlyItalyADSB in place of the ADS-B Exchange v2 API: same paths, same key headers, same JSON (ac, msg, now, total, ctime, ptime). Change the host and the key, nothing else.
Updated
The same data answers in two formats, with the same key:
- Our API,
https://api.flyitalyadsb.com/v2: our own conventions (radius in kilometres,nowin seconds, one aircraft as an object). The rest of these docs describe it. - The ADS-B Exchange v2 format,
https://api.flyitalyadsb.com/api/aircraft/v2: the paths, key headers and JSON of the ADS-B Exchange v2 API, for code already written for it.
Plans, limits and counting are the same: a request counts once, whichever format it uses. New code can use either; the MCP server and the Apify Actor use our API.
Switching
Change the host and put your FlyItalyADSB key in the header you already send:
| You call | Call instead |
|---|---|
https://adsbexchange.com/api/aircraft/v2/… | https://api.flyitalyadsb.com/api/aircraft/v2/… |
https://gateway.adsbexchange.com/api/aircraft/v2/… | https://api.flyitalyadsb.com/api/aircraft/v2/… |
https://adsbexchange-com1.p.rapidapi.com/v2/… | https://api.flyitalyadsb.com/api/aircraft/v2/… |
The key is read from api-auth (ADS-B Exchange), X-RapidAPI-Key (RapidAPI) or X-Api-Key. X-RapidAPI-Host can stay; it is ignored. No key yet? Get one free.
Before, on RapidAPI:
curl -H "X-RapidAPI-Key: RAPIDAPI_KEY" -H "X-RapidAPI-Host: adsbexchange-com1.p.rapidapi.com" \
https://adsbexchange-com1.p.rapidapi.com/v2/lat/45.46/lon/9.19/dist/25/
After:
curl -H "X-RapidAPI-Key: YOUR_FLYITALYADSB_KEY" \
https://api.flyitalyadsb.com/api/aircraft/v2/lat/45.46/lon/9.19/dist/25/
Endpoints
| Endpoint | Returns |
|---|---|
/hex/{hex} | aircraft by ICAO address; if not seen now, its last known position from the last 48 hours |
/icao/{hex} | aircraft by ICAO address, only if seen now |
/callsign/{callsign} | aircraft by callsign |
/registration/{reg} | aircraft by registration |
/sqk/{squawk} | aircraft squawking a code, e.g. 7700 |
/lat/{lat}/lon/{lon}/dist/{nm} | aircraft within nm nautical miles of a point, each with dst (NM) and dir (degrees) from the point |
/point/{lat}/{lon}/{nm} | the same, with the radius as the last segment |
/closest/{lat}/{lon}/{nm} | the one aircraft closest to the point within nm, with dst and dir |
/mil | military aircraft |
hex, icao, callsign, registration and sqk take up to 100 values separated by commas: /hex/4ca7b4,3c6444. A trailing slash is fine, as on ADS-B Exchange. Case does not matter. A value that cannot match anything (/hex/zzz) finds nothing: 200 with an empty list.
Also available here, in the same format: /ladd, /pia, /type/{type} and the aliases /reg/ and /squawk/.
The answer
A list answers in the format of readsb’s jv2 output, the one ADS-B Exchange serves, with the fields in the same order. A real answer for 25 NM around Milan, shortened to one aircraft and a few of its fields:
{
"ac": [
{"hex": "34608f", "type": "adsb_icao", "flight": "IBE06CZ ", "r": "EC-NAZ", "t": "A20N",
"alt_baro": 625, "gs": 154.0, "track": 349.0, "lat": 45.612255, "lon": 8.727882,
"dst": 21.442, "dir": 295.4}
],
"msg": "No error",
"now": 1793120254002,
"total": 17,
"ctime": 1793120254002,
"ptime": 32
}
nowandctime: Unix time in milliseconds.ptime: how long the request took, in milliseconds.- The aircraft are readsb’s records, with the same fields as on ADS-B Exchange, unchanged; they are described in Fields and units.
dstanddirare only in the radius queries, computed with readsb’s own formulas, so they are the same numbers ADS-B Exchange gives. /hexwith one value returns the aircraft object itself, as ADS-B Exchange does, withnow(the time it was last seen) andctime. Alongside it areac,msg,totalandptime, so code that reads the list works too. A trailing comma (/hex/4ca7b4,) returns the list only./hexalso finds an aircraft we are not receiving now: its last position from the last 48 hours, withseenandseen_posin seconds since then.- Nothing found: status
200with"ac": []and"total": 0.
Limits and errors
The plans and limits are those of the rest of the API (Limits and errors). The radius is checked in kilometres. In nautical miles:
| Plan | Maximum radius |
|---|---|
| Free | 270 NM (500 km), above the 250 NM that ADS-B Exchange documents |
| Starter | 540 NM (1,000 km) |
| Pro, Business | no maximum |
Errors carry msg, as on ADS-B Exchange, followed by the same fields as in our API (help, plans, and max_radius_nm with max_radius_km when the radius is above the plan). The status codes are ours:
| Status | When |
|---|---|
400 | coordinates or radius are not valid numbers, or more than 100 values; not counted |
401 | missing or invalid key |
403 | radius above the plan |
404 | the path does not exist; not counted |
429 | per-minute limit or monthly quota; see Retry-After |
Plan and usage are in the X-FIA-* headers of every answer, as in our API.
What is not available
- The routes of the ADS-B Exchange enterprise gateway:
/all,/minimal/…,/nohex/…,/airport/…,/geospatial/…,/operations/…,/traces/…, and thePOSTversions of the lookups. For the track of an aircraft over a day, use/v2/history. - The aircraft are those our network receives.
/hexlooks back 48 hours like ADS-B Exchange, but only in our own tracks.