add protocol_version
This commit is contained in:
parent
46f7bed948
commit
f63236fe74
4 changed files with 12 additions and 34 deletions
21
src/api.ml
21
src/api.ml
|
|
@ -1,35 +1,24 @@
|
|||
(* TODO
|
||||
|
||||
ppx?
|
||||
|
||||
normalized JSON-object
|
||||
for signature of ExchangeKeysResponse.exetensions field
|
||||
why is this one not defined by a struct?
|
||||
|
||||
how to handle protocol versions:
|
||||
- "@deprecated" fields
|
||||
- "@since protocol xx"
|
||||
|
||||
use of _monotonic_ time
|
||||
|
||||
option: correct use opt_mem or Jsont.option
|
||||
|
||||
better types:
|
||||
- payto_uri
|
||||
- uri
|
||||
- uri *)
|
||||
|
||||
let protocol_version = "31"
|
||||
|
||||
number:
|
||||
- number is "float", but we probably want int everywhere instead
|
||||
- numeric values capped at 2^53 -1 inclusive because json *)
|
||||
open Crypto
|
||||
open Signatures
|
||||
open Jsont.Object
|
||||
module DenominationHash = Hash.DenominationHash
|
||||
|
||||
let encode_exn jsont v = Jsont_bytesrw.encode_string jsont v |> Result.get_ok
|
||||
let encode jsont v = Jsont_bytesrw.encode_string jsont v
|
||||
let decode jsont v = Jsont_bytesrw.decode_string jsont v
|
||||
|
||||
open Jsont.Object
|
||||
|
||||
module Account_operation = struct
|
||||
type t =
|
||||
| Withdraw
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue