Continue If Block

Conditional execution in Scout workflows

The Continue If block is designed to evaluate a condition using Jinja templating and decide whether to proceed with executing subsequent blocks in a workflow. This functionality is crucial for implementing conditional logic that controls the workflow’s execution path based on dynamic criteria.

Configuration (Required)

condition
codeRequired

Template that should evaluate to True or False. This condition determines whether the workflow will continue executing subsequent blocks. Ensure the logic accurately reflects the decision criteria needed for your specific use case.

See Workflow Logic & State > State Management for details on using dynamic variables in this block.

Outputs

The block outputs the evaluated condition as a boolean, indicating whether the condition was True. Additionally, it includes details such as the response format and elapsed time for the block execution.

Usage Context

Use this block to control the execution path of your workflow based on dynamic conditions. The condition should be a Jinja template that evaluates to a boolean value.

Best Practices

  • Ensure the condition template is correctly formatted to evaluate to a boolean: Proper formatting is crucial for the block to function as intended.
  • Use Jinja templating to dynamically construct conditions based on the workflow state: This allows for flexible and context-aware decision-making within your workflows.
  • Consider the implications of skipped nodes if the condition evaluates to False: Understand how skipping nodes might affect the overall workflow execution and outcomes.