diff options
| author | Vitor Pamplona <vitor@vitorpamplona.com> | 2024-12-19 10:15:46 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-12-19 10:15:46 -0500 |
| commit | f7d97f3f40dc6677e6f996ffff431142ffe05810 (patch) | |
| tree | 2eaa8c8628cc9a4b05811ed3869e21221fd85307 /C7.md | |
| parent | d5b77b6d7348061cd0f16adc35e4d02a3a0b7380 (diff) | |
| parent | 561059ff85c171b87a12b8381b724b4afc569a97 (diff) | |
Merge branch 'master' into draft-event
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 | ``` | ||