Skip to content

Commit ab52b99

Browse files
committed
Fix inconsistencies
1 parent 59562db commit ab52b99

5 files changed

Lines changed: 65 additions & 71 deletions

File tree

src/cancel.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,9 @@ Mostro updates the parameterized replaceable event with `d` tag `<Order Id>` to
152152
["fa", "100"],
153153
["pm", "face to face"],
154154
["premium", "1"],
155+
["network", "mainnet"],
156+
["layer", "lightning"],
157+
["expiration", "1719391096"],
155158
["y", "mostro"],
156159
["z", "order"]
157160
],

src/key_management.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ Clients must offer a more private version where the client never send the identi
147147
"payload": null
148148
}
149149
},
150-
null
150+
null // Signature is not needed in full privacy mode
151151
],
152152
"created_at": 1691518405,
153153
"tags": []

src/new_buy_order.md

Lines changed: 40 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,27 @@
11
# Creating a new buy order
22

3-
To create a new buy order the user should send a Gift wrap Nostr event to Mostro with the following rumor's content:
3+
To create a new buy order the user should send a Gift wrap Nostr event to Mostro with the following message:
44

55
```json
6-
[
7-
{
8-
"order": {
9-
"version": 1,
10-
"action": "new-order",
11-
"trade_index": 1,
12-
"payload": {
13-
"order": {
14-
"kind": "buy",
15-
"status": "pending",
16-
"amount": 0,
17-
"fiat_code": "VES",
18-
"fiat_amount": 100,
19-
"payment_method": "face to face",
20-
"premium": 1,
21-
"created_at": 0
22-
}
6+
{
7+
"order": {
8+
"version": 1,
9+
"action": "new-order",
10+
"trade_index": 1,
11+
"payload": {
12+
"order": {
13+
"kind": "buy",
14+
"status": "pending",
15+
"amount": 0,
16+
"fiat_code": "VES",
17+
"fiat_amount": 100,
18+
"payment_method": "face to face",
19+
"premium": 1,
20+
"created_at": 0
2321
}
2422
}
25-
},
26-
"<index N signature of the sha256 hash of the serialized first element of content>"
27-
]
23+
}
24+
}
2825
```
2926

3027
The nostr event will look like this:
@@ -43,35 +40,32 @@ The nostr event will look like this:
4340

4441
## Confirmation message
4542

46-
Mostro will send back a nip59 event as a confirmation message, the content of the rumor looks like the following:
43+
Mostro will send back a nip59 event as a confirmation message, the message in the rumor looks like the following:
4744

4845
```json
49-
[
50-
{
51-
"order": {
52-
"version": 1,
53-
"id": "<Order id>",
54-
"action": "new-order",
55-
"payload": {
56-
"order": {
57-
"id": "<Order id>",
58-
"kind": "buy",
59-
"status": "pending",
60-
"amount": 0,
61-
"fiat_code": "VES",
62-
"fiat_amount": 100,
63-
"payment_method": "face to face",
64-
"premium": 1,
65-
"master_buyer_pubkey": null,
66-
"master_seller_pubkey": null,
67-
"buyer_invoice": null,
68-
"created_at": 1698870173
69-
}
46+
{
47+
"order": {
48+
"version": 1,
49+
"id": "<Order id>",
50+
"action": "new-order",
51+
"payload": {
52+
"order": {
53+
"id": "<Order id>",
54+
"kind": "buy",
55+
"status": "pending",
56+
"amount": 0,
57+
"fiat_code": "VES",
58+
"fiat_amount": 100,
59+
"payment_method": "face to face",
60+
"premium": 1,
61+
"buyer_trade_pubkey": null,
62+
"seller_trade_pubkey": null,
63+
"buyer_invoice": null,
64+
"created_at": 1698870173
7065
}
7166
}
72-
},
73-
null
74-
]
67+
}
68+
}
7569
```
7670

7771
Mostro publishes this order as an event kind `38383` with status `pending`:

src/new_sell_order.md

Lines changed: 20 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,29 @@
11
# Creating a new sell order
22

3-
To create a new sell order the user should send a Gift wrap Nostr event to Mostro, the rumor event should have the following rumor's content:
3+
To create a new sell order the user should send a Gift wrap Nostr event to Mostro, the message should look like this:
44

55
```json
6-
[
7-
{
8-
"order": {
9-
"version": 1,
10-
"action": "new-order",
11-
"trade_index": 1,
12-
"payload": {
13-
"order": {
14-
"kind": "sell",
15-
"status": "pending",
16-
"amount": 0,
17-
"fiat_code": "VES",
18-
"min_amount": null,
19-
"max_amount": null,
20-
"fiat_amount": 100,
21-
"payment_method": "face to face,bank transfer,mobile",
22-
"premium": 1,
23-
"created_at": 0
24-
}
6+
{
7+
"order": {
8+
"version": 1,
9+
"action": "new-order",
10+
"trade_index": 1,
11+
"payload": {
12+
"order": {
13+
"kind": "sell",
14+
"status": "pending",
15+
"amount": 0,
16+
"fiat_code": "VES",
17+
"min_amount": null,
18+
"max_amount": null,
19+
"fiat_amount": 100,
20+
"payment_method": "face to face,bank transfer,mobile",
21+
"premium": 1,
22+
"created_at": 0
2523
}
2624
}
27-
},
28-
null
29-
]
25+
}
26+
}
3027
```
3128

3229
Let's explain some of the fields:

src/take_buy.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ Mostro updates the addressable event with `d` tag `<Order Id>` to change the sta
7474
"kind": 38383,
7575
"tags": [
7676
["d", "<Order Id>"],
77-
["k", "sell"],
77+
["k", "buy"],
7878
["f", "VES"],
7979
["s", "in-progress"],
8080
["amt", "7851"],

0 commit comments

Comments
 (0)