Socket
Socket
Sign inDemoInstall

mandrill-mail

Package Overview
Dependencies
23
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    mandrill-mail

A simple mandrill wrapper for sending email.


Version published
Maintainers
1
Install size
1.15 MB
Created

Readme

Source

#What is

This is a simple wrapper to send email within the mandrill api.

#Getting started

Just install with

npm install mandrill-mail

The there is just a send() function who excepts 3 params. There is an example:

var client = require('mandrill-mail');

var data = {

	'html' : 'this is great', // Message itself in html format
	'subject' : 'great subject', //  the subject
	'from_email': 'mysuperemail@gmail.com', // Who sends the email
	'from_name' : 'mauro', // the sender name
	'to': [
			{                                   		 // the array who contains the recivers
	    		'email': 'mysuperemail@gmail.com',		// to email adress
	    		'name' : 'Mauro'						// to name
			},
			{
				'email' : 'foo@gmail.com',
				'name' : 'foo'
			}
		]
};

/**
 * [description]
 * @param  {string} The api key
 * @param {object} An obj containing all the information
 * @param {function} A callback function
 */
client.send('my-secret-key', data, function(json){
	console.log(json)
});

FAQs

Last updated on 23 Oct 2013

Did you know?

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc