{
"count": 3,
"items": [
{
"route": "JFK-LHR",
"from": {
"iata": "JFK",
"icao": "KJFK",
"name": "John F. Kennedy International Airport",
"city": "New York",
"countryCode": "US",
"latitude": 40.639447,
"longitude": -73.779317
},
"to": {
"iata": "LHR",
"icao": "EGLL",
"name": "London Heathrow Airport",
"city": "London",
"countryCode": "GB",
"latitude": 51.470748,
"longitude": -0.459909
},
"greatCircleKm": 5539.8,
"miles": 3442.3,
"nauticalMiles": 2991.3,
"initialBearingDeg": 51.4,
"initialBearingCompass": "NE",
"estimatedFlightMinutes": 430,
"estimatedFlightTime": "7h 10m",
"estimateAssumptions": "Estimate only: block time = distance / 830 km/h + 30 min taxi/climb/descent overhead. Not a schedule.",
"fromTimezone": "America/New_York",
"toTimezone": "Europe/London",
"timezoneDifferenceHours": 5,
"co2": {
"defraCategory": "long-haul",
"kgPerPassenger": 846.6,
"kgPerPassengerWithoutRF": 501,
"kgPerPassengerByClass": {
"economy": 648.4,
"premiumEconomy": 1037.4,
"business": 1880.2,
"first": 2593.4
},
"factorKgPerPassengerKm": 0.15282,
"includesRadiativeForcing": true,
"source": "UK DESNZ/DEFRA GHG conversion factors 2025, Business travel- air (direct flights, 8% distance uplift included)"
},
"scrapedAt": "2026-11-11T09:20:56Z"
},
{
"route": "SOF-VAR",
"from": {
"iata": "SOF",
"icao": "LBSF",
"name": "Sofia Airport",
"city": "Sofia",
"countryCode": "BG",
"latitude": 42.696357,
"longitude": 23.417671
},
"to": {
"iata": "VAR",
"icao": "LBWN",
"name": "Varna Airport",
"city": "Varna",
"countryCode": "BG",
"latitude": 43.232101,
"longitude": 27.8251
},
"greatCircleKm": 363.5,
"miles": 225.9,
"nauticalMiles": 196.3,
"initialBearingDeg": 79.1,
"initialBearingCompass": "E",
"estimatedFlightMinutes": 56,
"estimatedFlightTime": "0h 56m",
"estimateAssumptions": "Estimate only: block time = distance / 830 km/h + 30 min taxi/climb/descent overhead. Not a schedule.",
"fromTimezone": "Europe/Sofia",
"toTimezone": "Europe/Sofia",
"timezoneDifferenceHours": 0,
"co2": {
"defraCategory": "international",
"kgPerPassenger": 51.8,
"kgPerPassengerWithoutRF": 30.6,
"kgPerPassengerByClass": {
"economy": 39.7,
"premiumEconomy": 63.5,
"business": 115.1,
"first": 158.7
},
"factorKgPerPassengerKm": 0.14253,
"includesRadiativeForcing": true,
"source": "UK DESNZ/DEFRA GHG conversion factors 2025, Business travel- air (direct flights, 8% distance uplift included)"
},
"scrapedAt": "2026-11-11T09:20:56Z"
},
{
"route": "LAX-NRT",
"from": {
"iata": "LAX",
"icao": "KLAX",
"name": "Los Angeles International Airport",
"city": "Los Angeles",
"countryCode": "US",
"latitude": 33.942501,
"longitude": -118.407997
},
"to": {
"iata": "NRT",
"icao": "RJAA",
"name": "Narita International Airport",
"city": "Narita",
"countryCode": "JP",
"latitude": 35.76858,
"longitude": 140.388714
},
"greatCircleKm": 8753.4,
"miles": 5439.1,
"nauticalMiles": 4726.4,
"initialBearingDeg": 305.7,
"initialBearingCompass": "NW",
"estimatedFlightMinutes": 663,
"estimatedFlightTime": "11h 03m",
"estimateAssumptions": "Estimate only: block time = distance / 830 km/h + 30 min taxi/climb/descent overhead. Not a schedule.",
"fromTimezone": "America/Los_Angeles",
"toTimezone": "Asia/Tokyo",
"timezoneDifferenceHours": 17,
"co2": {
"defraCategory": "international",
"kgPerPassenger": 1247.6,
"kgPerPassengerWithoutRF": 737,
"kgPerPassengerByClass": {
"economy": 955.5,
"premiumEconomy": 1528.8,
"business": 2771,
"first": 3822
},
"factorKgPerPassengerKm": 0.14253,
"includesRadiativeForcing": true,
"source": "UK DESNZ/DEFRA GHG conversion factors 2025, Business travel- air (direct flights, 8% distance uplift included)"
},
"scrapedAt": "2026-11-11T09:20:56Z"
}
]
}
curl --location --request GET 'https://zylalabs.com/api/14790/airport+database+api/38334/airport+database+api?mode=distance&routes=JFK-LHR,SOF-VAR,LAX-NRT&codes=JFK,LHR,SOF&latitude=43.2321&longitude=27.8251&radiusKm=150&scheduledServiceOnly=true&includeTaf=false&includeFaaDelays=true&activeAirlinesOnly=true&maxItems=100' --header 'Authorization: Bearer YOUR_API_KEY'
注册后,每个开发者都会被分配一个个人 API 访问密钥,这是一个唯一的字母和数字组合,用于访问我们的 API 端点。要使用 机场数据库 API 进行身份验证,只需在 Authorization 标头中包含您的 bearer token。
| 标头 | 描述 |
|---|---|
授权
|
必需
应为 Bearer access_key. 订阅后,请查看上方的"您的 API 访问密钥"。
|
每个请求最多100个结果。使用maxItems参数进行设置
每个请求从公共源收集实时数据 相同的请求可以从缓存中服务最长6小时
列表参数接受多个用逗号分隔的值,例如:伦敦,巴黎
该端点接受这些查询参数,均为可选:mode、routes、codes、query、country、types、latitude、longitude、radiusKm、scheduledServiceOnly、includeTaf、includeFaaDelays、activeAirlinesOnly、maxItems。模式:距离 = 球面距离、航线的航向和预计飞行时间,例如JFK-LHR。查找 = 通过IATA/ICAO代码获取完整的机场详情。搜索 = 按文本、国家或类型查找机场。附近 = 在特定纬度/经度周围的机场。天气 = 最新的METAR(和可选的TAF)机场数据。航线:机场对的IATA或ICAO代码,例如JFK-LHR、SOF-VAR、LAX-NRT。接受的分隔符:破折号、'to'、'>'或空格。多个值:用逗号分隔。
每个端点返回有关机场的详细信息,包括IATA/ICAO代码、名称、位置、航程、预计飞行时间和实时METAR/TAF天气数据
关键字段包括机场代码(IATA,ICAO)、名称、地理坐标(纬度,经度)、航程距离指标(大圆公里,英里,海里)以及预计飞行时间
响应以JSON格式构建,包含结果的“计数”和“项目”数组,其中包含详细的机场信息,包括航线和距离计算
该API提供有关机场位置、机场之间的航班距离、预计飞行时间和指定机场的当前天气状况(METAR/TAF)的信息
典型的使用案例包括航班规划 旅行行程创建 物流的距离计算以及获取机场的实时天气更新
机场数据库 + 一次调用中的飞行距离:IATA/ICAO 查询、靠近某一点的机场、大圆距离、飞行时间和每位乘客的二氧化碳排放量(官方英国DEFRA 2025 数据),加上实时METAR/TAF。开放数据,无需API密钥