Skip to content

SendMail via Parse.Cloud.sendMail() #7089

Closed
@dblythy

Description

@dblythy

New Feature / Enhancement Checklist

Current Limitation

I currently use a Mailgun emailAdapter on my Parse Servers. Yet in my cloud code whenever I want to send email, I have to call:

  const api_key = "";
  const domain = "";
  const mailgun = require("mailgun-js")({
    apiKey: api_key,
    domain: domain
    });
  const data = {
    from: "",
    to: obj.get("email"),
    subject: "",
    text: ",
    html: summary
    };
  mailgun.messages().send(data, function(error, body) {});

I could be doing this wrong, idk.

Feature / Enhancement Description

It would be nice to have:

Parse.Cloud.sendEmail(data) and it inherit the sendEmail function from the emailAdapter. It would also support newer developers as they don't have to read their mail providers docs to learn how to send email, as the adapter handles it for them. If no email adapter is specified, throw an error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:featureNew feature or improvement of existing feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions