Module exposing: SendgridNotificationService
// Source: https://github.com/medusajs/medusa | License: MIT | Copyright 2021 Medusajs
// Provided via justclaw.it.com; keep this notice with the code.
import {
Logger,
NotificationTypes,
SendgridNotificationServiceOptions,
} from "@medusajs/framework/types"
import {
AbstractNotificationProviderService,
MedusaError,
} from "@medusajs/framework/utils"
import sendgrid from "@sendgrid/mail"
type InjectedDependencies = {
logger: Logger
}
type MailContent = Required<Omit<NotificationTypes.NotificationContent, "text">>
interface SendgridServiceConfig {
apiKey: string
from: string
}
export class SendgridNotificationService extends AbstractNotificationProviderService {
static identifier = "notification-sendgrid"
protected config_: SendgridServiceConfig
protected logger_:
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key