Skip to main content
Contributor I
May 16, 2022
Solved

Abandoned cart flow: Dynamic coupon code button "unable to find coupon code"

  • May 16, 2022
  • 3 replies
  • 625 views

Hi all! 

 

I’m trying to add a dynamic coupon code button to my abandoned cart flow so that the customer can access a discount on their cart. I did this with the following:

 

https://www.mywebsite.com/STOREID/checkouts/{{ event.extra.token }}?discount={% coupon_code 'TESTCODE' %}

 

When I send a test email I’m then finding the below error message in the discount code section of the cart

 

'Unable to find coupon with code: TESTCODE. It may have been deleted.'

 

The discount code is still valid so I’m wondering why this is happening? Can anybody help? 

This topic has been closed for replies.
Best answer by Bobi N.

@AniMus 

Are you sure you created the TESTCODE as dynamic coupon code in klaviyo? For this to work this code must be created as dynamic in klaviyo and it won’t work with Shopify static codes. If you can share screenshot of how you created the code maybe I can help more, like this I can’t be sure where the mistake happened..

 

3 replies

Bobi N.
Partner - Platinum
Bobi N.Answer
Champion & Partner
May 17, 2022

@AniMus 

Are you sure you created the TESTCODE as dynamic coupon code in klaviyo? For this to work this code must be created as dynamic in klaviyo and it won’t work with Shopify static codes. If you can share screenshot of how you created the code maybe I can help more, like this I can’t be sure where the mistake happened..

 

Head Email Marketing Technician at Flowium
AniMusAuthor
Contributor I
May 18, 2022

I think that was maybe the case! Now when you click on the button it has in the discount code slot on the page “TESTCODE-PREVIEW” - I take it when a customer does it, it will just be the code and not have preview added on which creates an error?

Bobi N.
Partner - Platinum
Champion & Partner
May 19, 2022

@AniMus 

Yes that is correct.. seeing it as PREVIEW when previewing the email means that the code is working and when the customer get it it will be 8 characters with random letters and numbers

Head Email Marketing Technician at Flowium