node package manager
Orgs are free. Discover, share, and reuse code in your team. Create a free org »

stratumn-sendgrid

stratumn-sendgrid

Sendgrid helper to be used in a Stratumn Agent

build status dependency status

Installation

npm install --save stratumn-sendgrid

Usage

In your agent:

const EmailHelper = require('./stratumn-sendgrid');
 
module.exports = {
  requestSignatures: function(data) {
    EmailHelper.send({
      to: data.email,
      from: data.requesterEmail,
      subject: data.fileName,
      text: data.text
    })
      .then(() => this.append())
      .catch(err => this.reject(err));
  }
};
``
 
## Credits
[Stratumn Team](https://github.com/stratumn/) 
 
## License
 
MIT