Documentation ¶
Index ¶
- Constants
- type ApiChannel
- func (apiChannel *ApiChannel) Execute(ctx context.Context, r *http.Request, mt MessageTemplate) (response *http.Response, err error)
- func (apiChannel *ApiChannel) MakeFromJson(ctx context.Context, rj *json.RawMessage) error
- func (apiChannel *ApiChannel) Send(ctx context.Context, msg string, templateId string, params url.Values) (map[string]interface{}, error)
- type Channel
- func (channel *Channel) Execute(ctx context.Context, r *http.Request, mt MessageTemplate) (response *http.Response, err error)
- func (channel *Channel) GetAttribute(attributeName string) (attributeValue interface{}, err error)
- func (channel *Channel) ProcessMessageTemplate(ctx context.Context, r *http.Request, mt MessageTemplate) (msg Message, err error)
- type ChannelI
- type Message
- type MessageTemplate
- type SmtpChannel
Constants ¶
View Source
const ( API_CHANNEL = "API" SMTP_CHANNEL = "SMTP" )
View Source
const ( HTML_EMAIL = "text/html" TEXT_EMAIL = "text/plain" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApiChannel ¶
func (*ApiChannel) Execute ¶
func (apiChannel *ApiChannel) Execute(ctx context.Context, r *http.Request, mt MessageTemplate) (response *http.Response, err error)
func (*ApiChannel) MakeFromJson ¶
func (apiChannel *ApiChannel) MakeFromJson(ctx context.Context, rj *json.RawMessage) error
type Channel ¶
func (*Channel) GetAttribute ¶
func (*Channel) ProcessMessageTemplate ¶
type ChannelI ¶
type ChannelI interface { Execute(ctx context.Context, r *http.Request, mt MessageTemplate) (response *http.Response, err error) GetAttribute(attributeName string) (attributeValue interface{}, err error) MakeFromJson(ctx context.Context, rj *json.RawMessage) error ProcessMessageTemplate(ctx context.Context, r *http.Request, mt MessageTemplate) (msg Message, err error) }
func GetChannel ¶
type MessageTemplate ¶
type SmtpChannel ¶
type SmtpChannel struct { Channel SmtpHost string SmtpPort int SmtpUser string SmtpDisplayName string SmtpPassword string }
func (*SmtpChannel) Execute ¶
func (smtpChannel *SmtpChannel) Execute(ctx context.Context, r *http.Request, mt MessageTemplate) (response *http.Response, err error)
func (*SmtpChannel) MakeFromJson ¶
func (smtpChannel *SmtpChannel) MakeFromJson(ctx context.Context, rj *json.RawMessage) error
Click to show internal directories.
Click to hide internal directories.