These docs are for v1.0. Click to read the latest docs for v2.0.
added

2-Step Cancellation

September 15th 2020 - A new pre-cancel endpoint that previews the cancellation fee immediately before a user cancels!

What's New?

Karhoo makes it easy to book a Taxi anywhere in the world, however Service Level Agreements are still bespoke per Fleet and vary greatly even within the same city.

Demand Partners and their passengers can now preview cancellation fee's with a new API!

The teams at Karhoo have been hard at work simplifying this complexity and have now reached the point where we are ready to expose the first feature from this body of work, 2-Step Cancellation.

How is this different from existing SLAs?

At the moment the Service Level Agreements passengers accept when booking is buried in the terms_and_conditions_url field for each quote_item. This rendered unstructured HTML table is meant to be displayed as a part of the booking disclaimer. While this works, it represents the minimum standard for disclosure and transparency we strive for at Karhoo.

Instead of digging through this table we will evaluate the rules for you right when you want to cancel.

How can I use this?

1. The first step is to call the new endpoint to get the fee for a booking right before you or your passengers intend to cancel.

GET v1/bookings/[id]/cancel-fee

This returns the following:

{
    "cancellation_fee": true,
    "fee": {
      "value": "1.00",
      "type": "FIXED",
      "currency": "EUR"
    }
}

When cancellation_fee is false then no fee applies!

When cancellation_fee is true then you can disclose the fee to better inform the passenger or booker of the trip.

2. The second step involves a request to the existing cancel endpoint to successfully cancel the booking.

POST v1/bookings/[id]/cancel

{
   "reason": "DRIVER_IS_LATE",
   "explanation": "Waited 10 minutes"
}

👍

Try it out!

Head on over to the updated Bookings API to kick the tires.