content/flux/v0/stdlib/pushbullet/pushdata.md
pushbullet.pushData() sends a push notification to the Pushbullet API.
(data: A, ?token: B, ?url: string) => int
{{% caption %}} For more information, see Function type signatures. {{% /caption %}}
URL of the PushBullet endpoint. Default is "https://api.pushbullet.com/v2/pushes".
API token string. Default is "".
({{< req >}}) Data to send to the endpoint. Data is JSON-encoded and sent to the Pushbullet's endpoint.
For how to structure data, see the Pushbullet API documentation.
import "pushbullet"
pushbullet.pushData(
token: "mY5up3Rs3Cre7T0k3n",
data: {
"type": "link",
"title": "Example title",
"body": "Example nofication body",
"url": "http://example-url.com",
},
)