Represents the WebPush-specific notification options that can be included in admin.messaging.WebpushConfig. This supports most of the standard options as defined in the Web Notification specification.

Indexable

[key: string]: any

Represents the WebPush-specific notification options that can be included in admin.messaging.WebpushConfig. This supports most of the standard options as defined in the Web Notification specification.

Index

Properties

Optional actions

actions: Array<object>

An array of notification actions representing the actions available to the user when the notification is presented.

Optional badge

badge: string

URL of the image used to represent the notification when there is not enough space to display the notification itself.

Optional body

body: string

Body text of the notification.

Optional data

data: any

Arbitrary data that you want associated with the notification. This can be of any data type.

Optional dir

dir: "auto" | "ltr" | "rtl"

The direction in which to display the notification. Must be one of auto, ltr or rtl.

Optional icon

icon: string

URL to the notification icon.

Optional image

image: string

URL of an image to be displayed in the notification.

Optional lang

lang: string

The notification's language as a BCP 47 language tag.

Optional renotify

renotify: boolean

A boolean specifying whether the user should be notified after a new notification replaces an old one. Defaults to false.

Optional requireInteraction

requireInteraction: boolean

Indicates that a notification should remain active until the user clicks or dismisses it, rather than closing automatically. Defaults to false.

Optional silent

silent: boolean

A boolean specifying whether the notification should be silent. Defaults to false.

Optional tag

tag: string

An identifying tag for the notification.

Optional timestamp

timestamp: number

Timestamp of the notification. Refer to https://developer.mozilla.org/en-US/docs/Web/API/notification/timestamp for details.

Optional title

title: string

Title text of the notification.

Optional vibrate

vibrate: number | number[]

A vibration pattern for the device's vibration hardware to emit when the notification fires.