Transactional Template: Correct Variables field in Code Example JSON
I have recently been trying to build a 2-part Opt-In using a Transactional template and had a very hard time getting the Variables correct, until a support operative corrected my syntax.
When adding variables and syntax is used, {{var:name}}, when not supplying a Default value (such as in a URL) the Variables list in the Example Code presented when the Template is Save/Published does not contain the {{var:name}} variables specified in the Template. Furthermore if you use incorrect syntax such as {{var:name:}} then they do appear even though they aren't valid!
The combination of the above issues lead me to waste a lot of time trying to understand why, when the variables I was using seemed to be valid the Template I was working on failed. It's extremely confusing!
![](https://secure.gravatar.com/avatar/791a0d5480bec6ae15958e2207a92d44?size=40&default=https%3A%2F%2Fassets.uvcdn.com%2Fpkg%2Fadmin%2Ficons%2Fuser_70-6bcf9e08938533adb9bac95c3e487cb2a6d4a32f890ca6fdc82e3072e0ea0368.png)