PushApi

interface PushApi

Subscribe to and receive push notifications when a server-side notification is received, via the Web Push API.

See also

Functions

Link copied to clipboard
abstract suspend fun deleteSubscription()

Removes the current Web Push API subscription.

Link copied to clipboard
abstract suspend fun getSubscription(): PushSubscription

View the PushSubscription currently associated with this access token.

Link copied to clipboard
abstract suspend fun subscribe(params: PushSubscribe): PushSubscription

Adds a Web Push API subscription to receive notifications.

Link copied to clipboard
abstract suspend fun updateSubscription(params: PushUpdate): PushSubscription

Updates the current push subscription.