Cancellations & Refunds
Cancel one or more upcoming OrderItems
Last updated
Cancel one or more upcoming OrderItems
Last updated
This guide is intended for a wishing to implement and understand how Cancellations & Refunds work with imin's Booking Platform.
There are two types of Cancellations that can happen:
: decides that they can no longer make an (e.g. if the Customer has fallen ill).
: cancels their Opportunity (e.g. if the instructor has fallen ill).
All successful cancellations will result in the Customer receiving a .
For either type of successful Cancellation, the Booking System issues a cancelled OrderItem in their OrdersFeed which triggers imin to process the Refund, taking these steps:
imin will apply the Refund to the Customer's account. The Customer will see their bank balance go up by the amount of the Refund.
imin will send the Customer an email informing them of the successful Refund.
All potentially cancellable OrderItems can be found using the endpoint.
Not all OrderItems are Customer cancellable. The conditions that determine cancellability are detailed in the Booking Spec . We have consolidated this logic into a boolean field named imin:isPresentlyCancellable
. This field is calculated at time of the request.
A successful cancellation request does not guarantee that the cancellation is successful. It means that the request has satisfied the pre-conditions and the request has been sent to the .
Note that cancellations will not always be successful as imin:isPresentlyCancellable
is time dependant. If the cancellation request is not successful, this will be indicated in the response. Please use this to determine how to respond to the customer (e.g. an error modal).
X-API-KEY
must be provided when making the request to this endpoint. This authorizes you to access the API for your customers.
PATCH https://book.imin.co/api/v2/orders/:orderIdentifier
This request must be made Server-side. Otherwise, it would be possible to view the secret API key with a browser.
Body:
orderIdentifier
: Identifier of the Order. Can be found in imin:order['identifier']
in the OrderItem
orderItemIdentifier
: Identifier of OrderItem to cancel
For a successful cancellation request, the response will have a 204 HTTP status code and no body.
We suggest that when the OrderItem has the status of CustomerCancellationPending
it is reflected to the customer to inform them of the status of their request. Upon cancellation confirmation by the booking system, the status will transition to CustomerCancelled
, a refund will be triggered, and a cancellation email will be sent to the customer.
If cancellation request is not successful, response will have 400 HTTP status code and body:
Seller Requested Cancellations are out of the scope for this guide as they are implemented by the Booking System.
Seller Requested Cancellation will result in a Refund being issued to the Customer. More details can be found in the Refund section above.
This endpoint is an implementation of the .
The cancellation request will also be reflected in the responses from the and theendpoints. The appropriate OrderItems will now have the following:
For more info, please review in the Booking Spec.