services

package
v0.0.0-...-a2883fb Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientService

type ClientService struct {
	FirebaseGoogle *FirebaseGoogleService
	Mailgun        *MailgunService
}

func NewServiceHandler

func NewServiceHandler(cfg *config.NotificationConfig) *ClientService

type FirebaseGoogleService

type FirebaseGoogleService struct {
	App *firebase.App
}

func NewFcmGoogleService

func NewFcmGoogleService(cfg *config.FirebaseGoogle) (*FirebaseGoogleService, error)

func (*FirebaseGoogleService) SendPushMessage

func (x *FirebaseGoogleService) SendPushMessage(osName, deviceToken, title, body string) error

func (*FirebaseGoogleService) SendPushNotification

func (x *FirebaseGoogleService) SendPushNotification(osName, deviceToken, title, body string, data map[string]string) error

type MailgunService

type MailgunService struct {
	Cfg *config.Mailgun
}

Ref: https://github.com/Golang-Coach/Lessons/blob/master/GoMailer/main.go

func NewMailgunClient

func NewMailgunClient(cfg *config.Mailgun) *MailgunService

func (*MailgunService) SendEmail

func (x *MailgunService) SendEmail(subject string, to []string, htmlMessage, textMessage string) (string, error)

Jump to

Keyboard shortcuts

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