API Error Cases

Understand the custom error responses you may encounter when making requests to the Wallet and Coupon APIs.

Wallet API Errors

The following are the custom API errors that you may receive upon failure requests of the Wallet APIs:

Error CaseError DetailsApplicable API
Invalid or incorrect wallet_IdThe specified Wallet ID is invalid or does not exist.All Wallet APIs
Missing required path parameterThe PARAMETER_NAME is a mandatory key.All Wallet APIs
Invalid transactionTypeThis error occurs when the transactionType key is invalid. It must be either DEBIT or CREDIT.Debit/Credit Wallet API
Missing mandatory key in the payloadKEY_NAME is required.Debit/Credit Wallet API
Incorrect data type for pointsThe points field must be numeric.Debit/Credit Wallet API
Negative points passed in the requestpoints must always be a positive value.Debit/Credit Wallet API
Debit points exceed the active points in the user's walletThe points to be debited cannot exceed the available balance in the user's wallet.Debit/Credit Wallet API

Coupon API Errors

The following are the custom API errors that you may receive upon failure requests of the Coupon APIs:

Error CaseError DetailsApplicable API
Wrong field added in request body or mandatory fields not passedA required field KEY_NAME is missing in the request body.All APIs
Coupon is expiredThe coupon code has expired and is no longer valid.All APIs
Total coupon redemption limit exceededThe total redemption limit for the coupon has been exceeded.All APIs
Per-user redemption limit exceededThe per-user redemption limit for the coupon has been exceeded.All APIs
Daily/Weekly/Monthly redemption exceededThe coupon's daily, weekly, or monthly redemption limit has been exceeded.All APIs
Coupon not available for specific days or timesThe coupon is not valid during the current day or time.All APIs
Coupon cart validation failedThe coupon cart validation failed based on specified conditions.All APIs
Coupon product validation failedProduct validation failed due to invalid conditions.All APIs
User property validation failedUser property validation failed based on specified conditions.All APIs
Selected items: No product property value matchedThe selected item’s properties do not match the coupon requirements.All APIs
Applied coupon code is expiredThe applied coupon code has expired.Validate and Redeem APIs
Coupon code or ID missing in the request bodyThe coupon code or ID is missing or invalid in the request body.Validate and Redeem APIs
Non-redeemed coupon is revertedThe coupon cannot be reverted as it was never redeemed.Validate and Redeem APIs
Coupon code or ID is invalidThe provided coupon code or ID is invalid or not found.Validate and Redeem APIs
Validation is applied on metadata properties, but the key is not passed in the payloadThe required metadata key for validation is missing in the payload.Validate and Redeem APIs
User is not logged in and is attempting to validate the campaign user couponThe user must log in or sign up before redeeming the coupon code.Validate and Redeem APIs
Validation for selected items failedThe discount validation for selected items has been failed.Validate and Redeem APIs
OrderStatus contains wrong valuesThe order status provided is invalid; it should be one of pending, completed, or reverted.Redeem API
Duplicate orderId passedThe provided orderId has already been used for a previous transaction.Redeem/Revert API
Query parameter not passedA required query parameter query_param_key is missing in the request.Redeem/Revert API
Query parameter is wrongThe query parameter type must be either redeemed or reverted.Redeem/Revert API
order and item object not passedBoth order and item objects are required in the request body.Redeem/Revert API
Mandatory keys in item or order object not passedA mandatory key is missing from the order or item object.Redeem/Revert API
order and item objects passed, but mandatory keys have empty valuesThe mandatory key value in the order or item object cannot be empty.Redeem/Revert API