Demonstrates completing a WAIT task via REST API for human-in-the-loop approval
Output: decision, result
wapi_prepare
│
WAIT [WAIT]
│
decision_switch [SWITCH]
├─ rejected: wapi_handle_decision
└─ default: wapi_handle_decision
HandleDecisionWorker (wapi_handle_decision): Worker for wapi_handle_decision — handles the outcome of the approval decision.
Reads decision. Outputs result.
PrepareWorker (wapi_prepare): Worker for wapi_prepare — prepares the workflow for the WAIT approval gate.
Outputs ready.
decision:${wait_ref.output.decision}result:${decision_switch_ref.output.result}
decision_switch [SWITCH]: switchCaseValue = ${wait_ref.output.decision}
11 tests cover valid inputs, boundary values, null handling, and error paths.
mvn testRun this example: see RUNNING.md for setup, build, and CLI instructions.