This is Elias from Shopify Support. I'd be happy to lend a hand with this!
When creating a discount code, you can set a Usage limits and limit your discount code to one use. This way, the discount code is unique and only the first person to checkout with the code will be able to use it.
Here's the Usage limits section when creating a discount code:
Do you offer unique discount codes often and why? Do you offer store wide discounts as well?
Thanks for the reply. Yes I know that you can set the discount code with limit.
But is there posible way to check if discount code are used.
Check if someone already used discount code
If noone isn't used then in shopify store there is showing some div or image element and visitor can claim that discount code, but if code is used then there is no div element or image.
Thanks for following up!
After setting up your discount codes, you can view the number of times used directly on the Discounts page. For example, if the discount code doesn't have a limit, then you'll see the total number of uses. However, if the discount code has a limit, then it will show how many times it was used out of how many times is available (eg. 3/10).
Let me know if this is what you're looking for?