Moves away from the relays tag in favor of multiple relay tags.

This commit is contained in:
Vitor Pamplona 2024-04-03 09:50:32 -04:00
parent 58eb479c3b
commit e9a201b5c0

9
63.md
View File

@ -10,9 +10,9 @@ Event kind `33012` is used to represent one or more Nostr filters.
The `d` tag represents the subscription id and the `filter` tag contains the JSON-stringified [NIP-01](01.md) filter. The `d` tag represents the subscription id and the `filter` tag contains the JSON-stringified [NIP-01](01.md) filter.
The optional `relays` tag contains the destination relays the filter was designed to download events from. The optional `relay` tag lists the authorized relays the filter can download events from.
The optional `authorized` pubkey contains the pubkey authorized to re-use this filter and receive events on behalf of the user. The optional `authorized` tag lists the pubkeys that are authorized to receive authed events on behalf of the user.
```js ```js
{ {
@ -22,7 +22,8 @@ The optional `authorized` pubkey contains the pubkey authorized to re-use this f
["filter", "<filter1>"], ["filter", "<filter1>"],
["filter", "<filter2>"], ["filter", "<filter2>"],
["authorized", "<32-bytes lowercase hex of a pubkey>"], ["authorized", "<32-bytes lowercase hex of a pubkey>"],
["relays", "<relay1>", "<relay2>", ...], ["relay", "<relay1>"],
["relay", "<relay2>"],
["expiration", "<unix timestamp>"], ["expiration", "<unix timestamp>"],
], ],
"content": "", "content": "",
@ -40,7 +41,7 @@ Supporting relays interpret the `filter` tags in the same way they do with `REQ`
Relays MUST authenticate the `authorized` key if present. Relays MUST authenticate the `authorized` key if present.
Relays MUST verify if they are included in the `relays` list if present. Relays MUST verify if they are included in the `relay` tag list if present.
Relays MUST comply with the `expiration` to limit the reuse of the filter. Relays MUST comply with the `expiration` to limit the reuse of the filter.