Override Caller ID to one EXT

Heres the setup:

Ext 10 is in ring group 11
Ext 20 is in ring group 21

Ext 10 calls ext 30 but wants the caller id to show up 11
Ext 20 calls ext 30 but wants the caller id to show up 21

Currently I have it set up so that ext dials a ring group that runs for 1 sec and terminates at set caller id. The set caller id ends to another ring group with the correct ext. The set caller id overrides the starting and inserts a different one. Is there a cleaner way to do this or is this the best way?

Bump? Anyone?

Do you want this for all internal call?

If so, in the extensions advanced settings see…

Much Luck.

1 Like

I just want it to do this when calling the one extension.

Then i guess custom scripting is what you want.
(unless you want to keep it the way it is)

I’m not good with scripting but you’ll probably need to add in extensions_custom.conf a few lines that will catch the call [from-internal] replace the CID and send to the correct destination.

Much luck.

1 Like

from /etc/asterisk/extensions.conf

;-------------------------------------------------------------------------------
; macro-dialout-one-predial-hook
;
; this macro intentionally left blank so it may be safely overwritten for any custom
; requirements that an installation may have.
;
; the macro is called by macro-dialout-trunk just prior to making a Dial() attempt
; to an individual extension.
;
[macro-dialout-one-predial-hook]
exten => s,1,MacroExit()
;-------------------------------------------------------------------------------
1 Like

I figured it would be a custom. I’m not that good to know all the modifiers. How would it be written to do what I want to do?

That’s one for either you to learn or perhaps quicker:-

Good idea, PitzKey. I have only used the extensions custom to block an extension from taking to another one but I dont know how to change the caller id.

exten => s,n.set(CALLERID(num)=whateveryouwant)
exten => s,n.set(CALLERID(name)=somethingmoreinformative)