exchangesmtp

package module
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2023 License: MIT Imports: 4 Imported by: 0

README

Simple library for send simple emails

Work with Microsoft Exchange. It supports plaint text and html emails.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoginAuth

func LoginAuth(username, password string) smtp.Auth

LoginAuth uses for authorization in Exchange. Plain auth for Exchange server doesn't work since 2017.

Types

type Mail

type Mail struct {
	From    string
	To      []string
	Subject string
	Body    string
	IsHTML  bool
	// contains filtered or unexported fields
}

Mail is a struct of plain text email.

func (*Mail) String

func (m *Mail) String() string

type MailSender

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

MailSender uses for send plain text emails.

func NewMailSender

func NewMailSender(username, password, server string) *MailSender

NewMailSender is constructor for MailSender.

func (*MailSender) SendToList

func (m *MailSender) SendToList(mail Mail) error

SendToList is send simple plain text email to list recipients.

type QuickSender added in v0.4.0

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

func NewQucikSender added in v0.4.0

func NewQucikSender(user, password, server, from string, to []string) *QuickSender

func (*QuickSender) Send added in v0.4.0

func (qs *QuickSender) Send(subject, body string) error

Jump to

Keyboard shortcuts

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