Skip to main content

Switch

This extension allows the call to be routed based on the variables set in the dialplan. When a call enters this door, variables from an external system can be loaded. Subsequently, the individual conditions are evaluated in order from top to bottom. If neither condition is met, the call is hung up, or directed to extension set as default extension.

Settings

The parameterMeaning
LookupPerforms a set query to an external system to obtain variables when entering this extension.
VariableThe name of the variable to make the decision against. It is entered without the Asterisk denotation $, eg my_variable or CALLERID(num)
OperatorCondition comparison type
is - is/equal
is not - is not/is not equal
greater than - more than
less than - less than
starts with - the text begins
ends with - the text ends
contains - the text contains
Value to compareThe value to which the variable is to be compared
Dial extensionThe extension number to dial if the condition is met.
Default extensionThe extension number to be dialed if none of the conditions are met.

Tips

Mergers and Demergers

If the same operation needs to be performed in the dialplan for several doors (e.g. playing a recording announcement), but then it should continue again with separate logic for each extension, then it is possible to set when entering the original extensions variable, from them continue into one playbackup and then use the switch to untangle into multiple extensions.

The parameterThe value
Variablecontinue
Operatoris not
Value to compare(empty)
Dial extension${continue}

Skipping an empty queue

If all agents are logged out of the queue, then in certain cases it is appropriate that the call did not enter the queue at all (e.g. skipping the message playback). This condition evaluates to number of available agents (ready or ACW) in queue ID 123. If the value is 0 (not available no operator), then connects the call to door 987, where there may be an answering machine, for example.

The parameterThe value
VariableQUEUE_MEMBER(queue123,logged)
Operatoris
Value to compare0
Dial extension987