notification

package
v0.29.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 5, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EmailConfigFromInstanceSetting

func EmailConfigFromInstanceSetting(setting *storepb.InstanceNotificationSetting_EmailSetting) *email.Config

EmailConfigFromInstanceSetting converts persisted notification settings into SMTP config.

func NewTestEmailMessage

func NewTestEmailMessage(recipientEmail, replyTo string) *email.Message

NewTestEmailMessage builds the plain-text test email for notification settings.

func SendTestEmail

func SendTestEmail(setting *storepb.InstanceNotificationSetting_EmailSetting, recipientEmail string) error

SendTestEmail sends a plain-text test email using notification email settings.

func ValidateEmailSetting

func ValidateEmailSetting(setting *storepb.InstanceNotificationSetting_EmailSetting) error

ValidateEmailSetting validates notification email SMTP settings.

Types

type EmailDispatcher

type EmailDispatcher struct {
	// contains filtered or unexported fields
}

EmailDispatcher dispatches notification emails for inbox events.

func NewEmailDispatcher

func NewEmailDispatcher(profile *profile.Profile, store *store.Store, sender EmailSender) *EmailDispatcher

NewEmailDispatcher creates a notification email dispatcher.

func (*EmailDispatcher) DispatchInboxEmail

func (d *EmailDispatcher) DispatchInboxEmail(ctx context.Context, inbox *store.Inbox) error

DispatchInboxEmail sends the email notification for an inbox entry when configured.

type EmailSender

type EmailSender func(*email.Config, *email.Message)

EmailSender sends a prepared email message with the given SMTP configuration.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL