Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CreateTemplateRequest ¶
type GetProviderReqeuest ¶
type GetProviderReqeuest struct { Token string `header:"X-Notifier-Token"` Type domain.ProviderType `param:"provider"` }
type GetProviderResponse ¶
type MessageService ¶
type MessageService interface {
Send(ctx context.Context, request *SendMessageRequest) (domain.Messages, domain.IError)
}
func NewMessageService ¶
func NewMessageService(templateRepository domain.TemplateRepository) MessageService
type ProviderService ¶
type ProviderService interface {
GetProvider(context.Context, *GetProviderReqeuest) (*GetProviderResponse, domain.IError)
}
func NewProviderService ¶
func NewProviderService() ProviderService
type SendMessageRequest ¶
type SendMessageRequest struct { TenantID string `param:"tenant_id"` Payload *map[string]interface{} `json:"payload"` Recipients []struct { Notifier *domain.Notifier `json:"notifier"` Template *domain.Template `json:"template"` } `json:"recipients"` }
func (*SendMessageRequest) Validate ¶
func (r *SendMessageRequest) Validate() domain.IError
type TemplateService ¶
type TemplateService interface {
Create(ctx context.Context, request *CreateTemplateRequest) (*domain.Template, error)
}
func NewTemplateService ¶
func NewTemplateService(repository domain.TemplateRepository) TemplateService
Click to show internal directories.
Click to hide internal directories.