Socket
Book a DemoInstallSign in
Socket

jsmtp

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsmtp

Simple SMTP server

latest
Source
npmnpm
Version
1.1.0
Version published
Maintainers
1
Created
Source

Early release, will come updates eventually

JSMTP

let jsmtp = require('jsmtp');
jsmtp.start("mail.example.com", "127-0-0-1.ex.broadband.net", "../mails/", fs.readFileSync('privkey.pem'), fs.readFileSync('fullchain.pem'), callback,false);
//           service             reverse                      dir          key                             cert                              cb
// you can put the key and cert to null to disable tls
// callback is of course optional, will tell you mail info when a mailer is exiting
function callback(mailInfo){
console.log(mailInfo);
}

jsmtp.send("mail.example", "smtp.example.com",587,"user@mail.example","touser@example.com","content",true);
//          service         server           port    from               to                 data      tls

Keywords

SMTP

FAQs

Package last updated on 04 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts