configservice

package
v0.0.0-...-d60bda4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 3, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIProxy

type APIProxy struct {
	Host  string
	Cache *cache.Cache
}

func NewConfigServiceProxy

func NewConfigServiceProxy(host string, cacheExpireInSeconds int) (*APIProxy, error)

func (*APIProxy) GetEmailSenderConfiguration

func (e *APIProxy) GetEmailSenderConfiguration(ctx context.Context, namespace string) (emailSender *EmailSenderConfiguration, err error)

type EmailSenderConfiguration

type EmailSenderConfiguration struct {
	Namespace             string           `json:"namespace"`
	FromAddress           string           `json:"fromAddress"`
	FromName              string           `json:"fromName"`
	APIKey                string           `json:"apiKey"`
	IsDomainAuthenticated bool             `json:"isDomainAuthenticated"`
	EmailTemplates        []*EmailTemplate `json:"emailTemplates,omitempty"`
}

func (EmailSenderConfiguration) GetEmailTemplate

func (d EmailSenderConfiguration) GetEmailTemplate(name string) *EmailTemplate

type EmailTemplate

type EmailTemplate struct {
	TemplateName string `json:"TemplateName"`
	TemplateID   string `json:"TemplateID"`
}

type ErrorEntity

type ErrorEntity struct {
	ErrorCode    int    `json:"errorCode"`
	ErrorMessage string `json:"errorMessage"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL