email

package
v0.0.0-...-7cf99fd Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init()

Types

type Email

type Email struct {
	*SMTPInfo
}

func New

func New(info ...*SMTPInfo) *Email

func (*Email) SendMail

func (e *Email) SendMail(to []string, subject, body string) error

type SMTPInfo

type SMTPInfo struct {
	Host     string   `mapstructure:"host"`
	Port     int      `mapstructure:"port"`
	IsSSL    bool     `mapstructure:"is_ssl"`
	Username string   `mapstructure:"username"`
	Password string   `mapstructure:"password"`
	From     string   `mapstructure:"from"`
	To       []string `mapstructure:"to"`
}

Jump to

Keyboard shortcuts

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