documentation: Document built-in system and channel vars

Documentation for built-in special system and channel
vars is currently outdated, and updating is a manual
process since there is no XML documentation for these
anywhere.

This adds documentation for system vars to func_env
and for channel vars to func_channel so that they
appear along with the corresponding fields that would
be accessed using a function.

ASTERISK-29848 #close

Change-Id: I6997f925c4a45fffe71321861f5898a8b7182fa9
This commit is contained in:
Naveen Albert
2022-01-08 20:35:09 +00:00
committed by Friendly Automation
parent fbaf74bd3a
commit 5f59e0d36f
2 changed files with 84 additions and 0 deletions

View File

@@ -278,6 +278,41 @@
same => n,Log(NOTICE, This channel is: ${CHANNEL(state)})
</example>
<xi:include xpointer="xpointer(/docs/info[@name='CHANNEL_EXAMPLES'])" />
<para>The following channel variables are available as special built-in
dialplan channel variables. These variables cannot be set or modified
and are read-only.</para>
<variablelist>
<variable name="CALLINGPRES">
<para>Caller ID presentation for incoming calls (PRI channels)</para>
</variable>
<variable name="CALLINGANI2">
<para>Caller ANI2 (PRI channels)</para>
</variable>
<variable name="CALLINGTON">
<para>Caller Type of Number (PRI channels)</para>
</variable>
<variable name="CALLINGTNS">
<para>Transit Network Selector (PRI channels)</para>
</variable>
<variable name="EXTEN">
<para>Current extension</para>
</variable>
<variable name="CONTEXT">
<para>Current context</para>
</variable>
<variable name="PRIORITY">
<para>Current priority</para>
</variable>
<variable name="CHANNEL">
<para>Current channel name</para>
</variable>
<variable name="UNIQUEID">
<para>Current call unique identifier</para>
</variable>
<variable name="HANGUPCAUSE">
<para>Asterisk cause of hangup (inbound/outbound)</para>
</variable>
</variablelist>
</description>
</function>
***/