ch4ot1c / songshop-btc

Minimalist on-chain BTC payment handling
MIT License
1 stars 0 forks source link

Current implementation only supports regtest and wallet txs #1

Open ch4ot1c opened 5 years ago

ch4ot1c commented 5 years ago

gettransaction is limited, since it can only retrieve wallet txs. Even if getrawtransaction is used, prior receiving addresses ('from' addresses) need to be identified for UTXOs, and -txindex is required so pruning will not be possible.

The current code needs to be extended with an 'address index', preferably https://github.com/bitcoinjs/indexd. This will allow for per-address per-txo queries to be readily executed against the chain history.

This can be run via indexd-server, see: https://github.com/CounterpartyXCP/indexd-server#utxos-endpoint

Code will need to use the UTXOs endpoint instead of standard RPCs in order to function in a testnet environment.

ch4ot1c commented 5 years ago

Alternatively, https://github.com/chris-belcher/electrum-personal-server for address balances / utxos