Syntax
parseCognigyScriptCondition(condition)
Description
Evaluates a CognigyScript expression and returns atrue or false value.
CognigyScript allows you to embed expressions like {{context.value > 5}} within strings. This function extracts and evaluates such an expression, used in logic checks for Flows, conditions, or custom functions.
This function is useful for dynamically checking conditions at run-time based on session data and information from the Input, Context, or Profile objects.
Parameters:
condition:string— the CognigyScript condition to evaluate.
boolean | null — the result of the condition, or null if evaluation fails.