From 8cb9b76a8400862b0ef98a86901c2fe3ff89ae98 Mon Sep 17 00:00:00 2001 From: Vitor Pamplona Date: Tue, 16 Apr 2024 13:15:46 -0400 Subject: [PATCH] Updates to allow multiple tags in a single 30021 record --- 54.md | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/54.md b/54.md index e8e1e659..aeac58ec 100644 --- a/54.md +++ b/54.md @@ -28,27 +28,33 @@ Kind `21` defines a `kind:1`-equivalent event that MUST NOT be displayed unless } ``` +Clients MUST include at least one `g`, `t`, `r` or `l` tags. + `.content` MUST be plain text and tags that mention, quote and assemble threading structures MUST follow [NIP-10](10.md). ## Topical Relay Setup -Kind `30021` defines a topic follower. It registers a list of relays to aggregate events for each topic. +Kind `30021` defines a following topic. It registers a list of relays to aggregate events for the list of topics. -The `d` tag of this kind is equal to `name:value` of the topics used in kind `21`. +The `d` tag of this kind is a simple `UUID`. ```js { "kind": 30021, "tags": [ - ["d", "g:"], - ["r", "wss://my-city-owned-relay"], - ["r", "wss://independent-but-city-based-relay"], + ["d", ""], + ["g", ""], + ["t", ""], + ["r", ""], + ["relay", "wss://my-city-owned-relay"], + ["relay", "wss://independent-but-city-based-relay"], // ... other tags ["title", "Name of this topic"] ], "content": nip44Encrypt([ - ["r", "wss://my-city-owned-relay2"], // private relay + ["relay", "wss://my-city-owned-relay2"], // private relay ["title", "Name of this topic"] // private topic title + ["t", ""], // private follows of tags. // ... other tags ]), //...other fields