email

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Email

type Email struct {
	From    string
	To      []string
	Cc      []string
	Bcc     []string
	Subject string
	Body    string
}

func (*Email) Validate

func (e *Email) Validate() error

type Fake

type Fake struct{}

func (Fake) SendEmail

func (f Fake) SendEmail(ctx context.Context, email *Email) (string, error)

type Mailgun

type Mailgun struct {
	Client     *http.Client
	BaseURL    string
	APIKey     string
	DomainName string
}

func NewMailgun

func NewMailgun(client *http.Client, baseURL, apiKey, domainName string) *Mailgun

func (*Mailgun) SendEmail

func (m *Mailgun) SendEmail(ctx context.Context, email *Email) (string, error)

Jump to

Keyboard shortcuts

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