{
    "openapi": "3.1.0",
    "info": {
        "title": "ViatoVia",
        "version": "1.0.0"
    },
    "servers": [
        {
            "url": "https:\/\/api-sandbox.viatovia.com\/api\/v1",
            "description": "Sandbox"
        },
        {
            "url": "https:\/\/api.viatovia.com\/api\/v1",
            "description": "Live"
        }
    ],
    "security": [
        {
            "http": []
        }
    ],
    "paths": {
        "\/booking-api\/search": {
            "post": {
                "operationId": "bookingApi.search",
                "description": "Search for available transfer vehicles.\n\nOne location must be an AIRPORT, the other a POINT.\n\nPickup or dropoff as AIRPORT: { \"type\": \"AIRPORT\", \"code\": \"AMS\" }\n\nPickup or dropoff as POINT:   { \"type\": \"POINT\", \"lat\": 52.3676, \"lng\": 4.9041, \"name\": \"Amsterdam City Centre\" }",
                "summary": "Search",
                "tags": [
                    "BookingApi"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application\/json": {
                            "schema": {
                                "$ref": "#\/components\/schemas\/SearchRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "`SearchResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "$ref": "#\/components\/schemas\/SearchResource"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Validation error",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "enum": [
                                                "Error"
                                            ],
                                            "example": "Error"
                                        },
                                        "code": {
                                            "type": "integer",
                                            "description": "Machine-readable error code:\n\n- `1300` \u2014 SEARCH_PICKUP_LOCATION_REQUIRED\n- `1301` \u2014 SEARCH_PICKUP_LOCATION_TYPE_REQUIRED\n- `1302` \u2014 SEARCH_PICKUP_LOCATION_TYPE_INVALID\n- `1303` \u2014 SEARCH_DROPOFF_LOCATION_REQUIRED\n- `1304` \u2014 SEARCH_DROPOFF_LOCATION_TYPE_REQUIRED\n- `1305` \u2014 SEARCH_DROPOFF_LOCATION_TYPE_INVALID\n- `1306` \u2014 SEARCH_PICKUP_IATA_CODE_REQUIRED\n- `1307` \u2014 SEARCH_PICKUP_IATA_CODE_INVALID\n- `1308` \u2014 SEARCH_DROPOFF_IATA_CODE_REQUIRED\n- `1309` \u2014 SEARCH_DROPOFF_IATA_CODE_INVALID\n- `1310` \u2014 SEARCH_PICKUP_LAT_REQUIRED\n- `1311` \u2014 SEARCH_PICKUP_LNG_REQUIRED\n- `1312` \u2014 SEARCH_PICKUP_NAME_REQUIRED\n- `1313` \u2014 SEARCH_DROPOFF_LAT_REQUIRED\n- `1314` \u2014 SEARCH_DROPOFF_LNG_REQUIRED\n- `1315` \u2014 SEARCH_DROPOFF_NAME_REQUIRED\n- `1316` \u2014 SEARCH_PICKUP_DATETIME_REQUIRED\n- `1317` \u2014 SEARCH_PICKUP_DATETIME_INVALID\n- `1318` \u2014 SEARCH_TRAVELERS_REQUIRED\n- `1319` \u2014 SEARCH_TRAVELERS_ADULT_REQUIRED\n- `1320` \u2014 SEARCH_TRAVELERS_ADULT_INVALID\n- `1321` \u2014 SEARCH_TRAVELERS_CHILDREN_INVALID\n- `1322` \u2014 SEARCH_TRAVELERS_INFANT_INVALID\n- `1323` \u2014 SEARCH_AIRPORT_REQUIRED",
                                            "enum": [
                                                1300,
                                                1301,
                                                1302,
                                                1303,
                                                1304,
                                                1305,
                                                1306,
                                                1307,
                                                1308,
                                                1309,
                                                1310,
                                                1311,
                                                1312,
                                                1313,
                                                1314,
                                                1315,
                                                1316,
                                                1317,
                                                1318,
                                                1319,
                                                1320,
                                                1321,
                                                1322,
                                                1323
                                            ],
                                            "example": 1300
                                        },
                                        "message": {
                                            "type": "string",
                                            "description": "Error code name",
                                            "enum": [
                                                "SEARCH_PICKUP_LOCATION_REQUIRED",
                                                "SEARCH_PICKUP_LOCATION_TYPE_REQUIRED",
                                                "SEARCH_PICKUP_LOCATION_TYPE_INVALID",
                                                "SEARCH_DROPOFF_LOCATION_REQUIRED",
                                                "SEARCH_DROPOFF_LOCATION_TYPE_REQUIRED",
                                                "SEARCH_DROPOFF_LOCATION_TYPE_INVALID",
                                                "SEARCH_PICKUP_IATA_CODE_REQUIRED",
                                                "SEARCH_PICKUP_IATA_CODE_INVALID",
                                                "SEARCH_DROPOFF_IATA_CODE_REQUIRED",
                                                "SEARCH_DROPOFF_IATA_CODE_INVALID",
                                                "SEARCH_PICKUP_LAT_REQUIRED",
                                                "SEARCH_PICKUP_LNG_REQUIRED",
                                                "SEARCH_PICKUP_NAME_REQUIRED",
                                                "SEARCH_DROPOFF_LAT_REQUIRED",
                                                "SEARCH_DROPOFF_LNG_REQUIRED",
                                                "SEARCH_DROPOFF_NAME_REQUIRED",
                                                "SEARCH_PICKUP_DATETIME_REQUIRED",
                                                "SEARCH_PICKUP_DATETIME_INVALID",
                                                "SEARCH_TRAVELERS_REQUIRED",
                                                "SEARCH_TRAVELERS_ADULT_REQUIRED",
                                                "SEARCH_TRAVELERS_ADULT_INVALID",
                                                "SEARCH_TRAVELERS_CHILDREN_INVALID",
                                                "SEARCH_TRAVELERS_INFANT_INVALID",
                                                "SEARCH_AIRPORT_REQUIRED"
                                            ],
                                            "example": "SEARCH_PICKUP_LOCATION_REQUIRED"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "code",
                                        "message"
                                    ]
                                }
                            }
                        }
                    }
                }
            }
        },
        "\/booking-api\/booking": {
            "post": {
                "operationId": "bookingApi.createBooking",
                "description": "Create a booking from a search result.\n\nPayment type is determined by the api_user_settings pay_type:\n- reverse_api \u2192 Third Party (no wallet deduction)\n- anything else \u2192 Wallet (balance is checked first)",
                "summary": "Create Booking",
                "tags": [
                    "BookingApi"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application\/json": {
                            "schema": {
                                "$ref": "#\/components\/schemas\/CreateBookingRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "`CreateBookingResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "$ref": "#\/components\/schemas\/CreateBookingResource"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Validation error",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "enum": [
                                                "Error"
                                            ],
                                            "example": "Error"
                                        },
                                        "code": {
                                            "type": "integer",
                                            "description": "Machine-readable error code:\n\n- `1001` \u2014 SEARCH_ID_REQUIRED\n- `1002` \u2014 SEARCH_NOT_EXISTS\n- `1003` \u2014 VEHICLE_ID_REQUIRED\n- `1004` \u2014 VEHICLE_ID_INVALID\n- `1005` \u2014 PASSENGER_REQUIRED\n- `1006` \u2014 PASSENGER_NAME_REQUIRED\n- `1007` \u2014 PASSENGER_SURNAME_REQUIRED\n- `1008` \u2014 PASSENGER_PHONE_REQUIRED\n- `1009` \u2014 PASSENGER_PHONE_INVALID\n- `1010` \u2014 PASSENGER_EMAIL_REQUIRED\n- `1011` \u2014 PASSENGER_EMAIL_INVALID\n- `1012` \u2014 TRAVEL_DETAILS_REQUIRED\n- `1013` \u2014 FLIGHT_NUMBER_REQUIRED\n- `1014` \u2014 SUITCASE_REQUIRED\n- `1015` \u2014 SUITCASE_INVALID\n- `1016` \u2014 SMALL_BAGS_REQUIRED\n- `1017` \u2014 SMALL_BAGS_INVALID\n- `1100` \u2014 CREATION_PERMISSION_DENIED\n- `1018` \u2014 EXTRA_SERVICES_INVALID\n- `1019` \u2014 EXTRA_SERVICE_ID_REQUIRED\n- `1020` \u2014 EXTRA_SERVICE_ID_INVALID\n- `1021` \u2014 EXTRA_SERVICE_QUANTITY_INVALID",
                                            "enum": [
                                                1001,
                                                1002,
                                                1003,
                                                1004,
                                                1005,
                                                1006,
                                                1007,
                                                1008,
                                                1009,
                                                1010,
                                                1011,
                                                1012,
                                                1013,
                                                1014,
                                                1015,
                                                1016,
                                                1017,
                                                1100,
                                                1018,
                                                1019,
                                                1020,
                                                1021
                                            ],
                                            "example": 1001
                                        },
                                        "message": {
                                            "type": "string",
                                            "description": "Error code name",
                                            "enum": [
                                                "SEARCH_ID_REQUIRED",
                                                "SEARCH_NOT_EXISTS",
                                                "VEHICLE_ID_REQUIRED",
                                                "VEHICLE_ID_INVALID",
                                                "PASSENGER_REQUIRED",
                                                "PASSENGER_NAME_REQUIRED",
                                                "PASSENGER_SURNAME_REQUIRED",
                                                "PASSENGER_PHONE_REQUIRED",
                                                "PASSENGER_PHONE_INVALID",
                                                "PASSENGER_EMAIL_REQUIRED",
                                                "PASSENGER_EMAIL_INVALID",
                                                "TRAVEL_DETAILS_REQUIRED",
                                                "FLIGHT_NUMBER_REQUIRED",
                                                "SUITCASE_REQUIRED",
                                                "SUITCASE_INVALID",
                                                "SMALL_BAGS_REQUIRED",
                                                "SMALL_BAGS_INVALID",
                                                "CREATION_PERMISSION_DENIED",
                                                "EXTRA_SERVICES_INVALID",
                                                "EXTRA_SERVICE_ID_REQUIRED",
                                                "EXTRA_SERVICE_ID_INVALID",
                                                "EXTRA_SERVICE_QUANTITY_INVALID"
                                            ],
                                            "example": "SEARCH_ID_REQUIRED"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "code",
                                        "message"
                                    ]
                                }
                            }
                        }
                    }
                }
            },
            "get": {
                "operationId": "bookingApi.bookingInfo",
                "description": "Get booking details by reservation number.",
                "summary": "Get Booking Details",
                "tags": [
                    "BookingApi"
                ],
                "parameters": [
                    {
                        "name": "reservation_no",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "`BookingResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "$ref": "#\/components\/schemas\/BookingResource"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "const": "Error"
                                        },
                                        "message": {
                                            "type": "string",
                                            "const": "Booking not found"
                                        },
                                        "data": {
                                            "type": "null"
                                        },
                                        "error_details": {
                                            "type": "null"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "message",
                                        "data",
                                        "error_details"
                                    ]
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Validation error",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "enum": [
                                                "Error"
                                            ],
                                            "example": "Error"
                                        },
                                        "code": {
                                            "type": "integer",
                                            "description": "Machine-readable error code:\n\n- `1400` \u2014 BOOKING_INFO_RESERVATION_REQUIRED\n- `1401` \u2014 BOOKING_INFO_RESERVATION_NOT_FOUND",
                                            "enum": [
                                                1400,
                                                1401
                                            ],
                                            "example": 1400
                                        },
                                        "message": {
                                            "type": "string",
                                            "description": "Error code name",
                                            "enum": [
                                                "BOOKING_INFO_RESERVATION_REQUIRED",
                                                "BOOKING_INFO_RESERVATION_NOT_FOUND"
                                            ],
                                            "example": "BOOKING_INFO_RESERVATION_REQUIRED"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "code",
                                        "message"
                                    ]
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "bookingApi.cancelBooking",
                "description": "Cancel a booking by reservation number. Only bookings with status\nPENDING_APPROVAL or APPROVED can be cancelled.\n\nYou can get cancellation_id from cancellation reasons endpoint.",
                "summary": "Cancel Booking",
                "tags": [
                    "BookingApi"
                ],
                "parameters": [
                    {
                        "name": "reservation_no",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "cancellation_id",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "integer"
                        }
                    },
                    {
                        "name": "note",
                        "in": "query",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "const": "Success"
                                        },
                                        "message": {
                                            "type": "string",
                                            "const": "Booking cancelled successfully."
                                        },
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "type": "string"
                                            },
                                            "minItems": 0,
                                            "maxItems": 0,
                                            "additionalItems": false
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "message",
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Validation error",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "enum": [
                                                "Error"
                                            ],
                                            "example": "Error"
                                        },
                                        "code": {
                                            "type": "integer",
                                            "description": "Machine-readable error code:\n\n- `1200` \u2014 CANCELLATION_RESERVATION_REQUIRED\n- `1201` \u2014 CANCELLATION_RESERVATION_NOT_FOUND\n- `1202` \u2014 CANCELLATION_TYPE_REQUIRED\n- `1203` \u2014 CANCELLATION_TYPE_INVALID\n- `1204` \u2014 CANCELLATION_FAILED",
                                            "enum": [
                                                1200,
                                                1201,
                                                1202,
                                                1203,
                                                1204
                                            ],
                                            "example": 1200
                                        },
                                        "message": {
                                            "type": "string",
                                            "description": "Error code name",
                                            "enum": [
                                                "CANCELLATION_RESERVATION_REQUIRED",
                                                "CANCELLATION_RESERVATION_NOT_FOUND",
                                                "CANCELLATION_TYPE_REQUIRED",
                                                "CANCELLATION_TYPE_INVALID",
                                                "CANCELLATION_FAILED"
                                            ],
                                            "example": "CANCELLATION_RESERVATION_REQUIRED"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "code",
                                        "message"
                                    ]
                                }
                            }
                        }
                    }
                }
            }
        },
        "\/booking-api\/cancellation-reasons": {
            "get": {
                "operationId": "bookingApi.cancellationReasons",
                "description": "Get the list of available cancellation reasons.",
                "summary": "Cancellation Reasons",
                "tags": [
                    "BookingApi"
                ],
                "responses": {
                    "200": {
                        "description": "Array of `CancellationReasonsResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "array",
                                    "items": {
                                        "$ref": "#\/components\/schemas\/CancellationReasonsResource"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    },
    "components": {
        "securitySchemes": {
            "http": {
                "type": "http",
                "scheme": "bearer"
            }
        },
        "schemas": {
            "AirportLocation": {
                "type": "object",
                "properties": {
                    "type": {
                        "type": "string",
                        "enum": [
                            "AIRPORT"
                        ]
                    },
                    "iata_code": {
                        "type": "string",
                        "description": "IATA airport code (e.g. AMS)",
                        "example": "AMS"
                    }
                },
                "required": [
                    "type",
                    "iata_code"
                ],
                "title": "AirportLocation"
            },
            "BookingApiErrorResource": {
                "type": "object",
                "properties": {
                    "status": {
                        "type": "string",
                        "const": "Error"
                    },
                    "code": {
                        "type": "string"
                    },
                    "message": {
                        "type": "string"
                    }
                },
                "required": [
                    "status",
                    "code",
                    "message"
                ],
                "title": "BookingApiErrorResource"
            },
            "BookingResource": {
                "type": "object",
                "properties": {
                    "reservation_no": {
                        "type": "string"
                    },
                    "status": {
                        "$ref": "#\/components\/schemas\/BookingStatus"
                    },
                    "pickup_location": {
                        "type": "object",
                        "properties": {
                            "name": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "type": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "name",
                            "type"
                        ]
                    },
                    "dropoff_location": {
                        "type": "object",
                        "properties": {
                            "name": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "type": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "name",
                            "type"
                        ]
                    },
                    "pickup_datetime": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "date-time"
                    },
                    "flight_number": {
                        "type": [
                            "string",
                            "null"
                        ]
                    },
                    "passengers": {
                        "type": "object",
                        "properties": {
                            "adult": {
                                "type": "integer"
                            },
                            "children": {
                                "type": "integer"
                            },
                            "infant": {
                                "type": "integer"
                            }
                        },
                        "required": [
                            "adult",
                            "children",
                            "infant"
                        ]
                    },
                    "passenger": {
                        "type": "object",
                        "properties": {
                            "name": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "surname": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "email": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "phone": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            }
                        },
                        "required": [
                            "name",
                            "surname",
                            "email",
                            "phone"
                        ]
                    },
                    "vehicle": {
                        "type": "object",
                        "properties": {
                            "make": {
                                "type": "string"
                            },
                            "model": {
                                "type": "string"
                            },
                            "type": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "make",
                            "model",
                            "type"
                        ]
                    },
                    "price": {
                        "type": "object",
                        "properties": {
                            "total": {
                                "type": "string"
                            },
                            "currency": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "total",
                            "currency"
                        ]
                    },
                    "distance_km": {
                        "type": "integer"
                    },
                    "booking_type": {
                        "type": "string"
                    },
                    "is_cancelable": {
                        "type": "boolean"
                    },
                    "extra_services": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    }
                },
                "required": [
                    "reservation_no",
                    "status",
                    "pickup_location",
                    "dropoff_location",
                    "pickup_datetime",
                    "flight_number",
                    "passengers",
                    "passenger",
                    "vehicle",
                    "price",
                    "distance_km",
                    "booking_type",
                    "is_cancelable",
                    "extra_services"
                ],
                "title": "BookingResource"
            },
            "BookingStatus": {
                "type": "string",
                "enum": [
                    "PENDING",
                    "PENDING_APPROVAL",
                    "APPROVED",
                    "CANCELLED",
                    "FAILED",
                    "DECLINED",
                    "REFUNDED",
                    "COMPLETED",
                    "DEFAULT"
                ],
                "title": "BookingStatus"
            },
            "CancellationReasonsResource": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer"
                    },
                    "name": {
                        "type": "string"
                    },
                    "description": {
                        "type": [
                            "string",
                            "null"
                        ]
                    },
                    "position": {
                        "type": "integer"
                    }
                },
                "required": [
                    "id",
                    "name",
                    "description",
                    "position"
                ],
                "title": "CancellationReasonsResource"
            },
            "CreateBookingRequest": {
                "type": "object",
                "properties": {
                    "search_id": {
                        "type": "string"
                    },
                    "vehicle_id": {
                        "type": "integer"
                    },
                    "suitcase": {
                        "type": "integer",
                        "minimum": 0
                    },
                    "small_bags": {
                        "type": "integer",
                        "minimum": 0
                    },
                    "passenger": {
                        "type": "object",
                        "properties": {
                            "name": {
                                "type": "string"
                            },
                            "surname": {
                                "type": "string"
                            },
                            "phone": {
                                "type": "string",
                                "pattern": "^\\+[1-9]\\d{1,14}$",
                                "minLength": 6
                            },
                            "email": {
                                "type": "string",
                                "format": "email"
                            }
                        },
                        "required": [
                            "name",
                            "surname",
                            "phone",
                            "email"
                        ]
                    },
                    "travel_details": {
                        "type": "object",
                        "properties": {
                            "flight_number": {
                                "type": "string"
                            },
                            "extra_requests": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            }
                        },
                        "required": [
                            "flight_number"
                        ]
                    },
                    "extra_services": {
                        "type": [
                            "array",
                            "null"
                        ],
                        "items": {
                            "type": "object",
                            "properties": {
                                "id": {
                                    "type": "integer"
                                },
                                "quantity": {
                                    "type": [
                                        "integer",
                                        "null"
                                    ],
                                    "minimum": 1
                                }
                            },
                            "required": [
                                "id"
                            ]
                        }
                    }
                },
                "required": [
                    "search_id",
                    "vehicle_id",
                    "suitcase",
                    "small_bags",
                    "passenger",
                    "travel_details"
                ],
                "title": "CreateBookingRequest"
            },
            "CreateBookingResource": {
                "type": "object",
                "properties": {
                    "status": {
                        "type": "string",
                        "const": "Success"
                    },
                    "booking": {
                        "$ref": "#\/components\/schemas\/BookingResource"
                    }
                },
                "required": [
                    "status",
                    "booking"
                ],
                "title": "CreateBookingResource"
            },
            "PointLocation": {
                "type": "object",
                "properties": {
                    "type": {
                        "type": "string",
                        "enum": [
                            "POINT"
                        ]
                    },
                    "lat": {
                        "type": "number",
                        "description": "Latitude",
                        "example": 52.3676
                    },
                    "lng": {
                        "type": "number",
                        "description": "Longitude",
                        "example": 4.9041
                    },
                    "name": {
                        "type": "string",
                        "description": "Location name",
                        "example": "Amsterdam City Centre"
                    }
                },
                "required": [
                    "type",
                    "lat",
                    "lng",
                    "name"
                ],
                "title": "PointLocation"
            },
            "SearchRequest": {
                "type": "object",
                "example": {
                    "pickup_location": {
                        "type": "AIRPORT",
                        "iata_code": "AMS"
                    },
                    "dropoff_location": {
                        "type": "POINT",
                        "lat": 52.3676,
                        "lng": 4.9041,
                        "name": "Amsterdam City Centre"
                    },
                    "pickup_datetime": "2026-06-07 01:25",
                    "travelers": {
                        "adult": 2,
                        "children": 0,
                        "infant": 0
                    }
                },
                "properties": {
                    "pickup_datetime": {
                        "type": "string",
                        "format": "date-time"
                    },
                    "pickup_location": {
                        "oneOf": [
                            {
                                "$ref": "#\/components\/schemas\/AirportLocation"
                            },
                            {
                                "$ref": "#\/components\/schemas\/PointLocation"
                            }
                        ],
                        "discriminator": {
                            "propertyName": "type"
                        }
                    },
                    "dropoff_location": {
                        "oneOf": [
                            {
                                "$ref": "#\/components\/schemas\/AirportLocation"
                            },
                            {
                                "$ref": "#\/components\/schemas\/PointLocation"
                            }
                        ],
                        "discriminator": {
                            "propertyName": "type"
                        }
                    },
                    "travelers": {
                        "type": "object",
                        "properties": {
                            "adult": {
                                "type": "integer",
                                "minimum": 1
                            },
                            "children": {
                                "type": [
                                    "integer",
                                    "null"
                                ],
                                "minimum": 0
                            },
                            "infant": {
                                "type": [
                                    "integer",
                                    "null"
                                ],
                                "minimum": 0
                            }
                        },
                        "required": [
                            "adult"
                        ]
                    }
                },
                "required": [
                    "pickup_datetime",
                    "pickup_location",
                    "dropoff_location",
                    "travelers"
                ],
                "title": "SearchRequest"
            },
            "SearchResource": {
                "type": "object",
                "properties": {
                    "distance_km": {
                        "type": [
                            "integer",
                            "null"
                        ]
                    },
                    "vehicles": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "vehicle_id": {
                                    "type": "string"
                                },
                                "make": {
                                    "type": "string"
                                },
                                "model": {
                                    "type": "string"
                                },
                                "type": {
                                    "type": "string"
                                },
                                "max_passengers": {
                                    "type": "string"
                                },
                                "suitcases": {
                                    "type": "string"
                                },
                                "small_bags": {
                                    "type": "string"
                                },
                                "price": {
                                    "type": "number"
                                },
                                "currency": {
                                    "type": "string"
                                },
                                "company": {
                                    "type": "string"
                                },
                                "extra_services": {
                                    "type": "array",
                                    "items": {
                                        "type": "object",
                                        "properties": {
                                            "id": {},
                                            "name": {},
                                            "price": {},
                                            "pricing_type": {}
                                        },
                                        "required": [
                                            "id",
                                            "name",
                                            "price",
                                            "pricing_type"
                                        ]
                                    }
                                }
                            },
                            "required": [
                                "vehicle_id",
                                "make",
                                "model",
                                "type",
                                "max_passengers",
                                "suitcases",
                                "small_bags",
                                "price",
                                "currency",
                                "company",
                                "extra_services"
                            ]
                        }
                    }
                },
                "required": [
                    "distance_km",
                    "vehicles"
                ],
                "title": "SearchResource"
            }
        }
    }
}