pushbullet.pushNote() function
The pushbullet.pushNote()
function sends a push notification of type note
to the Pushbullet API.
Function type: Output
import "pushbullet"
pushbullet.pushNote(
url: "https://api.pushbullet.com/v2/pushes",
token: "",
title: "This is a push notification!",
text: "This push notification came from Flux."
)
Parameters
url
Pushbullet API URL.
Defaults to https://api.pushbullet.com/v2/pushes
.
Data type: String
token
Pushbullet API token
to use when interacting with Pushbullet.
Defaults to ""
.
Data type: String
title
(Required)
Title of the notification.
Data type: String
text
(Required)
Text to display in the notification.
Data type: String
Examples
Send the last reported status to Pushbullet
import "pushbullet"
import "influxdata/influxdb/secrets"
token = secrets.get(key: "PUSHBULLET_TOKEN")
lastReported =
from(bucket: "example-bucket")
|> range(start: -1m)
|> filter(fn: (r) => r._measurement == "statuses")
|> last()
|> tableFind(fn: (key) => true)
|> getRecord(idx: 0)
pushbullet.pushNote(
token: token,
title: "Last reported status",
text: "${lastReported._time}: ${lastReported.status}."
)
Support and feedback
Thank you for being part of our community! We welcome and encourage your feedback and bug reports for InfluxDB and this documentation. To find support, the following resources are available:
InfluxDB Cloud and InfluxDB Enterprise customers can contact InfluxData Support.