@tsc_tech/medusa-plugin-mailgun

0.0.1 • Public • Published

Medusa logo

Medusa Plugin Starter

Building blocks for digital commerce

PRs welcome! Product Hunt Discord Chat Follow @medusajs

Compatibility

This starter is compatible with versions >= 2.5.0 of @medusajs/medusa.

Notification-mailgun

Enhance Email Communication with Mailgun - Strengthen the Medusa Community!

Dear Developers and E-commerce Enthusiasts,

Are you looking to optimize email communication for your MedusaJS store? We have an exciting solution that streamlines email delivery for the Medusa platform! Introducing the Mailgun Provider, a community-driven project that integrates Mailgun's powerful email services into the MedusaJS commerce stack for reliable and efficient email communication.

Why Use Mailgun?

🚀 Reliable Email Delivery: Mailgun ensures high deliverability and security for transactional and marketing emails.

🌐 Global Reach: Send emails to customers worldwide with ease, supporting various configurations tailored to your business needs.

🎉 Boost Your Medusa Store: Supporting this provider fosters innovation and strengthens email infrastructure across the Medusa platform.

Installation

Use the package manager npm to install Notification-mailgun.

npm install @tsc_tech/medusa-plugin-mailgun
yarn add @tsc_tech/medusa-plugin-mailgun

Additionally, install the mailgun package:

npm install mailgun.js
yarn add mailgun.js

Configuration

Step 1: Get Mailgun API Credentials

Sign up for a Mailgun account and retrieve your API credentials:

Mailgun Domain: Found in your Mailgun dashboard

Mailgun API Key: Required for authentication

Step 2: Set Up Environment Variables In your .env file, define the following variables:

MAILGUN_API_KEY=your-mailgun-api-key
MAILGUN_FROM=mailgun-from
MAILGUN_DOMAIN=your-mailgun-domain

Step 3: Update Medusa Configuration Modify your medusa-config.ts to include the mailgun provider:

module.exports = defineConfig({
modules: [
  ...
    {
      resolve: "@medusajs/medusa/notification",
      options: {
        providers: [
          {
            resolve: "@tsc_tech/medusa-plugin-mailgun/providers/mailgun",
            id: "notification-mailgun",
            options: {
              channels: ["email"],
              username: "api",
              key: process.env.MAILGUN_API_KEY,
              domain: process.env.MAILGUN_DOMAIN,
              from: process.env.MAILGUN_FROM,
            },
          },
        ],
      },
    },
  ...]
})

Contributing

Contributions are welcome! For significant changes, please open an issue first to discuss your proposed modifications.

Kindly ensure that tests are updated as needed.

License

MIT

Disclaimer

The code has been tested in a limited number of scenarios, so unforeseen bugs may arise. Please report any issues you encounter or submit a pull request if you'd like to contribute fixes.

Support the Mailgun Provider - Strengthen Our Medusa Community!

Package Sidebar

Install

npm i @tsc_tech/medusa-plugin-mailgun

Weekly Downloads

1

Version

0.0.1

License

MIT

Unpacked Size

13.4 kB

Total Files

7

Last publish

Collaborators

  • the_special_character