1.0.9 • Published 2 years ago

multiple-email-service v1.0.9

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

cali-email-service

This is the pacakge which have multiple email services.

1. NodeMailer
2. MailGun

Will add more services in future

Installation:

npm install multiple-email-service

To use NodeMailer follow the below steps

Step1: import nodimaler from multiple-email-service package

       const { nodemailerSendEmail } = require('multiple-email-service');

Step2: construct the required params to send email and all params are mandatory. 
       
       Also use any one params body or htmlContent for mail content
       
       example:     
       const emailParams = {

           // count of retry to send mail if not sent
           tryCount: 3, 

           // Create a Transporter
           transporterHost: 'youremail_SMTP_HOST', 
           transporterPort: 'youremail_SMTP_PORT', 
           transporterEmail: 'youremail_SMTP_USERNAME', 
           transporterPassword: 'youremail_SMTP_PASSWORD', 

           // Create a MailOptions
           from: 'fromemail@example.com', 
           to: 'toemail@example.com', 
           subject: 'mail subject', 
           body: 'mail body content',
           htmlContent: '<p>html content</p>' 
        }

Step3: To send email add below code
    
    nodemailerSendEmail(emailParams)
      



      
       
       
1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago