Use JavaScript to personalize actions

Ui / Improvements Api / Developers

Do you need to reshape your trigger data or perform calculations to reformat values? This update lets you manipulate values in Create or Update Person and Create Event actions using JavaScript return statements. If you're already familiar with JavaScript, you may have an easier time using JavaScript to convert and re-shape JSON values than you might with Liquid.

Use JavaScript to personalize actions

For example, where you might have checked if a variable existed by writing a complicated Liquid if statement, you can now write simple JavaScript instead!

return trigger.plan_name ?? 'free_trial';
{% if trigger.plan_name != blank %}
  {{ trigger.plan_name }}
{% else %}
  free_trial
{% endif %}