diff options
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 | ``` | ||