Getting Started with the Xeni Activities APIHow to Book an ActivityHow to Browse Activity Tags and CategoriesHow to Cancel an Activity BookingHow to Check Activity AvailabilityHow to Get Activity DetailsHow to Retrieve Activity Booking DetailsHow to Search for Activities with FiltersHow to Search for Activity DestinationsCar Rental API - Getting StartedCar Rental API - Understanding Response FieldsHow to Book a Car RentalHow to Get Rental Car Details and Equipment Add-OnsHow to Retrieve or Cancel a Car Rental BookingHow to Search for Available Rental CarsHow to Search for Pickup LocationsHow to Use Car Rental Search FiltersDeals API Best Practices for IntegrationDeals API Frequently Asked QuestionsGetting Started with the Xeni Deals APIDeals API Request Parameters and Headers ReferenceDeals API Supported Currencies and LocalizationHow to Display Deals in Your ApplicationHow to Fetch Hotel Deals by LocationFlights API Error Codes and TroubleshootingGetting Started with the Xeni Flights APIHow to Book a FlightHow to Check Flight Availability and PricingHow to Confirm or Cancel a Flight BookingHow to Retrieve Fare Rules for a FlightHow to Retrieve Flight Booking DetailsHow to Search for Airports Using AutocompleteHow to Search for FlightsHow to Use Flight Search Filters, Sorting, and PaginationHow to Check Room Availability and PricingHow to Filter Vacation Rental ResultsHow to Get Resort Property Details, Amenities, and AccessibilityHow to Hold and Confirm a Resort BookingHow to Release a Resort HoldHow to Retrieve Resort Booking DetailsHow to Search for Available ResortsHow to Search for Resort DestinationsHow to Search for Vacation Rental LocationsHow to Search for Vacation RentalsHow to Use Resort Search Filters and SortingGetting Started with the Xeni Resorts APIResorts API: Understanding Booking Statuses and PoliciesGetting Started with the Vacation Rentals APIVacation Rentals Frequently Asked QuestionsVacation Rentals Supported Property TypesUnderstanding Async Search for Vacation RentalsAuthentication & API SignaturesBooking Hotels — Direct API & SSO CheckoutError Handling, Rate Limits & Best PracticesGetting Started with the Xeni Hotels APIManaging Bookings: Status, Retrieval & CancellationPricing Confirmation & Token LifecycleRetrieving Hotel Details & Room AvailabilitySearching for Hotels: Locations, Filters & PaginationSearching for HotelsSession Management & Correlation IDsAPI authentication and getting your API keys

How to Confirm or Cancel a Flight Booking

Last updated: 2026-03-03

How to Confirm or Cancel a Flight Booking

After creating a booking, you can confirm it to issue tickets or cancel it if the reservation is no longer needed. Both actions use the same PATCH endpoint with different request bodies.

Endpoint

PATCH /flights/api/v2/bookings/{booking_id}

Headers

HeaderRequiredDescription
x-api-keyYesYour API key.
x-correlation-idYesCorrelation ID from the autocomplete response.

Path Parameters

ParameterTypeRequiredDescription
booking_idstringYesThe booking ID returned when the booking was created.

Confirming a Booking

Send a PATCH request with booking_status set to "Confirm" to issue tickets.

Request Body

JSON
{
  "booking_status": "Confirm"
}

Example Request

PATCH /flights/api/v2/bookings/XNFiEtVA3LL
JSON
{
  "booking_status": "Confirm"
}

Example Response

JSON
{
  "status": "success",
  "data": {
    "booking_id": "XNFiEtVA3LL",
    "booking_status": "TICKETED"
  },
  "message": "Booking confirmed successfully"
}

Possible Confirmation Statuses

StatusDescription
TICKETEDTickets have been issued immediately.
TICKETINPROCESSTicketing is in progress. Check back shortly using the get booking endpoint.

Cancelling a Booking

Send a PATCH request with booking_status set to "Cancel" to cancel the booking.

Request Body

JSON
{
  "booking_status": "Cancel"
}

Example Request

PATCH /flights/api/v2/bookings/XNFiEtVA3LL
JSON
{
  "booking_status": "Cancel"
}

Example Response

JSON
{
  "status": "success",
  "data": {
    "booking_id": "XNFiEtVA3LL",
    "booking_status": "CANCELLED"
  },
  "message": "Booking cancelled successfully"
}

Booking Status Reference

StatusDescription
BOOKEDReservation is held but not yet ticketed. Must be confirmed before the ticket time limit.
TICKETEDTickets have been issued. The booking is fully confirmed.
TICKETINPROCESSTicketing is being processed. Poll the get booking endpoint to check for completion.
CANCELLEDBooking has been cancelled.

Important Notes

  • Ticket time limit. When a booking has status BOOKED, it must be confirmed before the tickettimelimit returned in the booking creation response. After this deadline, the reservation may be automatically released by the airline.
  • Cancellation penalties. Cancelling a ticketed booking may incur penalties based on the fare rules. Review the fare rules before cancelling. See How to Retrieve Fare Rules for a Flight.
  • Cancelling a held booking. Cancelling a booking with status BOOKED (not yet ticketed) typically does not incur any penalty.
  • TICKETINPROCESS. If the confirmation response returns TICKETINPROCESS, the ticketing is still underway. Use the Get Booking Details endpoint to poll for the final status.

Related Articles

Was this article helpful?