Skip to content

It's Hacktoberfest!! SendGrid is giving out shirts if you make pull requests!

License

Notifications You must be signed in to change notification settings

anatolyyyyyy/smtpapi-go

 
 

Repository files navigation

SendGrid Logo

BuildStatus MIT licensed Email Notifications Badge Twitter Follow GitHub contributors Go Report Card GoDoc

This is a simple library to simplify the process of using SendGrid's X-SMTPAPI with the Go programming language

Table of Contents

Announcements

All updates to this library is documented in our CHANGELOG.

Installation

Prerequisites

  • Go version 1.6
  • The SendGrid service, starting at the free level

Install Package

go get github.com/sendgrid/smtpapi-go

Setup Environment Variables

Environment Variable

Update the development environment with your SENDGRID_API_KEY, for example:

echo "export SENDGRID_API_KEY='YOUR_API_KEY'" > sendgrid.env
echo "sendgrid.env" >> .gitignore
source ./sendgrid.env

Quick Start

package main

import (
  "github.com/sendgrid/smtpapi-go"
  "fmt"
)

func main() {
  header := smtpapi.NewSMTPAPIHeader()
  header.AddTo("test@example.com")
  fmt.Println(header.JSONString())
}

Usage

Roadmap

If you are interested in the future direction of this project, please take a look at our milestones. We would love to hear your feedback.

How to Contribute

We encourage contribution to our libraries, please see our CONTRIBUTING guide for details.

Quick links:

About

smtpapi-go is guided and supported by the SendGrid Developer Experience Team.

smtpapi-go is maintained and funded by SendGrid, Inc. The names and logos for smtpapi-go are trademarks of SendGrid, Inc.

License

The MIT License (MIT)

About

It's Hacktoberfest!! SendGrid is giving out shirts if you make pull requests!

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 100.0%