Created
December 26, 2016 00:59
-
-
Save ahmedengu/60278f8293f714decdedcd66f0bc48f8 to your computer and use it in GitHub Desktop.
Using simple-parse-smtp-adapter with cloud code, Parse Server, https://github.com/lcortess/simple-parse-smtp-adapter
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var sendSmtpMail = require('simple-parse-smtp-adapter')({ | |
fromAddress: '[email protected]', | |
user: '[email protected]', | |
password: 'AwesomePassword', | |
host: 'your.smtp.host', | |
isSSL: true, | |
port: 465, | |
emailField: 'email' | |
}).sendMail; | |
Parse.Cloud.afterSave("_User", function (request) { | |
sendSmtpMail({ | |
to: request.get('email'), | |
text: 'hi,<br> Message!', | |
subject: 'subject' | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment