Mailgun allows you to send and receive emails using their API. With Mailgun, you can build a variety of applications and services that can send or receive emails. Here are a few examples of what you can build with Mailgun:
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
mailgun: {
type: "app",
app: "mailgun",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://${this.mailgun.$auth.region && this.mailgun.$auth.region === "EU" ? "api.eu" : "api"}.mailgun.net/v3/domains`,
auth: {
username: `api`,
password: `${this.mailgun.$auth.api_key}`,
},
})
},
})
Emit new event when the email recipient could not be reached.
Emit new event when the email recipient clicked on a link in the email. Open tracking must be enabled in the Mailgun control panel, and the CNAME record must be pointing to mailgun.org. See more at the Mailgun User's Manual Tracking Messages section
Emit new event when the email recipient clicked on the spam complaint button within their email client. Feedback loops enable the notification to be received by Mailgun.
Emit new event when an email is sent and accepted by the recipient email server.
Emit new event when an email can't be delivered to the recipient email server.
Delete a mailing list member by address. See the docs here
Retrieve a mailing list member by address. See the docs here
Mailgun uses API keys for authentication. When you connect your Mailgun account, Pipedream securely stores the keys so you can easily authenticate to Mailgun APIs in both code and no-code steps.
Get your API Key in the Control Panel, specifically in Settings > API Keys. More info in docs.
If your Mailgun account resides in the EU, choose the EU option in the Region field. Otherwise, choose the US (non-EU) region.