mirror of
https://github.com/nostr-protocol/nips.git
synced 2024-12-23 00:45:53 -05:00
Update 107.md
This commit is contained in:
parent
0984355d91
commit
80b56485a2
8
107.md
8
107.md
|
@ -53,19 +53,21 @@ This message is sent by a `user` to a `device`. The `device` saves the config lo
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"type": 0,
|
"type": 0,
|
||||||
"admin_pubkeys": [ [<String (optional), admin user public-key>]],
|
|
||||||
"name": <String (optional), set a name for the device>,
|
"name": <String (optional), set a name for the device>,
|
||||||
"description": <String (optional), device description>,
|
"description": <String (optional), device description>,
|
||||||
"categories":[ <String (optional), device category, such as 'boiler'>],
|
"categories":[ <String (optional), device category, such as 'boiler'>],
|
||||||
"send_to_pubkeys":[ [<String (optional), user public-key>]],
|
"admin_pubkeys": [ [<String (optional), admin user public-key>]],
|
||||||
|
"publish_to_pubkeys":[ [<String (optional), user public-key>]],
|
||||||
"intents_from_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`.>
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
| Field | Description |
|
| Field | Description |
|
||||||
|---|---|
|
|---|---|
|
||||||
| `admin_pubkeys` | List of public keys that are allowed to configure this device.<br>A fresh/blank device will not have this value, so the first received `"type: 0"` should set it.<br/> The `admin_pubkeys` implicitly have the `actions_from_pubkeys` permissions. |
|
| `admin_pubkeys` | List of public keys that are allowed to configure this device.<br>A fresh/blank device will not have this value, so the first received `"type: 0"` should set it.<br/> The `admin_pubkeys` implicitly have the `actions_from_pubkeys` permissions. |
|
||||||
| `send_to_pubkeys` | List of public keys to which events are published. |
|
| `publish_to_pubkeys` | List of public keys to which events are published. |
|
||||||
| `actions_from_pubkeys` | List of public keys that are allowed to trigger an action on this device.<br/> The `admin_pubkeys` implicitly have the `actions_from_pubkeys` permissions. |
|
| `actions_from_pubkeys` | List of public keys that are allowed to trigger an action on this device.<br/> The `admin_pubkeys` implicitly have the `actions_from_pubkeys` permissions. |
|
||||||
|
|
||||||
### Event: Update a `device`
|
### Event: Update a `device`
|
||||||
|
|
Loading…
Reference in New Issue
Block a user