1
0
Fork 0

Adding upstream version 1.34.4.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-05-24 07:26:29 +02:00
parent e393c3af3f
commit 4978089aab
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
4963 changed files with 677545 additions and 0 deletions

View file

@ -0,0 +1,45 @@
# particle webhooks
You should configure your Particle.io's Webhooks to point at the `webhooks`
service. To do this go to [https://console.particle.io][particle.io]
and click `Integrations > New Integration > Webhook`. In the resulting page set
`URL` to `http://<my_ip>:1619/particle`, and under `Advanced Settings` click
on `JSON` and add:
```json
{
"measurement": "your_measurement_name"
}
```
If required, enter your username and password, etc. and then click `Save`
[particle.io]: https://console.particle.io/
## Events
Your Particle device should publish an event that contains a JSON in the form
of:
```json
String data = String::format("{ \"tags\" : {
\"tag_name\": \"tag_value\",
\"other_tag\": \"other_value\"
},
\"values\": {
\"value_name\": %f,
\"other_value\": %f,
}
}", value_value, other_value
);
Particle.publish("event_name", data, PRIVATE);
```
Escaping the "" is required in the source file.
The number of tag values and field values is not restricted so you can send as
many values per webhook call as you'd like.
You will need to enable JSON messages in the Webhooks setup of Particle.io, and
make sure to check the "include default data" box as well.
See [webhook doc](https://docs.particle.io/reference/webhooks/)