Authorizations
The access token received from the authorization server in the OAuth 2.0 flow.
Path Parameters
The original redemption ID to be rolled back (undone).
"r_0ba186c4824e4881e1"
Body
Add information about the original customer and order. Customer data and Redemption metadata can be updated in Voucherify when passing the customer data in the request body.
Request body schema for POST v1/redemptions/{redemptionId}/rollback
.
Reason for the rollback.
Customer's source_id
.
Order information.
A set of key/value pairs that you can send in the request body to update redemption metadata.
Response
Returns a redemption rollback object indicating the result of the rollback.
Response body schema for POST v1/redemptions/{redemptionId}/rollback
.
This is an object representing a redemption rollback.
Unique identifier of the redemption rollback.
"rr_0efeb3dab05e62e599"
The type of the object represented by the JSON
redemption_rollback
Timestamp representing the date and time when the object was created. The value is shown in the ISO 8601 format.
"2021-12-22T10:13:06.487Z"
Unique customer ID of the redeeming customer.
"cust_i8t5Tt6eiKG5K79KQlJ0Vs64"
Hashed customer source ID.
The metadata object stores all custom attributes assigned to the redemption.
Unique redemption ID of the parent redemption.
"r_0c656311b5878a2031"
Redemption result.
SUCCESS
, FAILURE
Redemption status.
SUCCEEDED
, FAILED
Order information.
Defines the details of the channel through which the redemption was issued.
Simplified customer data.
Defines the related object.
voucher
, promotion_tier
, redemption
Unique identifier of the related object. It is assigned by Voucherify, i.e. v_lfZi4rcEGe0sN9gmnj40bzwK2FH6QUno
for a voucher.
For gift cards, this represents the number of the credits restored to the card in the rolledback redemption. The number is a negative integer in the smallest currency unit, e.g. -100 cents for $1.00 added back to the card. For loyalty cards, this represents the number of loyalty points restored to the card in the rolledback redemption. The number is a negative integer.
-10000
System generated cause for the redemption being invalid in the context of the provided parameters.
If the result is FAILURE
, this parameter will provide a generic reason as to why the redemption failed.
"customer_rules_violated"
If the result is FAILURE
, this parameter will provide a more expanded reason as to why the redemption failed.
Defines the details of the voucher being originally redeemed. This is an object representing a voucher with categories and validation rules assignments. This is an object representing a voucher.
Contains details of the promotion tier and the parent campaign. This is an object representing a promotion tier. Promotion tiers are always assigned to a campaign and cannot be used standalone.
Contains the amount returned to the gift card in the redemption rollback. It is expressed as a negative integer.
Contains the number of points returned to the loyalty card in the reward redemption rollback. It is expressed as a negative integer.