@vafanassieff/bitcoin-cli-ts
Version:
Auto-generated Bitcoin client library for bitcoind JSON-RPC API
23 lines (19 loc) • 694 B
text/typescript
// Auto synced from github actions. Don't change this file
import { Bitcoind } from '../../types.js'
import request from '../../rpc-request.js'
type SetTxFeeParams = {
bitcoind: Bitcoind
/* The transaction fee rate in BTC/kvB */
amount: number | string
}
/**
* settxfee amount
*
* Set the transaction fee rate in BTC/kvB for this wallet. Overrides the global -paytxfee command line parameter.
* Can be deactivated by passing 0 as the fee. In that case automatic fee selection will be used by default.
*
*/
export function setTxFee(params: SetTxFeeParams) {
const { bitcoind, ...methodParams } = params
return request({ method: 'settxfee', params: methodParams }, bitcoind)
}