Hey @geosal
Thank you so much for coming to the Klaviyo Community for help with your show/hide content!
To identify the event variables you can use in your show/hide condition, navigate to the message editor within your flow or campaign, then click Preview.
In the preview modal, you’ll see sample event data from your most recent event. Scroll through the data to find the variable you want to use, then click that variable. Then, copy the resulting variable tag.
Note that you don’t need the curly brackets around the variable; you only need the variable text. In the screenshot below, you’ll see the variable tag {{ event|lookup:'Item Count' }}. You’ll only need the text event|lookup:'Item Count' for your show/hide condition. Similarly, if your variable tag was {{ event.extra.line_item.0.title }}, you can extract just the text — event.extra.line_item.0.title — from the tag.
Hope this helps! Thank you so much for being part of the Klaviyo Community!
Hi guys,
So, I'm trying to do this too using sku {{ event.extra.line_items.1.sku }} which I understand needs to be inputed into the logic as event.extra.line_items.1.sku, however i’m not sure how to write the logic. It seems to have changed recently, so I’ve tried various ways but can’t get it to work. Could someone please advise?
(Additional info: I’m trying to display a CTA which will link to a product guide per sku. I’m using Checkout Started data to get access to all products in basket.)
'COLHSN3' in event|lookup:'sku'
sku: COLHSN3
event|lookup:'sku’: COLHSN3
event|lookup:'sku’ = COLHSN3
sku = COLHSN3
sku = 'COLHSN3'
sku == « COLHSN3 »
event|lookup:’sku’ = COLHSN3
event|lookup:’sku’ : COLHSN3
person|lookup:’sku’ = COLHSN3
person|lookup:’sku’ = ‘COLHSN3’
person|lookup:’sku’: 'COLHSN3'
Thanks so much !
Jalna