Verifying a discount code before checkout

New Member
6 0 0

Would like to write a shopify page that prompt user to enter a discount code, then verify the code before redirecting to a specific shopify product collections page. What I need is an API that help verifying the code entered. I browsed through API help but all I get is applying discount code during checkout. Does that mean I cannot verify a discount code before checkout, or is there something I missed?

Thank you in advance for your help.

0 Likes
Shopify Staff
Shopify Staff
1099 75 140

Hey Jason, 

 

I think that the DiscountCode API endpoint will help you out here. You could use it to search by code, and if you get a 404 back then that code doesn't exist.

0 Likes
Highlighted
New Member
6 0 0
Josh, thanks for your reply. But I try not to use REST Admin API due to security issue. Is there other way?
0 Likes