diff options
Diffstat (limited to '26.md')
| -rw-r--r-- | 26.md | 29 |
1 files changed, 29 insertions, 0 deletions
| @@ -0,0 +1,29 @@ | |||
| 1 | NIP-26 | ||
| 2 | ====== | ||
| 3 | |||
| 4 | Relays List | ||
| 5 | ----------- | ||
| 6 | |||
| 7 | `draft` `optional` `author:fiatjaf` | ||
| 8 | |||
| 9 | A special event with kind `10001`, meaning "relay list" is defined as having a list of tags, one for each relay the author uses. | ||
| 10 | |||
| 11 | The content is not used. | ||
| 12 | |||
| 13 | The tags consist of arrays of 3 elements: the first is the relay URL, the second is the "read" condition -- which if set `"true"` means the client is reading events from that relay --, the third is the "write" condition -- which if set to `"true"` means the user is writing events to that relay. | ||
| 14 | |||
| 15 | In the future this NIP will be modified with more fine-grained conditions for writing and reading from relays, based on properties of the filter or of the event respectively, written as strings in a simple language. | ||
| 16 | |||
| 17 | Example: | ||
| 18 | |||
| 19 | ```json | ||
| 20 | { | ||
| 21 | "kind": 10001, | ||
| 22 | "tags": [ | ||
| 23 | ["wss://alicerelay.com/", "true", "false"], | ||
| 24 | ["wss://bobrelay.com/", "true", "true"], | ||
| 25 | ["wss://carolrelay.com/", "false", "true"], | ||
| 26 | ], | ||
| 27 | "content": "", | ||
| 28 | ...other fields | ||
| 29 | ``` | ||