fcm

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2026 License: AGPL-3.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 Config

type Config struct {
	// CredentialsPath is the path to the Firebase service account JSON file.
	// If empty, Application Default Credentials (ADC) are used.
	CredentialsPath string
}

Config holds FCM configuration.

type Sender

type Sender struct {
	// contains filtered or unexported fields
}

Sender sends push notifications to Android devices via FCM.

func NewSender

func NewSender(ctx context.Context, cfg *Config, tracerProvider tracing.TracerProvider, logger logging.Logger, metricsProvider metrics.Provider) (*Sender, error)

NewSender creates an FCM sender from config.

func (*Sender) Send

func (s *Sender) Send(ctx context.Context, deviceToken, title, body string) error

Send sends a push notification to a single device token.

Jump to

Keyboard shortcuts

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