Versions in this module Expand all Collapse all v1 v1.0.1 Jul 20, 2026 v1.0.0 Jul 20, 2026 Changes in this version + const MaxRecordSize + var ErrMaxPadExceeded = errors.New("payload has exceeded the maximum length") + func GenerateVAPIDKeys() (privateKey, publicKey string, err error) + func SendNotification(message []byte, s *Subscription, options *Options) (*http.Response, error) + func SendNotificationWithContext(ctx context.Context, message []byte, s *Subscription, options *Options) (*http.Response, error) + type AuthScheme string + const Vapid + const WebPush + type HTTPClient interface + Do func(*http.Request) (*http.Response, error) + type Keys struct + Auth string + P256dh string + type Options struct + AuthScheme AuthScheme + HTTPClient HTTPClient + RecordSize uint32 + Subscriber string + TTL int + Topic string + Urgency Urgency + VAPIDPrivateKey string + VAPIDPublicKey string + VapidExpiration time.Time + type Subscription struct + Endpoint string + Keys Keys + type Urgency string + const UrgencyHigh + const UrgencyLow + const UrgencyNormal + const UrgencyVeryLow