o365

package module
v0.0.0-...-cbc78ad Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2021 License: MIT Imports: 6 Imported by: 0

README

O365Sender

Office 365 Mail tester

Compilation

Clone the repository: git clone https://github.com/alex-arce/O365Sender

Build the binary:

cd cmd
./build.sh
Usage
./O365Sender -config o365sender.conf --from="user@domain.com" --to="user@domain.com" --subject="TEST SUBJECT" --text="TEST BODY"

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoginAuth

func LoginAuth(username, password string) smtp.Auth

Types

type Attachment

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

type MailServerConfig

type MailServerConfig struct {
	Username string
	Password string
	Host     string
	Port     string
}

func NewMailServerConfig

func NewMailServerConfig(username, password, host, port string) *MailServerConfig

type O365Client

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

func NewMailClient

func NewMailClient(cfgMail *MailServerConfig) *O365Client

func (*O365Client) AddAttachment

func (oc *O365Client) AddAttachment(filename string)

func (*O365Client) AddBody

func (oc *O365Client) AddBody(content string)

func (*O365Client) AddFrom

func (oc *O365Client) AddFrom(fromAddress string)

func (*O365Client) AddSubject

func (oc *O365Client) AddSubject(subject string)

func (*O365Client) AddTo

func (oc *O365Client) AddTo(toAdd string)

func (*O365Client) Send

func (oc *O365Client) Send() error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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