Problem : How to change monitor filename on outbound calls? need help please

I need to change the outbound monitor filename on all out bound calls. I found you can do this with this command and Ive included it in extensions_custom.conf, but it is not working. If I manually set it in extensions_additional.conf it works,but then if FreePBX reloads from the GUI it will rewrite this file. Does anyone have any suggestions?

exten = _.,s,Set(TOUCH_MONITOR=${AMPUSER}-)



I’m not interested in getting the uniqueid instead of phone number, what should I do with it,
we are running a call centre and we have to send the recording to our customers, which we can get only from
phone number,

Can anyone of asterisk guru, put the correct code to make this change.

will be very thankful to you.



Please post the code you used to get the output you wanted. That would be useful for me also.


For *1 recording (on demand)

Since FreePBX recreates the extensions.conf file everytime you have to make the changes in /admin/modules/core/etc/extensions.conf file. Here is the context I changed

exten => s,1,GotoIf($[${LEN(${BLINDTRANSFER})} > 0]?2:4)
exten => s,2,ResetCDR(w)
exten => s,3,StopMonitor()
exten => s,4,AGI(recordingcheck,${STRFTIME(${EPOCH},%Y%m%d-%H%M%S)},${UNIQUEID})
exten => s,5,Noop(No recording needed)
exten => s,6,Set(TOUCH_MONITOR=${EXTTOCALL}-${AMPUSER}) Here is where you can change the file name for *1 recording.
exten => s,999,MixMonitor(${CALLFILENAME}.wav)

If you want to change the file name for the record all calls option in the gui go to the /admin/modules/core/agi-bin/recordingcheck file and you will see where it creates the file names for inbound and outbound calls.

Hope this helps. Remember to back up your files first. :slight_smile: