zmail

package
v0.0.0-...-0521b85 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Address

type Address struct {
	Name  string
	Email string
}

type Authentication

type Authentication struct {
	ServiceType ServiceType
	UserID      string
	Password    string
	Server      string
	Port        int
}

type Mail

type Mail struct {
	To          []Address
	From        Address
	Subject     string
	TextContent string
	HTMLContent string
}

func (*Mail) AddTo

func (m *Mail) AddTo(name, email string)

func (Mail) Send

func (m Mail) Send(a Authentication) error

func (Mail) SendGridSend

func (m Mail) SendGridSend(apiKey string) error

func (Mail) SendWithPlunk

func (m Mail) SendWithPlunk(a Authentication) error

func (Mail) SendWithSMTP

func (m Mail) SendWithSMTP(a Authentication) (err error)

type ServiceType

type ServiceType string
const (
	PlunkType    ServiceType = "plunk"
	SMTPType     ServiceType = "smtp"
	SendGridType ServiceType = "sendgrid"
)

Jump to

Keyboard shortcuts

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