Skip to content

Instantly share code, notes, and snippets.

@bradycoye
bradycoye / send-email.js
Created February 17, 2016 15:21 — forked from taylorstine/send-email.js
emailSender function for parse-server
import aws from 'aws-sdk'
import path from 'path'
import fs from 'fs'
aws.config.loadFromPath(path.resolve('credentials', 'aws_config.json'));
const ses = new aws.SES({apiVersion: '2010-12-01'});
const resetEmail = fs.readFileSync(path.resolve('emails', 'reset-password.html'), 'utf8');
const verifyEmail = fs.readFileSync(path.resolve('emails', 'verify-email.html'), 'utf8');
import {Constants} from 'parse-server'
import Promise from 'bluebird'