func (s *SendGrid) Send(subject, from, body string, to []string) (*rest.Response, error) {
	e := createEmail(subject, from, body, emailSender, to)
	r, err := s.Service.Send(e)
	if err != nil {
		return nil, err
	}
	if r.StatusCode < 200 || r.StatusCode > 202 {
		return nil, fmt.Errorf("Error to send email. StatusCode:(%d)", r.StatusCode)
	}
	return r, err
}
Send email SendGrid.
package clients
import (
	"fmt"
	"github.com/sendgrid/rest"
	"github.com/sendgrid/sendgrid-go"
	"github.com/sendgrid/sendgrid-go/helpers/mail"
)
const (
	emailSender = "Security Response Automation"
)
type SendGridClient interface {
	Send(mail *mail.SGMailV3) (*rest.Response, error)
}
type SendGrid struct {
	Service SendGridClient
}
func NewSendGridClient(apiKey string) *SendGrid {
	return &SendGrid{Service: sendgrid.NewSendClient(apiKey)}
}