bitcoind.app
CommandsGuidesContact ↗
Home/Wallet/walletcreatefundedpsbt
Wallet

walletcreatefundedpsbt

Creates and funds a transaction in PSBT format. Inputs will be added if supplied inputs are not enough.

Parameters

inputsarrayoptional
Leave empty to have the wallet select. Array of {txid, vout, sequence} objects
outputsarrayREQUIRED
Array of {"address": amount} objects
locktimenumberoptional
Raw locktime. Default: 0
optionsobjectoptional
Options: add_inputs, include_watching, changeAddress, changePosition, fee_rate, etc.
bip32derivsbooleanoptional
Include BIP32 derivation paths. Default: true

Returns

objectObject with psbt, fee, and changepos

Code Examples

curl --user myuser --data-binary '{"jsonrpc":"1.0","id":"1","method":"walletcreatefundedpsbt","params":[[],[{"bc1q...":0.1}]]}' -H 'content-type:text/plain;' http://127.0.0.1:8332/

Example Response

{
  "psbt": "cHNidP8BAFUCAAAAAe...",
  "fee": 0.00001410,
  "changepos": 1
}
← Previous
simulaterawtransaction
Next →
walletdisplayaddress

More Wallet Commands

abandontransactioncreatewalletdumpprivkeygetbalancegetnewaddressgettransaction

bitcoind.app — Bitcoin Core RPC Reference

GuidesContact ↗