Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoInstallSign in
Socket

node-sap-mailer

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-sap-mailer

SAP mailer

latest
Source
npmnpm
Version
0.3.1
Version published
Weekly downloads
4
-42.86%
Maintainers
2
Weekly downloads
 
Created
Source

Build Version Dependency Status devDependency Status Coverage node-sap-mailer

This service gives the ability to easily send emails. This service is based on Nodemailer node package.

###Nodemailer transport options

//./config.js
module.exports = {
     host: "mail.example.com",
      port: 25,
      debug: true,
      tls: {
        rejectUnauthorized: false
    }
};

How to use Mailer service in module

//./config.js
var Mailer = require('norman-common-server').Mailer;
Mailer.sender = 'no-reply@mail.example.com';
mailer.send(mailOptions, function onError(error) {
    console.log('Error', error);
}, function onSuccess(info) {
   console.log('Success', info);
});

mailOptions:

// setup an e-mail
var mailOptions = {
    from: 'foo@mail.example.com', // sender address
    to: 'bar@mail.example.com, baz@mail.example.com', // list of receivers
    subject: 'Hello', // Subject line
    text: 'Hello world', // plaintext body
    html: '<b>Hello world</b>' // html body
};

For more please see the https://github.com/andris9/Nodemailer example for mailOptions.

FAQs

Package last updated on 18 Sep 2015

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