Skip to main content

Run another flow and wait

Steprun-flowcontrolside effects

Starts another flow of this workspace on the same documents and waits until it finishes. Then you can go on by what it did, such as its status or the fields it found. The other flow keeps its own settings, connections and cost.

At a glance​

PropertyValue
Step namerun-flow
ResourceClusterStep (lumen.ai/v1alpha1)
Palette group, categorycontrol, logic
Credits0 credits each time it succeeds
Side effectsyes It changes something outside Lumen, so a retry asks first and a test shows what it would do instead of doing it.
Installation must providenothing

Inputs​

PropertyValue
Needsnothing
Producesfields
Works onitem one document at a time

Needs and Produces are data types (file, text, fields, email). The editor offers a step only where what it needs is already on the path. See Documents and data.

Outputs​

A later node references an output as {nodeId.field} in text, or nodeId.field in a condition.

OutputType
childRunstring
flowstring
statusstring
outcomestring
errorstring
timedOutboolean
outputobject

Settings​

Set under config: on the flow node. Text settings may contain {nodeId.field} placeholders.

SettingTypeDefaultDescription
flowrequiredstring-One of this workspace's flows that starts with 'Another flow starts it'. The step starts it on the same documents and waits for it to finish.minLength 1; maxLength 253
timeoutHoursinteger168TimeoutHours is how long to wait for the child; unset is 168 (7 days).minimum 1; maximum 720
onTimeoutstring"fail"OnTimeout is what the step does when the child is not done in time.one of fail, continue
onFailurestring"fail"OnFailure is what the step does when the child fails.one of fail, continue

The full JSON Schema of these settings: run-flow.schema.json.

Example​

Hand an email to the price list flow

config
flow: price-list-update
timeoutHours: 72

Use it in a flow​

A node that runs run-flow goes under spec.nodes of a Flow. Give it any id, and list the next node ids in next.

flow.yaml (spec.nodes)
- id: run-flow
stepRef: {name: run-flow}
config:
flow: price-list-update
timeoutHours: 72