{
  "openapi": "3.0.0",
  "paths": {
    "/v1": {
      "get": {
        "operationId": "AppController_getHello_v1",
        "parameters": [],
        "responses": {
          "200": {
            "description": ""
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "tags": [
          "App"
        ]
      }
    },
    "/v1/auth/login": {
      "post": {
        "description": "Login",
        "operationId": "AuthController_login_v1",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoginDTO"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginEntity"
                }
              }
            }
          },
          "401": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "404": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "summary": "Login",
        "tags": [
          "Authentication"
        ]
      }
    },
    "/v1/auth/register": {
      "post": {
        "description": "Create a new user",
        "operationId": "AuthController_register_v1",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterDTO"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RegisterEntity"
                }
              }
            }
          },
          "409": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "summary": "Register",
        "tags": [
          "Authentication"
        ]
      }
    },
    "/v1/auth/@me": {
      "get": {
        "description": "Get current user",
        "operationId": "AuthController_getCurrentUser_v1",
        "parameters": [],
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserEntity"
                }
              }
            }
          },
          "404": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get current user",
        "tags": [
          "Authentication"
        ]
      }
    },
    "/v1/airports": {
      "get": {
        "description": "Get all airports. We do not recommend using this route without any search query. This route has over 20k records",
        "operationId": "AirportsController_getAirports_v1",
        "parameters": [
          {
            "name": "search",
            "required": false,
            "in": "query",
            "description": "Search query for airport. Can be iata, ident(icao), name or a part of any these. Searching is case insensitive",
            "schema": {
              "example": "VIDP",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AirportEntity"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "summary": "Get all airports",
        "tags": [
          "Airports"
        ]
      }
    },
    "/v1/airlines": {
      "get": {
        "description": "Get airlines.  Has over 800 records, only has commerical airlines.",
        "operationId": "AirlinesController_getAirlines_v1",
        "parameters": [
          {
            "name": "search",
            "required": false,
            "in": "query",
            "description": "The full(or a part of) name, ident or icao. Case Insensitive.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AirlineEntity"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "summary": "Get airlines",
        "tags": [
          "Airlines"
        ]
      }
    },
    "/v1/flights/airline": {
      "post": {
        "description": "Get airline with search query. This doesn't check if the number is correct",
        "operationId": "FlightsController_getAirline_v1",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GetAirlineDTO"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AirlineEntity"
                }
              }
            }
          },
          "404": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get airline",
        "tags": [
          "Flights"
        ]
      }
    },
    "/v1/flights": {
      "get": {
        "description": "Get all flights between two airports for a specific date",
        "operationId": "FlightsController_getFlights_v1",
        "parameters": [
          {
            "name": "from",
            "required": true,
            "in": "query",
            "description": "Departure airport IATA code",
            "schema": {
              "example": "LAX",
              "type": "string"
            }
          },
          {
            "name": "to",
            "required": true,
            "in": "query",
            "description": "Arrival airport IATA code",
            "schema": {
              "example": "JFK",
              "type": "string"
            }
          },
          {
            "name": "date",
            "required": true,
            "in": "query",
            "description": "Flight date in ISO format",
            "schema": {
              "example": "2024-03-20",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightsResponseEntity"
                }
              }
            }
          },
          "401": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get flights between two airports",
        "tags": [
          "Flights"
        ]
      }
    },
    "/v1/flights/bounds": {
      "get": {
        "deprecated": true,
        "description": "Get all aircraft currently flying within a specified geographic bounding box using FlightAware data with comprehensive aircraft details",
        "operationId": "FlightsController_getFlightsInBounds_v1",
        "parameters": [
          {
            "name": "minLat",
            "required": true,
            "in": "query",
            "description": "Minimum latitude of the bounding box",
            "schema": {
              "minimum": -90,
              "maximum": 90,
              "example": 40,
              "type": "number"
            }
          },
          {
            "name": "maxLat",
            "required": true,
            "in": "query",
            "description": "Maximum latitude of the bounding box",
            "schema": {
              "minimum": -90,
              "maximum": 90,
              "example": 50,
              "type": "number"
            }
          },
          {
            "name": "minLng",
            "required": true,
            "in": "query",
            "description": "Minimum longitude of the bounding box",
            "schema": {
              "minimum": -180,
              "maximum": 180,
              "example": -10,
              "type": "number"
            }
          },
          {
            "name": "maxLng",
            "required": true,
            "in": "query",
            "description": "Maximum longitude of the bounding box",
            "schema": {
              "minimum": -180,
              "maximum": 180,
              "example": 10,
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of flights within the specified bounds with detailed aircraft information",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "timestamp": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "bounds": {
                      "type": "object",
                      "properties": {
                        "minLat": {
                          "type": "number"
                        },
                        "maxLat": {
                          "type": "number"
                        },
                        "minLng": {
                          "type": "number"
                        },
                        "maxLng": {
                          "type": "number"
                        }
                      }
                    },
                    "totalAircraft": {
                      "type": "number"
                    },
                    "airborneAircraft": {
                      "type": "number"
                    },
                    "flights": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "ident_icao": {
                            "type": "string",
                            "nullable": true
                          },
                          "ident_iata": {
                            "type": "string",
                            "nullable": true
                          },
                          "callsign": {
                            "type": "string",
                            "nullable": true
                          },
                          "latitude": {
                            "type": "number",
                            "nullable": true
                          },
                          "longitude": {
                            "type": "number",
                            "nullable": true
                          },
                          "altitude": {
                            "type": "number",
                            "nullable": true
                          },
                          "velocity": {
                            "type": "number",
                            "nullable": true
                          },
                          "heading": {
                            "type": "number",
                            "nullable": true
                          },
                          "verticalRate": {
                            "type": "number",
                            "nullable": true
                          },
                          "lastContact": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "isOnGround": {
                            "type": "boolean"
                          },
                          "aircraftType": {
                            "type": "string",
                            "nullable": true
                          },
                          "aircraftTypeFaa": {
                            "type": "string",
                            "nullable": true
                          },
                          "aircraftFamily": {
                            "type": "string",
                            "nullable": true
                          },
                          "manufacturer": {
                            "type": "string",
                            "nullable": true
                          },
                          "model": {
                            "type": "string",
                            "nullable": true
                          },
                          "engineType": {
                            "type": "string",
                            "nullable": true
                          },
                          "engineCount": {
                            "type": "string",
                            "nullable": true
                          },
                          "wakeTurbulenceCategory": {
                            "type": "string",
                            "nullable": true
                          },
                          "aircraftId": {
                            "type": "string",
                            "nullable": true
                          },
                          "aircraftRegistration": {
                            "type": "string",
                            "nullable": true
                          },
                          "ownerIcao": {
                            "type": "string",
                            "nullable": true
                          },
                          "ownerIata": {
                            "type": "string",
                            "nullable": true
                          },
                          "ownerName": {
                            "type": "string",
                            "nullable": true
                          },
                          "operator": {
                            "type": "string",
                            "nullable": true
                          },
                          "operatorIcao": {
                            "type": "string",
                            "nullable": true
                          },
                          "operatorIata": {
                            "type": "string",
                            "nullable": true
                          },
                          "operatorCountry": {
                            "type": "string",
                            "nullable": true
                          },
                          "origin": {
                            "type": "object",
                            "nullable": true,
                            "properties": {
                              "code": {
                                "type": "string",
                                "nullable": true
                              },
                              "codeIcao": {
                                "type": "string",
                                "nullable": true
                              },
                              "codeIata": {
                                "type": "string",
                                "nullable": true
                              },
                              "name": {
                                "type": "string",
                                "nullable": true
                              },
                              "city": {
                                "type": "string",
                                "nullable": true
                              },
                              "timezone": {
                                "type": "string",
                                "nullable": true
                              }
                            }
                          },
                          "destination": {
                            "type": "object",
                            "nullable": true,
                            "properties": {
                              "code": {
                                "type": "string",
                                "nullable": true
                              },
                              "codeIcao": {
                                "type": "string",
                                "nullable": true
                              },
                              "codeIata": {
                                "type": "string",
                                "nullable": true
                              },
                              "name": {
                                "type": "string",
                                "nullable": true
                              },
                              "city": {
                                "type": "string",
                                "nullable": true
                              },
                              "timezone": {
                                "type": "string",
                                "nullable": true
                              }
                            }
                          },
                          "status": {
                            "type": "string",
                            "nullable": true
                          },
                          "progressPercent": {
                            "type": "number",
                            "nullable": true
                          },
                          "routeDistance": {
                            "type": "number",
                            "nullable": true
                          },
                          "filedAirspeedKts": {
                            "type": "number",
                            "nullable": true
                          },
                          "filedAltitude": {
                            "type": "number",
                            "nullable": true
                          },
                          "scheduledOff": {
                            "type": "string",
                            "nullable": true
                          },
                          "scheduledOn": {
                            "type": "string",
                            "nullable": true
                          },
                          "estimatedOff": {
                            "type": "string",
                            "nullable": true
                          },
                          "estimatedOn": {
                            "type": "string",
                            "nullable": true
                          },
                          "actualOff": {
                            "type": "string",
                            "nullable": true
                          },
                          "actualOn": {
                            "type": "string",
                            "nullable": true
                          },
                          "departureDelay": {
                            "type": "string",
                            "nullable": true
                          },
                          "arrivalDelay": {
                            "type": "string",
                            "nullable": true
                          },
                          "gateOrigin": {
                            "type": "string",
                            "nullable": true
                          },
                          "gateDestination": {
                            "type": "string",
                            "nullable": true
                          },
                          "terminalOrigin": {
                            "type": "string",
                            "nullable": true
                          },
                          "terminalDestination": {
                            "type": "string",
                            "nullable": true
                          },
                          "route": {
                            "type": "string",
                            "nullable": true
                          },
                          "type": {
                            "type": "string",
                            "nullable": true
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get flights within geographic bounds(deprecated - will return nothing)",
        "tags": [
          "Flights"
        ]
      }
    },
    "/v1/flights/tracked": {
      "get": {
        "description": "Returns a list of all flights that have been tracked in the system, sorted by most recently created. Limited to 50 most recent flights.",
        "operationId": "FlightsController_getTrackedFlights_v1",
        "parameters": [],
        "responses": {
          "200": {
            "description": "List of tracked flights with complete flight information",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TrackedFlightsResponseEntity"
                }
              }
            }
          },
          "401": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get all tracked flights",
        "tags": [
          "Flights"
        ]
      }
    },
    "/v1/flight/track": {
      "get": {
        "description": "Get the flight path with all position data points for a specific flight",
        "operationId": "FlightController_getFlightTrack_v1",
        "parameters": [
          {
            "name": "iata",
            "required": true,
            "in": "query",
            "description": "IATA flight number",
            "schema": {
              "example": "UA123",
              "type": "string"
            }
          },
          {
            "name": "icao",
            "required": true,
            "in": "query",
            "description": "ICAO flight number",
            "schema": {
              "example": "UAL123",
              "type": "string"
            }
          },
          {
            "name": "date",
            "required": false,
            "in": "query",
            "description": "Flight date (ISO format). Defaults to current date if not provided",
            "schema": {
              "example": "2024-03-20",
              "type": "string"
            }
          },
          {
            "name": "timezone",
            "required": true,
            "in": "query",
            "description": "The timezone from which the request is being made.",
            "schema": {
              "example": "IST",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight track data retrieved successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightTrackResponseEntity"
                }
              }
            }
          },
          "400": {
            "description": "Invalid request parameters or flight not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get flight track/path",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/flight/search": {
      "get": {
        "description": "Search for flights by identifier and optional date. Returns lightweight flight summaries for selection.",
        "operationId": "FlightController_searchFlights_v1",
        "parameters": [
          {
            "name": "iata",
            "required": true,
            "in": "query",
            "description": "IATA flight number",
            "schema": {
              "example": "UA123",
              "type": "string"
            }
          },
          {
            "name": "icao",
            "required": true,
            "in": "query",
            "description": "ICAO flight number",
            "schema": {
              "example": "UAL123",
              "type": "string"
            }
          },
          {
            "name": "date",
            "required": false,
            "in": "query",
            "description": "Flight date (ISO format). Filters flights by date if provided",
            "schema": {
              "example": "2024-03-20",
              "type": "string"
            }
          },
          {
            "name": "timezone",
            "required": true,
            "in": "query",
            "description": "The timezone from which the request is being made.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight search results",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightSearchResponseEntity"
                }
              }
            }
          },
          "400": {
            "description": "Invalid request parameters",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Search flights",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/flight": {
      "get": {
        "description": "Get detailed information about a specific flight including real-time tracking data. Use faFlightId to fetch a specific flight after searching.",
        "operationId": "FlightController_getFlight_v1",
        "parameters": [
          {
            "name": "iata",
            "required": true,
            "in": "query",
            "description": "IATA flight number",
            "schema": {
              "example": "UA123",
              "type": "string"
            }
          },
          {
            "name": "icao",
            "required": true,
            "in": "query",
            "description": "ICAO flight number",
            "schema": {
              "example": "UAL123",
              "type": "string"
            }
          },
          {
            "name": "date",
            "required": false,
            "in": "query",
            "description": "Flight date (ISO format). Defaults to current date if not provided",
            "schema": {
              "example": "2024-03-20",
              "type": "string"
            }
          },
          {
            "name": "timezone",
            "required": true,
            "in": "query",
            "description": "The timezone from which the request is being made.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "forceUpdate",
            "required": false,
            "in": "query",
            "description": "Force update the flight data(used to refresh the flight data)",
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "name": "faFlightId",
            "required": false,
            "in": "query",
            "description": "FlightAware flight ID to fetch a specific flight. Use this after searching for flights to get details of a selected flight.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight details retrieved successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightResponseEntity"
                }
              }
            }
          },
          "400": {
            "description": "Invalid request parameters",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get flight details",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/flight/booking": {
      "post": {
        "description": "Create a new booking for a flight with booking details",
        "operationId": "FlightController_createFlightBooking_v1",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFlightBookingDTO"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Flight booking created successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightBookingEntity"
                }
              }
            }
          },
          "400": {
            "description": "Invalid request parameters or flight not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Create a flight booking",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/flight/booking/{bookingId}": {
      "put": {
        "description": "Update an existing flight booking",
        "operationId": "FlightController_updateFlightBooking_v1",
        "parameters": [
          {
            "name": "bookingId",
            "required": true,
            "in": "path",
            "description": "ID of the booking to update",
            "schema": {
              "example": "booking_abc123",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateFlightBookingDTO"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Flight booking updated successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightBookingEntity"
                }
              }
            }
          },
          "400": {
            "description": "Invalid request parameters",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "404": {
            "description": "Booking not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Update a flight booking",
        "tags": [
          "Flight"
        ]
      },
      "get": {
        "description": "Get details of a specific flight booking",
        "operationId": "FlightController_getFlightBooking_v1",
        "parameters": [
          {
            "name": "bookingId",
            "required": true,
            "in": "path",
            "description": "ID of the booking to retrieve",
            "schema": {
              "example": "booking_abc123",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight booking retrieved successfully",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlightBookingEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "404": {
            "description": "Booking not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get a flight booking",
        "tags": [
          "Flight"
        ]
      },
      "delete": {
        "description": "Delete a flight booking",
        "operationId": "FlightController_deleteFlightBooking_v1",
        "parameters": [
          {
            "name": "bookingId",
            "required": true,
            "in": "path",
            "description": "ID of the booking to delete",
            "schema": {
              "example": "booking_abc123",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight booking deleted successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Booking deleted successfully"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "404": {
            "description": "Booking not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Delete a flight booking",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/flight/booking/flight/{flightId}": {
      "get": {
        "description": "Get all bookings associated with a specific flight",
        "operationId": "FlightController_getFlightBookingsByFlightId_v1",
        "parameters": [
          {
            "name": "flightId",
            "required": true,
            "in": "path",
            "description": "ID of the flight",
            "schema": {
              "example": "flight_abc123",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Flight bookings retrieved successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/FlightBookingEntity"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Flight not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "401": {
            "description": "User is not authenticated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get all bookings for a flight",
        "tags": [
          "Flight"
        ]
      }
    },
    "/v1/profile/@me": {
      "get": {
        "description": "Returns comprehensive statistics about tracked flights including passport data, aircraft stats, airlines, airports, and routes",
        "operationId": "ProfileController_getProfileStats_v1",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Profile statistics including passport data and flight analytics",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProfileStatsResponseEntity"
                }
              }
            }
          },
          "401": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GenericErrorEntity"
                }
              }
            }
          }
        },
        "security": [
          {
            "JWT-auth": []
          }
        ],
        "summary": "Get profile stats",
        "tags": [
          "Profile"
        ]
      }
    }
  },
  "info": {
    "title": "Plane Pal",
    "description": "Plane Pal API Documentation",
    "version": "1.0.0",
    "contact": {}
  },
  "tags": [],
  "servers": [],
  "components": {
    "securitySchemes": {
      "JWT-auth": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "type": "http"
      }
    },
    "schemas": {
      "LoginDTO": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          }
        },
        "required": [
          "email",
          "password"
        ]
      },
      "UserEntity": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "id": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "id"
        ]
      },
      "LoginEntity": {
        "type": "object",
        "properties": {
          "token": {
            "type": "string",
            "description": "JWT token which will be used for all other requests"
          },
          "user": {
            "$ref": "#/components/schemas/UserEntity"
          }
        },
        "required": [
          "token",
          "user"
        ]
      },
      "GenericErrorEntity": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          }
        },
        "required": [
          "message"
        ]
      },
      "RegisterDTO": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "required": [
          "email",
          "password",
          "name"
        ]
      },
      "RegisterEntity": {
        "type": "object",
        "properties": {
          "token": {
            "type": "string",
            "description": "JWT token which will be used for all other requests"
          },
          "user": {
            "$ref": "#/components/schemas/UserEntity"
          }
        },
        "required": [
          "token",
          "user"
        ]
      },
      "AirportType": {
        "type": "string",
        "enum": [
          "small_airport",
          "seaplane_base",
          "medium_airport",
          "large_airport",
          "heliport",
          "closed",
          "balloonport"
        ]
      },
      "AirportEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "ident": {
            "type": "string",
            "example": "VIDP"
          },
          "type": {
            "allOf": [
              {
                "$ref": "#/components/schemas/AirportType"
              }
            ]
          },
          "elevation": {
            "type": "string",
            "description": "Elevation in feet"
          },
          "continent": {
            "type": "string",
            "examples": [
              "AS",
              "EU"
            ]
          },
          "isoCountry": {
            "type": "string"
          },
          "isoRegion": {
            "type": "string"
          },
          "municipality": {
            "type": "string"
          },
          "gpsCode": {
            "type": "string"
          },
          "iataCode": {
            "type": "string",
            "description": "Nullable for private airports"
          },
          "name": {
            "type": "string"
          },
          "lat": {
            "type": "string"
          },
          "long": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "ident",
          "type",
          "continent",
          "isoCountry",
          "isoRegion",
          "name",
          "lat",
          "long"
        ]
      },
      "AirlineEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "icao": {
            "type": "string"
          },
          "iata": {
            "type": "string"
          },
          "image": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "icao",
          "iata"
        ]
      },
      "GetAirlineDTO": {
        "type": "object",
        "properties": {
          "search": {
            "type": "string",
            "description": "The search query, like 6E9920"
          }
        },
        "required": [
          "search"
        ]
      },
      "FlightsRouteEntity": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        },
        "required": [
          "from",
          "to"
        ]
      },
      "AirlineInfo": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "iataCode": {
            "type": "string"
          },
          "icaoCode": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "iataCode"
        ]
      },
      "AircraftFlightEntity": {
        "type": "object",
        "properties": {
          "iataNumber": {
            "type": "string"
          },
          "icaoNumber": {
            "type": "string"
          },
          "number": {
            "type": "string"
          }
        },
        "required": [
          "iataNumber",
          "icaoNumber",
          "number"
        ]
      },
      "AirportInfo": {
        "type": "object",
        "properties": {
          "actualRunway": {
            "type": "string"
          },
          "actualTime": {
            "type": "string"
          },
          "baggage": {
            "type": "string"
          },
          "delay": {
            "type": "string",
            "description": "in mins"
          },
          "estimatedRunway": {
            "type": "string"
          },
          "estimatedTime": {
            "type": "string"
          },
          "gate": {
            "type": "string"
          },
          "iataCode": {
            "type": "string"
          },
          "icaoCode": {
            "type": "string"
          },
          "scheduledTime": {
            "type": "string"
          },
          "terminal": {
            "type": "string"
          }
        }
      },
      "FlightStatus": {
        "type": "string",
        "enum": [
          "scheduled",
          "active",
          "landed",
          "cancelled",
          "incident",
          "diverted",
          "unknown"
        ]
      },
      "FlighType": {
        "type": "string",
        "enum": [
          "arrival",
          "departure"
        ]
      },
      "FlightEntity": {
        "type": "object",
        "properties": {
          "airline": {
            "$ref": "#/components/schemas/AirlineInfo"
          },
          "flight": {
            "$ref": "#/components/schemas/AircraftFlightEntity"
          },
          "departure": {
            "$ref": "#/components/schemas/AirportInfo"
          },
          "arrival": {
            "$ref": "#/components/schemas/AirportInfo"
          },
          "status": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlightStatus"
              }
            ]
          },
          "type": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlighType"
              }
            ]
          },
          "codeshared": {
            "type": "object"
          }
        },
        "required": [
          "airline",
          "flight",
          "departure",
          "arrival",
          "status",
          "type"
        ]
      },
      "FlightsResponseEntity": {
        "type": "object",
        "properties": {
          "success": {
            "type": "boolean"
          },
          "date": {
            "type": "string"
          },
          "route": {
            "$ref": "#/components/schemas/FlightsRouteEntity"
          },
          "flightCount": {
            "type": "number"
          },
          "flights": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightEntity"
            }
          }
        },
        "required": [
          "success",
          "date",
          "route",
          "flightCount",
          "flights"
        ]
      },
      "AircraftEntity": {
        "type": "object",
        "properties": {
          "modeS": {
            "type": "string"
          },
          "registration": {
            "type": "string"
          },
          "model": {
            "type": "string"
          },
          "image": {
            "type": "string"
          },
          "aircraft_id": {
            "type": "string"
          },
          "age": {
            "type": "string"
          },
          "firstFlightDate": {
            "type": "string"
          },
          "deliveryDate": {
            "type": "string"
          },
          "isFreighter": {
            "type": "boolean"
          },
          "attribution": {
            "type": "string"
          },
          "payload": {
            "type": "object"
          }
        }
      },
      "PartialAirlineEntity": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "iata": {
            "type": "string"
          },
          "icao": {
            "type": "string"
          },
          "image": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ]
      },
      "LocationEntity": {
        "type": "object",
        "properties": {
          "lat": {
            "type": "number"
          },
          "lon": {
            "type": "number"
          }
        },
        "required": [
          "lat",
          "lon"
        ]
      },
      "RouteAirportEntity": {
        "type": "object",
        "properties": {
          "iata": {
            "type": "string"
          },
          "icao": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "timeZone": {
            "type": "string"
          },
          "shortName": {
            "type": "string"
          },
          "countryCode": {
            "type": "string"
          },
          "municipalityName": {
            "type": "string"
          },
          "location": {
            "$ref": "#/components/schemas/LocationEntity"
          }
        },
        "required": [
          "iata",
          "icao",
          "name",
          "timeZone",
          "countryCode",
          "municipalityName",
          "location"
        ]
      },
      "TimeEntity": {
        "type": "object",
        "properties": {
          "utc": {
            "type": "string"
          },
          "local": {
            "type": "string"
          }
        },
        "required": [
          "utc",
          "local"
        ]
      },
      "RouteInfoEntity": {
        "type": "object",
        "properties": {
          "airport": {
            "$ref": "#/components/schemas/RouteAirportEntity"
          },
          "terminal": {
            "type": "string"
          },
          "gate": {
            "type": "string"
          },
          "scheduledTime": {
            "$ref": "#/components/schemas/TimeEntity"
          },
          "revisedTime": {
            "$ref": "#/components/schemas/TimeEntity"
          },
          "predictedTime": {
            "$ref": "#/components/schemas/TimeEntity"
          },
          "baggageBelt": {
            "type": "string"
          }
        },
        "required": [
          "airport",
          "scheduledTime"
        ]
      },
      "StringifiedGreatCircleDistanceEntity": {
        "type": "object",
        "properties": {
          "meter": {
            "type": "string"
          },
          "km": {
            "type": "string"
          },
          "mile": {
            "type": "string"
          },
          "nm": {
            "type": "string"
          },
          "feet": {
            "type": "string"
          }
        }
      },
      "FlightAwareDataEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "ident": {
            "type": "string",
            "description": "Flight identifier"
          },
          "identIcao": {
            "type": "string"
          },
          "identIata": {
            "type": "string"
          },
          "actualRunwayOff": {
            "type": "string"
          },
          "actualRunwayOn": {
            "type": "string"
          },
          "operator": {
            "type": "string"
          },
          "operatorIcao": {
            "type": "string"
          },
          "operatorIata": {
            "type": "string"
          },
          "flightNumber": {
            "type": "string"
          },
          "registration": {
            "type": "string"
          },
          "atcIdent": {
            "type": "string"
          },
          "inboundFaFlightId": {
            "type": "string"
          },
          "codesharesIata": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "codesharesIcao": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "departureDelay": {
            "type": "number",
            "description": "Departure delay in seconds (negative = early)"
          },
          "arrivalDelay": {
            "type": "number",
            "description": "Arrival delay in seconds (negative = early)"
          },
          "filedEte": {
            "type": "number",
            "description": "Estimated time en route in seconds"
          },
          "progressPercent": {
            "type": "number",
            "description": "Percent completion (0-100)"
          },
          "status": {
            "type": "string",
            "description": "Flight status description"
          },
          "aircraftType": {
            "type": "string"
          },
          "routeDistance": {
            "type": "number",
            "description": "Planned flight distance in statute miles"
          },
          "filedAirspeed": {
            "type": "number",
            "description": "Filed IFR airspeed in knots"
          },
          "filedAltitude": {
            "type": "number",
            "description": "Filed IFR altitude in 100s of feet"
          },
          "route": {
            "type": "string"
          },
          "baggageClaim": {
            "type": "string"
          },
          "seatsCabinBusiness": {
            "type": "number",
            "description": "Business class seats"
          },
          "seatsCabinCoach": {
            "type": "number",
            "description": "Coach class seats"
          },
          "seatsCabinFirst": {
            "type": "number",
            "description": "First class seats"
          },
          "gateOrigin": {
            "type": "string"
          },
          "gateDestination": {
            "type": "string"
          },
          "terminalOrigin": {
            "type": "string"
          },
          "terminalDestination": {
            "type": "string"
          },
          "scheduledOut": {
            "format": "date-time",
            "type": "string"
          },
          "estimatedOut": {
            "format": "date-time",
            "type": "string"
          },
          "actualOut": {
            "format": "date-time",
            "type": "string"
          },
          "scheduledOff": {
            "format": "date-time",
            "type": "string"
          },
          "estimatedOff": {
            "format": "date-time",
            "type": "string"
          },
          "actualOff": {
            "format": "date-time",
            "type": "string"
          },
          "scheduledOn": {
            "format": "date-time",
            "type": "string"
          },
          "estimatedOn": {
            "format": "date-time",
            "type": "string"
          },
          "actualOn": {
            "format": "date-time",
            "type": "string"
          },
          "scheduledIn": {
            "format": "date-time",
            "type": "string"
          },
          "estimatedIn": {
            "format": "date-time",
            "type": "string"
          },
          "actualIn": {
            "format": "date-time",
            "type": "string"
          },
          "foresightPredictionsAvailable": {
            "type": "boolean",
            "description": "Foresight predictions available"
          },
          "blocked": {
            "type": "boolean"
          },
          "diverted": {
            "type": "boolean"
          },
          "cancelled": {
            "type": "boolean"
          },
          "positionOnly": {
            "type": "boolean"
          },
          "originCode": {
            "type": "string"
          },
          "originCodeIcao": {
            "type": "string"
          },
          "originCodeIata": {
            "type": "string"
          },
          "originCodeLid": {
            "type": "string"
          },
          "originTimezone": {
            "type": "string"
          },
          "originName": {
            "type": "string"
          },
          "originCity": {
            "type": "string"
          },
          "destinationCode": {
            "type": "string"
          },
          "destinationCodeIcao": {
            "type": "string"
          },
          "destinationCodeIata": {
            "type": "string"
          },
          "destinationCodeLid": {
            "type": "string"
          },
          "destinationTimezone": {
            "type": "string"
          },
          "destinationName": {
            "type": "string"
          },
          "destinationCity": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          }
        },
        "required": [
          "id",
          "ident",
          "status",
          "foresightPredictionsAvailable",
          "blocked",
          "diverted",
          "cancelled",
          "positionOnly",
          "createdAt",
          "updatedAt"
        ]
      },
      "FlightBookingEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Unique booking identifier",
            "example": "booking_abc123"
          },
          "bookingCode": {
            "type": "object",
            "description": "Booking code/confirmation code (e.g., \"ABC123\")",
            "example": "ABC123"
          },
          "seatNumber": {
            "type": "object",
            "description": "Seat number (e.g., \"12A\", \"1F\")",
            "example": "12A"
          },
          "seatType": {
            "type": "string",
            "description": "Type of seat position",
            "enum": [
              "window",
              "middle",
              "aisle",
              "jumpseat",
              "captain",
              "pilot",
              "copilot",
              "flight_engineer",
              "flight_attendant",
              "observer",
              "other"
            ],
            "example": "window"
          },
          "seatingClass": {
            "type": "string",
            "description": "Class of service",
            "enum": [
              "economy",
              "premium_economy",
              "business",
              "first",
              "private",
              "other"
            ],
            "example": "economy"
          },
          "reason": {
            "type": "string",
            "description": "Reason for the flight",
            "enum": [
              "personal",
              "business",
              "crew",
              "training",
              "repositioning",
              "other"
            ],
            "example": "personal"
          },
          "notes": {
            "type": "object",
            "description": "Additional notes about the booking",
            "example": "Window seat preferred"
          },
          "flightId": {
            "type": "string",
            "description": "Flight ID associated with this booking",
            "example": "flight_abc123"
          },
          "userId": {
            "type": "string",
            "description": "User ID who owns this booking",
            "example": "user_abc123"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string",
            "description": "Date and time when the booking was created",
            "example": "2024-03-20T10:00:00Z"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string",
            "description": "Date and time when the booking was last updated",
            "example": "2024-03-20T10:00:00Z"
          }
        },
        "required": [
          "id",
          "flightId",
          "userId",
          "createdAt",
          "updatedAt"
        ]
      },
      "FlightResponseEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "flightNo": {
            "type": "string"
          },
          "callSign": {
            "type": "string"
          },
          "aircraft": {
            "$ref": "#/components/schemas/AircraftEntity"
          },
          "airline": {
            "$ref": "#/components/schemas/PartialAirlineEntity"
          },
          "arrival": {
            "$ref": "#/components/schemas/RouteInfoEntity"
          },
          "departure": {
            "$ref": "#/components/schemas/RouteInfoEntity"
          },
          "cargo": {
            "type": "boolean"
          },
          "greatCircleDistance": {
            "$ref": "#/components/schemas/StringifiedGreatCircleDistanceEntity"
          },
          "date": {
            "format": "date-time",
            "type": "string"
          },
          "image": {
            "type": "string"
          },
          "flightAwareData": {
            "$ref": "#/components/schemas/FlightAwareDataEntity"
          },
          "bookings": {
            "description": "Bookings associated with this flight",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightBookingEntity"
            }
          }
        },
        "required": [
          "id",
          "flightNo",
          "callSign",
          "airline",
          "arrival",
          "departure",
          "cargo",
          "greatCircleDistance",
          "date"
        ]
      },
      "TrackedFlightsResponseEntity": {
        "type": "object",
        "properties": {
          "success": {
            "type": "boolean"
          },
          "total": {
            "type": "number"
          },
          "flights": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightResponseEntity"
            }
          }
        },
        "required": [
          "success",
          "total",
          "flights"
        ]
      },
      "FlightPositionEntity": {
        "type": "object",
        "properties": {
          "fa_flight_id": {
            "type": "string",
            "description": "FlightAware flight ID for this position"
          },
          "altitude": {
            "type": "number",
            "description": "Aircraft altitude in hundreds of feet",
            "example": 350
          },
          "altitude_change": {
            "type": "string",
            "description": "Altitude change indicator",
            "enum": [
              "C",
              "D",
              "-"
            ],
            "example": "C"
          },
          "groundspeed": {
            "type": "number",
            "description": "Groundspeed in knots",
            "example": 450
          },
          "heading": {
            "type": "number",
            "description": "Aircraft heading in degrees (0-360)",
            "example": 270,
            "minimum": 0,
            "maximum": 360
          },
          "latitude": {
            "type": "number",
            "description": "Latitude position",
            "example": 40.7128
          },
          "longitude": {
            "type": "number",
            "description": "Longitude position",
            "example": -74.006
          },
          "timestamp": {
            "type": "string",
            "description": "Time that position was received",
            "example": "2024-03-20T14:30:00Z"
          },
          "update_type": {
            "type": "string",
            "description": "Update type: P=projected, O=oceanic, Z=radar, A=ADS-B, M=multilateration, D=datalink, X=surface and near surface, S=space-based, V=virtual event",
            "enum": [
              "P",
              "O",
              "Z",
              "A",
              "M",
              "D",
              "X",
              "S",
              "V"
            ]
          }
        },
        "required": [
          "altitude",
          "altitude_change",
          "groundspeed",
          "latitude",
          "longitude",
          "timestamp"
        ]
      },
      "FlightTrackResponseEntity": {
        "type": "object",
        "properties": {
          "actual_distance": {
            "type": "number",
            "description": "Distance flown in miles as of the latest position point",
            "example": 2450
          },
          "positions": {
            "description": "Array of flight positions",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightPositionEntity"
            }
          }
        },
        "required": [
          "positions"
        ]
      },
      "FlightSummaryOriginEntity": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "codeIata": {
            "type": "string"
          },
          "codeIcao": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "city": {
            "type": "string"
          }
        },
        "required": [
          "code"
        ]
      },
      "FlightSummaryDestinationEntity": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "codeIata": {
            "type": "string"
          },
          "codeIcao": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "city": {
            "type": "string"
          }
        },
        "required": [
          "code"
        ]
      },
      "FlightSummaryAirlineEntity": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "iata": {
            "type": "string"
          },
          "icao": {
            "type": "string"
          },
          "image": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ]
      },
      "FlightCandidateEntity": {
        "type": "object",
        "properties": {
          "faFlightId": {
            "type": "string",
            "description": "FlightAware flight ID for fetching full details"
          },
          "ident": {
            "type": "string",
            "description": "Flight identifier (e.g., \"AC113\")"
          },
          "origin": {
            "$ref": "#/components/schemas/FlightSummaryOriginEntity"
          },
          "destination": {
            "$ref": "#/components/schemas/FlightSummaryDestinationEntity"
          },
          "scheduledOut": {
            "format": "date-time",
            "type": "string"
          },
          "scheduledOff": {
            "format": "date-time",
            "type": "string"
          },
          "status": {
            "type": "string",
            "description": "Flight status description"
          },
          "airline": {
            "$ref": "#/components/schemas/FlightSummaryAirlineEntity"
          }
        },
        "required": [
          "faFlightId",
          "ident",
          "origin",
          "destination",
          "status",
          "airline"
        ]
      },
      "FlightSearchResponseEntity": {
        "type": "object",
        "properties": {
          "flights": {
            "description": "Array of flight candidates",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightCandidateEntity"
            }
          },
          "count": {
            "type": "number",
            "description": "Number of flights found"
          }
        },
        "required": [
          "flights",
          "count"
        ]
      },
      "CreateFlightBookingDTO": {
        "type": "object",
        "properties": {
          "flightId": {
            "type": "string",
            "description": "Flight ID to associate the booking with",
            "example": "flight_abc123"
          },
          "bookingCode": {
            "type": "string",
            "description": "Booking code/confirmation code (e.g., \"ABC123\")",
            "example": "ABC123",
            "maxLength": 50
          },
          "seatNumber": {
            "type": "string",
            "description": "Seat number (e.g., \"12A\", \"1F\")",
            "example": "12A",
            "maxLength": 10
          },
          "seatType": {
            "type": "string",
            "description": "Type of seat position",
            "enum": [
              "window",
              "middle",
              "aisle",
              "jumpseat",
              "captain",
              "pilot",
              "copilot",
              "flight_engineer",
              "flight_attendant",
              "observer",
              "other"
            ],
            "example": "window"
          },
          "seatingClass": {
            "type": "string",
            "description": "Class of service",
            "enum": [
              "economy",
              "premium_economy",
              "business",
              "first",
              "private",
              "other"
            ],
            "example": "economy"
          },
          "reason": {
            "type": "string",
            "description": "Reason for the flight",
            "enum": [
              "personal",
              "business",
              "crew",
              "training",
              "repositioning",
              "other"
            ],
            "example": "personal",
            "default": "personal"
          },
          "notes": {
            "type": "string",
            "description": "Additional notes about the booking",
            "example": "Window seat preferred",
            "maxLength": 500
          }
        },
        "required": [
          "flightId"
        ]
      },
      "UpdateFlightBookingDTO": {
        "type": "object",
        "properties": {
          "bookingCode": {
            "type": "object",
            "description": "Booking code/confirmation code (e.g., \"ABC123\"). Set to null to clear.",
            "example": "ABC123",
            "maxLength": 50,
            "nullable": true
          },
          "seatNumber": {
            "type": "object",
            "description": "Seat number (e.g., \"12A\", \"1F\"). Set to null to clear.",
            "example": "12A",
            "maxLength": 10,
            "nullable": true
          },
          "seatType": {
            "type": "string",
            "description": "Type of seat position. Set to null to clear.",
            "enum": [
              "window",
              "middle",
              "aisle",
              "jumpseat",
              "captain",
              "pilot",
              "copilot",
              "flight_engineer",
              "flight_attendant",
              "observer",
              "other"
            ],
            "example": "window",
            "nullable": true
          },
          "seatingClass": {
            "type": "string",
            "description": "Class of service. Set to null to clear.",
            "enum": [
              "economy",
              "premium_economy",
              "business",
              "first",
              "private",
              "other"
            ],
            "example": "economy",
            "nullable": true
          },
          "reason": {
            "type": "string",
            "description": "Reason for the flight. Set to null to clear.",
            "enum": [
              "personal",
              "business",
              "crew",
              "training",
              "repositioning",
              "other"
            ],
            "example": "personal",
            "nullable": true
          },
          "notes": {
            "type": "object",
            "description": "Additional notes about the booking. Set to null to clear.",
            "example": "Window seat preferred",
            "maxLength": 500,
            "nullable": true
          }
        }
      },
      "MostFlownAircraftEntity": {
        "type": "object",
        "properties": {
          "aircraftName": {
            "type": "string"
          },
          "flightCount": {
            "type": "number"
          }
        },
        "required": [
          "aircraftName",
          "flightCount"
        ]
      },
      "FlightSummaryEntity": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "flightNo": {
            "type": "string"
          },
          "callSign": {
            "type": "string"
          },
          "airline": {
            "$ref": "#/components/schemas/FlightSummaryAirlineEntity"
          },
          "departureAirportCode": {
            "type": "string",
            "description": "Departure airport code (IATA or ICAO)"
          },
          "departureAirportName": {
            "type": "string",
            "description": "Departure airport name"
          },
          "arrivalAirportCode": {
            "type": "string",
            "description": "Arrival airport code (IATA or ICAO)"
          },
          "arrivalAirportName": {
            "type": "string",
            "description": "Arrival airport name"
          },
          "date": {
            "type": "string",
            "description": "Flight date (ISO string)"
          }
        },
        "required": [
          "id",
          "flightNo",
          "callSign",
          "airline",
          "departureAirportCode",
          "departureAirportName",
          "arrivalAirportCode",
          "arrivalAirportName",
          "date"
        ]
      },
      "AircraftWithAge": {
        "type": "object",
        "properties": {
          "aircraftName": {
            "type": "string"
          },
          "tailNumber": {
            "type": "string"
          },
          "age": {
            "type": "number"
          },
          "image": {
            "type": "string"
          }
        },
        "required": [
          "aircraftName",
          "tailNumber"
        ]
      },
      "AircraftStatsEntity": {
        "type": "object",
        "properties": {
          "mostFlownAircraftName": {
            "type": "string"
          },
          "mostFlownAircraftFlightCount": {
            "type": "number"
          },
          "mostFlownAircraftImage": {
            "type": "string"
          },
          "mostFlownAircraftFlights": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FlightSummaryEntity"
            }
          },
          "mostCommonTailNumber": {
            "type": "string"
          },
          "mostCommonTailNumberCount": {
            "type": "number"
          },
          "medianAge": {
            "type": "number"
          },
          "youngestAircraft": {
            "$ref": "#/components/schemas/AircraftWithAge"
          },
          "oldestAircraft": {
            "$ref": "#/components/schemas/AircraftWithAge"
          }
        },
        "required": [
          "mostFlownAircraftName",
          "mostFlownAircraftFlightCount",
          "mostFlownAircraftFlights",
          "mostCommonTailNumber",
          "mostCommonTailNumberCount"
        ]
      },
      "PassportEntity": {
        "type": "object",
        "properties": {
          "totalFlights": {
            "type": "number",
            "description": "Total number of flights taken"
          },
          "totalDistanceKm": {
            "type": "number",
            "description": "Total distance in kilometers"
          },
          "totalDurationMinutes": {
            "type": "number",
            "description": "Total flight duration in minutes (including delays)"
          },
          "totalAirports": {
            "type": "number",
            "description": "Number of unique airports"
          },
          "totalAirlines": {
            "type": "number",
            "description": "Number of unique airlines"
          }
        },
        "required": [
          "totalFlights",
          "totalDistanceKm",
          "totalDurationMinutes",
          "totalAirports",
          "totalAirlines"
        ]
      },
      "FlightDistanceEntity": {
        "type": "object",
        "properties": {
          "flight": {
            "$ref": "#/components/schemas/FlightSummaryEntity"
          },
          "distanceKm": {
            "type": "number",
            "description": "Distance in kilometers"
          }
        },
        "required": [
          "flight",
          "distanceKm"
        ]
      },
      "FlightDurationEntity": {
        "type": "object",
        "properties": {
          "flight": {
            "$ref": "#/components/schemas/FlightSummaryEntity"
          },
          "durationMinutes": {
            "type": "number",
            "description": "Duration in minutes"
          }
        },
        "required": [
          "flight",
          "durationMinutes"
        ]
      },
      "AirlineStatsEntity": {
        "type": "object",
        "properties": {
          "airlineName": {
            "type": "string"
          },
          "airlineIata": {
            "type": "string"
          },
          "airlineIcao": {
            "type": "string"
          },
          "image": {
            "type": "string",
            "description": "Airline image URL from DB, when available"
          },
          "flightCount": {
            "type": "number"
          }
        },
        "required": [
          "airlineName",
          "airlineIata",
          "flightCount"
        ]
      },
      "AirportStatsEntity": {
        "type": "object",
        "properties": {
          "airportCode": {
            "type": "string"
          },
          "airportName": {
            "type": "string"
          },
          "departureCount": {
            "type": "number",
            "description": "Number of flights departing from this airport"
          }
        },
        "required": [
          "airportCode",
          "airportName",
          "departureCount"
        ]
      },
      "TopRouteEntity": {
        "type": "object",
        "properties": {
          "origin": {
            "type": "string"
          },
          "destination": {
            "type": "string"
          },
          "flightCount": {
            "type": "number"
          }
        },
        "required": [
          "origin",
          "destination",
          "flightCount"
        ]
      },
      "ProfileStatsResponseEntity": {
        "type": "object",
        "properties": {
          "mostFlownAircraft": {
            "$ref": "#/components/schemas/MostFlownAircraftEntity"
          },
          "aircraftStats": {
            "$ref": "#/components/schemas/AircraftStatsEntity"
          },
          "passport": {
            "$ref": "#/components/schemas/PassportEntity"
          },
          "shortestDistanceFlight": {
            "$ref": "#/components/schemas/FlightDistanceEntity"
          },
          "longestDistanceFlight": {
            "$ref": "#/components/schemas/FlightDistanceEntity"
          },
          "shortestDurationFlight": {
            "$ref": "#/components/schemas/FlightDurationEntity"
          },
          "longestDurationFlight": {
            "$ref": "#/components/schemas/FlightDurationEntity"
          },
          "airlines": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AirlineStatsEntity"
            }
          },
          "airports": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AirportStatsEntity"
            }
          },
          "topRoutes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TopRouteEntity"
            }
          }
        },
        "required": [
          "mostFlownAircraft",
          "passport",
          "shortestDistanceFlight",
          "longestDistanceFlight",
          "shortestDurationFlight",
          "longestDurationFlight",
          "airlines",
          "airports",
          "topRoutes"
        ]
      }
    }
  }
}