mailer

package
v0.0.0-...-230cbbc Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2019 License: BSD-2-Clause Imports: 5 Imported by: 0

Documentation

Overview

Package mailer is a utility to send email. Configuration is not within the scope of this package, it simply takes an SMTP server, port, username and password as an argument to the NewClient function.

This has been tested with Gmail using smtp.gmail.com and port 587

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	// SendEmail will send a mail to the specified email address
	SendEmail(subject, content string, recipients ...string) error
}

Client is used to send emails using standard settings

func NewClient

func NewClient(username, password, displayName, from, smtpServer string, smtpPort int) Client

NewClient will create a new email client for sending mails

Jump to

Keyboard shortcuts

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