[Asterisk-Users] SetCallerID based on extension

Jodie Crouch jodie.crouch at gmail.com
Sat Jun 4 22:39:03 MST 2005


I am going through previous posts, but I am not finding anything.  I
apologize if this has been covered already.

I want to be able to change the CallerID for outbound calls based on
the extension making the calls.  However, I don't really need this
level of granularity.  I have one asterisk box serving many markets. 
I want to set the CallerID to a local number in each market.  So, of
someone in Dallas, TX calls out it shows our Dallas number.  If
someone in Arizona calls out, I want it to show our Arizona number.  I
figured the best way to do this would be based on the extension, but
if someone else has a better idea, please let me know.

So, if we are going to set the caller id based on the extension, then
this is what I need to know how to do.

Right now, outbound is configured as below, in the extensions.conf file.

exten => _1NXXXXXXXXX,1,Dial(SIP/9725432876/${EXTEN})
exten => _1NXXXXXXXXX,2,Hangup


Please let me know how I can create this same process but change the
CallerID to 2134531762 instead of 9725432876 when someone calls from
extension 112 and to 9725432876 for extension 317.

Thanks!
Jodie



More information about the asterisk-users mailing list