We are working through a bit of customization of our system, based on Trixbox CE 2.2 (Asterisk 1.2) with FreePBX 2.5.1, where on a custom trunk we set the Outbound Caller ID to the name and number of the project we are calling out for and have a Custom dial String of “Local/$OUTNUM$@project-a-outdial/n” to handle some calling logic.
Everything works fine, except that by setting the outbound caller id, we lose the number of the extension the call was made from.
For example, calling out from extensions 1004 and 1010, and setting the outbound callerid to 8005551212 results in all calls appearing to be from 8005551212.
I can see in the console that the extension number is there as part of the extension/channel information as the call begins, but once my macro is entered, the information is lost.
I’m sure there’s a way to maintain the information of which agent dialled the call, but I can not seem to find the right variable, or capture it before it is overwritten by the outbound callerid.
I have tried AGENTEXTEN, REALCALLERID, CHANNEL, EXTEN, SIPCALLID, MACRO_EXTEN, and possibly a few others.
Can I do something like “Local/$EXTEN$$OUTNUM$@queuedial/n” ? I haven’t really seen any additional information on what can be passed in a Custom Dial String (although I am still searching).
I’m hoping I can just modify the macro a little, and not have to mess with the FreePBX macros in order to accomplish this. I have a feeling this is a pretty obvious answer for someone a little more skilled at this than I am, and sure would appreciate any pointers.
Thanks in advance.
DionV