upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfiatjaf_ <fiatjaf@gmail.com>2023-03-25 21:05:24 -0300
committerGitHub <noreply@github.com>2023-03-25 21:05:24 -0300
commit7823488ad17e32a15c7e837db05b6a60546bf058 (patch)
tree3dbbd15d055a1630260516f5c033250a26b010bd
parent23cec80e31f6b41df14f51533de6292d6cb8c9b0 (diff)
parent45b1860b52025182d6400fd804a5d376a183ee40 (diff)
Merge pull request #381 from arthurfranca/mention-alternative
-rw-r--r--08.md2
-rw-r--r--27.md20
-rw-r--r--README.md3
3 files changed, 24 insertions, 1 deletions
diff --git a/08.md b/08.md
index 113cb53..2ab2b8f 100644
--- a/08.md
+++ b/08.md
@@ -1,3 +1,5 @@
1> __Warning__ `unrecommended`: deprecated in favor of NIP-27
2
1NIP-08 3NIP-08
2====== 4======
3 5
diff --git a/27.md b/27.md
new file mode 100644
index 0000000..f4e4629
--- /dev/null
+++ b/27.md
@@ -0,0 +1,20 @@
1NIP-27
2======
3
4Text Note References
5--------------------
6
7`draft` `optional` `author:fiatjaf` `author:scsibug` `author:arthurfranca`
8
9This document standardizes the treatment given by clients of inline references of other events and profiles inside the content of `text notes` (currently kinds 1 and 30023).
10
11Once a mention is identified by a client, for example, when an user pastes a NIP-19 nostr profile string inside the event content input field (or optionally by any other means the client may wish to support, such as selecting an user from a context menu or autocompleter), the client MUST replace it with the notation `nostr:nprofile1qqsw3dy8cpu...6x2argwghx6egsqstvg` as per NIP-21 before effectively creating the event. The client MAY add the corresponding pubkey to the `.tags` with the tag `p` if it wishes to notify mentioned user.
12
13The same process applies for referencing event IDs (using `nostr:nevent1...`), except that the client SHOULD NOT add the event id to the `.tags` with the tag `e` so to not negatively impact thread loading.
14Because `e` tags on `text notes` are usually considered ancestor events used to build a conversarion thread (as per NIP-10), it is advised to use inline references when mentioning events and NOT adding corresponding `e` tag to the `.tags` event key.
15
16Other nostr identifiers should be referenced similarly using NIP-21 URLs inside event content (e.g. `nostr:naddr1...` for parameterized replaceable events).
17
18Note that the usage of `nostr:npub1...` for profile mentions or `nostr:note1...` for event mentions is discouraged due to their lack of embedded relay recommendation.
19
20A reader client that receives a `text_note` event with such `nostr:...` mentions in its `.content` CAN do any desired context augmentation (for example, linking to the profile or showing a preview of the mentioned event contents) it wants in the process. If turning such mentions into links, they could become internal links, NIP-21 links or direct links to web clients that will handle these references.
diff --git a/README.md b/README.md
index 37b2fe4..9390916 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ NIPs stand for **Nostr Implementation Possibilities**. They exist to document wh
9- [NIP-05: Mapping Nostr keys to DNS-based internet identifiers](05.md) 9- [NIP-05: Mapping Nostr keys to DNS-based internet identifiers](05.md)
10- [NIP-06: Basic key derivation from mnemonic seed phrase](06.md) 10- [NIP-06: Basic key derivation from mnemonic seed phrase](06.md)
11- [NIP-07: `window.nostr` capability for web browsers](07.md) 11- [NIP-07: `window.nostr` capability for web browsers](07.md)
12- [NIP-08: Handling Mentions](08.md) 12- [NIP-08: Handling Mentions](08.md) – `unrecommended`: deprecated in favor of [NIP-27](27.md)
13- [NIP-09: Event Deletion](09.md) 13- [NIP-09: Event Deletion](09.md)
14- [NIP-10: Conventions for clients' use of `e` and `p` tags in text events](10.md) 14- [NIP-10: Conventions for clients' use of `e` and `p` tags in text events](10.md)
15- [NIP-11: Relay Information Document](11.md) 15- [NIP-11: Relay Information Document](11.md)
@@ -25,6 +25,7 @@ NIPs stand for **Nostr Implementation Possibilities**. They exist to document wh
25- [NIP-23: Long-form Content](23.md) 25- [NIP-23: Long-form Content](23.md)
26- [NIP-25: Reactions](25.md) 26- [NIP-25: Reactions](25.md)
27- [NIP-26: Delegated Event Signing](26.md) 27- [NIP-26: Delegated Event Signing](26.md)
28- [NIP-27: Text Note References](27.md)
28- [NIP-28: Public Chat](28.md) 29- [NIP-28: Public Chat](28.md)
29- [NIP-33: Parameterized Replaceable Events](33.md) 30- [NIP-33: Parameterized Replaceable Events](33.md)
30- [NIP-36: Sensitive Content](36.md) 31- [NIP-36: Sensitive Content](36.md)