Updates the guidance of the contact list to account for the new additions by clients.

This commit is contained in:
Vitor Pamplona 2023-07-13 20:44:10 -04:00
parent 20b9bb787b
commit f093143f24

11
02.md
View File

@ -6,19 +6,22 @@ Contact List and Petnames
`final` `optional` `author:fiatjaf` `author:arcbtc`
A special event with kind `3`, meaning "contact list" is defined as having a list of `p` tags, one for each of the followed/known profiles one is following.
A special event with kind `3`, meaning "contact list" is defined as having a list of `p`, `t`, `e` or `a` tags, one for each of the profiles, hashtags and other events such as communities or chats one is following.
Each tag entry should contain the key for the profile, a relay URL where events from that key can be found (can be set to an empty string if not needed), and a local name (or "petname") for that profile (can also be set to an empty string or not provided), i.e., `["p", <32-bytes hex key>, <main relay URL>, <petname>]`. The `content` can be anything and should be ignored.
Each `p` tag entry should contain the key for the profile, a relay URL where events from that key can be found (can be set to an empty string if not needed), and a local name (or "petname") for that profile (can also be set to an empty string or not provided), i.e., `["p", <32-bytes hex key>, <main relay URL>, <petname>]`. The `content` can be anything and should be ignored.
For example:
```json
```js
{
"kind": 3,
"tags": [
["p", "91cf9..4e5ca", "wss://alicerelay.com/", "alice"],
["p", "14aeb..8dad4", "wss://bobrelay.com/nostr", "bob"],
["p", "612ae..e610f", "ws://carolrelay.com/ws", "carol"]
["p", "612ae..e610f", "ws://carolrelay.com/ws", "carol"],
["t", "intro"] // hashtag
["a", "34550:3f770d65d3a764a9c5cb503ae123e62ec7598ad035d836e2a810f3877a745b24:android", "ws://carolrelay.com/ws"] // Android community
["e", "25e5c82273a271cb1a840d0060391a0bf4965cafeb029d5ab55350b418953fbb", "ws://carolrelay.com/ws"] // Nostr Public Chat kind:40 Creation Event
],
"content": "",
...other fields