Scenario is:
I have generate orderCode in my side. Now I have popup that user can submit their email and order code. Then Klaviyo will send email to recipients.
Question:
How to check with database that orderCode is correct? In case someone have submit wrong code, Klaviyo won’t send email to.
Noted: orderCode storaged in database of website, not in Klaviyo. Klaviyo just storaged orderCode that recipient submitted.
You could use the Klaviyo API to set the order ID from your system as a custom property in the Klaviyo profile. The /identify endpoint was used for this, but the new API probably has a different endpoint for it.
Hi
Thank for answer, I thinking about this. But, User can have many orderID. How to storaged all orderID to doublecheck?
Klaviyo data storage has an array type which you can use, but personally I just store people’s most recent order ID.
Also, don’t forget that the Klaviyo ‘Placed Order’ event will probably contain your order ID. Here’s an example from my own site:

It sounds like you need to check the input with your INTERNAL database, not Klaviyo’s records. If you are trying to check with Klaviyo you can do a GetEvent call with your parameters to see if there is a record with that ID.
https://developers.klaviyo.com/en/reference/get_event
Hi
But soon after user submitted, they will receive email from Klaviyo because engage a list. How can I double check in same time to prevent if they submitted wrong code?
Log in to the Community
Use your Klaviyo credentials
Log in with Klaviyo
Use your Klaviyo credentials
Log in with KlaviyoEnter your E-mail address. We'll send you an e-mail with instructions to reset your password.