According to the docs (http://godoc.org/github.com/btcsuite/btcrpcclient) the fee can be set by using
SetTxFee(fee btcutil.Amount) // hard coded0.0006 BTC
I set the fee to 0.0000016 bitcoin/kilobyte and do as follow:
But when i try to send transaction i get
-26: 256: absurdly-high-fee
Is there any other way to set the fee using this library?
Debug.log
ThreadRPCServer method=listunspent
ThreadRPCServer method=settxfee
ThreadRPCServer method=createrawtransaction
ThreadRPCServer method=signrawtransaction
ThreadRPCServer method=sendrawtransaction
Amounts:
amounts := map[btcutil.Address]btcutil.Amount{
destAddress: destAmount,
}
UPDATE It seems like it tries to send whole sum of the transaction, not the amount i want it to send.
If transaction in to A is 1 BTC and i want to send 0.3 BTC to another address, how to achieve this when setting amounts?
On the main page of your wallet, select your unconfirmed transaction. 2. Tap Increase fee. If your wallet balance is close to zero, you may not have enough funds in your wallet to pay for the additional transaction fees.
Two of the main factors that determine Bitcoin transaction fees are the data volume of the transaction and the speed at which the user wants their transaction completed. As of Aug. 23, 2022, the average Bitcoin transaction fee is 0.000044 BTC, or $0.957.
This fee is paid to cryptocurrency miners, which are the systems that process the transactions and secure the respective network. Coinbase incurs and pays these fees directly. Accordingly, Coinbase will charge a fee based on our estimate of the network transaction fees for a stand-alone wallet-to-wallet send.
settxfee
is not for createrawtransaction
command.
if you have one input with 1 BTC and you would send 0.9 BTC so remaining amount is the transaction fee.
if you don't want to set transaction fee for 0.1 BTC you could send 0.09 to change address and leave that 0.01 and it's your transaction fee.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With