N
Novu•8mo ago
bjornaer

Can a variant condition read the digest step variables?

can I have an email variant step, which is used if the condition is step.total_count greater than 2 or step.digest Equal true? I tried setting it up, but nothing happened, maybe I need to use {{ }}? Or maybe those values are not accessible by the variant check?
8 Replies
bjornaer
bjornaer•8mo ago
happy to share my custom code email
Tomer Barnea
Tomer Barnea•8mo ago
@Engineering can we get your help here today? 🙂
Gali Baum
Gali Baum•8mo ago
It is accessible, but only in the Value side of a condition, not in the Key. Something like this where you add the key in the payload when you trigger
No description
empe
empe•8mo ago
@bjornaer Do you mind sharing the custom code email content?
bjornaer
bjornaer•8mo ago
hi everyone, I solved it using if checks directly inside the custom code section, I actually solved it speaking with @Tomer Barnea on Novu's chat widget.
Pawan Jain
Pawan Jain•8mo ago
Hi @bjornaer Thanks for sharing the use case. Currently, conditions based on digest variables are not supported. Only workaround is to use if/else in step content editor as you used
Linear
Linear•8mo ago
Issue DVRL-160 created.
bjornaer
bjornaer•8mo ago
understood! thanks @Pawan Jain for clarifying and creating the issue for docs
Want results from more Discord servers?
Add your server