mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-12 15:01:38 +03:00
add marks
This commit is contained in:
parent
0a51cd34d2
commit
f5960c656c
@ -99,6 +99,18 @@ Above tests w 2 outputs, total fees with 2 inputs of 27.500. Gives:
|
|||||||
1. 500.000 input
|
1. 500.000 input
|
||||||
2. Inputs 0 and 3
|
2. Inputs 0 and 3
|
||||||
|
|
||||||
|
## Make a full TXBU
|
||||||
|
Provider is `~zod`, `~dopzod` is a client.
|
||||||
|
On `~zod`:
|
||||||
|
```
|
||||||
|
:btc-provider|command [%set-credentials api-url='http://localhost:50002']
|
||||||
|
:btc-provider|command [%whitelist-clients `(set ship)`(sy ~[~dopzod])]
|
||||||
|
```
|
||||||
|
|
||||||
|
on `~dopzod`:
|
||||||
|
```
|
||||||
|
:btc-wallet-hook|action [%set-provider ~zod]
|
||||||
|
```
|
||||||
|
|
||||||
## scrys
|
## scrys
|
||||||
```
|
```
|
||||||
@ -107,22 +119,3 @@ Above tests w 2 outputs, total fees with 2 inputs of 27.500. Gives:
|
|||||||
.^(@ud %gx /=btc-wallet-store=/balance/[xpub]/noun)
|
.^(@ud %gx /=btc-wallet-store=/balance/[xpub]/noun)
|
||||||
```
|
```
|
||||||
|
|
||||||
## Algos
|
|
||||||
|
|
||||||
### Monitor addresses
|
|
||||||
- nixt also stores next 50 addresses for each account.
|
|
||||||
- every update-address call also checks those
|
|
||||||
|
|
||||||
### make a payment
|
|
||||||
* make payment
|
|
||||||
- get address
|
|
||||||
- on-agent gets return value, construct tx
|
|
||||||
- store tx (view or other command can get it)
|
|
||||||
|
|
||||||
::
|
|
||||||
++ send-address-update
|
|
||||||
|= [xpub=tape =walt a=address:btc us=(set utxo)]
|
|
||||||
^- (quip card _state)
|
|
||||||
:_ state(walts (~(put by walts.state) xpub walt))
|
|
||||||
~[[%give %fact ~[/wallets] %btc-wallet-store-update !>([%address a us])]]
|
|
||||||
::
|
|
||||||
|
@ -114,7 +114,7 @@
|
|||||||
==
|
==
|
||||||
[cards this]
|
[cards this]
|
||||||
==
|
==
|
||||||
++ on-arvo on-arvo:def
|
++ on-arvo on-arvo:def
|
||||||
++ on-fail on-fail:def
|
++ on-fail on-fail:def
|
||||||
--
|
--
|
||||||
|_ =bowl:gall
|
|_ =bowl:gall
|
||||||
|
@ -19,7 +19,7 @@ while getopts "w" opt; do
|
|||||||
done
|
done
|
||||||
|
|
||||||
if [ -z "$WATCH_MODE" ]; then
|
if [ -z "$WATCH_MODE" ]; then
|
||||||
echo "Installed %bippy"
|
echo "Installed btc-agents"
|
||||||
rsync -r --exclude-from=$EXCLUDE_FILE * $PIER/
|
rsync -r --exclude-from=$EXCLUDE_FILE * $PIER/
|
||||||
else
|
else
|
||||||
echo "Watching for changes to copy to ${PIER}..."
|
echo "Watching for changes to copy to ${PIER}..."
|
||||||
|
@ -12,7 +12,19 @@
|
|||||||
++ txbu
|
++ txbu
|
||||||
|= =^txbu
|
|= =^txbu
|
||||||
^- json
|
^- json
|
||||||
[%s 'txbu placeholder']
|
%- pairs
|
||||||
|
:~ [%inputs ~]
|
||||||
|
['associatedKeysets' s+'hi']
|
||||||
|
['changePath' s+'hi']
|
||||||
|
['outputScriptHex' s+'hi']
|
||||||
|
['lockTime' s+'hi']
|
||||||
|
['sigHashType' s+'hi']
|
||||||
|
[%segwit s+'hi']
|
||||||
|
['initialTimestamp' s+'hi']
|
||||||
|
==
|
||||||
|
:: TODO inputs, keysets, changeppath, outputscripthex, locktime, sigHashType, segwit, initialTimestamp
|
||||||
|
:: , additionals ("bech32")
|
||||||
|
:: TODO: use 'pairs' at the top level
|
||||||
--
|
--
|
||||||
::
|
::
|
||||||
++ defaults
|
++ defaults
|
||||||
|
12
mar/btc-provider/action.hoon
Normal file
12
mar/btc-provider/action.hoon
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/- *btc-provider
|
||||||
|
|_ act=action
|
||||||
|
++ grad %noun
|
||||||
|
++ grow
|
||||||
|
|%
|
||||||
|
++ noun act
|
||||||
|
--
|
||||||
|
++ grab
|
||||||
|
|%
|
||||||
|
++ noun action
|
||||||
|
--
|
||||||
|
--
|
12
mar/btc-provider/status.hoon
Normal file
12
mar/btc-provider/status.hoon
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/- *btc-provider
|
||||||
|
|_ sta=status
|
||||||
|
++ grad %noun
|
||||||
|
++ grow
|
||||||
|
|%
|
||||||
|
++ noun sta
|
||||||
|
--
|
||||||
|
++ grab
|
||||||
|
|%
|
||||||
|
++ noun status
|
||||||
|
--
|
||||||
|
--
|
12
mar/btc-provider/update.hoon
Normal file
12
mar/btc-provider/update.hoon
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/- *btc-provider
|
||||||
|
|_ upd=update
|
||||||
|
++ grad %noun
|
||||||
|
++ grow
|
||||||
|
|%
|
||||||
|
++ noun upd
|
||||||
|
--
|
||||||
|
++ grab
|
||||||
|
|%
|
||||||
|
++ noun update
|
||||||
|
--
|
||||||
|
--
|
12
mar/btc-wallet/hook-action.hoon
Normal file
12
mar/btc-wallet/hook-action.hoon
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
/- *btc-wallet-hook
|
||||||
|
|_ act=action
|
||||||
|
++ grad %noun
|
||||||
|
++ grow
|
||||||
|
|%
|
||||||
|
++ noun act
|
||||||
|
--
|
||||||
|
++ grab
|
||||||
|
|%
|
||||||
|
++ noun action
|
||||||
|
--
|
||||||
|
--
|
@ -44,6 +44,7 @@
|
|||||||
[%get-raw-tx =txid =rawtx]
|
[%get-raw-tx =txid =rawtx]
|
||||||
[%get-block-count blockcount=@ud]
|
[%get-block-count blockcount=@ud]
|
||||||
[%get-block-and-fee blockcount=@ud fee=sats]
|
[%get-block-and-fee blockcount=@ud fee=sats]
|
||||||
|
|
||||||
==
|
==
|
||||||
--
|
--
|
||||||
--
|
--
|
||||||
|
Loading…
Reference in New Issue
Block a user