canonical: https://jentic.com/apis/amadeus.com/amadeus-airport-nearest-relevant

# Amadeus Airport Nearest Relevant

The Amadeus Airport Nearest Relevant API returns the commercial airports closest to a given latitude and longitude, ranked by relevance. The single GET endpoint at /reference-data/locations/airports takes coordinates plus an optional radius and returns each airport with its IATA code, distance, time zone, and an analytics score that reflects passenger traffic. It is used to default a flight search to the nearest airport and to suggest secondary airports for fare comparisons.

## For AI agents

Find the nearest commercial airports to a coordinate, ranked by traffic. Agents call /reference-data/locations/airports with lat/long to seed flight searches with the right origin.

## Scope

Does not return flight schedules, terminal layouts, or non-commercial airfields - use for finding commercial airports closest to a coordinate only.

## Capabilities

- Look up the nearest commercial airports to a latitude and longitude pair
- Filter results to a configurable radius in kilometres around the coordinate
- Rank nearby airports by analytics score so high-traffic hubs appear first
- Retrieve each airport's IATA code, name, and distance for direct use in a flight search
- Return time zone metadata so layover times can be computed without a second call
- Suggest secondary airports within range for fare-comparison searches

## Use cases

### Geo-Aware Flight Search

When a user opens a travel app the device exposes GPS coordinates but not an airport code. The /reference-data/locations/airports endpoint converts those coordinates into the closest commercial airport with an IATA code, which can then seed the origin field of a flight search. Sorting by analytics score keeps the default to the busiest airport rather than a small regional one.

Example prompt: Call /reference-data/locations/airports with latitude=48.85, longitude=2.35 and return the IATA code of the highest-ranked airport.

### Multi-Airport Fare Comparison

Frequent travellers compare fares across several airports near their home. By calling the lookup with a radius of 100 km the API returns every commercial airport in range so the front end can run parallel flight searches against each origin. This catches cheaper fares from secondary airports that a single-airport search would miss.

Example prompt: Get every airport within 100 km of latitude=51.51, longitude=-0.13 and run a fare comparison across all returned IATA codes.

### Travel Manager Coordinate Mapping

Corporate travel platforms often store meeting venues by address, not by airport. Geocode the address, then call the lookup to get the nearest airport for use in the booking flow. The endpoint returns distance and time zone in the same response, which is enough to flag long ground transfers in an itinerary.

Example prompt: After geocoding the venue address, fetch the closest airport for those coordinates and warn the user if the distance exceeds 80 km.

### Agent-Driven Geo Booking

An AI travel agent given 'book a flight from where I am' needs to translate the user's GPS into an airport before calling Flight Offers Search. Through Jentic the agent searches for 'nearest airport to coordinates', loads the schema, and executes the lookup. The IATA code from the top result then feeds directly into the next operation.

Example prompt: Use Jentic to find the airport-nearest-relevant operation, pass the device coordinates, and feed the resulting IATA code into a Flight Offers Search call.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /reference-data/locations/airports | Find airports nearest to a coordinate, ranked by traffic |

## Key resources

- **Airports by Coordinate** — GET commercial airports nearest to a latitude and longitude, ranked by relevance.

## Why Jentic

- **Setup:** Wiring the Airport Nearest Relevant API by hand means running Amadeus OAuth2 to get a token, targeting the test.api.amadeus.com/v1 host, and refreshing that token yourself. Through Jentic you install once, import the Airport Nearest Relevant API from the API Directory, store the OAuth2 credentials once, and your agent calls it.
- **Permission scoping:** The Airport Nearest Relevant API exposes a single read-only /reference-data/locations/airports endpoint whose coordinates travel as query parameters rather than a path resource, so limit the agent to that one operation. You choose whether the agent may call it, and no other operations exist to add.
- **Credential handling:** Your Amadeus OAuth2 credentials are stored once, encrypted, by your own Jentic One instance and injected at execution time. They never enter the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'find commercial airports nearest a coordinate', and Jentic returns the matching Amadeus operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Amadeus Airport & City Search** — Looks up airports by keyword rather than by latitude and longitude.
- **Amadeus Flight Availabilities Search** — Searches available flights between two IATA codes resolved by the lookup.
- **Amadeus Flight Cheapest Date Search** — Finds the cheapest dates from the airport returned by the lookup.

## FAQ

### What authentication does the Airport Nearest Relevant API use?

The API uses the Amadeus OAuth 2.0 client-credentials flow. Exchange API key and secret for a bearer token at the Amadeus token endpoint and send it on /reference-data/locations/airports calls. Jentic stores the credentials in the encrypted vault and refreshes tokens automatically.

### Can I limit the search to a specific radius?

Yes. The endpoint accepts a radius parameter in kilometres so you can return only airports within, for example, 100 km of the supplied coordinate. The default radius and maximum allowed value are documented in the Amadeus self-service portal.

### What are the rate limits for the Airport Nearest Relevant API?

Rate limits are not declared in the OpenAPI spec and depend on the Amadeus contract tier. The lookup is read-only and cacheable, so cache responses keyed on coordinate and radius to stay well under the per-second cap for your account.

### How do I find the nearest airport through Jentic?

Run pip install jentic, then search Jentic for 'nearest airport to coordinates'. The /reference-data/locations/airports operation surfaces with its input schema; pass latitude, longitude, and radius and execute. The IATA code in the top result can flow straight into a Flight Offers Search.

### Does the API return more than just the IATA code?

Yes. Each result includes the airport name, IATA code, distance from the supplied coordinate, time zone, and an analytics score that reflects passenger traffic, all in a single response.

### Is the Airport Nearest Relevant API free?

Amadeus self-service APIs include a free test environment with quota limits and a paid production tier. Production access is contracted with Amadeus and pricing scales with transaction volume - check current rates in the developer portal.

### Can I limit what my agent is allowed to do with the Airport Nearest Relevant API?

Yes. Jentic One is self-hosted, so your own rules decide which operations and credentials your agent may use. This API exposes only a single read-only operation, a GET on /reference-data/locations/airports that takes the coordinate and radius as query parameters, and you choose whether the agent may call it. Because no other operations exist, that lookup is the full extent of what the agent can reach, and your stored Amadeus OAuth2 credentials are injected at execution time rather than exposed to the agent.
