email

package
v4.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseHtml

func ParseHtml(data any) (string, error)

Types

type Email

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

func NewClient

func NewClient(options ...Options) *Email

func NewGoEmail

func NewGoEmail(host string, port int, username string, password string) *Email

func NewSendGrid

func NewSendGrid(apiKey string) *Email

func (*Email) Date

func (t *Email) Date(date time.Time)

func (*Email) From

func (t *Email) From(from string)

func (*Email) InviteHtmlBody

func (t *Email) InviteHtmlBody(title, name, link string) error

func (*Email) Send

func (t *Email) Send() error

func (*Email) Subject

func (t *Email) Subject(subject string)

func (*Email) TextBody

func (t *Email) TextBody(body string)

func (*Email) To

func (t *Email) To(to string)

type Option

type Option struct {
	Host     string
	Port     int
	User     string
	Password string
	ApiKey   string
}

type Options

type Options func(option *Option)

func WithApiKey

func WithApiKey(apiKey string) Options

func WithHost

func WithHost(host string) Options

func WithPassword

func WithPassword(password string) Options

func WithPort

func WithPort(port int) Options

func WithUser

func WithUser(user string) Options

Jump to

Keyboard shortcuts

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