Guest User

Untitled

a guest
Aug 23rd, 2015
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. Parse.Cloud.define("blendedBookMailToUser", function(request, response) {
  2. var Mailgun = require('mailgun');
  3. Mailgun.initialize('SandBoxCode', 'Key');
  4.  
  5. Mailgun.sendEmail({
  6. subject: "Session Booked",
  7. text: "HIIIIIIIIIIII" ,
  8. html:'<html><body style="text-align:center;"><img border="0" src="' + request.params.qrUrlKey + '" width="200" height="200" ></body></html>',
  9.  
  10. }, {
  11. success: function(httpResponse) {
  12. console.log(httpResponse);
  13. response.success("Email sent!");
  14. },
  15. error: function(httpResponse) {
  16. console.error(httpResponse);
  17. response.error("Uh oh, something went wrong");
  18. }
  19. });
  20. });
Advertisement
Add Comment
Please, Sign In to add comment