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-11-15 21:11:37 -0300
committerfiatjaf <fiatjaf@gmail.com>2023-11-15 21:12:08 -0300
commit2e1c4b0c69d84cd08f72d3a284546d7b6f9e5679 (patch)
tree7925741caa2589fc7097f590624be1bbb55189f7
parentf1433e0f0cb28d17102b530081b48d47e0ee38ac (diff)
NIP-19: add `nreq`.
-rw-r--r--19.md21
1 files changed, 18 insertions, 3 deletions
diff --git a/19.md b/19.md
index cd989e2..497f67a 100644
--- a/19.md
+++ b/19.md
@@ -4,7 +4,7 @@ NIP-19
4bech32-encoded entities 4bech32-encoded entities
5----------------------- 5-----------------------
6 6
7`draft` `optional` `author:jb55` `author:fiatjaf` `author:Semisol` 7`draft` `optional` `author:jb55` `author:fiatjaf` `author:Semisol` `author:kieran`
8 8
9This NIP standardizes bech32-formatted strings that can be used to display keys, ids and other information in clients. These formats are not meant to be used anywhere in the core protocol, they are only meant for displaying to users, copy-pasting, sharing, rendering QR codes and inputting data. 9This NIP standardizes bech32-formatted strings that can be used to display keys, ids and other information in clients. These formats are not meant to be used anywhere in the core protocol, they are only meant for displaying to users, copy-pasting, sharing, rendering QR codes and inputting data.
10 10
@@ -33,9 +33,10 @@ For these events, the contents are a binary-encoded list of `TLV` (type-length-v
33These are the possible bech32 prefixes with `TLV`: 33These are the possible bech32 prefixes with `TLV`:
34 34
35 - `nprofile`: a nostr profile 35 - `nprofile`: a nostr profile
36 - `nevent`: a nostr event 36 - `nevent`: a nostr event pointer
37 - `nrelay`: a nostr relay 37 - `nrelay`: a nostr relay
38 - `naddr`: a nostr _replaceable event_ coordinate 38 - `naddr`: a nostr _replaceable event_ coordinate
39 - `nreq`: a nostr filter
39 40
40These possible standardized `TLV` types are indicated here: 41These possible standardized `TLV` types are indicated here:
41 42
@@ -46,14 +47,28 @@ These possible standardized `TLV` types are indicated here:
46 - for `nrelay`, this is the relay URL 47 - for `nrelay`, this is the relay URL
47 - for `naddr`, it is the identifier (the `"d"` tag) of the event being referenced. For non-parameterized replaceable events, use an empty string. 48 - for `naddr`, it is the identifier (the `"d"` tag) of the event being referenced. For non-parameterized replaceable events, use an empty string.
48- `1`: `relay` 49- `1`: `relay`
49 - for `nprofile`, `nevent` and `naddr`, _optionally_, a relay in which the entity (profile or event) is more likely to be found, encoded as ascii 50 - for `nprofile`, `nevent`, `naddr`, `nreq`, _optionally_, a relay in which the entity (profile or event) is more likely to be found, encoded as ascii
50 - this may be included multiple times 51 - this may be included multiple times
51- `2`: `author` 52- `2`: `author`
52 - for `naddr`, the 32 bytes of the pubkey of the event 53 - for `naddr`, the 32 bytes of the pubkey of the event
53 - for `nevent`, _optionally_, the 32 bytes of the pubkey of the event 54 - for `nevent`, _optionally_, the 32 bytes of the pubkey of the event
55 - for `nreq`, _optionally_, 32 bytes of one entry in the `"authors"` field, can be specified multiple times
54- `3`: `kind` 56- `3`: `kind`
55 - for `naddr`, the 32-bit unsigned integer of the kind, big-endian 57 - for `naddr`, the 32-bit unsigned integer of the kind, big-endian
56 - for `nevent`, _optionally_, the 32-bit unsigned integer of the kind, big-endian 58 - for `nevent`, _optionally_, the 32-bit unsigned integer of the kind, big-endian
59 - for `nreq`, _optionally_, 32-bit unsigned integer representing one entry in the `"kinds"` field, can be specified multiple times
60- `4`: `id`
61 - for `nreq`, _optionally_, 32 bytes of one entry in the `"authors"` field, can be specified multiple times
62- `5`: `tag`
63 - for `nreq`, _optionally_, the UTF-8 encoded single-letter of the tag to be searched (the `*` in a `"#*"` field) followed by one entry in this `#*` field, can be specified multiple times
64- `6`: `limit`
65 - for `nreq`, _optionally_, 32-bit unsigned integer representing the `"limit"` field
66- `7`: `since`
67 - for `nreq`, _optionally_, 32-bit unsigned integer representing the `"since"` field
68- `8`: `until`
69 - for `nreq`, _optionally_, 32-bit unsigned integer representing the `"until"` field
70- `9`: `search`
71 - for `nreq`, _optionally_, the UTF-8 encoded string of the `"search"` field
57 72
58## Examples 73## Examples
59 74