Need help with call recording filename

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Need help with call recording filename

Postby pendesarapen » Thu May 28, 2020 12:16 am

Hello guys,

Good day! I have set campaign recording to "allforce" and my goal is when an inbound call is answered by an agent, i have to get the generated recording filename and pass it into a PHP Script. is there any way i can achieve this? looking forward to any help on this. :|

Thank you in advance,

Asterisk version: Asterisk 13.29.2-vici
Vicidial Version: ViciBox v.9.0.2 200415-1712
pendesarapen
 
Posts: 4
Joined: Wed May 27, 2020 2:02 am

Re: Need help with call recording filename

Postby ambiorixg12 » Thu May 28, 2020 7:58 pm

Use the Dispo Call URL option to add your php script and the rec name using the recording_filename variable
ambiorixg12
 
Posts: 453
Joined: Tue Sep 17, 2013 10:35 pm

Re: Need help with call recording filename

Postby pendesarapen » Thu May 28, 2020 10:28 pm

ambiorixg12 wrote:Use the Dispo Call URL option to add your php script and the rec name using the recording_filename variable


Hi ambiorixg12,

Thank you for your idea. However, i am a total noob on vicidial and i don't know how to start. Can you give me example on how to do it? currently i execute my php script inside the dialplan (extensions.conf) because i am getting the $callerID value also but i have no idea how to do that using the Start Call URL or Dispo Call URL.
pendesarapen
 
Posts: 4
Joined: Wed May 27, 2020 2:02 am

Re: Need help with call recording filename

Postby pendesarapen » Fri May 29, 2020 12:51 am

I got it working now. Since Vicidial executes "agi-VDAD_ALL_inbound.agi" when inbound call is answered by an agent, I've added a line of code somewhere in agi script to get the CallerID and Campaign_rec_filename and pass it to my php script. Maybe on other future requirements i can make use of the Start Call URL or Dispo Call URL.

Thank you!
pendesarapen
 
Posts: 4
Joined: Wed May 27, 2020 2:02 am

Re: Need help with call recording filename

Postby williamconley » Fri May 29, 2020 3:26 pm

When a call ends, the dispo_call_url script is fired off by the server. If you do look at the instructions for the use (and paramaters) of the dispo_call_url, you will find that you can place a php script in that location and that script will be given the call information and the script will fire at the moment the agent pushes the "submit" button to indicate the outcome of the call. If you do not provide parameters, it will supply ALL information available. If you dump the $_GET in the php page, you'll find that there is a great deal of information available, including credentials. This same data set is available in start and end call as well as no-agent call urls, with slight adjustments for "information that does not yet exist" (such as "disposition/status" when the status has not yet been chosen).

This removes the need to edit any scripts in the system and allows upgrade without loss of function. While "upgrade-proof" may not seem like a big deal today, trust me when I say you really do want to keep track of every alteration in every file for when you upgrade. Vicidial has new features and bug fixes weekly (sometimes even daily), and upgrading is pretty easy. But if you have altered any files ...
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Need help with call recording filename

Postby pendesarapen » Mon Jun 01, 2020 2:55 am

williamconley wrote:When a call ends, the dispo_call_url script is fired off by the server. If you do look at the instructions for the use (and paramaters) of the dispo_call_url, you will find that you can place a php script in that location and that script will be given the call information and the script will fire at the moment the agent pushes the "submit" button to indicate the outcome of the call. If you do not provide parameters, it will supply ALL information available. If you dump the $_GET in the php page, you'll find that there is a great deal of information available, including credentials. This same data set is available in start and end call as well as no-agent call urls, with slight adjustments for "information that does not yet exist" (such as "disposition/status" when the status has not yet been chosen).

This removes the need to edit any scripts in the system and allows upgrade without loss of function. While "upgrade-proof" may not seem like a big deal today, trust me when I say you really do want to keep track of every alteration in every file for when you upgrade. Vicidial has new features and bug fixes weekly (sometimes even daily), and upgrading is pretty easy. But if you have altered any files ...


Hello william,

First of all, thank you very much for making it clear how it works. I understood now how to use this and i managed to get the variables available and pass it to my php script using dispo call url. I removed my previously added code inside the AGI script. I also used this documentation as reference - http://vicidial.org/docs/CALL_URL_FEATURES.txt

Again thank you :)
pendesarapen
 
Posts: 4
Joined: Wed May 27, 2020 2:02 am


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 53 guests