Skip to content

Latest commit

 

History

History
47 lines (33 loc) · 1.18 KB

README.md

File metadata and controls

47 lines (33 loc) · 1.18 KB

azmail

Go Reference Go Report

Go API for sending emails through Microsoft Azure's Email Communication Service.

Installation

$ go get -u github.com/darylhjd/azmail

Example Usage

package main

import (
	"log"

	"github.com/darylhjd/azmail"
)

func main() {
	client, _ := azmail.NewClient("ENDPOINT", "ACCESS_KEY", "SENDER_ADDRESS")

	// Create mails that you want to send.
	mail1 := azmail.NewMail()
	mail1.Recipients = ...
	mail1.Content = ...
	mail1.Attachments = ...
	mail2 := azmail.NewMail()
	...

	// Send your mails.
	errs := client.SendMails(mail1, mail2)
	log.Println(errs)
}

Current Version and Documentation

This wrapper implements version 2023-03-31 of the Email API.

More information on the API can be found here.