C.46. SIPCHANINFO()

SIPCHANINFO(field)
Returns information about the current SIP channel. The field may be one of:
peerip
The IP address of the peer
recvip
The source IP address of the peer
from
The URI from the From: header
uri
The URI from the Contact: header
useragent
The user agent
peername
The name of the peer
; Query the name of a SIP peer:
exten => 123,1,Set(foo=${SIPCHANINFO(peername)}) 

Note

Internal help for this application in Asterisk 1.4:
  -= Info about function 'SIPCHANINFO' =- 

[Syntax]
SIPCHANINFO(item)

[Synopsis]
Gets the specified SIP parameter from the current channel

[Description]
Valid items are:
- peerip                The IP address of the peer.
- recvip                The source IP address of the peer.
- from                  The URI from the From: header.
- uri                   The URI from the Contact: header.
- useragent             The useragent.
- peername              The name of the peer.
- t38passthrough        1 if T38 is offered or enabled in this channel, otherwise 0
diff output to internal help in Asterisk 1.2:
18d17
< - t38passthrough        1 if T38 is offered or enabled in this channel, otherwise 0