booking.com

booking.com · Acciones GPT

Amadeus Flight Offers Search API

Fetch flight offers based on search criteria using the Amadeus API.

  • GET /v2/shopping/flight-offersSearch for flight offers based on specified criteria.
Esquema original API
{
  "openapi": "3.0.0",
  "info": {
    "title": "Amadeus Flight Offers Search API",
    "description": "Fetch flight offers based on search criteria using the Amadeus API.",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://api.amadeus.com",
      "description": "Production environment for Amadeus API"
    }
  ],
  "paths": {
    "/v2/shopping/flight-offers": {
      "get": {
        "operationId": "searchFlightOffers",
        "summary": "Search for flight offers based on specified criteria.",
        "parameters": [
          {
            "name": "originLocationCode",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "destinationLocationCode",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "departureDate",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight offers successfully fetched.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "meta": {
                      "type": "object",
                      "properties": {
                        "count": {
                          "type": "integer"
                        },
                        "links": {
                          "type": "object",
                          "properties": {
                            "self": {
                              "type": "string"
                            }
                          }
                        }
                      }
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/FlightOffer"
                      }
                    },
                    "dictionaries": {
                      "$ref": "#/components/schemas/Dictionaries"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "FlightOffer": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "source": {
            "type": "string"
          },
          "instantTicketingRequired": {
            "type": "boolean"
          },
          "nonHomogeneous": {
            "type": "boolean"
          },
          "oneWay": {
            "type": "boolean"
          },
          "lastTicketingDate": {
            "type": "string",
            "format": "date"
          },
          "numberOfBookableSeats": {
            "type": "integer"
          }
        }
      }
    }
  }
}