From Zenitel Wiki
The IF and ENDIF statements are used in the Event Handler. If the expression following the IF evaluates to the number zero, the following statements are skipped until a (matching) ENDIF is found. The IF statement can test numeric values only.
The IF - ENDIF statements can be nested.
The statement STOP stops the execution of the action string.