Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/bitcoin_rpc/mod.ts>default

A Bitcoin RPC Module for Deno.
Latest
class default
import { default } from "https://deno.land/x/bitcoin_rpc@v1.0.3/mod.ts";

Constructors

new
default(unnamed 0: Args)

initializes a new instance of the BitcoinRPC class.

Properties

auth: boolean
optional
pass: string
url: string
optional
user: string

Methods

abandontransaction(txid: string)

Mark in-wallet transaction as abandoned This will mark this transaction and all its in-wallet descendants as abandoned which will allow for their inputs to be respent. It can be used to replace “stuck” or evicted transactions. https://developer.bitcoin.org/reference/rpc/abandontransaction.html

Stops current wallet rescan triggered by an RPC call, e.g. by an importprivkey call. https://developer.bitcoin.org/reference/rpc/abortrescan.html

addmultisigaddress(
nrequired: number,
keys: Array<string>,
label?: string,
address_type?: string,
)

Add an nrequired-to-sign multisignature address to the wallet. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/addmultisigaddress.html

addnode(node: string, command: string)

Attempts to add or remove a node from the addnode list. https://developer.bitcoin.org/reference/rpc/addnode.html

analyzepsbt(psbt: string)

Analyzes and provides information about the current status of a PSBT and its inputs https://developer.bitcoin.org/reference/rpc/analyzepsbt.html

backupwallet(destination: string)

Safely copies current wallet file to destination, which can be a directory or a path with filename. https://developer.bitcoin.org/reference/rpc/backupwallet.html

bumpfee(txid: string, options?: { conf_target?: number; fee_rate?: number | string; replaceable?: boolean; estimate_mode?: string; })

Bumps the fee of an opt-in-RBF transaction T, replacing it with a new transaction B. https://developer.bitcoin.org/reference/rpc/bumpfee.html

combinepsbt(txs: Array<string>)

Combine multiple partially signed Bitcoin transactions into one transaction. https://developer.bitcoin.org/reference/rpc/combinepsbt.html

combinerawtransaction(txs: Array<string>)

Combine multiple partially signed transactions into one transaction. https://developer.bitcoin.org/reference/rpc/combinerawtransaction.html

converttopsbt(
hexstring: string,
permitsigdata?: boolean,
iswitness?: boolean,
)

Converts a network serialized transaction to a PSBT. This should be used only with createrawtransaction and fundrawtransaction createpsbt and walletcreatefundedpsbt should be used for new applications. https://developer.bitcoin.org/reference/rpc/converttopsbt.html

createmultisig(nrequired: number, keys: Array<string>)

Creates a multi-signature address with n signature of m keys required. https://developer.bitcoin.org/reference/rpc/createmultisig.html

createpsbt(
inputs: Array<{ txid: string; vout?: number; sequence?: number; }>,
outputs: Array<{ address: number; } | { address: string; } | { data: string; }>,
locktime?: number,
replaceable?: boolean,
)

Creates a transaction in the Partially Signed Transaction format. https://developer.bitcoin.org/reference/rpc/createpsbt.html

createrawtransaction(
inputs: Array<{ txid: string; vout: number; sequence?: number; }>,
output: Array<{ [address: string]: number; } | { [address: string]: string; } | { data: string; }>,
locktime?: number,
replaceable?: boolean,
)

Create a transaction spending the given inputs and creating new outputs. https://developer.bitcoin.org/reference/rpc/createrawtransaction.html

createwallet(
wallet_name: string,
disable_private_keys?: boolean,
blank?: boolean,
passphrase?: string,
avoid_reuse?: boolean,
descriptors?: boolean,
load_on_startup?: boolean,
)
decodepsbt(psbt: string)

Return a JSON object representing the serialized, base64-encoded partially signed Bitcoin transaction. https://developer.bitcoin.org/reference/rpc/decodepsbt.html

decoderawtransaction(hexstring: string, iswitness?: boolean)

Return a JSON object representing the serialized, hex-encoded transaction. https://developer.bitcoin.org/reference/rpc/decoderawtransaction.html

decodescript(hexstring: string)
deriveaddresses(descriptor: string, range?: number | Array<number>)

Derives one or more addresses corresponding to an output descriptor. https://developer.bitcoin.org/reference/rpc/deriveaddresses.html

disconnectnode(address: string, nodeid?: number)

Immediately disconnects from the specified peer node. https://developer.bitcoin.org/reference/rpc/disconnectnode.html

dumpprivkey(address: string)

Reveals the private key corresponding to ‘address’. https://developer.bitcoin.org/reference/rpc/dumpprivkey.html

dumpwallet(filename: string)

Dumps all wallet keys in a human-readable format to a server-side file. This does not allow overwriting existing files. https://developer.bitcoin.org/reference/rpc/dumpwallet.html

encryptwallet(passphrase: string)

Encrypts the wallet with ‘passphrase’. This is for first time encryption. https://developer.bitcoin.org/reference/rpc/encryptwallet.html

estimatesmartfee(conf_target: number, estimate_mode?: string)

Estimates the approximate fee per kilobyte needed for a transaction to begin confirmation within conf_target blocks if possible and return the number of blocks for which the estimate is valid. Uses virtual transaction size as defined in BIP 141 (witness data is discounted). https://developer.bitcoin.org/reference/rpc/estimatesmartfee.html

finalizepsbt(psbt: string, extract?: boolean)

Finalize the inputs of a PSBT. If the transaction is fully signed, it will produce a network serialized transaction which can be broadcast with sendrawtransaction. Otherwise a PSBT will be created which has the final_scriptSig and final_scriptWitness fields filled for inputs that are complete. https://developer.bitcoin.org/reference/rpc/finalizepsbt.html

fundrawtransaction(
hexstring: string,
options?: { add_inputs?: boolean; changeAddress?: string; changePosition?: number; change_type?: string; includeWatching?: boolean; lockUnspents?: boolean; fee_rate?: number | string; feeRate?: number | string; subtractFeeFromOutputs?: Array<number>; },
iswitness?: boolean,
)

If the transaction has no inputs, they will be automatically selected to meet its out value. https://developer.bitcoin.org/reference/rpc/fundrawtransaction.html

generateblock(output: string, transactions: Array<string>)

Mine a block with a set of ordered transactions immediately to a specified address or descriptor (before the RPC call returns) https://developer.bitcoin.org/reference/rpc/generateblock.html

generatetoaddress(
nblocks: number,
address: string,
maxtries?: number,
)

Mine blocks immediately to a specified address (before the RPC call returns) https://developer.bitcoin.org/reference/rpc/generatetoaddress.html

generatetodescriptor(
num_blocks: number,
descriptor: string,
maxtries?: number,
)

Mine blocks immediately to a specified descriptor (before the RPC call returns) https://developer.bitcoin.org/reference/rpc/generatetodescriptor.html

getaddednodeinfo(node?: string)

Returns information about the given added node, or all added nodes (note that onetry addnodes are not listed here) https://developer.bitcoin.org/reference/rpc/getaddednodeinfo.html

getaddressinfo(address: string)

Return information about the given bitcoin address. https://developer.bitcoin.org/reference/rpc/getaddressinfo.html

getbalance(
dummy: string,
minconf?: number,
include_watchonly?: boolean,
avoid_reuse?: boolean,
)

Returns the hash of the best (tip) block in the most-work fully-validated chain. https://developer.bitcoin.org/reference/rpc/getbestblockhash.html

getblock(blockhash: string, verbosity?: number)

If verbosity is 0, returns a string that is serialized, hex-encoded data for block ‘hash’. https://developer.bitcoin.org/reference/rpc/getblock.html

Returns an object containing various state info regarding blockchain processing. https://developer.bitcoin.org/reference/rpc/getblockchaininfo.html

Returns the height of the most-work fully-validated chain. https://developer.bitcoin.org/reference/rpc/getblockcount.html

getblockfilter(blockhash: string, filtertype: string)

Retrieve a BIP 157 content filter for a particular block. https://developer.bitcoin.org/reference/rpc/getblockfilter.html

getblockhash(height: number)

Returns hash of block in best-block-chain at height provided. https://developer.bitcoin.org/reference/rpc/getblockhash.html

getblockheader(blockhash: string, verbose?: boolean)

If verbose is false, returns a string that is serialized, hex-encoded data for blockheader ‘hash’. https://developer.bitcoin.org/reference/rpc/getblockheader.html

getblockstats(hash_or_height: number | string, stats?: Array<string>)

Compute per block statistics for a given window. All amounts are in satoshis. https://developer.bitcoin.org/reference/rpc/getblockstats.html

getblocktemplate(template_request: { mode?: string; capabilities?: Array<string>; })

If the request parameters include a ‘mode’ key, that is used to explicitly select between the default ‘template’ request or a ‘proposal’. https://developer.bitcoin.org/reference/rpc/getblocktemplate.html

Return information about all known tips in the block tree, including the main chain as well as orphaned branches. https://developer.bitcoin.org/reference/rpc/getchaintips.html

getchaintxstats(nblocks: number, blockhash?: string)

Compute statistics about the total number and rate of transactions in the chain. https://developer.bitcoin.org/reference/rpc/getchaintxstats.html

Returns the proof-of-work difficulty as a multiple of the minimum difficulty. https://developer.bitcoin.org/reference/rpc/getdifficulty.html

getindexinfo(index_name: number)

Returns the status of one or all available indices currently running in the node. https://developer.bitcoin.org/reference/rpc/getindexinfo.html

getmemoryinfo(mode?: string)

Returns an object containing information about memory usage. https://developer.bitcoin.org/reference/rpc/getmemoryinfo.html

getmempoolancestors(txid: string, verbose?: boolean)

If txid is in the mempool, returns all in-mempool ancestors. https://developer.bitcoin.org/reference/rpc/getmempoolancestors.html

getmempooldescendants(txid: string, verbose?: boolean)

If txid is in the mempool, returns all in-mempool descendants. https://developer.bitcoin.org/reference/rpc/getmempooldescendants.html

getmempoolentry(txid: string)

Returns mempool data for given transaction https://developer.bitcoin.org/reference/rpc/getmempoolentry.html

Returns details on the active state of the TX memory pool. https://developer.bitcoin.org/reference/rpc/getmempoolinfo.html

Returns a json object containing mining-related information. https://developer.bitcoin.org/reference/rpc/getmininginfo.html

Returns information about network traffic, including bytes in, bytes out, and current time. https://developer.bitcoin.org/reference/rpc/getnettotals.html

getnetworkhashps(nblocks?: number, height?: number)

Returns the estimated network hashes per second based on the last n blocks. https://developer.bitcoin.org/reference/rpc/getnetworkhashps.html

Returns an object containing various state info regarding P2P networking. https://developer.bitcoin.org/reference/rpc/getnetworkinfo.html

getnewaddress(label?: string, address_type?: string)

Returns a new Bitcoin address for receiving payments. https://developer.bitcoin.org/reference/rpc/getnewaddress.html

getnodeaddresses(count?: number)

Return known addresses which can potentially be used to find new nodes in the network https://developer.bitcoin.org/reference/rpc/getnodeaddresses.html

Returns data about each connected network node as a json array of objects. https://developer.bitcoin.org/reference/rpc/getpeerinfo.html

getrawchangeaddress(address_type?: string)

Returns a new Bitcoin address, for receiving change. https://developer.bitcoin.org/reference/rpc/getrawchangeaddress.html

getrawmempool(verbose?: boolean, mempool_sequence?: boolean)

Returns all transaction ids in memory pool as a json array of string transaction ids. https://developer.bitcoin.org/reference/rpc/getrawmempool.html

getrawtransaction(
txid: string,
verbose?: boolean,
blockhash?: string,
)
getreceivedbyaddress(address: string, minconf?: number)

Returns the total amount received by the given address in transactions with at least minconf confirmations. https://developer.bitcoin.org/reference/rpc/getreceivedbyaddress.html

getreceivedbylabel(label: string, minconf?: number)

Returns the total amount received by addresses with in transactions with at least [minconf] confirmations. https://developer.bitcoin.org/reference/rpc/getreceivedbylabel.html

gettransaction(
txid: string,
include_watchonly?: boolean,
verbose?: boolean,
)

Get detailed information about in-wallet transaction https://developer.bitcoin.org/reference/rpc/gettransaction.html

gettxout(
txid: string,
n: number,
includemempool?: boolean,
)

Returns details about an unspent transaction output. https://developer.bitcoin.org/reference/rpc/gettxout.html

gettxoutproof(txids: Array<string>, blockhash?: string)

Returns a hex-encoded proof that “txid” was included in a block. https://developer.bitcoin.org/reference/rpc/gettxoutproof.html

gettxoutsetinfo(hash_type?: string)

Returns statistics about the unspent transaction output set. https://developer.bitcoin.org/reference/rpc/gettxoutsetinfo.html

DEPRECATED Identical to getbalances().mine.untrusted_pending https://developer.bitcoin.org/reference/rpc/getunconfirmedbalance.html

Returns an object containing various wallet state info. https://developer.bitcoin.org/reference/rpc/getwalletinfo.html

help(command?: string)

List all commands, or get help for a specified command. https://developer.bitcoin.org/reference/rpc/help.html

importaddress(
address: string,
label?: string,
rescan?: boolean,
p2sh?: string,
)

Adds an address or script (in hex) that can be watched as if it were in your wallet but cannot be used to spend. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/importaddress.html

importdescriptors(requests: Array<{ desc: string; active?: boolean; range: number | Array<number>; next_index: number; timestamp: number | string; internal?: boolean; label?: string; }>)

Import descriptors. This will trigger a rescan of the blockchain based on the earliest timestamp of all descriptors being imported. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/importdescriptors.html

importmulti(requests: Array<{ desc: string; scriptPubKey?: string | object; timestamp: number | string; redeemscript?: string; witnessscript?: string; pubkeys?: Array<string>; keys?: Array<string>; }>, options?: { rescan: boolean; })

Import addresses/scripts (with private or public keys, redeem script (P2SH)), optionally rescanning the blockchain from the earliest creation time of the imported scripts. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/importmulti.html

importprivkey(
privkey: string,
label?: string,
rescan?: boolean,
)

Adds a private key (as returned by dumpprivkey) to your wallet. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/importprivkey.html

importprunedfunds(rawtransaction: string, txoutproof: string)

Imports funds without rescan. Corresponding address or script must previously be included in wallet. Aimed towards pruned wallets. The end-user is responsible to import additional transactions that subsequently spend the imported outputs or rescan after the point in the blockchain the transaction is included. https://developer.bitcoin.org/reference/rpc/importprunedfunds.html

importpubkey(
pubkey: string,
label?: string,
rescan?: boolean,
)

Adds a public key (in hex) that can be watched as if it were in your wallet but cannot be used to spend. Requires a new wallet backup. https://developer.bitcoin.org/reference/rpc/importpubkey.html

importwallet(filename: string)

Imports keys from a wallet dump file (see dumpwallet). Requires a new wallet backup to include imported keys. https://developer.bitcoin.org/reference/rpc/importwallet.html

joinpsbts(psbts: Array<string>)

Joins multiple distinct PSBTs with different inputs and outputs into one PSBT with inputs and outputs from all of the PSBTs No input in any of the PSBTs can be in more than one of the PSBTs. https://developer.bitcoin.org/reference/rpc/joinpsbts.html

Lists groups of addresses which have had their common ownership made public by common use as inputs or as the resulting change in past transactions https://developer.bitcoin.org/reference/rpc/listaddressgroupings.html

listlabels(purpose?: string)

Returns the list of all labels, or labels that are assigned to addresses with a specific purpose. https://developer.bitcoin.org/reference/rpc/listlabels.html

listreceivedbyaddress(
minconf?: number,
include_empty?: boolean,
include_watchonly?: boolean,
address_filter?: string,
)
listreceivedbylabel(
minconf?: number,
include_empty?: boolean,
include_watchonly?: boolean,
)
listsinceblock(
blockhash?: string,
target_confirmations?: number,
include_watchonly?: boolean,
include_removed?: boolean,
)

Get all transactions in blocks since block [blockhash], or all transactions if omitted. https://developer.bitcoin.org/reference/rpc/listsinceblock.html

listtransactions(
label?: string,
count?: number,
skip?: number,
include_watchonly?: boolean,
)

If a label name is provided, this will return only incoming transactions paying to addresses with the specified label. https://developer.bitcoin.org/reference/rpc/listtransactions.html

listunspent(
minconf?: number,
maxconf?: number,
addresses?: Array<string>,
include_unsafe?: boolean,
query_options?: object,
)

Returns array of unspent transaction outputs with between minconf and maxconf (inclusive) confirmations. https://developer.bitcoin.org/reference/rpc/listunspent.html

Returns a list of wallets in the wallet directory. https://developer.bitcoin.org/reference/rpc/listwalletdir.html

loadwallet(filename: string, load_on_startup?: boolean)

Loads a wallet from a wallet file or directory. https://developer.bitcoin.org/reference/rpc/loadwallet.html

lockunspent(unlock: boolean, transactions: Array<{ txid: string; vout: number; }>)

Updates list of temporarily unspendable outputs. https://developer.bitcoin.org/reference/rpc/lockunspent.html

logging(include?: Array<string>, exclude?: Array<string>)

Gets and sets the logging configuration. https://developer.bitcoin.org/reference/rpc/logging.html

Requests that a ping be sent to all other nodes, to measure ping time. https://developer.bitcoin.org/reference/rpc/ping.html

preciousblock(blockhash: string)

Treats a block as if it were received before others with the same work. https://developer.bitcoin.org/reference/rpc/preciousblock.html

prioritisetransaction(
txid: string,
fee_delta: number,
dummy?: number,
)

Accepts the transaction into mined blocks at a higher (or lower) priority https://developer.bitcoin.org/reference/rpc/prioritisetransaction.html

psbtbumpfee(txid: string, options: { conf_target?: number; fee_rate?: number; replaceable?: boolean; estimate_mode?: string; })

Bumps the fee of an opt-in-RBF transaction T, replacing it with a new transaction B. https://developer.bitcoin.org/reference/rpc/psbtbumpfee.html

removeprunedfunds(txid: string)

Deletes the specified transaction from the wallet. Meant for use with pruned wallets and as a companion to importprunedfunds. This will affect wallet balances. https://developer.bitcoin.org/reference/rpc/removeprunedfunds.html

request(method: string, params: any[])

Make a request to the Bitcoin JSON RPC.

rescanblockchain(start_height?: number, stop_height?: number)

Rescan the local blockchain for wallet related transactions. https://developer.bitcoin.org/reference/rpc/rescanblockchain.html

Dumps the mempool to disk. It will fail until the previous dump is fully loaded. https://developer.bitcoin.org/reference/rpc/savemempool.html

scantxoutset(action: string, scanobjects?: Array<string | { desc: string; range?: number | Array<number>; }>)

EXPERIMENTAL warning: this call may be removed or changed in future releases. https://developer.bitcoin.org/reference/rpc/scantxoutset.html

send(
outputs: Array<{ [address: string]: string | number; } | { data: string; }>,
conf_target?: number,
estimate_mode?: string,
fee_rate?: number,
options?: { add_inputs?: boolean; add_to_wallet?: boolean; change_address?: string; change_position?: number; change_type?: string; subtract_fee_from_outputs?: Array<number>; conf_target?: number; estimate_mode?: string; fee_rate?: number | string; include_watching?: boolean; inputs?: Array<{ txid: string; vout: number; sequence: number; }>; },
)

EXPERIMENTAL warning: this call may be changed in future releases. https://developer.bitcoin.org/reference/rpc/send.html

sendmany(
dummy: string,
amounts: object,
minconf?: number,
comment?: string,
subtractfeefrom?: Array<string>,
replaceable?: boolean,
conf_target?: number,
estimate_mode?: string,
fee_rate?: number,
)

Send multiple times. Amounts are double-precision floating point numbers. https://developer.bitcoin.org/reference/rpc/sendmany.html

sendrawtransaction(hexstring: string, maxfeerate?: number | string)

Submit a raw transaction (serialized, hex-encoded) to local node and network. https://developer.bitcoin.org/reference/rpc/sendrawtransaction.html

sendtoaddress(
address: string,
amount: number | string,
comment?: string,
comment_to?: string,
subtractfeefromamount?: boolean,
replaceable?: boolean,
conf_target?: number,
estimate_mode?: string,
avoid_reuse?: boolean,
)
setban(
subnet: string,
command: string,
bantime?: number,
absolute?: boolean,
)

Attempts to add or remove an IP/Subnet from the banned list. https://developer.bitcoin.org/reference/rpc/setban.html

sethdseed(newkeypool?: string, seed?: string)

Set or generate a new HD wallet seed. Non-HD wallets will not be upgraded to being a HD wallet. Wallets that are already HD will have a new HD seed set so that new keys added to the keypool will be derived from this new seed. https://developer.bitcoin.org/reference/rpc/sethdseed.html

setlabel(address: string, label: string)

Sets the label associated with the given address. https://developer.bitcoin.org/reference/rpc/setlabel.html

setnetworkactive(state: boolean)
settxfee(amount: number)

Set the transaction fee per kB for this wallet. Overrides the global -paytxfee command line parameter. https://developer.bitcoin.org/reference/rpc/settxfee.html

setwalletflag(flag: string, value?: boolean)

Change the state of the given wallet flag for a wallet. https://developer.bitcoin.org/reference/rpc/setwalletflag.html

signmessage(address: string, message: string)

Sign a message with the private key of an address Requires wallet passphrase to be set with walletpassphrase call if wallet is encrypted. https://developer.bitcoin.org/reference/rpc/signmessage.html

signmessagewithprivkey(privkey: string, message: string)

Sign a message with the private key of an address https://developer.bitcoin.org/reference/rpc/signmessagewithprivkey.html

signrawtransactionwithkey(
hexstring: string,
privkeys: Array<string>,
prevtxs?: Array<{ txid: string; vout: number; scriptPubKey: string; redeemScript: string; witnessScript: string; amount?: number; }>,
sighashtype?: string,
)

Sign inputs for raw transaction (serialized, hex-encoded). https://developer.bitcoin.org/reference/rpc/signrawtransactionwithkey.html

signrawtransactionwithwallet(
hexstring: string,
prevtxs: Array<{ txid: string; vout: number; scriptPubKey: string; redeemScript?: string; witnessScript?: string; amount: number | string; }>,
sighashtype: string,
)

Sign inputs for raw transaction (serialized, hex-encoded). https://developer.bitcoin.org/reference/rpc/signrawtransactionwithwallet.html

Request a graceful shutdown of Bitcoin Core. https://developer.bitcoin.org/reference/rpc/stop.html

submitblock(hexdata: string, dummy?: boolean)

Attempts to submit new block to network. https://developer.bitcoin.org/reference/rpc/submitblock.html

submitheader(hexdata: string)

Decode the given hexdata as a header and submit it as a candidate chain tip if valid. https://developer.bitcoin.org/reference/rpc/submitheader.html

testmempoolaccept(rawtxs: Array<string>, maxfeerate?: number | string)

Returns result of mempool acceptance tests indicating if raw transaction (serialized, hex-encoded) would be accepted by mempool. https://developer.bitcoin.org/reference/rpc/testmempoolaccept.html

unloadwallet(wallet_name?: string, load_on_startup?: boolean)

Unloads the wallet referenced by the request endpoint otherwise unloads the wallet specified in the argument. https://developer.bitcoin.org/reference/rpc/unloadwallet.html

upgradewallet(version: number)

Upgrade the wallet. Upgrades to the latest version if no version number is specified. https://developer.bitcoin.org/reference/rpc/upgradewallet.html

Returns the total uptime of the server. https://developer.bitcoin.org/reference/rpc/uptime.html

utxoupdatepsbt(psbt: string, descriptors?: Array<string | { desc: string; range?: number | Array<number>; }>)

Updates all segwit inputs and outputs in a PSBT with data from output descriptors, the UTXO set or the mempool. https://developer.bitcoin.org/reference/rpc/utxoupdatepsbt.html

validateaddress(address: string)

Return information about the given bitcoin address. https://developer.bitcoin.org/reference/rpc/validateaddress.html

verifychain(checklevel: number, nblocks?: number)
verifymessage(
address: string,
signature: string,
message: string,
)
verifytxoutproof(proof: string)

Verifies that a proof points to a transaction in a block, returning the transaction it commits to and throwing an RPC error if the block is not in our best chain https://developer.bitcoin.org/reference/rpc/verifytxoutproof.html

walletcreatefundedpsbt(
inputs: Array<{ txid: string; vout: number; sequence: number; }>,
outputs: Array<{ address: string; } | { data: string; }>,
locktime?: number,
options?: object,
bip32derivs?: boolean,
)

Creates and funds a transaction in the Partially Signed Transaction format. https://developer.bitcoin.org/reference/rpc/walletcreatefundedpsbt.html

Removes the wallet encryption key from memory, locking the wallet. https://developer.bitcoin.org/reference/rpc/walletlock.html

walletpassphrase(passphrase: string, timeout: number)

Stores the wallet decryption key in memory for ‘timeout’ seconds. https://developer.bitcoin.org/reference/rpc/walletpassphrase.html

walletpassphrasechange(old_passphrase: string, new_passphrase: string)

Changes the wallet passphrase from ‘oldpassphrase’ to ‘newpassphrase’. https://developer.bitcoin.org/reference/rpc/walletpassphrasechange.html

walletprocesspsbt(
psbt: string,
sign?: boolean,
sighashtype?: string,
bip32derivs?: boolean,
)

Update a PSBT with input information from our wallet and then sign inputs that we can sign for. https://developer.bitcoin.org/reference/rpc/walletprocesspsbt.html