v1
latestOpenAPI 3.0.02026-07-141046209.2 KBChange a booking
<!-- theme: danger -->Updates the specified booking with immediate effect. This action might result in a cancellation charge being charged.
Please note that if you wish to change the contact details associated with a booking, you should use the Change a Booking's Contact Details endpoint.
Changes / updates a confirmed booking with the details you provide in the request body.
When your guest needs to change their booking, you can use this endpoint to change any of the details you initially supplied when you made their booking, e.g. you'll need to query for availability and use the roomTypes[].rates[].rateId that are available currently for their new stay dates. Any new rates selected must be for the same hotel as the original booking.
A booking cannot be updated on or after the check in day of the original or new stay.
In addition, we require you do supply a updateBookingVersionAtTimestamp field with the updatedAt timestamp of the booking. You can find this value by looking up the booking via the Retrieve a booking endpoint. This is to avoid race conditions where another update might have happened since the last time you have checked for the current details of this booking.
The status of this booking will switch back to PENDING until we have submitted and confirmed the new details with the hotel.
<!-- theme: warning -->This request might take up to 20 seconds to load. While we work to return a response to your request within milliseconds in most cases, some bookings require us to re-verify current pricing in real-time and doing so might take up to 20 seconds. Please make sure your app handles this waiting state appropriately.
Path parameters
The unique identifier of the booking you would like to update.
Request body
Example request
{
"bookingContact": {
"email": "jocelin.carreon.crespo@example.com",
"firstName": "Jocelín",
"lastName": "Carreón Sample"
},
"rooms": [
{
"adults": 2,
"rateId": "3rX3IaqkpJaPlttxoFoM3uDcHJEZCAuByqfBSLUPMvkBGyu7IAlhbxl3rZ7cVmVj6TbXL4EfiHlTA"
}
],
"updateBookingVersionAtTimestamp": "2020-12-20T11:01:30.745Z"
}Response
We've submitted the change to the hotel and are returning some of its details in the response body.
Example response
{
"bookedRooms": [
{
"rate": {
"cancellationPolicies": [
{
"end": "2020-12-17 23:59:59.999",
"fee": {
"count": 100,
"price": {
"amount": 9500,
"currency": {
"code": "EUR"
}
},
"type": "PERCENTAGE"
},
"formatted": "Non-refundable after October 19, 2021 00:00",
"start": "2020-12-15 23:59:59.999"
}
],
"components": [
{
"formatted": "breakfast",
"type": "BREAKFAST"
}
],
"end": "2021-11-23",
"hotelAgreement": {
"conditions": [
"PRIVATE_RATE"
],
"dealId": "D1234",
"dealsSellable": {
"remaining": 5
},
"discount": {
"count": 10,
"type": "PERCENTAGE"
},
"hotelAgreementId": "A82983",
"href": "v1/deal-requests/D1234/agreements/A76543",
"specialInstructions": "This deal can only be sold via desktop (not allowed for mobile apps)"
},
"retailRate": {
"taxesAndFees": {
"includedInRate": [
{
"charges": {
"amount": 9500,
"currency": {
"code": "EUR"
}
},
"formatted": "10% VAT"
}
],
"payAtHotel": [
{
"charges": {
"amount": 9500,
"currency": {
"code": "EUR"
}
},
"formatted": "10% VAT"
}
]
},
"total": {
"amount": 9500,
"currency": {
"code": "EUR"
}
}
},
"sellerCommissionPercentage": 9.5,
"start": "2021-11-20"
},
"roomType": {
"name": "Penthouse Suite",
"roomTypeId": "d5b192ce-c45f-46da-abf5-3880b429b7cc"
},
"sellerToImpalaPayment": {
"amount": 9500,
"currency": {
"code": "EUR"
}
}
}
],
"bookingId": "IM-0199-00000103",
"cancellation": {
"fee": {
"count": 100,
"price": {
"amount": 9500,
"currency": {
"code": "EUR"
}
},
"type": "PERCENTAGE"
}
},
"contact": {
"email": "jocelin.carreon.crespo@example.com",
"firstName": "Jocelín",
"lastName": "Carreón Sample",
"contactId": "3c8aa2ff-5e5e-4f23-bcfc-9036ba818a84"
},
"createdAt": "2020-10-20T12:38:22Z",
"end": "2020-10-24",
"hotel": {
"address": {
"city": "Impalaland",
"country": "GBR",
"countryName": "United Kingdom",
"line1": "12 Sample Avenue",
"postalCode": "12345"
},
"checkIn": {
"from": "12:00",
"to": "21:00"
},
"checkOut": {
"from": "12:00",
"to": "21:00"
},
"hotelId": "60a06628-2c71-44bf-9685-efbd2df4179e",
"href": "/v1/hotels/60a06628-2c71-44bf-9685-efbd2df4179e",
"images": [
{
"altText": "A photo of an object",
"height": 4000,
"url": "https://cdn.impala.travel/ckhlsuxbb000b3b666rr9ussq.jpg",
"width": 4000
}
],
"location": {
"latitude": 58.386186,
"longitude": -9.952549
},
"name": "Impala Minimalist Palace",
"starRating": 2.5,
"timezone": "AST"
},
"hotelConfirmationCode": "04M3995",
"start": "2020-10-21",
"status": "ACCEPTED",
"updatedAt": "2020-10-22T20:12:33Z"
}