Documentation
¶
Index ¶
Constants ¶
View Source
const ErrNotEnoughBalance = "16: bad-txns-vout-negative. Code:-26"
type errorBroadcast string
View Source
const ErrNotEnoughFee = "66: insufficient priority. Code:-26"
View Source
const ErrTransactionTooSmall = "64: dust. Code:-26"
View Source
const ErrTxDecodeFailed = "Something seems wrong: TX decode failed. Code:-2"
Variables ¶
This section is empty.
Functions ¶
func BroadcastTransaction ¶
func BroadcastTransaction(asset bcoins.Coin, tx bcoins.Transaction) (insightjson.Txid, bcoins.Transaction, error)
broadcast a signed transaction to the blockexplorer. the transaction will either be denied or rejected by the network
Types ¶
type UTXO ¶
type UTXO struct { Hash *chainhash.Hash TxIndex uint32 Amount int64 Spendable bool PKScript []byte }
func GetMinimalRequiredUTXO ¶
take in requiredAmount in satoshi. This is how much we want to spend however we don't want to use all utxo's we have on our address only the minimal utxo's combined is what we want so the transaction becomes smaller in bytes the smaller the transaction, the less fees is required
Click to show internal directories.
Click to hide internal directories.