N
Novu•12mo 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
bjornaerOP•12mo ago
happy to share my custom code email
Tomer Barnea
Tomer Barnea•12mo ago
@Engineering can we get your help here today? 🙂
Gali Baum
Gali Baum•11mo 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•11mo ago
@bjornaer Do you mind sharing the custom code email content?
bjornaer
bjornaerOP•11mo 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•11mo 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•11mo ago
Issue DVRL-160 created.
bjornaer
bjornaerOP•11mo ago
understood! thanks @Pawan Jain for clarifying and creating the issue for docs
Want results from more Discord servers?
Add your server