Find airports near any latitude/longitude via FlightAware AeroAPI, pay-per-request at $0.008.
What it does
This endpoint returns airports near a given geographic coordinate using FlightAware AeroAPI data, proxied through StableTravel's pay-per-request infrastructure. It accepts required `latitude` and `longitude` query parameters, with optional `radius`, `only_iap` (instrument approach procedures only), pagination via `max_pages` and `cursor`. The response includes an array of airport objects with ICAO/IATA/LID codes, name, type, elevation, city, state, country, timezone, coordinates, distance from the query point, and heading. Pagination links and page count are also returned.
Pricing is $0.008 per request, settled via MPP (Tempo method on chain 4217) or x402 protocol using USDC. No API keys, OAuth tokens, or subscriptions are required — payment serves as authentication. The endpoint is part of StableTravel's broader travel API suite covering flights (Amadeus GDS + Google Flights), hotels, activities, transfers, and extensive FlightAware operational data including real-time tracking, airport delays, weather (METAR/TAF), flight history, and disruption counts.
The endpoint is live, returning a 402 MPP payment challenge on unauthenticated requests. A full OpenAPI 3.1 schema is published at `/openapi.json` with detailed response types for the airports array. Use `npx agentcash fetch` for automatic payment handling.
Capabilities
Use cases
- —Find the closest airports to a user's current GPS position
- —Determine alternate airports near a destination for flight planning
- —Build a travel agent that suggests airports based on hotel or activity locations
- —Power a map UI showing airports within a radius of a point of interest
- —Pre-flight planning: identify diversion airports near a route waypoint
Fit
Best for
- —AI travel agents needing airport discovery by coordinates
- —Applications requiring FlightAware-quality airport data without a subscription
- —Autonomous agents that pay per call with no credential setup
- —Geo-aware travel planning workflows
Not for
- —Bulk downloading the entire global airport database (use the /api/flightaware/airports list endpoint instead)
- —Flight booking or ticketing (use the Amadeus flight endpoints on the same platform)
- —Free-tier or zero-cost airport lookups
Quick start
npx agentcash fetch "https://stabletravel.dev/api/flightaware/airports/nearby?latitude=40.6413&longitude=-73.7781&radius=50"Example
Response
{
"links": {
"next": null
},
"airports": [
{
"city": "New York",
"name": "John F Kennedy Intl",
"type": "Airport",
"state": "NY",
"heading": 200,
"code_lid": "JFK",
"distance": 0.1,
"latitude": 40.6398,
"timezone": "America/New_York",
"wiki_url": null,
"code_iata": "JFK",
"code_icao": "KJFK",
"elevation": 13,
"longitude": -73.7789,
"airport_code": "KJFK",
"alternatives": null,
"country_code": "US",
"airport_flights_url": null
}
],
"num_pages": 1
}Endpoint
Quality
Full OpenAPI 3.1 schema with detailed response types, clear pricing ($0.008/request), live 402 MPP challenge captured, comprehensive documentation including parameter descriptions and guidance. Only minor gap: no example response in the spec itself (inferred from schema).
Citations
- —Endpoint price is $0.008 per requesthttps://stabletravel.dev/openapi.json
- —Endpoint is live, returning 402 MPP payment challengehttps://stabletravel.dev/api/flightaware/airports/nearby
- —Payment via USDC on Tempo (chain 4217) or x402 protocol, no API keys neededhttps://stabletravel.dev/openapi.json
- —Required parameters are latitude and longitude; optional parameters include radius, only_iap, max_pages, cursorhttps://stabletravel.dev/openapi.json
- —Response includes airport_code, name, distance, heading, and other airport metadatahttps://stabletravel.dev/openapi.json
- —Part of StableTravel suite covering flights, hotels, activities, transfers, and FlightAware datahttps://stabletravel.dev