From 00b2e0a5cb819f9b2e8135f08d29ee94607d83b6 Mon Sep 17 00:00:00 2001 From: Vitor Pamplona Date: Thu, 30 May 2024 15:27:59 -0400 Subject: Adds private outbox relays. --- 35.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to '35.md') diff --git a/35.md b/35.md index 4bec44b..45663dd 100644 --- a/35.md +++ b/35.md @@ -29,3 +29,22 @@ An additional `k` tag identifies the kind of the draft event. A blanked `.content` means this draft has been deleted by a client but relays still have the event. Tags `e` and `a` identify one or more anchor events, such as parent events on replies. + +## Relay List for Private Content + +Kind `10013` indicates the user's preferred relays to store private events like Drafts. The event MUST include a list of `relay` URLs in private tags. Private tags are JSON Stringified, NIP-44-encrypted to the signer's keys and placed inside the .content of the event. + +```js +{ + "kind": 10013, + "tags": [], + "content": nip44Encrypt(JSON.stringify([ + ["relay", "wss://myrelay.mydomain.com"] + ])) + //...other fields +} +``` + +Relays listed in this event SHOULD be authed and only allow downloads to events signed by the authed user. + +Clients SHOULD publish kind `10013` events to the author's [NIP-65](65.md) `write` relays. -- cgit v1.2.3