Set, export, and legs
When performing a bridge
to connect two different call legs, you may find that you have a channel variable in the originating leg (the A leg) that you wish to be available also in the B leg. Sometimes you have a value that you want only to appear in one leg or the other. The techniques presented in this section will explain how to accomplish these tasks.
Set versus export
There are two general API commands available to set and modify information about calls and the way the switch will process calls. These commands are named set
and export
.
The
set
command sets variables on a channel, for use during the duration of the channel. These variables can then be accessed by applications (such as CDR) or by Dialplan condition testing. You have seen the set
command used several times in examples throughout this book.
The export
command takes set
a step further. It sets variables on the current channel but also saves the variable for use in any future channels created that stem from...