PushSubscription extension type

The PushSubscription interface of the Push API provides a subscription's URL endpoint and allows unsubscribing from a push service.

An instance of this interface can be serialized.


API documentation sourced from MDN Web Docs.

on
Implemented types
Available extensions

Properties

endpoint String
The endpoint read-only property of the PushSubscription interface returns a string containing the endpoint associated with the push subscription.
no setter
expirationTime EpochTimeStamp?
The expirationTime read-only property of the PushSubscription interface returns a DOMHighResTimeStamp of the subscription expiration time associated with the push subscription, if there is one, or null otherwise.
no setter
hashCode int
The hash code for this object.
no setterinherited
options PushSubscriptionOptions
The options read-only property of the PushSubscription interface is an object containing the options used to create the subscription.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getKey(PushEncryptionKeyName name) JSArrayBuffer?
The getKey() method of the PushSubscription interface returns an ArrayBuffer representing a client public key, which can then be sent to a server and used in encrypting push message data.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJSON() PushSubscriptionJSON
The toJSON() method of the PushSubscription interface is a standard serializer: it returns a JSON representation of the subscription properties, providing a useful shortcut.
toString() String
A string representation of this object.
inherited
unsubscribe() JSPromise<JSBoolean>
The unsubscribe() method of the PushSubscription interface returns a Promise that resolves to a boolean value when the current subscription is successfully unsubscribed.

Operators

operator ==(Object other) bool
The equality operator.
inherited