Add annotations

This commit is contained in:
Jon Staab 2024-02-26 07:52:03 -08:00
parent b765b3c030
commit 71cae195b4

32
37.md Normal file
View File

@ -0,0 +1,32 @@
NIP-37
======
Annotations
-----------
`draft` `optional`
This NIP adds a new concept called "annotations" which allow authors to create privileged comments on their own notes.
These are simply `kind:1` replies with an additional `annotation` tag.
These can be used to indicate updates, edits, corrections, or retractions, without obscuring the content of the original
note or forcing clients to handle multiple versions of the note. These MAY be applied to events of any kind.
```js
{
"kind": 1,
"pubkey": "<pubkey>",
"tags": [
["e", "<event_id>", "<relay_hint>", "reply"],
["annotation"]
],
"content": "EDIT: I forgot to say...",
// ...other fields
}
```
Clients MUST check if the pubkey of the annotation is the same as the referenced event.
These events are designed so that clients that don't support annotations will still show these events as replies.
Clients SHOULD have a strategy for displaying replies to annotations.