I’m trying to build a simple routing logic in CXone Studio that checks a custom field before branching. The goal is to set a flag variable based on the priority value from the REST proxy response, then use an IF action to route high-priority calls.
The REST call works fine and returns JSON. I’m using an ASSIGN action to parse the response:
ASSIGN
Set: $flag.highPriority
Value: $restProxy.response.priority == "high"
Then the IF action checks:
IF
Condition: $flag.highPriority == true
Branch: High Priority Queue
The issue is the IF action always falls through to the default branch. Debugging shows $flag.highPriority is empty or null after the ASSIGN step, even though the REST response clearly contains "priority": "high".
Is there a specific syntax for boolean evaluation in ASSIGN actions? Or do I need to use a string comparison in the IF condition instead? The documentation isn’t clear on how complex expressions are handled in the assignment value field.
We’ve tried wrapping the expression in quotes, but that just sets the variable to a string literal rather than evaluating the condition. Any ideas on how to properly set a boolean flag from a REST response value in Studio?