Portal Community

Properties

PropertyTypeRequiredDefaultDescription
variable_name string Yes The name under which the value is stored in workflow memory. Must be a valid identifier (letters, numbers, underscores; no spaces). Case-sensitive. Examples: invoiceTotal, customerId, isApproved.
value string | number | boolean | null No null A literal value to assign directly. Can be a string ("pending"), number (42), or boolean (true). Set to null to remove the variable from memory entirely. Mutually exclusive with value_expression — if both are supplied, value_expression takes precedence.
value_expression string (BizFirst expression) No A BizFirst expression evaluated at runtime to produce the value. Supports all expression prefixes: {@ $input.current.amount }, {@ var.subtotal + var.tax }, {@ output.GetCustomer.data.name }. When present, overrides any value literal.
scope string enum No execution Controls the lifetime and visibility of the variable.

execution — The variable lives for the entire workflow run and is accessible from any node.
local — The variable is scoped to the current execution block (e.g., inside a Loop or TryBlock) and is discarded when that block exits.
Expression Prefixes

The value_expression field supports the following context prefixes inside {@ ... }:

Scope Behaviour

Understanding variable scope is critical for loops and parallel branches:

ScopeAccessible FromLifetimeUse When
execution Any node in the entire workflow Entire workflow run You need the value after the current block completes; default choice for most scenarios.
local Only nodes within the same block (Loop body, TryBlock, etc.) Until the enclosing block exits Temporary loop scratch variables that should not pollute the top-level namespace.
Null Assignment Removes the Variable

Setting value to null (and providing no value_expression) will remove the named variable from memory completely. Downstream nodes that attempt to read a removed variable will receive null rather than an error, so design conditional logic accordingly.

Naming Conventions

Variable names must begin with a letter or underscore and may contain only alphanumeric characters and underscores. The runtime is case-sensitive: invoiceTotal and InvoiceTotal are two different variables. Recommended conventions:

JSON Configuration Example

{
  "node_type": "VariableAssignment",
  "name": "StoreInvoiceTotal",
  "config": {
    "variable_name": "invoiceTotal",
    "value_expression": "{@ var.subtotal + var.taxAmount }",
    "scope": "execution"
  }
}