flight-number-query
China Domestic Flight Number Lookup API
Look up China domestic routes, airlines, airports, planned times and reference operating days by flight number, with pagination.
Usage Cost
15 coins/call
Quick Start
Use a unified response envelope and call directly from your backend.
https://openapi.toolkk.com/v1/flight-number-querycURL Example
curl --request GET \
--url 'https://openapi.toolkk.com/v1/flight-number-query' \
--header 'Content-Type: application/json' \
--header 'X-API-Key: YOUR_API_KEY' \
--data '{\n "STRING": "AY6863",\n "PAGE_NUM": "1"\n}'Python Example
import os
import requests
url = "https://openapi.toolkk.com/v1/flight-number-query"
payload = {
"STRING": "AY6863",
"PAGE_NUM": "1"
}
headers = {
"Content-Type": "application/json",
"X-API-Key": os.getenv("TOOLKK_API_KEY", "YOUR_API_KEY"),
}
response = requests.get(url, headers=headers, params=payload, timeout=30)
response.raise_for_status()
print(response.json())Go Example
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
endpoint := "https://openapi.toolkk.com/v1/flight-number-query"
payload := []byte("{\n \"STRING\": \"AY6863\",\n \"PAGE_NUM\": \"1\"\n}")
req, err := http.NewRequest("GET", endpoint, bytes.NewBuffer(payload))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-Key", "YOUR_API_KEY")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
body, err := io.ReadAll(resp.Body)
if err != nil {
panic(err)
}
fmt.Println(string(body))
}Java Example
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class ToolkkExample {
public static void main(String[] args) throws Exception {
String payload = "{\n \"STRING\": \"AY6863\",\n \"PAGE_NUM\": \"1\"\n}";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://openapi.toolkk.com/v1/flight-number-query"))
.method("GET", HttpRequest.BodyPublishers.ofString(payload))
.header("Content-Type", "application/json")
.header("X-API-Key", "YOUR_API_KEY")
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
}
}PHP Example
<?php
$endpoint = 'https://openapi.toolkk.com/v1/flight-number-query';
$payload = "{\n \"STRING\": \"AY6863\",\n \"PAGE_NUM\": \"1\"\n}";
$ch = curl_init($endpoint);
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => [
'Content-Type: application/json',
'X-API-Key: YOUR_API_KEY',
],
CURLOPT_POSTFIELDS => $payload,
]);
$response = curl_exec($ch);
if ($response === false) {
throw new RuntimeException(curl_error($ch));
}
curl_close($ch);
echo $response;Response Example
{
"索引条件": {
"索引字符串": "AY6863"
},
"索引状态": "一切都如您的神机妙算,天下均在您的掌握之中",
"索引总数量": "2",
"索引总页数": "0",
"索引页容量": "10",
"索引页序号": "1",
"索引实体信息": [
{
"数据编码": "0000618A49CF960D91DD25A2C4B6FC75",
"出发洲际_中文": "亚洲",
"出发洲际_英文": "AISA",
"出发国家_中文": "泰国",
"出发国家_英文": "THAILAND",
"出发城市": "普吉岛",
"出发城市缩写": "HKT",
"出发城市拼音": "PHUKET",
"抵达洲际_中文": "亚洲",
"抵达洲际_英文": "AISA",
"抵达国家_中文": "泰国",
"抵达国家_英文": "THAILAND",
"抵达城市": "曼谷",
"抵达城市缩写": "BKK",
"抵达城市拼音": "BANGKOK",
"航班号": "AY6863",
"航空公司": "芬兰航空",
"机型": "空客320",
"开始时间": "17:30",
"结束时间": "19:00",
"起飞机场": "素万那普国际机场",
"抵达机场": "普吉国际机场D",
"本周参考航班": "日,四,六,二,三,五,一",
"准点率": ""
}
]
}Examples illustrate the response structure. Actual results depend on the API response.
- Authentication
- Send X-API-Key in request headers
- Rate limit
- 60 req/min
- Timeout
- 30000 ms
Send your API Key in the X-API-Key header from your backend.
Check both HTTP status and business fields before treating a call as successful.
Use retries and backoff together with rate limits in high-frequency scenarios.
Request Fields
Send requests from your server with the key in the X-API-Key header.
Request Fields
Fields are read from the API schema. Missing descriptions and examples are marked as unspecified.
| Path | Type | Required | Description | Sample |
|---|---|---|---|---|
| STRING | string | Yes | 搜索字符串,如:AY6863 | AY6863 |
| PAGE_NUM | string | Yes | 搜索结果页码序列,如:1 | 1 |
Request Example
{
"STRING": "AY6863",
"PAGE_NUM": "1"
}- Authentication
- Send X-API-Key in request headers
- Rate limit
- 60 req/min
- Timeout
- 30000 ms
Response Fields
Examples illustrate the response structure. Actual results depend on the API response.
Response Fields
Fields are read from the API schema. Missing descriptions and examples are marked as unspecified.
| Path | Type | Required | Description | Sample |
|---|---|---|---|---|
| 索引条件 | object | No | Unspecified | Unspecified |
| 索引条件.索引字符串 | string | No | Unspecified | AY6863 |
| 索引状态 | string | No | Unspecified | 一切都如您的神机妙算,天下均在您的掌握之中 |
| 索引总数量 | string | No | Unspecified | 2 |
| 索引总页数 | string | No | Unspecified | 0 |
| 索引页容量 | string | No | Unspecified | 10 |
| 索引页序号 | string | No | Unspecified | 1 |
| 索引实体信息 | array | No | Unspecified | Unspecified |
| 索引实体信息[] | object | Unspecified | Unspecified | Unspecified |
| 索引实体信息[].数据编码 | string | No | Unspecified | 0000618A49CF960D91DD25A2C4B6FC75 |
| 索引实体信息[].出发洲际_中文 | string | No | Unspecified | 亚洲 |
| 索引实体信息[].出发洲际_英文 | string | No | Unspecified | AISA |
| 索引实体信息[].出发国家_中文 | string | No | Unspecified | 泰国 |
| 索引实体信息[].出发国家_英文 | string | No | Unspecified |
API overview
Capabilities, use cases, limitations, and frequently asked questions.
What the API provides
Look up a China domestic flight number to retrieve route information and reference schedules. Records can include departure and arrival cities, airline, airports, planned times, operating days and on-time rate. Pagination statistics accompany the list. A flight number can return several records with different reference schedules.
Where to use it
An itinerary tool can fill in route details for a known flight number. Support teams can check a number supplied by a traveller, and travel applications can let users compare schedule records. Matching a record to a travel date, deduplication, display language and saving an itinerary are handled by your application.
Calling and interpreting results
Send STRING and PAGE_NUM as GET query parameters, for example HU7613 and page 1. Preserve the parameter names shown in the request tab. After checking the business response code, read the record list and pagination statistics. The live response still uses Chinese field names; changing the documentation language does not change the JSON keys. Statistical values can be strings.
Scope and limitations
This request has no date input and cannot establish whether a flight operates, is delayed or is cancelled on a particular day. It does not book tickets. Planned times and operating days are references. Source pagination metadata can report a total page count of string 0 even when the first page contains records; do not discard those records solely for that reason.
Frequently asked questions
Why can one flight number return several records?
Operating days, times or aircraft can differ. Compare each record against the itinerary instead of always selecting the first one.