{"modulePath":"github.com/infinitbyte/framework","version":"v1.1.5","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package smtp\n\n## Functions\n\n```go\nfunc AddCC(msg *gomail.Message, ccs []map[string]string)\n```\n\n```go\nfunc New(c *config.Config) (pipeline.Processor, error)\n```\n\n## Types\n\n```go\ntype Attachment struct {\n\tFile        string `config:\"file\"`\n\tContentType string `config:\"content_type\"`\n\tInline      bool   `config:\"inline\"`\n\tCID         string `config:\"cid\"`\n}\n```\n\n```go\ntype Config struct {\n\tDialTimeoutInSeconds int                    `config:\"dial_timeout_in_seconds\"`\n\tMessageField         param.ParaKey          `config:\"message_field\"`\n\tVariableStartTag     string                 `config:\"variable_start_tag\"`\n\tVariableEndTag       string                 `config:\"variable_end_tag\"`\n\tVariables            map[string]interface{} `config:\"variables\"`\n\n\tServers map[string]*ServerConfig `config:\"servers\"`\n\n\tTemplates map[string]*Template `config:\"templates\"`\n}\n```\n\n```go\ntype SMTPProcessor struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc (processor *SMTPProcessor) Name() string\n```\n\n```go\nfunc (processor *SMTPProcessor) Process(ctx *pipeline.Context) error\n```\n\n```go\ntype ServerConfig struct {\n\tServer struct {\n\t\tHost string `config:\"host\"`\n\t\tPort int    `config:\"port\"`\n\t\tTLS  bool   `config:\"tls\"`\n\t} `config:\"server\"`\n\n\tAuth struct {\n\t\tUsername string `config:\"username\"`\n\t\tPassword string `config:\"password\"`\n\t} `config:\"auth\"`\n\n\tSendFrom string `config:\"sender\"`\n\n\tRecipients struct {\n\t\tTo  []string `config:\"to\"`\n\t\tCC  []string `config:\"cc\"`\n\t\tBCC []string `config:\"bcc\"`\n\t} `config:\"recipients\"`\n}\n```\n\n```go\ntype Template struct {\n\tContentType string       `config:\"content_type\"` //text or html\n\tSubject     string       `config:\"subject\"`\n\tBody        string       `config:\"body\"`\n\tBodyFile    string       `config:\"body_file\"` //use file to store template\n\tAttachments []Attachment `config:\"attachments\"`\n\t// contains filtered or unexported fields\n}\n```\n\n","path":"github.com/infinitbyte/framework/plugins/smtp","name":"smtp","synopsis":"","isRedistributable":true}
