emailer

package
v0.0.0-...-14a4c8a Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attachment

type Attachment struct {
	Name string
	Data []byte
}

type Emailer

type Emailer interface {
	Send(toName string, to string, subject string, content string, attachments []Attachment) error
}

type MailgunApiMail

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

func NewMailgunApiMail

func NewMailgunApiMail(domain, apiKey, fromName, from, baseApi string) *MailgunApiMail

func (*MailgunApiMail) Send

func (o *MailgunApiMail) Send(toName string, to string, subject string, content string, attachments []Attachment) error

type SendgridApiMail

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

func NewSendgridApiMail

func NewSendgridApiMail(apiKey, fromName, from string) *SendgridApiMail

func (*SendgridApiMail) Send

func (o *SendgridApiMail) Send(toName string, to string, subject string, content string, attachments []Attachment) error

type SmtpMail

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

func NewSmtpMail

func NewSmtpMail(hostname string, port int, username string, password string, noTLSCheck bool, auth string, fromName, from string, encryption string) *SmtpMail

func (*SmtpMail) Send

func (o *SmtpMail) Send(toName string, to string, subject string, content string, attachments []Attachment) error

Jump to

Keyboard shortcuts

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