smptclient

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PLAINTEXT_EMAIL = "plain"
	HTML_EMAIL      = "html"
)

Variables

This section is empty.

Functions

func NewSmtpClient

func NewSmtpClient(SmtpConfig *SmtpConfig, logger *plogger.Logger) mo.Result[*SmtpClient]

Types

type SmtpClient

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

func (*SmtpClient) SendHtmlEmail

func (client *SmtpClient) SendHtmlEmail(
	to string, subject string, body string,
	cc *string, bcc *string, replyTo *string,
	attachmentFilePaths []string,
) error

func (*SmtpClient) SendPlainTextEmail

func (client *SmtpClient) SendPlainTextEmail(
	to string, subject string, body string,
	cc *string, bcc *string, replyTo *string,
	attachmentFilePaths []string,
) error

type SmtpConfig

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

func NewSmtpConfig

func NewSmtpConfig(
	host string, port int,
	username string, password string,
	fromEmail string,
) *SmtpConfig

Jump to

Keyboard shortcuts

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