Go client for Microsoft Exchange Web Services (EWS)
To install Go, visit this link.
go get -u github.com/kangchengkun/exchangelib-go
Before using this Go module, you will need to fetch a access token from microsoft online by using https://github.com/kangchengkun/mso-token.
import github.com/kangchengkun/exchangelib-go
exchangelib.Sender = "your-mail-box"
exchangelib.AccessToken = "your-ews-token"
// Change the default exchange web service endpoint
exchangelib.ExchangeServerAddr = "your-exchange-server"
// Send an email
response, err := exchangelib.SendMail(to, cc, bcc, subject, body, attachments)
if err != nil {
fmt.Println("SendMail failed")
}
Follow the Guide to publish new versions
...
git add .
git commit -m "new updates"
$ git tag vx.x.x
$ git push origin vx.x.x