Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

medusa-plugin-sendgrid

medusajs6.6kMIT1.3.13

SendGrid transactional emails

medusa-plugin, medusa-plugin-notification

readme

SendGrid

Handle sending emails to customers related to orders, restock notifications, users, or custom events.

SendGrid Plugin Documentation | Medusa Website | Medusa Repository

Features

  • Send emails when an event related to orders, restock notifications, or users is triggered.
  • Use dynamic templates in SendGrid to build the emails to be sent.
  • Send emails with SendGrid for custom events.

Prerequisites


How to Install

1. Run the following command in the directory of the Medusa backend:

  npm install medusa-plugin-sendgrid

2. Set the following environment variable in .env:

  SENDGRID_API_KEY=<API_KEY>
  SENDGRID_FROM=<SEND_FROM_EMAIL>
  # IDs for different email templates
  SENDGRID_ORDER_PLACED_ID=<ORDER_PLACED_TEMPLATE_ID> # example

3. In medusa-config.js add the following at the end of the plugins array:

  const plugins = [
    // ...,
    {
      resolve: `medusa-plugin-sendgrid`,
      options: {
        api_key: process.env.SENDGRID_API_KEY,
        from: process.env.SENDGRID_FROM,
        order_placed_template: 
          process.env.SENDGRID_ORDER_PLACED_ID,
        localization: {
          "de-DE": { // locale key
            order_placed_template:
              process.env.SENDGRID_ORDER_PLACED_ID_LOCALIZED,
          },
        },
      },
    },
  ]

Test the Plugin

1. Run the following command in the directory of the Medusa backend to run the backend:

  npm run start

2. Place an order using a storefront or the Store APIs. You should receive a confirmation email.


Additional Resources

changelog

Change Log

1.3.13

Patch Changes

1.3.12

Patch Changes

1.3.11

Patch Changes

1.3.10

Patch Changes

  • #4389 9dcdc0041 Thanks @adrien2p! - fix(medusa, utils): fix the way selects are consumed alongside the relations

  • #4384 f65a501da Thanks @pevey! - feat(medusa-plugin-sendgrid): Add error messages to SendgridService.sendNotification

1.3.9

Patch Changes

  • #3763 4104d9ccb Thanks @StephixOne! - fix(plugin-discount-generator,plugin-economic,plugin-mailchimp,plugin-restock-notification,plugin-sendgrid,plugin-wishlist): Temporarily remove payload validation in some plugins

1.3.8

Patch Changes

1.3.8-rc.0

Patch Changes

1.3.7

Patch Changes

1.3.6

Patch Changes

1.3.5

Patch Changes

1.3.4

Patch Changes

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

1.3.3 (2022-07-05)

Note: Version bump only for package medusa-plugin-sendgrid

1.3.2 (2022-06-19)

Note: Version bump only for package medusa-plugin-sendgrid

1.3.1 (2022-05-31)

Note: Version bump only for package medusa-plugin-sendgrid

1.3.0 (2022-05-01)

Features

1.2.1 (2022-02-28)

Bug Fixes

  • reset user password subscription in sendgrid plugin (#1072) (91263fb)

Features

1.2.0 (2022-02-25)

Bug Fixes

  • reset user password subscription in sendgrid plugin (#1072) (90121dd)

Features

1.1.38 (2022-01-11)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.37 (2021-12-29)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.36 (2021-12-17)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.35 (2021-12-08)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.34 (2021-11-23)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.33 (2021-11-22)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.32 (2021-11-19)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.31 (2021-11-19)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.30 (2021-10-18)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.29 (2021-10-18)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.28 (2021-10-18)

Features

  • allow product selection on discounts allocated to a specific item (#395) (84d4d79)

1.1.27 (2021-10-18)

Features

  • allow product selection on discounts allocated to a specific item (#395) (84d4d79)

1.1.26 (2021-09-15)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.25 (2021-09-14)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.24 (2021-08-05)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.23 (2021-07-26)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.22 (2021-07-15)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.21 (2021-07-15)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.20 (2021-07-02)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.19 (2021-06-22)

Bug Fixes

1.1.18 (2021-06-09)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.17 (2021-06-09)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.16 (2021-06-09)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.15 (2021-06-09)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.14 (2021-06-08)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.13 (2021-04-28)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.12 (2021-04-20)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.11 (2021-04-20)

Features

1.1.10 (2021-04-13)

Bug Fixes

1.1.9 (2021-04-13)

Bug Fixes

1.1.8 (2021-03-30)

Bug Fixes

  • format numbers correctly in sendgrid (7682980)
  • publish assist (7719957)

1.1.7 (2021-03-17)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.6 (2021-03-17)

Bug Fixes

  • enable gift-card creation without order_id (9ce935a)

1.1.5 (2021-03-17)

Bug Fixes

  • enable gift-card creation without order_id (9ce935a)

1.1.4 (2021-02-25)

Bug Fixes

  • add tracking links to shipments (7be4bb5)
  • sendgrid tracking links (5cfc8d8)

1.1.3 (2021-02-17)

Bug Fixes

  • attachment generator for invoices (0cc2ccd)
  • handles normalizeThumb without thumbnail (93f6812)

Features

1.1.2 (2021-02-03)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.1 (2021-01-27)

Note: Version bump only for package medusa-plugin-sendgrid

1.1.0 (2021-01-26)

Note: Version bump only for package medusa-plugin-sendgrid

1.0.14 (2020-12-17)

Note: Version bump only for package medusa-plugin-sendgrid

1.0.13 (2020-11-24)

Note: Version bump only for package medusa-plugin-sendgrid

1.0.12 (2020-10-19)

Note: Version bump only for package medusa-plugin-sendgrid

1.0.11 (2020-09-11)

Bug Fixes

  • medusa-plugin-sendgrid: do display_value calculations (5e47aec)

1.0.10 (2020-09-09)

Bug Fixes

1.0.7 (2020-09-07)

1.0.1 (2020-09-05)

1.0.1-beta.0 (2020-09-04)

Bug Fixes

  • medusa: product variant metadata (#98) (520115a)

1.0.0 (2020-09-03)

1.0.0-alpha.35 (2020-08-28)

Bug Fixes

  • medusa-plugin-sendgrid: Adds order shipped support (ddfd26d)

1.0.0-alpha.34 (2020-08-28)

Bug Fixes

  • medusa-plugin-sendgrid: decorate order placed data for email (2edf152)

1.0.0-alpha.30 (2020-08-28)

1.0.0-alpha.27 (2020-08-27)

1.0.0-alpha.25 (2020-08-27)

1.0.0-alpha.24 (2020-08-27)

1.0.0-alpha.3 (2020-08-20)

1.0.0-alpha.2 (2020-08-20)

1.0.0-alpha.1 (2020-08-20)

1.0.0-alpha.0 (2020-08-20)

1.0.10 (2020-09-09)

Bug Fixes