Aircraft

Aircraft are used to describe what passengers will fly in for a given trip

iata_code
string

The three-character IATA code for the aircraft

Example: "380"
id
string

Duffel's unique identifier for the aircraft

Example: "arc_00009UhD4ongolulWd91Ky"
name
string

The name of the aircraft

Example: "Airbus Industries A380"

Retrieves a paginated list of all aircraft. The results may be returned in any order.

Query parameters

limit
integer

The maximum number of records to return per page. Defaults to 50. May be set to any integer between 1 and 200. For more information on how to paginate through records, see the Pagination section.

Example: 1
Default value: 50
before
string

A cursor pointing to the next page of records. For more information on how to paginate through records, see the Pagination section.

Example: "g2wAAAACbQAAABBBZXJvbWlzdC1LaGFya2l2bQAAAB="
after
string

A cursor pointing to the previous page of records. For more information on how to paginate through records, see the Pagination section.

Example: "g2wAAAACbQAAABBBZXJvbWlzdC1LaGFya2l2bQAAAB="

Endpoint

GET https://api.duffel.com/air/aircraft

Request

curl -X GET --compressed "https://api.duffel.com/air/aircraft?limit=1&before=g2wAAAACbQAAABBBZXJvbWlzdC1LaGFya2l2bQAAAB=&after=g2wAAAACbQAAABBBZXJvbWlzdC1LaGFya2l2bQAAAB=" \
-H "Accept: application/json" \
-H "Accept-Encoding: gzip" \
-H "Duffel-Version: beta" \
-H "Authorization: Bearer <YOUR_ACCESS_TOKEN>"

Response

{
"meta": {
"limit": 50,
"after": "g2wAAAACbQAAABBBZXJvbWlzdC1LaGFya2l2bQAAAB="
},
"data": [
{
"name": "Airbus Industries A380",
"id": "arc_00009UhD4ongolulWd91Ky",
"iata_code": "380"
}
]
}

Retrieves an aircraft by its ID

URL parameters

id
string
required

Duffel's unique identifier for the aircraft

Example: "arc_00009UhD4ongolulWd91Ky"

Endpoint

GET https://api.duffel.com/air/aircraft/{id}

Request

curl -X GET --compressed "https://api.duffel.com/air/aircraft/{id}" \
-H "Authorization: Bearer <YOUR_ACCESS_TOKEN>"

Response

{
"data": {
"name": "Airbus Industries A380",
"id": "arc_00009UhD4ongolulWd91Ky",
"iata_code": "380"
}
}