mirror of
https://github.com/edufeed-org/nips.git
synced 2025-12-10 00:34:32 +00:00
Adds draft event.
This commit is contained in:
parent
de71f99828
commit
2f2dead4cc
2 changed files with 27 additions and 0 deletions
25
35.md
Normal file
25
35.md
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
NIP-35
|
||||
======
|
||||
|
||||
Draft Events
|
||||
------------
|
||||
|
||||
`draft` `optional`
|
||||
|
||||
This NIP defines kind `31234` as a private draft event for any other event kind.
|
||||
|
||||
The draft event is JSON-stringified, [NIP44-encrypted](44.md) to the owner's public key and placed inside the `.content` of the event.
|
||||
|
||||
An additional `k` tag identifies the kind of the draft event.
|
||||
|
||||
```js
|
||||
{
|
||||
"kind": 31234,
|
||||
"tags": [
|
||||
["d", "<identifier>"],
|
||||
["k", "<kind of the draft event>"],
|
||||
],
|
||||
"content": nip44Encrypt(JSON.stringify(draft_event)),
|
||||
// other fields
|
||||
}
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue