Patch docs/spec.md
This commit is contained in:
1 parent
caaa61b0d8
commit
baea90f046
1 file changed
+9
-6
+9
-6
@@ -638,14 +638,17 @@ CSRF header. Errors are `{"error": "<nynorsk message>", "field": "<field name or
|
|||||||
empty means "use the method".
|
empty means "use the method".
|
||||||
|
|
||||||
The API takes sats as a whole number: `1500000` or `"1 500 000"`. A decimal number of BTC is
|
The API takes sats as a whole number: `1500000` or `"1 500 000"`. A decimal number of BTC is
|
||||||
rejected. A NOK amount may carry two decimals, as the storage is øre.
|
rejected. A kroner amount may carry two decimals, as the storage is øre. A fee is sent as
|
||||||
|
`fee_sats` only: `fee_ore` is never sent by a client and stays 0 in the database.
|
||||||
|
|
||||||
For `admin_cost`, `market_id` must be absent or null, `lot_picks` are rejected, and a fee is
|
For `admin_cost`, the amount is sent as `leg_out_ore`, `market_id` must be absent or null,
|
||||||
rejected; the account is not required and not looked up.
|
`lot_picks` are rejected, and a fee is rejected; the account is not required and not looked up.
|
||||||
|
|
||||||
Every transaction object carries `btc_price_ore`: the bitcoin price of §7.3 in øre per whole
|
Every transaction object carries `btc_price_ore`: the price of §7.3 in øre per whole BTC, or
|
||||||
BTC, or null when the type has no price. The lot objects carry the same field name for the same
|
null when the type has no price. For a `transfer_out` it is worked out from the consumed lots
|
||||||
unit, worked out from the lot's remaining cost and sats.
|
(`cost_ore` and `consumed_sats`), and for a `transfer_in` from its own mirrored lots
|
||||||
|
(`lot_cost_ore` and `lot_sats`), so the two sides agree. The lot objects carry `btc_price_ore`
|
||||||
|
for the same unit, worked out from the lot's remaining cost and sats.
|
||||||
|
|
||||||
The CSV export is a plain semicolon-separated file with a UTF-8 BOM so it opens correctly in a
|
The CSV export is a plain semicolon-separated file with a UTF-8 BOM so it opens correctly in a
|
||||||
Norwegian Excel: one block of report rows, then one block of the year's transactions with the
|
Norwegian Excel: one block of report rows, then one block of the year's transactions with the
|
||||||
|
|||||||
Reference in new issue
Block a user