Skip to content

Liquid and Formulas ​

Liquid turns a template into text using the data available when it runs. In Nawfe, use it to insert workflow values into an email, format a date, build an execution name, or calculate a field in a form.

The Liquid features available in Nawfe depend on where you write the expression.

Use the variable selector ​

The variable selector, also called the variable picker, is the menu for browsing the values available in the current setting. In a Liquid-enabled editor, it builds a Liquid expression for you, including the variable path and any formatting option you choose.

Depending on the editor, your selection appears as a labeled chip or as Liquid text. The chip represents the same expression you could write yourself:

SelectionEquivalent Liquid expression
Process → Name{{ process.name }}
Process → Current Execution → Created At → Short Date{{ processExecution.createdAt | date_fmt: "DATE_SHORT" }}

The expression reads the value when the template or formula runs; selecting a variable does not copy its current value into the text. Use the selector to insert the correct reference, then add text or supported filters when you need to build a more detailed formula.

Choose the right environment ​

CapabilityWorkflow templatesForm logic formulas
Insert values with {{ ... }}YesYes
Combine literal text and valuesYesYes
Read process, execution, and earlier step dataYes, when available to the current stepNo; formulas read current form fields
Read current form answers with fields.<field>.valueNoYes
Transform values with filtersAll supported filtersOnly the approved formula filters
Use {% ... %} tags for conditions, loops, or assignmentsYesNo tags
Format dates with date_fmt or numbers with number_fmtYesNo
ResultText for the setting being evaluatedText converted to the target field's type

Workflow templates include Liquid-enabled settings such as email subjects and bodies, HTTP request templates, execution names, and text assignments in Set Variable. A plain text or typed setting does not become a template just because you enter Liquid into it. Use the variable selector where the builder provides one.

Form logic formulas are the Formula source in a form logic Value action. They run against answers in the current form as it changes. Use rule conditions for conditional behavior. Workflow variables selected through a separate Variable source are not extra roots inside a formula.

First workflow template ​

liquid
Process: {{ process.name }}
Execution: {{ processExecution.name | default: "New request" }}
Started: {{ processExecution.createdAt | date_fmt: "DATE_MED" }}

Each {{ ... }} inserts a value. A pipe (|) passes that value through a filter. Here, default supplies fallback text and date_fmt formats the start date using the workflow's workspace settings.

First form formula ​

Suppose the current form has Number Input fields labeled Quantity and Unit Price, plus a Number Input field labeled Total.

  1. Open the form's logic editor.
  2. Add an Always Runs rule.
  3. Add a Value action targeting Total.
  4. Select Formula and enter:
liquid
{{ fields.quantity.value | default: 0 | times: fields.unit_price.value | round: 2 }}

For quantity 3 and unit price 12.5, the result is 37.5. Make Total read only with an Editability action if people should not replace the calculated value.

Use the editor's field mentions to insert the actual references for your form. The names in these examples are sample field aliases, not fields Nawfe creates automatically.

  • Syntax and variables: expressions, data paths, types, and missing values.
  • Tags: conditions, loops, temporary variables, comments, and supported boundaries.
  • Filters: the supported filter reference, examples, and formula availability.
  • Form formulas: field references, calculated values, validation, and troubleshooting.