mail

package
v1.3.174 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attachment added in v1.1.4

type Attachment struct {
	ContentType   string
	Filename      string
	Base64Content string
}

type IProvider added in v1.2.77

type IProvider interface {
	GetTemplateKeyFromConfig(configService config.IConfig, templateName string) (string, error)
	SendTemplate(message *Message) error
	GetDefaultFromEmail() string
	GetDefaultFromName() string
	SendTemplateWithAttachments(message *MessageAttachment) error
	GetTemplateHTMLCode(templateName string) (string, error)
}

func NewMailjet added in v1.1.4

func NewMailjet(configService config.IConfig) (IProvider, error)

func NewMandrill

func NewMandrill(configService config.IConfig) (IProvider, error)

type ISender added in v1.2.77

type ISender interface {
	GetTemplateKeyFromConfig(templateName string) (string, error)
	SendTemplate(ormService *beeorm.Engine, message *Message) error
	SendTemplateWithAttachments(ormService *beeorm.Engine, message *MessageAttachment) error
	GetTemplateHTMLCode(templateName string) (string, error)
}

type Mailjet added in v1.1.4

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

func (*Mailjet) GetDefaultFromEmail added in v1.2.89

func (s *Mailjet) GetDefaultFromEmail() string

func (*Mailjet) GetDefaultFromName added in v1.2.89

func (s *Mailjet) GetDefaultFromName() string

func (*Mailjet) GetTemplateHTMLCode added in v1.1.4

func (s *Mailjet) GetTemplateHTMLCode(templateName string) (string, error)

func (*Mailjet) GetTemplateKeyFromConfig added in v1.2.23

func (s *Mailjet) GetTemplateKeyFromConfig(configService config.IConfig, templateName string) (string, error)

func (*Mailjet) SendTemplate added in v1.1.4

func (s *Mailjet) SendTemplate(message *Message) error

func (*Mailjet) SendTemplateWithAttachments added in v1.1.4

func (s *Mailjet) SendTemplateWithAttachments(message *MessageAttachment) error

type Mandrill

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

func (*Mandrill) GetDefaultFromEmail added in v1.2.89

func (s *Mandrill) GetDefaultFromEmail() string

func (*Mandrill) GetDefaultFromName added in v1.2.89

func (s *Mandrill) GetDefaultFromName() string

func (*Mandrill) GetTemplateHTMLCode added in v0.8.69

func (s *Mandrill) GetTemplateHTMLCode(templateName string) (string, error)

func (*Mandrill) GetTemplateKeyFromConfig added in v1.2.23

func (s *Mandrill) GetTemplateKeyFromConfig(configService config.IConfig, templateName string) (string, error)

func (*Mandrill) SendTemplate

func (s *Mandrill) SendTemplate(message *Message) error

func (*Mandrill) SendTemplateWithAttachments

func (s *Mandrill) SendTemplateWithAttachments(message *MessageAttachment) error

type Message

type Message struct {
	From         string
	FromName     string
	ReplyTo      string
	To           string
	Subject      string
	TemplateName string
	TemplateData interface{}
}

type MessageAttachment

type MessageAttachment struct {
	Message
	Attachments []Attachment
}

type NewSenderFunc added in v1.1.4

type NewSenderFunc func(configService config.IConfig) (IProvider, error)

type Sender

type Sender struct {
	ConfigService      config.IConfig
	ClockService       clock.IClock
	ErrorLoggerService errorlogger.ErrorLogger
	Provider           IProvider
}

func NewSender added in v1.3.105

func NewSender(
	ormConfig beeorm.ValidatedRegistry,
	configService config.IConfig,
	clockService clock.IClock,
	errorLogger errorlogger.ErrorLogger,
	newFunc NewSenderFunc,
) (*Sender, error)

func (*Sender) GetTemplateHTMLCode added in v0.8.69

func (s *Sender) GetTemplateHTMLCode(templateName string) (string, error)

func (*Sender) GetTemplateKeyFromConfig added in v1.2.23

func (s *Sender) GetTemplateKeyFromConfig(templateName string) (string, error)

func (*Sender) SendTemplate

func (s *Sender) SendTemplate(ormService *beeorm.Engine, message *Message) error

func (*Sender) SendTemplateWithAttachments

func (s *Sender) SendTemplateWithAttachments(ormService *beeorm.Engine, message *MessageAttachment) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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