I heard that
exten => s,1,NoOp(${SIP_HEADER(TO)})
works - but not on an IAX2 trunk!
Is this easy to do?
My client has two companies with 2 numbers VOIP trunks and he would like to have calls treated differently in the dial plan depending on number dialled.
I noticed that the info I want is displayed when the call hangs up.
== Spawn extension (from-gradwell-01753, 01753208000, 6) exited non-zero on ‘IAX2/gradwell-1’
– Hungup 'IAX2/gradwell-1’
localhost*CLI>