Cancel a Carpool Booking
POST/carpool/bookings/:booking_id/cancel
Cancels one booking with a reason from GET /carpool/cancel-reasons. This operation is available to the main account only.
A booking that is REQUESTED, APPROVED, EXPIRING_APPROVAL or in one of
the ACTIVE statuses becomes CANCELLED, and the driver is sent the
account's configured cancellation SMS and email. Any other status returns
409 with CARPOOL_BOOKING_STATE_CONFLICT, and nothing is changed.
See Cancelling and Force Terminating for the responses and how to retry.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 422
- 429
- 500
- 503
The cancelled booking.
The request body is declared as JSON but cannot be parsed, or is not a JSON object or array. Nothing was processed.
Unauthorized access. Authentication is required.
The operation requires main account credentials. Valid subusers receive this response.
The requested resource was not found.
The current status of the booking does not permit the action. Nothing was changed.
Validation failed for the input parameters.
Too Many Requests - the endpoint's rate limit has been exceeded. Retry after the number of seconds in the Retry-After header.
Response Headers
Seconds to wait before retrying. The same value as X-RateLimit-Retry-After-Seconds when that wait is non-negative. If the computed wait is negative, Retry-After is floored at 0.
Unix timestamp of the next earliest successful request.
Seconds until the next earliest successful request.
Internal server error.
Service temporarily unavailable. The request did not complete and can be retried after the number of seconds in the Retry-After header, when one is sent.
Response Headers
Seconds to wait before retrying. Sent with db_busy and db_pool_timeout.