mail

package
v1.0.7 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SendViaMailgun

func SendViaMailgun(conf *Config, params *Params) (string, string, error)

SendViaMailgun will try to send the mail using mailgun

func SendViaMailjet

func SendViaMailjet(conf *MailjetConfig, params *MailjetParams) (*mailjet.ResultsV31, error)

SendViaMailjet will try to send the mail using mailjet

Types

type Config

type Config struct {
	Key, Domain string
}

type MailjetConfig

type MailjetConfig struct {
	PubKey, PrivateKey string
}

type MailjetParams

type MailjetParams struct {
	SenderEmail, SenderName, ReplyToEmail string
	RecipientEmail                        []string
	Subject                               string
	CC, BCC                               []string
	TextPart, HtmlPart                    string
}

type Params

type Params struct {
	Sender, Subject string
	Body, Recipient string
	ReplyTo         string
	CC, BCC         []string // CC emails
	Timeout         int      // timeout in seconds
}

Jump to

Keyboard shortcuts

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