diff options
| author | hodlbod <jstaab@protonmail.com> | 2024-11-21 06:55:23 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-11-21 11:55:23 -0300 |
| commit | 1e47fd75572704b84cf484ce52394fc7ea7d4067 (patch) | |
| tree | a95fbc731f2fdf9ac778a6a5be52b5389c2f8b2e /C7.md | |
| parent | 84aeb10d395d0b9a3379c81aacf5b1ff4d675499 (diff) | |
Break out chat and threads from nip 29 (#1591)
Diffstat (limited to 'C7.md')
| -rw-r--r-- | C7.md | 29 |
1 files changed, 29 insertions, 0 deletions
| @@ -0,0 +1,29 @@ | |||
| 1 | NIP-C7 | ||
| 2 | ====== | ||
| 3 | |||
| 4 | Chats | ||
| 5 | ----- | ||
| 6 | |||
| 7 | `draft` `optional` | ||
| 8 | |||
| 9 | A chat message is a `kind 9` event. | ||
| 10 | |||
| 11 | ```json | ||
| 12 | { | ||
| 13 | "kind": 9, | ||
| 14 | "content": "GM", | ||
| 15 | "tags": [] | ||
| 16 | } | ||
| 17 | ``` | ||
| 18 | |||
| 19 | A reply to a `kind 9` is an additional `kind 9` which quotes the parent using a `q` tag. | ||
| 20 | |||
| 21 | ```json | ||
| 22 | { | ||
| 23 | "kind": 9, | ||
| 24 | "content": "nostr:nevent1...\nyes", | ||
| 25 | "tags": [ | ||
| 26 | ["q", <event-id>, <relay-url>, <pubkey>] | ||
| 27 | ] | ||
| 28 | } | ||
| 29 | ``` | ||