Menu
Do While
Run the loop body first, then repeat while a condition stays true, up to a max iteration cap.
Use it in a workflow
- Add a step and choose the For Loop connector.
- Pick the Do While action (under workflow).
- Fill in the fields below, then reference the result from later steps as
{{doWhile.response.data}}.
Fields
Examples
Poll until a job finishes
Repeat the loop body (e.g. a status-check HTTP call) while a runtime variable still reads 'pending', up to a safety cap of 50 attempts
{
"continueCondition": {
"type": "condition",
"lhs": "{{runtimeVariables.jobStatus}}",
"operator": "equals",
"rhs": "pending"
},
"maxIterations": 50,
"indexVariable": "attempt"
}
Need more? See the For Loop guide for connection setup and behaviour shared by every action.
Was this page helpful?