hermes/examples/default/welcome.go

42 lines
915 B
Go
Raw Normal View History

2017-03-28 16:16:20 +00:00
package main
import (
"github.com/matcornic/hermes"
)
type Welcome struct {
}
func (w *Welcome) Name() string {
return "welcome"
}
func (w *Welcome) Email() hermes.Email {
return hermes.Email{
Body: hermes.Body{
Name: "Jon Snow",
Intros: []string{
"Welcome to Hermes! We're very excited to have you on board.",
},
Dictionary: []hermes.Entry{
{Key: "Firstname", Value: "Jon"},
{Key: "Lastname", Value: "Snow"},
{Key: "Birthday", Value: "01/01/283"},
},
Actions: []hermes.Action{
{
Instructions: "To get started with Hermes, please click here:",
Button: hermes.Button{
Color: "#22BC66",
Text: "Confirm your account",
Link: "https://hermes-example.com/confirm?token=d9729feb74992cc3482b350163a1a010",
},
},
},
Outros: []string{
"Need help, or have questions? Just reply to this email, we'd love to help.",
},
},
}
}