{"openapi":"3.1.0","info":{"title":"Car Rental API","version":"v0.9","description":"Search rental cars by pickup location and dates, compare inclusive rates and insurance options, and create reservations. The Car Rental API is in public beta: the schema is stable, and supplier coverage is growing."},"servers":[{"url":"https://api.flightota.com","description":"Production"},{"url":"https://sandbox.flightota.com","description":"Sandbox"}],"security":[{"bearerAuth":[]}],"paths":{"/car/v0/search":{"post":{"operationId":"car-search","summary":"Search rental cars","description":"Available vehicles for a pickup and drop-off location and time.","tags":["Search"],"parameters":[],"responses":{"200":{"description":"Successful response","content":{"application/json":{"example":{"data":{"vehicles":[{"rate_id":"car_rt_01","category":"compact","example":"VW Golf or similar","transmission":"automatic","total":"289.00","currency":"USD"}]}}}}},"400":{"description":"validation_error: One or more request parameters are invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"validation_error":{"value":{"error":{"code":"validation_error","message":"One or more request parameters are invalid."}}}}}}},"401":{"description":"unauthorized: The API key is missing, revoked or invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"unauthorized":{"value":{"error":{"code":"unauthorized","message":"The API key is missing, revoked or invalid."}}}}}}},"429":{"description":"rate_limited: Too many requests. Retry after the time given in the Retry-After header.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"rate_limited":{"value":{"error":{"code":"rate_limited","message":"Too many requests. Retry after the time given in the Retry-After header."}}}}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["pickup_location","pickup_at","dropoff_at","driver_age"],"properties":{"pickup_location":{"type":"string","description":"IATA code or branch ID."},"pickup_at":{"type":"string","format":"date-time","description":"Pickup date and time."},"dropoff_at":{"type":"string","format":"date-time","description":"Drop-off date and time."},"driver_age":{"type":"integer","description":"Age of the main driver."}}},"example":{"pickup_location":"LHR","pickup_at":"2026-12-20T10:00:00","dropoff_at":"2026-12-27T10:00:00","driver_age":32}}}}}},"/car/v0/reservations":{"post":{"operationId":"car-reserve","summary":"Create a reservation","description":"Reserves a vehicle rate for the main driver.","tags":["Reservations"],"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Unique key (UUID v4) that makes retries safe. Reusing a key returns the original result.","schema":{"type":"string"},"example":"4f9a2c3e-6b1d-4e8a-9c7f-2d5b8e1a0c34"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"example":{"data":{"reservation_id":"crs_01JDC1","status":"confirmed","confirmation":"EU-88213"}}}}},"400":{"description":"validation_error: One or more request parameters are invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"validation_error":{"value":{"error":{"code":"validation_error","message":"One or more request parameters are invalid."}}}}}}},"401":{"description":"unauthorized: The API key is missing, revoked or invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"unauthorized":{"value":{"error":{"code":"unauthorized","message":"The API key is missing, revoked or invalid."}}}}}}},"409":{"description":"offer_expired: The offer is no longer valid at the supplier. Search or reprice again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"offer_expired":{"value":{"error":{"code":"offer_expired","message":"The offer is no longer valid at the supplier. Search or reprice again."}}}}}}},"429":{"description":"rate_limited: Too many requests. Retry after the time given in the Retry-After header.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"rate_limited":{"value":{"error":{"code":"rate_limited","message":"Too many requests. Retry after the time given in the Retry-After header."}}}}}}},"502":{"description":"supplier_unavailable: The upstream supplier did not respond. No booking was created.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"supplier_unavailable":{"value":{"error":{"code":"supplier_unavailable","message":"The upstream supplier did not respond. No booking was created."}}}}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["rate_id"],"properties":{"rate_id":{"type":"string","description":"Rate identifier."}}},"example":{"rate_id":"car_rt_01","driver":{"given_name":"Omar","family_name":"Rahman","age":32}}}}}}},"/car/v0/reservations/{reservation_id}/cancel":{"post":{"operationId":"car-cancel","summary":"Cancel a reservation","description":"Cancels a car rental reservation.","tags":["Reservations"],"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Unique key (UUID v4) that makes retries safe. Reusing a key returns the original result.","schema":{"type":"string"},"example":"4f9a2c3e-6b1d-4e8a-9c7f-2d5b8e1a0c34"},{"name":"reservation_id","in":"path","required":true,"description":"Reservation identifier.","schema":{"type":"string"},"example":"crs_01JDC1"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"example":{"data":{"reservation_id":"crs_01JDC1","status":"cancelled"}}}}},"400":{"description":"validation_error: One or more request parameters are invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"validation_error":{"value":{"error":{"code":"validation_error","message":"One or more request parameters are invalid."}}}}}}},"401":{"description":"unauthorized: The API key is missing, revoked or invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"unauthorized":{"value":{"error":{"code":"unauthorized","message":"The API key is missing, revoked or invalid."}}}}}}},"409":{"description":"offer_expired: The offer is no longer valid at the supplier. Search or reprice again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"offer_expired":{"value":{"error":{"code":"offer_expired","message":"The offer is no longer valid at the supplier. Search or reprice again."}}}}}}},"429":{"description":"rate_limited: Too many requests. Retry after the time given in the Retry-After header.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"rate_limited":{"value":{"error":{"code":"rate_limited","message":"Too many requests. Retry after the time given in the Retry-After header."}}}}}}},"502":{"description":"supplier_unavailable: The upstream supplier did not respond. No booking was created.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"},"examples":{"supplier_unavailable":{"value":{"error":{"code":"supplier_unavailable","message":"The upstream supplier did not respond. No booking was created."}}}}}}}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Your API key"}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}}}}}}}}