Skip to content

Latest commit

 

History

History
20 lines (19 loc) · 759 Bytes

README.md

File metadata and controls

20 lines (19 loc) · 759 Bytes

Mailer API | example workflow

Intro

A simple mailing service via HTTP. It receives messages from a POST payload and send email as requested, if the message is valid. The message must have the format like Message. To connect to the server, set HOST_SMTP environment variable. For now, it only accepts the gmail server (setted host and port to "smtp.gmail.com:465").

MESSAGE STRUCT

type message struct {
	To      string `json:"to"`
	Subject string `json:"subject"`
	Body    string `json:"body"`
	From    string `json:"from"`
	Token   string `json:"token"` // a temporary token!
}

TODOS

  • Add validator hooks for package mailer.