@cfxlabsinc/b2b-services
    Preparing search index...

    Reusable email send core: recipient deduplication → active template resolution → rendering → SES transport. ONE implementation, reused by both the Lambda handler (event-driven sends) and admin sendTest (manual test sends).

    Orchestrates the full send pipeline so callers need only provide:

    • Recipients (email + name)
    • Notification payload
    • Template key

    This is the notification analogue of how wire-email-handler consumes @cfxlabsinc/wire-email-services.

    Index
    instance: (...args: []) => EmailSendCore = ...

    The React Email renderer loads on the first render, so this barrel stays free of it.

    • Send an email notification via the active template.

      Orchestrates:

      1. Recipient deduplication (lowercased email)
      2. Active template resolution
      3. Rendering, once per recipient
      4. One SES send per recipient, sequentially

      Throws on SES errors; caller must handle retries/DLQ.

      Parameters

      • __namedParameters: {
            notification: EmailNotification;
            recipientGate?: EmailRecipientGate;
            recipients: { email: string; name?: string }[];
            templateKey:
                | "IDENTITY"
                | "ORGANIZATION"
                | "LEDGER_ACCOUNT"
                | "PAYMENT_INSTRUMENT"
                | "DEPOSIT"
                | "WITHDRAW"
                | "TRANSFER"
                | "CARD_TRANSACTION"
                | "INVOICE"
                | "RECEIPT"
                | "AUTH"
                | "APPLICATION";
        }
        • notification: EmailNotification

          Notification payload

        • OptionalrecipientGate?: EmailRecipientGate

          Skips recipients an earlier attempt already mailed.

        • recipients: { email: string; name?: string }[]
        • templateKey:
              | "IDENTITY"
              | "ORGANIZATION"
              | "LEDGER_ACCOUNT"
              | "PAYMENT_INSTRUMENT"
              | "DEPOSIT"
              | "WITHDRAW"
              | "TRANSFER"
              | "CARD_TRANSACTION"
              | "INVOICE"
              | "RECEIPT"
              | "AUTH"
              | "APPLICATION"

          Template key for active template lookup

      Returns Promise<EmailSendOutcome>