Email sending after Call

Discussions about new features or changes in existing features

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

Email sending after Call

Postby weber43 » Tue Dec 13, 2011 7:25 pm

Is it possible to send a email after the call is end (Dispossion)?
weber43
 
Posts: 1
Joined: Tue Dec 13, 2011 7:23 pm

Postby williamconley » Sun Dec 18, 2011 12:25 pm

1) Welcome to the party!

2) when you post, please post your entire configuration including (but not limited to) your installation method and vicidial version with build.

this IS a requirement for posting along with reading the stickies (at the top of each forum) and the manager's manual (available on EFLO.net, both free and paid versions)

You should also post: Asterisk version, telephony hardware (model number is helpful here), cluster information if you have one, and whether any other software is installed in the box. If your installation method is "from scratch" you must post your operating system and should also post the .iso version from which you installed your original operating system.

If this is a "Cloud" or "Virtual" server, please note the technology involved along with the version of that techology (ie: VMware Server Version 2.0.2). If it is not, merely stating the Motherboard model # and CPU would be helpful.

Similar to This:

Vicibox X.X from .iso | Vicidial X.X.X-XXX Build XXXXXX-XXXX | Asterisk X.X.X | Single Server | No Digium/Sangoma Hardware | No Extra Software After Installation | Intel DG35EC | Core2Quad Q6600

3) Depends on your version! (Which you did not post.) If you have the appropriate version the "End Call URL" in the Campaign Modify screen will allow execution of a script that can do ... anything.
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby brett05 » Sat Jul 21, 2012 8:27 pm

yes very good idea if in each dispostion for sales vicidial can send a mail auto
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby Acidshock » Tue Aug 21, 2012 5:52 pm

This is already doable. Use the DispoCall URL and pass the info onto a php script which generates an email:

Dispo Call URL - This web URL address is not seen by the agent, but it is called every time a call is dispositioned by an agent if it is populated. Uses the same variables as the web form fields and scripts. dispo and talk_time are the variables you can use to retrieve the agent-defined disposition for the call and the actual talk time in seconds of the call. This URL can NOT be a relative path. Default is blank.
VERSION: 2.14-698a | BUILD: 190207-2301 | Asterisk:13.24.1-vici | Vicibox 8.1.2
Acidshock
 
Posts: 430
Joined: Wed Mar 03, 2010 3:19 pm

Re: Email sending after Call

Postby lconsult » Mon Aug 27, 2012 3:55 am

Is Dispo Call URL available for outbound campaigns? In Version 2.4-309a Build 120307-0248, I don't see any outbound information.

Also, is there information on the format to add system and custom form variables to the URL so that those values are added to the URL before it is executed?

Thanks!
lconsult
 
Posts: 1
Joined: Mon Aug 27, 2012 3:47 am

Re: Email sending after Call

Postby Acidshock » Fri Jan 18, 2013 10:47 am

A couple people PM'd me asking for examples so here is a modified and very much simplified version of a script I use. I put the url for it in the DispoCall URL option under the campaign. The URL looks like this:
Code: Select all
http://test.com/myscript.php?dispo=--A--dispo--B--&recording_filename=--A--recording_filename--B--&lead_id=--A--lead_id--B--&vendor_id=--A--vendor_lead_code--B--&list_id=--A--list_id--B--&gmt_offset_now=--A--gmt_offset_now--B--&phone_code=--A--phone_code--B--&phone_number=--A--phone_number--B--&title=--A--title--B--&first_name=--A--first_name--B--&middle_initial=--A--middle_initial--B--&last_name=--A--last_name--B--&address1=--A--address1--B--&address2=--A--address2--B--&address3=--A--address3--B--&city=--A--city--B--&state=--A--state--B--&province=--A--province--B--&postal_code=--A--postal_code--B--&country_code=--A--country_code--B--&gender=--A--gender--B--&date_of_birth=--A--date_of_birth--B--&alt_phone=--A--alt_phone--B--&email=--A--email--B--&security_phrase=--A--security_phrase--B--&comments=--A--comments--B--&user=--A--user--B--&pass=--A--pass--B--&campaign=--A--campaign--B--&phone_login=--A--phone_login--B--&fronter=--A--fronter--B--&closer=--A--user--B--&group=--A--group--B--&channel_group=--A--group--B--&SQLdate=--A--SQLdate--B--&epoch=--A--epoch--B--&uniqueid=--A--uniqueid--B--&rank=--A--rank--B--&owner=--A--owner--B--&customer_zap_channel=--A--customer_zap_channel--B--&server_ip=--A--server_ip--B--&SIPexten=--A--SIPexten--B--&session_id=--A--session_id--B--

Code: Select all

<?php
error_reporting(E_ALL);
 ini_set('display_errors','On');
    //Written by Drew Gilkey. 2/24/2012
    //Syntax:
    //Lead Disposition emailer
    //Description:
    //Emails information provided from VICIDIAL based on disposition.
    //VICIDIAL is a Open Source Asterisk Based call center solution. Visit them on http://www.vicidial.org
    //License:
    //AGPLv2
     
    set_time_limit(0);
    date_default_timezone_set('America/Los_Angeles');

  function emailinfo($agent, $location, $lead, $phone, $customer, $addinfo = "NA", $error_message = "Log was not sent" , $success_message = "Log was sent",$emailtouse = "test@test.com" )
{
    $owner_email = $emailtouse;
    $headers = 'From:' . $emailtouse;
    $subject = 'Agent: ' . $agent . ' ' . $location;
    $messageBody = "";
   
    $messageBody .= 'Agent: ' . $agent  . ' ' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Lead: ' . $lead . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Phone Number: ' . $phone . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Where was the action made: ' . $location . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Customer: ' . $customer . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Additional information: ' . $addinfo . "" . "\n";
   
   

    try{
        if(!mail($owner_email, $subject, $messageBody, $headers)){
            throw new Exception($error_message);
        }else{
            echo $success_message;
        }
    }catch(Exception $e){
        echo $e->getMessage() ."\n";
    }
}


    $user_id = $_REQUEST['user'];
   // $location = $WEB_SERVER . $WEB_PATH .
    $status = $_REQUEST['dispo'];
    $lead_id = $_REQUEST['lead_id'];
    $phone_number = $_REQUEST['phone_number'];
    $filename = $_REQUEST['recording_filename'];
    $customername = $_REQUEST['first_name'] . " " . $_REQUEST['last_name'];

    if($status == "SOLD")
    {
        emailinfo($_REQUEST['user'], "CallCenter1", $lead_id, $phone_number, $customername , " ", " ", " ", "testemail@destination.com");
        //You can also add code here to do something else like store the lead information into another database or table.
    }


?>

VERSION: 2.14-698a | BUILD: 190207-2301 | Asterisk:13.24.1-vici | Vicibox 8.1.2
Acidshock
 
Posts: 430
Joined: Wed Mar 03, 2010 3:19 pm

Re: Email sending after Call

Postby brett05 » Fri Jan 18, 2013 3:55 pm

thankkkkkkkkkkkkkkkkkkkkkkkkkkks
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby williamconley » Fri Jan 18, 2013 5:54 pm

Acidshock wrote:A couple people PM'd me asking for examples so here is a modified and very much simplified version of a script I use. I put the url for it in the DispoCall URL option under the campaign. The URL looks like this:
...

That, sir, was a beautiful post. Very cool. :)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby brett05 » Sat Jan 19, 2013 7:05 am

i have try it but he don't send any mail ??

do you have a idea
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby brett05 » Sat Jan 19, 2013 7:08 am

it's working sorry
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby brett05 » Sat Jan 19, 2013 8:44 am

Code: Select all
 function emailinfo($agent, $location, $lead, $phone, $customer, $addinfo = "NA", $error_message = "Log was not sent" , $success_message = "Log was sent",$emailtouse = "test@test.com" )
{
    $owner_email = $emailtouse;
    $headers = 'From:' . $emailtouse;
    $subject = 'Agent: ' . $agent . ' ' . $location;
    $messageBody = "";
   
    $messageBody .= 'Agent: ' . $agent  . ' ' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Lead: ' . $lead . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Phone Number: ' . $phone . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Where was the action made: ' . $location . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Customer: ' . $customer . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Additional information: ' . $addinfo . "" . "\n";


this will only sent agent name ,lead number , phone number, action made , customer and i want other messageBody as campaign name address, city etc..
ant one have a idea please
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby Acidshock » Sat Jan 19, 2013 1:05 pm

Quick and dirty way is to just add the info into the messageBody..

Code: Select all
function emailinfo($agent, $location, $lead, $phone, $customer, $addinfo = "NA", $error_message = "Log was not sent" , $success_message = "Log was sent",$emailtouse = "test@test.com" )
{
    $owner_email = $emailtouse;
    $headers = 'From:' . $emailtouse;
    $subject = 'Agent: ' . $agent . ' ' . $location;
    $messageBody = "";
   
    $messageBody .= 'Agent: ' . $agent  . ' ' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Lead: ' . $lead . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Phone Number: ' . $phone . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Where was the action made: ' . $location . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Customer: ' . $customer . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Additional information: ' . $addinfo . "" . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Campaign: ' . $_REQUEST['campaign'] . "" . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Address: ' . $_REQUEST['address1'] . "" . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'City: ' . $_REQUEST['city'] . "" . "\n";



In the example above I simply add the variables that were passed to the script directly into the function. If you look at the URL you see &campaign=... Well that is the variable. So Simply use $_REQUEST['campaign'] to pull that information. You can follow the pattern above to format the message body.
VERSION: 2.14-698a | BUILD: 190207-2301 | Asterisk:13.24.1-vici | Vicibox 8.1.2
Acidshock
 
Posts: 430
Joined: Wed Mar 03, 2010 3:19 pm

Re: Email sending after Call

Postby brett05 » Sat Jan 19, 2013 1:27 pm

i have try request variable before but with no result
really thank
i finaly question please ? it"s there a solution to send the record of status as attachement in mail ; not sendind the filename
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby Acidshock » Sun Jan 20, 2013 1:35 am

What type of attachment?
VERSION: 2.14-698a | BUILD: 190207-2301 | Asterisk:13.24.1-vici | Vicibox 8.1.2
Acidshock
 
Posts: 430
Joined: Wed Mar 03, 2010 3:19 pm

Re: Email sending after Call

Postby brett05 » Sun Jan 20, 2013 6:53 am

exemple the email script he will sent in each time the diso with lead information to the mail destination
it is possible to send with this information the recording wav or mp3 of the lead dispo as attachement mail
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby Acidshock » Mon Jan 21, 2013 7:27 pm

Do you need the actual mp3/wav attached or is a URL ok? Actual attachment is possible but you would have to have some background processes to catch the recording after conversion/compression. You wouldnt want to send a wav file for a 2 hour call via email.
VERSION: 2.14-698a | BUILD: 190207-2301 | Asterisk:13.24.1-vici | Vicibox 8.1.2
Acidshock
 
Posts: 430
Joined: Wed Mar 03, 2010 3:19 pm

Re: Email sending after Call

Postby brett05 » Mon Jan 21, 2013 8:14 pm

HI url call it's not ok
--A--recording_filename--B&--A--recording_id--B it"s show as recording_filename recording_id he not show the url of recording i think this is a bug in call dispo url because in webform it's working
but i welcom your solution to test it about to have some background processes to catch the recording after conversion/compression.;..

thnaks
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby williamconley » Mon Jan 21, 2013 8:20 pm

recording may not be available during dispo. you may need to build in a delay to the sending script in some fashion. remember that this file must be mixed and compressed before it lands in its final destination (and possibly even ftpd!)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby brett05 » Tue Jan 22, 2013 7:49 am

yes i confrme the same thing but i think this is possible
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby williamconley » Tue Jan 22, 2013 9:37 pm

you could either build a delay into the request ... so the script would sit there for XX minutes hoping the recording is available when it "fires" (lazy!)

or you could create a DB entry which is then checked by another process every 10 minutes and checked for availability of the recordings and sends those that are available. (slow and more involved)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby brett05 » Wed Jan 23, 2013 2:02 pm

Why recording_filename and talk_time if I insert them with dispo call URL it show no information but it's working in webform or script
Any solution to show the call recording filename and the time and date of the call
Thanks
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby williamconley » Wed Jan 23, 2013 10:53 pm

possibly because the web form or script may pull the data from a different place ... or perhaps they are wrong. how can the webform have the talk time if the call is not yet over? Seems a little odd to me ... 8-)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby gardo » Wed Jan 23, 2013 11:18 pm

A cron job doing all those can do the trick. Send the email with the sales recording attached to it. 15 minute interval can be a good starting point. By default the recordings are mixed (and FTPed) every 5 minutes.
http://goautodial.com
Empowering the next generation contact centers
gardo
 
Posts: 1926
Joined: Fri Sep 15, 2006 10:24 am
Location: Manila, 1004

Re: Email sending after Call

Postby brett05 » Thu Jan 24, 2013 9:04 am

Re: Email sending after Call
by gardo » Thu Jan 24, 2013 4:18 am

A cron job doing all those can do the trick. Send the email with the sales recording attached to it. 15 minute interval can be a good starting point. By default the recordings are mixed (and FTPed) every 5 minutes.


do you have a script used before or try it ?
Jasperreports & Queuemetrics & SugarCRM integration - Customization and Add-ons
Freepbx||Billing||Centos||Opensuse||Debian||Centos||Fedora||Sangoma||Diguim
brett05
 
Posts: 571
Joined: Sun May 24, 2009 5:48 pm
Location: tunisia

Re: Email sending after Call

Postby williamconley » Fri Jan 25, 2013 11:09 am

the main script is already listed here. to make it a cronjob requires a little modification to select the appropriate leads and supply the data to the rest of the already built script.
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby roll72 » Tue Mar 05, 2013 6:31 pm

Hello,

I'm been using Call Dispo URL as mentionned below for automatic survey campaign (using 8366 ). My purpose is to receive an email each time somebody is pressing a number after the voice message. But unfortunatly it is not working. Does the Call Dispo is working only with manual campaign and humain agent and not Survey campaign ?

my dispo Call URL :
VARhttp://xxx.xxx.xxx.xxx:82/sms2mailII ... umber--B--

I tested my remote URL by hand and from my vicidial server using a wget, and all is working correctly. I checked all the logs I can found to see if there is any clue but nothing.

I tested as well the following ULR as Dispo Call URL and I couldn't find any generated logs.
VARhttp://myvicidialip/agc/vdc_call_url ... dispo--B--

Does someone got similar issue ?

My vicidial is as follow :
VERSION: 2.2.1-237
BUILD: 100510-2015
roll72
 
Posts: 82
Joined: Wed Jun 10, 2009 12:32 pm

Re: Email sending after Call

Postby williamconley » Tue Mar 05, 2013 7:13 pm

dispo call url only works when the call is dispo'd by an agent. later versions have a "no agent url". consider upgrading :)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby roll72 » Wed Mar 06, 2013 2:07 am

Thanks for your quick answer.

I'm checking now the forum for the update.
roll72
 
Posts: 82
Joined: Wed Jun 10, 2009 12:32 pm

Re: Email sending after Call

Postby Nefariousparity » Thu Oct 17, 2013 3:23 pm

This looks awesome and exactly what I need. However, is there anyway to have this function only send email if a "SPECIFIC" disposition is selected? Like for instance a service call? So if my marketer calls customer and they need a service. When they disposition the call, as service, it sends the email out and not anything else.
|| DB Schema Version: 1609 || Asterisk 11.25.1-vici || BUILD: 190902-0839 ||VERSION: 2.14-718a||SVN: 3133||10xTelephony||1x Database||1x Slave||1x Web||1x Archive||ViciBox v.8.0.1
Nefariousparity
 
Posts: 327
Joined: Wed Sep 12, 2012 7:01 pm

Re: Email sending after Call

Postby mav2287 » Thu Oct 24, 2013 8:03 pm

Yes that is possible, the dirty and easy way to do it would be to put the whole thing into an if then statement based around the Service dispo. Keep in mind though that it is only the dispo code that shows not the description so if the code for service in your system is SRVC you will want to put that where I it says service. Unless there is a dispo_description variable I am unaware of you will have to use that.
Code: Select all
    if($_REQUEST['dispo'] == "Service")
    {
THE EMAIL SENDING CODE GOES HERE
}


It should look a little like this below. I'm a bit rusty on my php but that should work.
Code: Select all
if($_REQUEST['dispo'] == "SERVICE")
    {
  function emailinfo($agent, $location, $lead, $phone, $customer, $addinfo = "NA", $error_message = "Log was not sent" , $success_message = "Log was sent",$emailtouse = "test@test.com" );
{
    $owner_email = $emailtouse;
    $headers = 'From:' . $emailtouse;
    $subject = 'Agent: ' . $agent . ' ' . $location;
    $messageBody = "";
   
    $messageBody .= 'Agent: ' . $agent  . ' ' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Lead: ' . $lead . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Phone Number: ' . $phone . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Where was the action made: ' . $location . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Customer: ' . $customer . '' . "\n";
    $messageBody .= '' . "\n";
    $messageBody .= 'Additional information: ' . $addinfo . "" . "\n";
   
   

    try{
        if(!mail($owner_email, $subject, $messageBody, $headers)){
            throw new Exception($error_message);
        }else{
            echo $success_message;
        }
    }catch(Exception $e){
        echo $e->getMessage() ."\n";
    }
}


    $user_id = $_REQUEST['user'];
   // $location = $WEB_SERVER . $WEB_PATH .
    $status = $_REQUEST['dispo'];
    $lead_id = $_REQUEST['lead_id'];
    $phone_number = $_REQUEST['phone_number'];
    $filename = $_REQUEST['recording_filename'];
    $customername = $_REQUEST['first_name'] . " " . $_REQUEST['last_name'];



    }
ViciBox5.x86_64-5.0.3.preload from .iso upgraded to 13.1 | VERSION: 2.10-444c BUILD: 150129-0828 | 1.8.32.2-vici | Dual Server | No Digium/Sangoma Hardware | No Extra Software After Installation | Intel twin quad core 3Ghz Xeon chips | 32gb of RAM
mav2287
 
Posts: 256
Joined: Thu Oct 03, 2013 6:47 pm

Re: Email sending after Call

Postby hazanty » Wed Apr 02, 2014 8:29 am

I tried it but it doesn't send any mail,
kindly help on how to fix this


Thanks
hazanty
 
Posts: 1
Joined: Wed Apr 02, 2014 8:24 am

Re: Email sending after Call

Postby williamconley » Thu Apr 10, 2014 7:36 pm

They did help. All you said was "it doesn't work" with no error message or outcome other than it doesn't work. Perhaps you could contribute a wee bit more detail (error message? code you used to try to make it happen? method you used to test?)

Of course, this is purely php at this point and not part of Vicidial. There's a HUGE world of php developers out there with more active forums.

Or you could just pay someone.

Also be aware that there are several methods of sending email, and some ports may be blocked by ISP's to avoid SPAM generation servers.

Happy Hunting. 8-)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby oshonubi » Mon Apr 14, 2014 3:15 am

Hi William,

Thanks for the response. Kindly help some information.

1. Where does the script need to be be, the http folder, agc folder or any folder

2. Does the script need a mail client or its acting as a mail client

3. Where is the configuration of the mail client done pointing it to the mail server.
Vicidial Scratch Install
Rocky Linux 9.2
PHP 8.0
Asterisk 16.17.0-vici
Dahdi 3.2
oshonubi
 
Posts: 169
Joined: Mon Jun 15, 2009 8:36 am
Location: Lagos, Nigeria

Re: Email sending after Call

Postby williamconley » Thu Apr 17, 2014 5:08 pm

oshonubi wrote:Hi William,

Thanks for the response. Kindly help some information.

1. Where does the script need to be be, the http folder, agc folder or any folder

2. Does the script need a mail client or its acting as a mail client

3. Where is the configuration of the mail client done pointing it to the mail server.

1) Depends on what you put in the dispourl field, since that will be a link to the file, they must match.
2) It is acting as a mail client
3) Dunno, haven't looked that far into the code. Just stopping by to chat. 8-) This isn't after all a Vicidial issue, it's purely PHP.
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby oshonubi » Wed Apr 23, 2014 11:03 am

Hello William,

Thanks for the response. I really appreciate it. I hope one day someone will throw more lights to this topic. As much as I want it deployed, I am still not getting a way forward on it.
Vicidial Scratch Install
Rocky Linux 9.2
PHP 8.0
Asterisk 16.17.0-vici
Dahdi 3.2
oshonubi
 
Posts: 169
Joined: Mon Jun 15, 2009 8:36 am
Location: Lagos, Nigeria

Re: Email sending after Call

Postby williamconley » Thu Apr 24, 2014 6:24 pm

Unfortunately, I don't have time to "dig in and build/install/fix" it for you. I can, however, respond to whatever stumps you after you've done almost all the work. Like ... and error code/error line or a technical challenge. make it easy for me (no grunt work) so i need merely apply my experience to this situation and I'll help. :) As will many others on the forum. But do note that this is outside "Vicidial" so I won't be digging in that far on the Free forum (happy to help, but ... I have limitations on my time!).
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby Nefariousparity » Mon Apr 28, 2014 2:25 pm

oshonubi wrote:Hi William,

Thanks for the response. Kindly help some information.

1. Where does the script need to be be, the http folder, agc folder or any folder

2. Does the script need a mail client or its acting as a mail client

3. Where is the configuration of the mail client done pointing it to the mail server.



1) Through my experience the http folder will be fine.
2) You can write s simple php mailer, that sends the email
3) I don't really understand what you are asking
|| DB Schema Version: 1609 || Asterisk 11.25.1-vici || BUILD: 190902-0839 ||VERSION: 2.14-718a||SVN: 3133||10xTelephony||1x Database||1x Slave||1x Web||1x Archive||ViciBox v.8.0.1
Nefariousparity
 
Posts: 327
Joined: Wed Sep 12, 2012 7:01 pm

Re: Email sending after Call

Postby oshonubi » Tue Apr 29, 2014 5:07 am

Hello Nefariousparity,

Thanks for the response. From all indications, it seems there are global variables called in the test scripts (permit my ignorance, I am not a programmer), if we are to write a mail script to do the job, how do we call the variables and some conditional statement like if($status == "SOLD").

Thank you
Vicidial Scratch Install
Rocky Linux 9.2
PHP 8.0
Asterisk 16.17.0-vici
Dahdi 3.2
oshonubi
 
Posts: 169
Joined: Mon Jun 15, 2009 8:36 am
Location: Lagos, Nigeria

Re: Email sending after Call

Postby williamconley » Thu May 01, 2014 10:06 pm

This is part of the "dispo_url" system already built into Vicidial. There is even a sample dispo_url php script in the web folder.

If you use the (?) next to the various available web forms (web form, start call url, dispo url, no agent url ...) you will find that the language and syntax are shared among them and they also use some of the naming conventions of Scripts.

Happy Hunting 8-)
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: 20229
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Email sending after Call

Postby Alex » Sat Mar 04, 2017 4:01 am

Hi. I just got this email after call dispo option working on my Server with the help of VICIdial support team. So I felt this could be useful for the people who are stuck in getting this feature working.

Below is the simple procedure for sending auto email after call disposition.

1. First Of All Create/Add a "Settings Container". The option is available in VICIdial Administrator section ---> Admin ---> Settings Container.

2. Add the below content in "Container Entry Field"

#################################################################
; destination email
;email_to => xyz@gmail.com ;;;;; (For Static Mail Recipient)
email_to => --A--customer_email--B-- ;;;;; (To Mail ID of individual lead if available in database)

; sending email address
;email_from => abcd@gmail.com
email_from => --A--agent_email--B--

; subject of the email
email_subject => Order confirmation --A--vendor_lead_code--B--

; body of the email
email_body_begin =>
Hello --A--first_name--B--,

Good Day

You spoke to agent --A--fullname--B--.

Here is a summary of your account information:

lead_id: --A--lead_id--B--
vendor_id: --A--vendor_id--B--
vendor_lead_code: --A--vendor_lead_code--B--
list_id: --A--list_id--B--
list_name: --A--list_name--B--
list_description: --A--list_description--B--
gmt_offset_now: --A--gmt_offset_now--B--
phone_code: --A--phone_code--B--
phone_number: --A--phone_number--B--
title: --A--title--B--
first_name: --A--first_name--B--
middle_initial: --A--middle_initial--B--
last_name: --A--last_name--B--
address1: --A--address1--B--
address2: --A--address2--B--
address3: --A--address3--B--
city: --A--city--B--
state: --A--state--B--
province: --A--province--B--
postal_code: --A--postal_code--B--
country_code: --A--country_code--B--
gender: --A--gender--B--
date_of_birth: --A--date_of_birth--B--
alt_phone: --A--alt_phone--B--
email: --A--email--B--
security_phrase: --A--security_phrase--B--
comments: --A--comments--B--
user: --A--user--B--
closer: --A--user--B--
SQLdate: --A--SQLdate--B--
source_id: --A--source_id--B--
rank: --A--rank--B--
owner: --A--owner--B--
entry_list_id: --A--entry_list_id--B--
call_id: --A--call_id--B--
entry_date: --A--entry_date--B--
fullname: --A--fullname--B--
agent_email: --A--agent_email--B--
user_custom_one: --A--user_custom_one--B--
user_custom_two: --A--user_custom_two--B--
user_custom_three: --A--user_custom_three--B--
user_custom_four: --A--user_custom_four--B--
user_custom_five: --A--user_custom_five--B--
user_group: --A--user_group--B--

Have A Happy Day.

email_body_end

#################################################################

3. Use the below URL for entering in Campaign "DISPO CALL URL" field. This URL will send mail on selection of any disposition (sale_status=--A--dispo--B--). Change the container ID in this URL as per your server container ID which you have created.

VARhttp://192.168.1.100/agc/dispo_send_ ... _to_file=1

To send Mail for only Selected disposition (sale_status=SALE---NI---DEC---XFER---SSALE---XSALE), use the below sample URL:

VARhttp://192.168.1.100/agc/dispo_send_ ... _to_file=1

4. Also make sure that the outbound mails are working from your server. You can test the outbound mail from server command line
mail -s "Test subject" xyz@gmail.com

Or you can configure the outbound mail using the below link.
https://www.howtoforge.com/tutorial/con ... ail-relay/

If the mails are not sending or received by recipient, then you can also check the errors in "Admin Utilities" for "URL Log report".
This option is available in Administrator ---> Reports ---> Admin Utilities (At the bottom of the page)

Hope it helps. Enjoy.
Alex
 
Posts: 53
Joined: Mon Jun 01, 2015 1:37 am

Next

Return to Features

Who is online

Users browsing this forum: No registered users and 11 guests