email/payload.go

40 lines
787 B
Go
Raw Normal View History

2022-11-16 07:04:03 +00:00
package email
import (
"git.selly.red/Selly-Modules/natsio"
)
// Config ...
type Config struct {
Nats natsio.Config
}
type Recipient struct {
To []string `json:"to,omitempty"`
From string `json:"from,omitempty"`
CC []string `json:"cc,omitempty"`
BCC []string `json:"bcc,omitempty"`
Subject string `json:"subject,omitempty"`
Attachment []Attachment `json:"attachment"`
}
type Attachment struct {
URL string `json:"url"`
}
type Data struct {
Password string `json:"password"`
}
// SendPayload ...
type SendPayload struct {
Subject string `json:"subject"`
Recipient Recipient `json:"recipient"`
Data Data `json:"data"`
}
// Response ...
type Response struct {
RequestID string `json:"requestId"`
}