feat: add http as sms provider (#8540)

# Which Problems Are Solved

Send SMS messages as a HTTP call to a relay, for own logic on handling
different SMS providers.

# How the Problems Are Solved

Add HTTP as SMS provider type and handling of webhook messages in the
notification handlers.

# Additional Changes

Clean up old Twilio events, which were supposed to handle the general
SMS providers with deactivate, activate and remove.

# Additional Context

Partially closes #8270

---------

Co-authored-by: Livio Spring <livio.a@gmail.com>
This commit is contained in:
Stefan Benz
2024-09-06 15:11:36 +02:00
committed by GitHub
parent d2e0ac07f1
commit 5bdf1a4547
26 changed files with 2536 additions and 593 deletions

View File

@@ -15,23 +15,23 @@ const (
)
type TemplateData struct {
Title string
PreHeader string
Subject string
Greeting string
Text string
URL string
ButtonText string
PrimaryColor string
BackgroundColor string
FontColor string
LogoURL string
FontURL string
FontFaceFamily string
FontFamily string
Title string `json:"title,omitempty"`
PreHeader string `json:"preHeader,omitempty"`
Subject string `json:"subject,omitempty"`
Greeting string `json:"greeting,omitempty"`
Text string `json:"text,omitempty"`
URL string `json:"url,omitempty"`
ButtonText string `json:"buttonText,omitempty"`
PrimaryColor string `json:"primaryColor,omitempty"`
BackgroundColor string `json:"backgroundColor,omitempty"`
FontColor string `json:"fontColor,omitempty"`
LogoURL string `json:"logoUrl,omitempty"`
FontURL string `json:"fontUrl,omitempty"`
FontFaceFamily string `json:"fontFaceFamily,omitempty"`
FontFamily string `json:"fontFamily,omitempty"`
IncludeFooter bool
FooterText string
IncludeFooter bool `json:"includeFooter,omitempty"`
FooterText string `json:"footerText,omitempty"`
}
func (data *TemplateData) Translate(translator *i18n.Translator, msgType string, args map[string]interface{}, langs ...string) {