Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to get the phone number customers dialed when calling in. I have tried all of the CALLERID options available but to no avail. Any ides?

share|improve this question

2 Answers 2

up vote 0 down vote accepted

You're looking for the ${DNIS} variable what it contains will depend on what your telecom provider is passing. Either 0,4, or 7 digits.

CallerID is the number that the person is calling FROM, DNIS is the number that the caller CALLED.

This is the NoOp we use to see what the DNIS is, put it into your "landing" for your telecom, open up the asterisk console and see what it comes up with:

exten => _.,1,NoOp("DNID is ${DNID}, DNIS is ${DNIS}, EXTEN is ${EXTEN}, Caller: ${CALLERID(num)}")

Also, check with your telecom provider and make sure they are actually passing the number sorry ... having a brain fart right now forget the exact term.

share|improve this answer
    
Thank you both for the reply but neither seems to return the 8XX number. Any other possibilities/approaches? –  Benny May 27 '10 at 3:54
    
@Benny: See updates, also you probably won't see the 8XX part of the number all local telecoms i've worked with generally only pass NXX-XXXX not NPA-NXX-XXXX (you might be able to talk them into it but probably not for smaller amounts of telecom) –  Zypher May 27 '10 at 4:02
    
No such luck. When using the above noop to print everything, nothing has a value. Is this something I need to work out with my provider at this point? –  Benny May 27 '10 at 4:45
    
@Benny: Yep that seems like the best place to start now. –  Zypher May 27 '10 at 4:54

Have a look at your CDR's. It'll be either dst or a substring of dstcontext if I'm not wrong.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.