loginauth "github.com/rafaelsouzaribeiro/send-email/pkg/login-auth"
auth := loginauth.LoginAuth("email", "password")
subject := "Subject: Test Email from Go\n"
body := "This is a test email message from Go.\n"
msg := []byte(subject + "\n" + body)
err := smtp.SendMail("smtp-mail.outlook.com:25", auth, "fromemail", []string{"[email protected]"}, msg)
if err != nil {
panic(err)
}
fmt.Println("Email successfully sent!")
-
Notifications
You must be signed in to change notification settings - Fork 0
rafaelsouzaribeiro/send-email
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Sending email with hotmail
Topics
Resources
Stars
Watchers
Forks
Packages 0
No packages published