Skip to main content

Update a contract

Changes in trip details happen, even more often than we would like, but what should you do if it happens? We are here to talk about it!

When should you update a contract?

Usually, you will need to update a contract in case of:

  • Changes made by the customers on their booking before (regular update) or after their departure date (partial update): change in departure date, the addition of a service after the booking, etc.
  • Unavailability of the tickets that you have sold to the customers
  • Changes made by the carrier before departure (change in flight date, flight number, etc.)
note

We will only accept updates if the contract is still valid (= the customers can still make a claim for the contract). If you update an invalid contract, you will receive a 401 error and the update will not be considered.

What data can you update?

Except the booking number, you can update all the elements of a contract.

Among other things, you can update for a contract:

  • the number of travelers and their info
  • the trip price
  • the Journeys details
  • the Stays details
note

If the change suffered has also caused the modification of the booking number used for the contract, please contact us by email at contact@hikoala.co with all the details.

Could it have an impact on Koala product price?

Yes, sometimes it can! For instance, if the cost of the product is a % of the booking price and your traveller decides to add an option that increases the booking price, the product price will increase by the corresponding %.

But do not worry, we got your back by informing you via priceDelta in the response of the Quote. This object informs you the delta between with the new price and the previous price of the subscription before the update. It can be positive or negative.

note

**You will be responsible for charging or reimbursing the customer this delta **.

How can you update a trip? (Regular update)

Updating trip details is a 2-steps process:

Step 1:

You first need to use our Quotes endpoint with the new contract details. Even if only one field has been changed, you must return the entire Quote.

curl -X POST "https://staging-partner.api.hikoala.co/quotes" -H "Content-Type: application/JSON" -H "accept: application/JSON" -H "Authorization: Bearer <token>"

Please store the id you received in the response, you will need it for Step 2.


Step 2:

Once you have completed Step 1, you will need to add the customer and traveler information (even if it has not changed) and Patch the Quote you have just made on: (please replace the bookingNumber with the booking number of the contract that is being changed)

curl -X PATCH "https://staging-partner.api.hikoala.co/subscriptions/{bookingNumber}" -H "Content-Type: application/JSON" -H "accept: application/JSON" -H "Authorization: Bearer <token>" --data-raw '{"data": {}}'

If you followed the two steps, you will receive a 201 response, meaning that the trip's details are now up to date and that we have adapted accordingly our operations 💪

Possible outputs

Our API can send you back the following responses:

  • 200: The Subscription has successfully been updated 🤩
  • 400: Something went wrong with the update. You may have forgotten one mandatory field or made a mistake with one format.
  • 401: The Update cannot be made because you are experimenting with an issue with your token.
  • 404: There is no contract associated with the bookingNumber that you have provided.