FCM entry point for firebase-admin-util
- Source:
Methods
(async, inner) sendSilentToDevice(token, data) → {Promise.<object>}
Send silent notification to device
Parameters:
Name | Type | Description |
---|---|---|
token |
string | The registration token from FCM. |
data |
object | The push notification payload. |
- Source:
Returns:
Same behavior as vanilla firebase admin sdk.
- Type
- Promise.<object>
(async, inner) sendSilentToTopic(topic, data) → {Promise.<object>}
Send silent notification to topic
Parameters:
Name | Type | Description |
---|---|---|
topic |
string | The subscription topic string. |
data |
object | The push notification payload. |
- Source:
Returns:
Same behavior as vanilla firebase admin sdk.
- Type
- Promise.<object>
(async, inner) sendToDevice(token, title, message, dataopt) → {Promise.<object>}
Send push notification to device
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
token |
string | The registration token from FCM. | |
title |
string | The push notification title. | |
message |
string | The push notification message. | |
data |
object |
<optional> |
The push notification payload. |
- Source:
Returns:
Same behavior as vanilla firebase admin sdk.
- Type
- Promise.<object>
(async, inner) sendToTopic(topic, title, message, dataopt) → {Promise.<object>}
Send push notification to topic
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
topic |
string | The subscription topic string. | |
title |
string | The push notification title. | |
message |
string | The push notification message. | |
data |
object |
<optional> |
The push notification payload. |
- Source:
Returns:
Same behavior as vanilla firebase admin sdk.
- Type
- Promise.<object>