Skip to main content

I’m creating a metric flow in Klaviyo and have an event variable, amount_dollars, that gets sent with each payload. Within an email that triggers off of the flow, I want to change one word depending on how large amount_dollars is; e.g. I want it to say “extremely” if amount_dollars is greater than 500. I tried writing the following into my email within the flow:

{{% if event.amount_dollars>500 %}}extremely {{% endif %}}

 

But when I do, I get an error message. How can I create an if statement based on metric event variables?

Hello @Lle4,

Thank you for sharing your question with the Klaviyo Community.

Your “if” statement should only have a single bracket around each item and should also include a space between dollars and the figure. So using the example of 100 instead of 500 dollars it should look like the following:

Thanks and have a wonderful day!


Thanks so much!!


Reply