Skip to main content

Set Variable

Controlled node

Overview​

Store a value for use elsewhere in the workflow.

Set Variable saves a named value for other nodes to read during the workflow. Use it for counters, intermediate results or state shared between branches.

Connect its done event to the next action so that the value is saved before that action reads it.

Inputs​

InputTypeDescription
setEventStores the value. This event input is named set, not run.
nameTextThe variable name or path, such as counter or customer.status.
valueDataThe value to store: text, a number, a boolean, a list or an object.
DynamicDataAdditional sockets created by placeholders in the name, such as item_{{id}}.

Setting the same name replaces its previous value. Supply a non-empty name and a value; a missing name or an undefined value does not create a variable. Values such as 0, false and null can be stored.

Properties​

PropertyTypeDescriptionDefault
isGlobalBooleanUse the top-level workflow’s shared scope when enabled; otherwise use the current flow’s local scope.false

“Global” means shared within the current workflow execution, including its nested workflows—not across the project or across separate job workers. Local values with the same name take precedence when read by a Variable node.

Use a database or library file for information that must remain available to separate workflow runs. A normal new workflow run starts with fresh variables.

Outputs​

OutputTypeDescription
doneEventContinues after the node finishes. It can also fire when no value was written because the name or value was missing.

Example​

Set name to counter, connect a Number value of 0 to value, and trigger set. A Variable node with name set to counter can now read it.

For structured data, first store a complete object under customer. You can then update an existing nested path such as customer.status.

For dynamic names, enter item_{{id}} in name, connect the resulting id socket, and supply value. An ID of 42 stores the value under item_42.