Cancel a rental

Flags a rental (pickup or return) as canceled, according to the specified parameters. Use cases include:

  • a wrong manipulation at the terminal by the operator that needs to be canceled
  • a justified request by a customer who is not satisfied by the offered service and wants his/her money back
Endpoint
Copy

Rentals can be canceled only if an unique partner_transaction_id was sent during the initial creation of the rental (pickup or return). Based on this identifier, the rental can be flagged as canceled (but will not be deleted).

Request parameters

Path variables

  • partner_transaction_id (required) The unique id of the original transaction that created the rental and is asked to be canceled, as given by the partner terminal software.

Query parameters

  • lang (optional) The language to be used for the response. Accepted values: see Locales
  • slip_width (optional) The width of the sales slip in characters. Accepted values: 32, 42

Response

Response body

If the cancel request fails, the error will be reported by the HTTP status.

For HTTP status 200 OK the response body contains a JSON object with the following structure:

JSON
Copy

Response items

  • status (string) The request status. Can be one of pickup_canceled, return_canceled, error.
  • error_type (string or null) The error type, expressed in a codified expression. It can be either null for a successful request or one of the following: original_rental_not_found, general_error.
  • error_message (string or null) The verbose description of the error in the requested locale.
  • rental_type (string) Either pickup or return.
  • charge_currency (string) The currency used for the money transaction (ISO 4217 alphabetic currency code).
  • total_amounts (object of numbers) The total amounts of the initial transaction that is being canceled, listed by category. See Total amounts for more.
Type to search, ESC to discard
Type to search, ESC to discard
Type to search, ESC to discard