Update 107.md

This commit is contained in:
Vlad Stan 2023-10-25 12:32:49 +03:00 committed by GitHub
parent 570387ea2a
commit 05a988973a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

7
107.md
View File

@ -55,7 +55,7 @@ This message is sent by an admin `user` to a `device`. The `device` saves the co
"publish_to_pubkeys":[ [<String (optional), user public-key>]],
"intents_from_pubkeys":[ [<String (optional), user public-key>]],
"publish_on_change": <Boolean (optional, default `true`), publish event each time a sensor value changes>,
"publish_interval": <Integer (optional), publish the sensor value at regular intervals (regardless the value changes or not). The value is in `millisecods`.>
"publish_interval": <Integer (optional), publish the sensor value at regular intervals (regardless if the value changes or not). The value is in `millisecods`.>
"unix_time": <Integer (optional), set system time in `millisecods`.>
}
```
@ -100,7 +100,10 @@ Example that turns on a device and sets the temperature to `20.9` degrees Celsiu
### Data Events (`kind: 8001 - 8999`)
Data Events represent data publised by `device`(s). The `kind` of the event and the `content` must follow ths specification from [NIP-91 Event Kinds](https://github.com/nostr-protocol/nips/blob/iot/91.md#event-kinds).
Data Events represent data published by `device`(s). The `kind` of the event and the `content` must follow ths specification from [NIP-91 Event Kinds](https://github.com/nostr-protocol/nips/blob/iot/91.md#event-kinds).
> [!NOTE]
> If a device has more sensors attached (eg: temperature and humidity) then it will publish separate events for each measured value.
**Event Tags**:
```json