Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*pushNotifications)
func WithCustomBaseURL ¶
func WithRequestTimeout ¶
type PushNotifications ¶
type PushNotifications interface { // Publishes notifications to all devices subscribed to at least 1 of the interests given // Returns a non-empty `publishId` JSON string if successful; or a non-nil `error` otherwise. PublishToInterests(interests []string, request map[string]interface{}) (publishId string, err error) // DEPRECATED. An alias for `PublishToInterests` Publish(interests []string, request map[string]interface{}) (publishId string, err error) // Publishes notifications to all devices associated with the given user ids // Returns a non-empty `publishId` JSON string successful, or a non-nil `error` otherwise. PublishToUsers(users []string, request map[string]interface{}) (publishId string, err error) // Creates a signed JWT for a user id. // Returns a signed JWT if successful, or a non-nil `error` otherwise. GenerateToken(userId string) (token map[string]interface{}, err error) // Contacts the Beams service to remove all the devices of the given user // Return a non-nil `error` if there's a problem. DeleteUser(userId string) (err error) }
The Pusher Push Notifications Server API client
Click to show internal directories.
Click to hide internal directories.