Asterisk func channel
Synopsis:
CHANNEL(item)Description:
Gets/set various pieces of information about the channel. (New in 1.4)item may be one of the following:
| Read/write | Item | Description |
|---|---|---|
| R/O | audioreadformat | format currently being read |
| R/O | audionativeformat | format used natively for audio |
| R/O | audiowriteformat | format currently being written |
| R/W | callgroup | call groups for call pickup |
| R/O | channeltype | technology used for channel |
| R/W | language | language for sounds played |
| R/W | musicclass | class (from musiconhold.conf) for hold music |
| R/O | state | state for channel |
| R/W | tonezone | zone for indications played |
| R/O | videonativeformat | format used natively for video |
Notes
- Those items marked R/W above may be both read and set.
- *CLI> show function CHANNEL
- Additional items may be available from the channel driver providing the channel; see its documentation for details.
- Any item requested that is not available on the current channel will return an empty string.
Return value
Returns the resulting string.Example
exten => s,1,Set(foo=${CHANNEL(channeltype)})exten => s,1,Set(CHANNEL(callgroup)=g3)

Comments