View Single Post
Old 17.11.2017, 09:52
torrero007 torrero007 is offline
DSL User
Join Date: Apr 2015
Posts: 35
Default Script for sending email after package finished

I came up with a way to send myself an email after a package is finished in JD. The trigger for the Event Scripter is "package finished". Here is the script:

//Add your script here. Feel free to use the available api properties and methods
callAsync(function(exitCode, stdOut, errOut) {}, "C:\\sendEmail.exe", "-o", "tls=yes", "-t", "", "-u", "Download Completed:", package.getName(), "-m", "Download completed:", package.getName(), "-f", "", "-s", "", "-xu", "yourusername", "-xp", "yourpassword");

"C:\\sendEmail.exe" : the path were the sendEmail is in your PC
"-t", "" : the address which will notified
"-f", "" : the address which will send the notification
"-xu", "yourusername" : your username on the "-f" account
"-xp", "yourpassword" : your password on the "-f" account

You will need a very simple program called "Sendemail". Download the version with TLS support.

You will also need to enable POP and IMAP in the Gmail account you will use to send the notification from (the "f" attribute email address). In addition you need to turn on the "Access for less secure apps" on this account or else the Gmail with block the access to the acount.

I would like to thank Jiaz for helping me start and finish it.

Hope it helps

Last edited by torrero007; 17.11.2017 at 13:32. Reason: corrections
Reply With Quote