Asterisk retrieve the IP of extension?

I need to send http action to the Snom Phone via Http. So I need the IP for extension. have a way to get it Dynamically by Manager or Dialplan?

Hi

Will push it out to the script, you will need to do a bit of manipulation of the header to extract the IP. But this works.

Ian
www.cyber-cottage.co.uk

what is myscript?

Its the script i’m sending the variables to .

Ian
www.cyber-cottage.co.uk

now I see you talking about SIP_HEADER(VIA) that return Header.
But which header is return? Callee or Caller?

Now I find that have ${SIPPEER(203,ip) , have a reason that you address to use SIP_HEADER(VIA) ?

Hi

I used the via for historic reasons, But yes SIPPEER does work, what are you trying to do ?

Ian

I try to Control my Phone like thaht:

10.0.0.3/command.htm?key=OffHOOK ;get dial tone
10.0.0.3/command.htm?number=204 ;dial

I still have q:

+why this below line is not work, even it work wrom browser?
exten => 9777,n,sendurl(10.0.0.3/command.htm?key=OffHOOK,wait)

+it’s reasonable to call SIPPEER every time I need to send http? or beter way is use with fix IP? (what is the overhead of this call?)

+How I can execute App from Managar API? and specially how I exec sippeer?

+I see on Manager Action:
Action : SIPShowPeer
Peer: 205

but is not recognize this action!?
and Action SIPpeers it’s return All list, and take lot of resource when my need is only one sip.