2020-12-08 20:31:21 +03:00
|
|
|
:: chyg: whether account is (non-)change. 0 or 1
|
2020-12-10 11:22:23 +03:00
|
|
|
:: bytc: "btc-byts" with dat cast to @ux
|
2020-10-05 14:57:50 +03:00
|
|
|
|%
|
|
|
|
+$ network ?(%main %testnet)
|
2020-11-12 13:13:54 +03:00
|
|
|
+$ xpub @ta
|
2020-10-13 14:31:08 +03:00
|
|
|
+$ legacy-address $%([%legacy @uc])
|
|
|
|
+$ bech32-address $%([%bech32 cord])
|
|
|
|
+$ address ?(legacy-address bech32-address)
|
2020-12-10 11:22:23 +03:00
|
|
|
+$ fprint [%4 @ux]
|
|
|
|
+$ bipt $?(%44 %49 %84)
|
2020-12-08 19:16:16 +03:00
|
|
|
+$ chyg $?(%0 %1)
|
2020-12-08 20:31:21 +03:00
|
|
|
+$ idx @ud
|
2020-12-10 16:22:48 +03:00
|
|
|
+$ hdkey [=fprint pubkey=bytc =bipt =chyg =idx]
|
2020-10-30 14:45:38 +03:00
|
|
|
+$ sats @ud
|
2020-11-18 14:39:57 +03:00
|
|
|
+$ vbytes @ud
|
2020-12-10 11:22:23 +03:00
|
|
|
+$ bytc [wid=@ dat=@ux]
|
2020-10-20 11:28:19 +03:00
|
|
|
+$ hash256 [wid=%32 dat=@ux]
|
|
|
|
+$ hash160 [wid=%20 dat=@ux]
|
|
|
|
+$ hash ?(hash256 hash160)
|
2020-11-20 14:58:27 +03:00
|
|
|
+$ txid hash256
|
2020-12-10 11:22:23 +03:00
|
|
|
+$ rawtx bytc
|
2020-10-16 14:02:55 +03:00
|
|
|
+$ buffer (list @ux)
|
2020-12-10 16:22:48 +03:00
|
|
|
+$ utxo [pos=@ =txid height=@ value=sats recvd=(unit @da)]
|
2020-10-20 11:28:19 +03:00
|
|
|
++ address-info
|
|
|
|
$: =address
|
2020-10-20 12:05:37 +03:00
|
|
|
confirmed-value=sats
|
|
|
|
unconfirmed-value=sats
|
|
|
|
utxos=(set utxo)
|
2020-10-20 11:28:19 +03:00
|
|
|
==
|
2020-10-16 10:33:10 +03:00
|
|
|
++ tx
|
|
|
|
|%
|
2020-12-13 23:33:08 +03:00
|
|
|
+$ data
|
|
|
|
$: is=(list input)
|
|
|
|
os=(list output)
|
|
|
|
locktime=@ud
|
2020-12-14 13:35:42 +03:00
|
|
|
nversion=@ud
|
2020-12-14 17:40:31 +03:00
|
|
|
segwit=(unit @ud)
|
2020-12-13 23:33:08 +03:00
|
|
|
==
|
2020-12-06 20:53:02 +03:00
|
|
|
+$ val
|
|
|
|
$: =txid
|
|
|
|
pos=@ud
|
|
|
|
=address
|
|
|
|
value=sats
|
|
|
|
==
|
2020-12-21 12:50:33 +03:00
|
|
|
:: included: whether tx is in the mempool or blockchain
|
|
|
|
::
|
2020-12-07 23:31:09 +03:00
|
|
|
+$ info
|
2020-12-21 12:50:33 +03:00
|
|
|
$: included=?
|
|
|
|
=txid
|
2020-12-07 23:31:09 +03:00
|
|
|
confs=@ud
|
|
|
|
recvd=(unit @da)
|
|
|
|
inputs=(list val)
|
|
|
|
outputs=(list val)
|
|
|
|
==
|
2020-10-16 10:33:10 +03:00
|
|
|
+$ input
|
2020-11-20 14:58:27 +03:00
|
|
|
$: =txid
|
2020-12-13 23:33:08 +03:00
|
|
|
pos=@ud
|
2020-12-14 13:35:42 +03:00
|
|
|
sequence=bytc
|
|
|
|
redeem-script=(unit bytc)
|
|
|
|
pubkey=(unit bytc)
|
2020-10-16 12:28:51 +03:00
|
|
|
value=sats
|
2020-10-16 10:33:10 +03:00
|
|
|
==
|
2020-12-13 23:33:08 +03:00
|
|
|
+$ output
|
2020-12-14 15:13:24 +03:00
|
|
|
$: script-pubkey=bytc
|
2020-12-13 23:33:08 +03:00
|
|
|
value=sats
|
|
|
|
==
|
2020-10-16 10:33:10 +03:00
|
|
|
--
|
2020-12-08 15:42:39 +03:00
|
|
|
++ psbt
|
|
|
|
|%
|
2020-12-10 18:54:39 +03:00
|
|
|
+$ base64 cord
|
2020-12-10 16:22:48 +03:00
|
|
|
+$ in [=utxo =rawtx =hdkey]
|
2020-12-08 20:51:14 +03:00
|
|
|
+$ out [=address hk=(unit hdkey)]
|
2020-12-08 19:16:16 +03:00
|
|
|
+$ target $?(%input %output)
|
2020-12-10 11:22:23 +03:00
|
|
|
+$ keyval [key=bytc val=bytc]
|
2020-12-08 17:48:40 +03:00
|
|
|
+$ map (list keyval)
|
2020-12-08 15:42:39 +03:00
|
|
|
--
|
2020-10-15 13:55:41 +03:00
|
|
|
++ ops
|
|
|
|
|%
|
2020-10-16 10:33:10 +03:00
|
|
|
++ op-dup 118
|
2020-10-15 13:55:41 +03:00
|
|
|
++ op-equalverify 136
|
|
|
|
++ op-hash160 169
|
|
|
|
++ op-checksig 172
|
|
|
|
--
|
2020-10-05 14:57:50 +03:00
|
|
|
--
|