Search

verifyIssuedCoupon

Validate a coupon identifier. The function verifies that the coupon has indeed been issued previously (using saveIssuedCoupon), that it has not expired, and that it has not been redeemed yet (using redeemIssuedCoupon).

If coupon has not been issued, returns error 1040. If coupon has been redeemed already, returns error 1041. If coupon has expired, returns error 1045. If coupon is valid, returns error 0.

Input parameters

Parameter nameDescriptionPossible valueRequired
uniqueIdentifierUnique identifier of the coupon. Typically this is printed on the coupon as a barcode.String (20) yes

Response

Field nameTypeDescription
issuedCouponIDIntegerInternal ID of the validated coupon. This does not need to be checked however - it suffices to make sure that verifyIssuedCoupon() returns error code 0.
couponIDIntegerID if the coupon code.
uniqueIdentifierString (20)Identifier of the coupon, same that was passed as input parameter.
campaignNameString
expiryDateISO date (yyyy-mm-dd)