upleb.uk

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

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAsai Toshiya <to.asai.60@gmail.com>2024-01-16 23:28:23 +0900
committerfiatjaf_ <fiatjaf@gmail.com>2024-01-16 12:37:47 -0300
commitd8d75d9b19e6c66f7d75c771e784cd9dee4d2320 (patch)
treeebcd463908a3928d13c153191127c80fa84d93b1
parent20d33785fc2e2884f28bece04e4fab679b621ec8 (diff)
Fix some minor nitpicks in NIP-15 and NIP-51
-rw-r--r--15.md20
-rw-r--r--51.md14
2 files changed, 17 insertions, 17 deletions
diff --git a/15.md b/15.md
index e2ba639..55814fb 100644
--- a/15.md
+++ b/15.md
@@ -56,7 +56,7 @@ A merchant can publish these events:
56 "id": <string, id of the shipping zone, generated by the merchant>, 56 "id": <string, id of the shipping zone, generated by the merchant>,
57 "name": <string (optional), zone name>, 57 "name": <string (optional), zone name>,
58 "cost": <float, base cost for shipping. The currency is defined at the stall level>, 58 "cost": <float, base cost for shipping. The currency is defined at the stall level>,
59 "regions": [<string, regions included in this zone>], 59 "regions": [<string, regions included in this zone>]
60 } 60 }
61 ] 61 ]
62} 62}
@@ -101,7 +101,7 @@ Fields that are not self-explanatory:
101 "shipping": [ 101 "shipping": [
102 { 102 {
103 "id": <string, id of the shipping zone (must match one of the zones defined for the stall)>, 103 "id": <string, id of the shipping zone (must match one of the zones defined for the stall)>,
104 "cost": <float, extra cost for shipping. The currency is defined at the stall level>, 104 "cost": <float, extra cost for shipping. The currency is defined at the stall level>
105 } 105 }
106 ] 106 ]
107} 107}
@@ -139,7 +139,7 @@ Fields that are not self-explanatory:
139 139
140## Checkout events 140## Checkout events
141 141
142All checkout events are sent as JSON strings using ([NIP04](https://github.com/nostr-protocol/nips/blob/master/04.md)). 142All checkout events are sent as JSON strings using ([NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md)).
143 143
144The `merchant` and the `customer` can exchange JSON messages that represent different actions. Each `JSON` message `MUST` have a `type` field indicating the what the JSON represents. Possible types: 144The `merchant` and the `customer` can exchange JSON messages that represent different actions. Each `JSON` message `MUST` have a `type` field indicating the what the JSON represents. Possible types:
145 145
@@ -150,19 +150,19 @@ The `merchant` and the `customer` can exchange JSON messages that represent diff
150| 2 | Merchant | Order Status Update | 150| 2 | Merchant | Order Status Update |
151 151
152### Step 1: `customer` order (event) 152### Step 1: `customer` order (event)
153The below json goes in content of [NIP04](https://github.com/nostr-protocol/nips/blob/master/04.md). 153The below JSON goes in content of [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md).
154 154
155```json 155```json
156{ 156{
157 "id": <string, id generated by the customer>, 157 "id": <string, id generated by the customer>,
158 "type": 0, 158 "type": 0,
159 "name": <string (optional), ???>, 159 "name": <string (optional), ???>,
160 "address": <string (optional), for physical goods an address should be provided> 160 "address": <string (optional), for physical goods an address should be provided>,
161 "message": "<string (optional), message for merchant>, 161 "message": "<string (optional), message for merchant>,
162 "contact": { 162 "contact": {
163 "nostr": <32-bytes hex of a pubkey>, 163 "nostr": <32-bytes hex of a pubkey>,
164 "phone": <string (optional), if the customer wants to be contacted by phone>, 164 "phone": <string (optional), if the customer wants to be contacted by phone>,
165 "email": <string (optional), if the customer wants to be contacted by email>, 165 "email": <string (optional), if the customer wants to be contacted by email>
166 }, 166 },
167 "items": [ 167 "items": [
168 { 168 {
@@ -182,7 +182,7 @@ _Open_: is `contact.nostr` required?
182 182
183Sent back from the merchant for payment. Any payment option is valid that the merchant can check. 183Sent back from the merchant for payment. Any payment option is valid that the merchant can check.
184 184
185The below json goes in `content` of [NIP04](https://github.com/nostr-protocol/nips/blob/master/04.md). 185The below JSON goes in `content` of [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md).
186 186
187`payment_options`/`type` include: 187`payment_options`/`type` include:
188 188
@@ -217,7 +217,7 @@ The below json goes in `content` of [NIP04](https://github.com/nostr-protocol/ni
217 217
218Once payment has been received and processed. 218Once payment has been received and processed.
219 219
220The below json goes in `content` of [NIP04](https://github.com/nostr-protocol/nips/blob/master/04.md). 220The below JSON goes in `content` of [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md).
221 221
222```json 222```json
223{ 223{
@@ -275,7 +275,7 @@ This event leverages naddr to enable comprehensive customization and sharing of
275 "shipping": [ 275 "shipping": [
276 { 276 {
277 "id": <String, UUID of the shipping zone. Must match one of the zones defined for the stall>, 277 "id": <String, UUID of the shipping zone. Must match one of the zones defined for the stall>,
278 "cost": <float, extra cost for shipping. The currency is defined at the stall level>, 278 "cost": <float, extra cost for shipping. The currency is defined at the stall level>
279 } 279 }
280 ] 280 ]
281} 281}
@@ -310,7 +310,7 @@ Bids are simply events of kind `1021` with a `content` field specifying the amou
310{ 310{
311 "status": <String, "accepted" | "rejected" | "pending" | "winner">, 311 "status": <String, "accepted" | "rejected" | "pending" | "winner">,
312 "message": <String (optional)>, 312 "message": <String (optional)>,
313 "duration_extended": <int (optional), number of seconds>, 313 "duration_extended": <int (optional), number of seconds>
314} 314}
315``` 315```
316 316
diff --git a/51.md b/51.md
index 47ed899..9a1639f 100644
--- a/51.md
+++ b/51.md
@@ -18,18 +18,18 @@ When new items are added to an existing list, clients SHOULD append them to the
18 18
19Standard lists use non-parameterized replaceable events, meaning users may only have a single list of each kind. They have special meaning and clients may rely on them to augment a user's profile or browsing experience. 19Standard lists use non-parameterized replaceable events, meaning users may only have a single list of each kind. They have special meaning and clients may rely on them to augment a user's profile or browsing experience.
20 20
21For example, _mute lists_ can contain the public keys of spammers and bad actors users don't want to see in their feeds or receive annoying notifications from. 21For example, _mute list_ can contain the public keys of spammers and bad actors users don't want to see in their feeds or receive annoying notifications from.
22 22
23| name | kind | description | expected tag items | 23| name | kind | description | expected tag items |
24| --- | --- | --- | --- | 24| --- | --- | --- | --- |
25| Mute list | 10000 | things the user doesn't want to see in their feeds | `"p"` (pubkeys), `"t"` (hashtags), `"word"` (lowercase string), `"e"` (threads) | 25| Mute list | 10000 | things the user doesn't want to see in their feeds | `"p"` (pubkeys), `"t"` (hashtags), `"word"` (lowercase string), `"e"` (threads) |
26| Pinned notes | 10001 | events the user intends to showcase in their profile page | `"e"` (kind:1 notes) | 26| Pinned notes | 10001 | events the user intends to showcase in their profile page | `"e"` (kind:1 notes) |
27| Bookmarks | 10003 | uncategorized, "global" list of things a user wants to save | `"e"` (kind:1 notes), `"a"` (kind:30023 articles), `"t"` (hashtags), `"r" (URLs)` | 27| Bookmarks | 10003 | uncategorized, "global" list of things a user wants to save | `"e"` (kind:1 notes), `"a"` (kind:30023 articles), `"t"` (hashtags), `"r"` (URLs) |
28| Communities | 10004 | [NIP-72](72.md) communities the user belongs to | `"a"` (kind:34550 community definitions) | 28| Communities | 10004 | [NIP-72](72.md) communities the user belongs to | `"a"` (kind:34550 community definitions) |
29| Public chats | 10005 | [NIP-28](28.md) chat channels the user is in | `"e"` (kind:40 channel definitions) | 29| Public chats | 10005 | [NIP-28](28.md) chat channels the user is in | `"e"` (kind:40 channel definitions) |
30| Blocked relays | 10006 | relays clients should never connect to | `"relay"` (relay URLs) | 30| Blocked relays | 10006 | relays clients should never connect to | `"relay"` (relay URLs) |
31| Search relays | 10007 | relays clients should use when performing search queries | `"relay"` (relay URLs) | 31| Search relays | 10007 | relays clients should use when performing search queries | `"relay"` (relay URLs) |
32| Interests | 10015 | topics a user may be interested in and pointers | `"t"` (hashtags) and `"a" (kind:30015 interest set)` | 32| Interests | 10015 | topics a user may be interested in and pointers | `"t"` (hashtags) and `"a"` (kind:30015 interest set) |
33| Emojis | 10030 | user preferred emojis and pointers to emoji sets | `"emoji"` (see [NIP-30](30.md)) and `"a"` (kind:30030 emoji set) | 33| Emojis | 10030 | user preferred emojis and pointers to emoji sets | `"emoji"` (see [NIP-30](30.md)) and `"a"` (kind:30030 emoji set) |
34 34
35## Sets 35## Sets
@@ -44,9 +44,9 @@ Aside from their main identifier, the `"d"` tag, sets can optionally have a `"ti
44| --- | --- | --- | --- | 44| --- | --- | --- | --- |
45| Follow sets | 30000 | categorized groups of users a client may choose to check out in different circumstances | `"p"` (pubkeys) | 45| Follow sets | 30000 | categorized groups of users a client may choose to check out in different circumstances | `"p"` (pubkeys) |
46| Relay sets | 30002 | user-defined relay groups the user can easily pick and choose from during various operations | `"relay"` (relay URLs) | 46| Relay sets | 30002 | user-defined relay groups the user can easily pick and choose from during various operations | `"relay"` (relay URLs) |
47| Bookmark sets | 30003 | user-defined bookmarks categories , for when bookmarks must be in labeled separate groups | `"e"` (kind:1 notes), `"a"` (kind:30023 articles), `"t"` (hashtags), `"r" (URLs)` | 47| Bookmark sets | 30003 | user-defined bookmarks categories , for when bookmarks must be in labeled separate groups | `"e"` (kind:1 notes), `"a"` (kind:30023 articles), `"t"` (hashtags), `"r"` (URLs) |
48| Curation sets | 30004 | groups of articles picked by users as interesting and/or belonging to the same category | `"a"` (kind:30023 articles), `"e"` (kind:1 notes) | 48| Curation sets | 30004 | groups of articles picked by users as interesting and/or belonging to the same category | `"a"` (kind:30023 articles), `"e"` (kind:1 notes) |
49| Curation sets | 30005 | groups of videos picked by users as interesting and/or belonging to the same category | `"a"` (kind:34235 videos) | 49| Curation sets | 30005 | groups of videos picked by users as interesting and/or belonging to the same category | `"a"` (kind:34235 videos) |
50| Interest sets | 30015 | interest topics represented by a bunch of "hashtags" | `"t"` (hashtags) | 50| Interest sets | 30015 | interest topics represented by a bunch of "hashtags" | `"t"` (hashtags) |
51| Emoji sets | 30030 | categorized emoji groups | `"emoji"` (see [NIP-30](30.md)) | 51| Emoji sets | 30030 | categorized emoji groups | `"emoji"` (see [NIP-30](30.md)) |
52 52
@@ -82,7 +82,7 @@ Some clients have used these lists in the past, but they should work on transiti
82 82
83### A _curation set_ of articles and notes about yaks 83### A _curation set_ of articles and notes about yaks
84 84
85``` 85```json
86{ 86{
87 "id": "567b41fc9060c758c4216fe5f8d3df7c57daad7ae757fa4606f0c39d4dd220ef", 87 "id": "567b41fc9060c758c4216fe5f8d3df7c57daad7ae757fa4606f0c39d4dd220ef",
88 "pubkey": "d6dc95542e18b8b7aec2f14610f55c335abebec76f3db9e58c254661d0593a0c", 88 "pubkey": "d6dc95542e18b8b7aec2f14610f55c335abebec76f3db9e58c254661d0593a0c",