apn

package module
v0.0.0-...-c871668 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2020 License: MIT Imports: 9 Imported by: 0

README

APN Worker

This is a proof of concept for utilizing Google Pub/Sub and Kubernetes for sending Apple Push Notifications.

Read the full article on http://blog.joonix.se/2017/02/apple-push-notifications-with.html

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPError

type HTTPError struct {
	Response *http.Response
}

HTTPError will be returned when the HTTP code suggest an error occured when sending notifications.

func (HTTPError) Error

func (e HTTPError) Error() string

type NotificationProvider

type NotificationProvider func(msg proto.NotificationPayload, token, identifier string, expiration time.Time) (*http.Response, error)

NotificationProvider defines the necessary parameters for sending a notification.

func NewNotificationProvider

func NewNotificationProvider(pub, key, topic, server string) (NotificationProvider, error)

NewNotificationProvider prepares an Apple APN provider for sending push notifications. Read more about it in the Apple documentation https://goo.gl/ywkRfD

Directories

Path Synopsis
cmd
apn

Jump to

Keyboard shortcuts

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