Questions tagged [json-rpc]

This tag should be used for questions relating to the Bitcoin Core/bitcoind JSON-RPC interface.

Filter by
Sorted by
Tagged with
0 votes
1 answer
21 views

Bitcoin RPC createrawtransaction parse error

I try to create a raw transaction using the Bitcoin Core RPC through curl. Python script: import requests data = '{"jsonrpc":"2.0","id":"curltext","method&...
  • 135
4 votes
2 answers
74 views

Why would I need to ban peer nodes in bitcoin network?

Bitcoin RPC has the setban command and some other ban related commands. From what I understood from Bitcoin, the network becomes more secure as more nodes are connected sharing blockchain data. From ...
0 votes
1 answer
19 views

How to get multiple vouts in one RPC call?

Is there an RPC call to get more (or better all) vouts for given transaction? Iterating over each one takes a lot of network time. gettxout txid 0 gettxout txid 1 gettxout txid 2 gettxout txid 3 -> ...
0 votes
0 answers
22 views

get value of transactions in mempool

with getrawmempool verbose=true i can get the latest unconfirmed transactions and some useful details about each one. However I can't seem to get the value of any of the transactions from ...
  • 1
0 votes
1 answer
64 views

Access REST endpoint of Bitcoin-qt from another computer on the local network

I have bitcoin-qt running on a Windows machine in my network started with the following command and empty config file (hence, all default configurations). bitcoin-qt.exe -server=1 -rest=1 I can query ...
0 votes
0 answers
35 views

Localhost peer not detected error when trying to connect to Bitcoind server via JSON RPC from Java Application

I am running Bitcoin Network on local Ubuntu machine. The network consists of multiple nodes. I want to connect to the network from a java application running on the same machine via JSON RPC. I can ...
  • 1
0 votes
1 answer
27 views

TX decode failed Separator is missing at the end of an output map: iostream error

import requests url = "http://127.0.0.1:18332/wallet/w3" headers = { 'Authorization': 'Basic dXNlcjpwYXNz', 'Content-Type': 'text/plain' } def combinetx(): payload = "{\&...
0 votes
0 answers
23 views

Hardware crashed, Bitcoin core won’t load

I can’t believe this hasn’t come up multiple times. My hardware crashed (actually locked up and could only be unlocked by a forced (unplug) power off) while Bitcoin core was running. Of course on ...
1 vote
1 answer
29 views

How do I set up credentials for bcoin's JSON RPC interface?

I've recently been introduced to bcoin. In the documentation, it's stated that bcoin's RPC interface is similar to that of Bitcoin Core but after syncing my node, I can't find a way to set up a JSON ...
0 votes
1 answer
38 views

Specification of Bitcoin RPC getbalances

I would like to track balances using address, but I have a few questions. If I don't use the rescan option, will the balance be incorrect? Why is the balance off when I check it against an external ...
  • 3
3 votes
1 answer
67 views

How do I maintain a continuously updated copy of a local mempool?

Let's say I want to build a database of transactions that is continuously being updated from a locally running Bitcoin Core node using JSON-RPC and ZeroMQ. My concern is how to make it robust against ...
2 votes
1 answer
71 views

On signet of bitcoin core, why didn't the average time between blocks I mined accord with the time I set?

I'm new here. I met some problem when I use signet on bitcoin core in docker container. I used this command to work out the nbits value to set the average mining time which is 60s. python3.8 miner --...
  • 21
0 votes
0 answers
30 views

Connection error

i have installed bitcoin node, it was syncing before i went to sleep, i want to know the percentage of the synced, anytime i query on the bitcoin-cli getblockcount ,i get this error " error: ...
1 vote
1 answer
121 views

Using bitcoind json-rpc with multiple wallets

Since some time bitcoind can have more wallets, there are commands: https://bitcoincore.org/en/doc/22.0.0/rpc/wallet/loadwallet/ and https://bitcoincore.org/en/doc/22.0.0/rpc/wallet/listwallets/ Does ...
0 votes
1 answer
30 views

Will remote RPC under http expose the rpcusername and rpcpassword?

I'm confused with the examples of contacting bitcoin-cli as the examples always show sending user name:pass to http does this expose the name:pass? This command: (I modified the help example from ...
1 vote
1 answer
220 views

Can I use the Bitcoin Core CLI to learn the block height at which a transaction was mined?

I am interested in figuring out at what height a transaction was mined, but I cannot find the right command to extract this information. Perhaps it's not possible? My Bitcoin Core was not involved as ...
3 votes
0 answers
54 views

Problems with multiple wallets on RPC in bitcoin-core

I have been playing around a bit with Bitcoin Core (version 23.0), more specifically connecting to different wallets in Bitcoin Core through RPC in Python. I have found this library and tried to ...
0 votes
1 answer
24 views

Same blockhash that appears more times in a bitcoind’s rpc call listsinceblock transaction returned json

Let's suppose that listsinceblocks return a json like this: { "transactions": [ { "involvesWatchonly": true, "account": "", "...
1 vote
1 answer
52 views

Consider only deposits in a bitcoind’s RPC call listsinceblock transaction returned JSON

I have a JSON result of a bitcoind’s RPC call listsinceblock. There are 4 categories of transaction: "send" means transactions sent "receive" means non-coinbase transactions ...
0 votes
1 answer
36 views

Can a receive transaction be 0 in a bitcoind’s rpc call listsinceblock transaction returned json?

Suppose that I want to check all the valid deposits of the results of bitcoind’s rpc call listsinceblock transactions, can I found a ‘receive’ transactions with ‘amount’ as 0? Should I consider that ...
1 vote
0 answers
25 views

How to check whether bitcoin is deposited or not with RPC API?

I am developing a new feature in my website that raises a user's level when they deposit to a new bitcoin address. Using RPC API, I was successful in creating a new wallet address and printing it on ...
0 votes
1 answer
21 views

What does getnewaddress return

The address generated by getnewaddress RPC is associated to a wallet that the user possesses or is it a random address not necessarily belonging to user ?
1 vote
2 answers
139 views

RPC port 8332 not accessible after reboot

I have compiled and installed Bitcoin Core for the first time on Debian 11. Everything is up and running except that RPC port 8332 is not accessible after a reboot. I get the following error running ...
0 votes
0 answers
41 views

Increase performance of RPC and ZeroMQ in bitcoin-core

I am interested in the possibility of increasing performance of my Bitcoin Core RPC and ZeroMQ subsystems. I know there is a setting for controlling the number of threads used by the RPC process, ...
0 votes
1 answer
39 views

What does the Bitcoin Core RPC createmultisig do? Should it be deprecated?

What does the Bitcoin Core RPC createmultisig do? What would I use it for? Should it be deprecated?
0 votes
2 answers
160 views

Generating bitcoin core -rpcauth argument using golang

We're developing a Blockchain deployment solution kotal, and generating -rpcauth argument from the supplied user name and password. The problem is when we try to use the same user and password using ...
  • 863
1 vote
1 answer
60 views

Is it possible to set multiple JSON-RPC users?

I am passing multiple -rpcuser and -rpcpassword options, but the last user is the one that's working ! I was assuming that I can set multiple JSON-RPC users.
  • 863
0 votes
0 answers
56 views

Bitcoin Core RPC in Online Shop - Wallet file not specified error when making purchase

I have my shop website connected to my server running Bitcoin core. If someone makes a purchase, the following error occurs. I don't know where to specify the wallet file as a purchase would happen ...
  • 1
1 vote
1 answer
93 views

C-lightning configuration to use bitcoin blockchain data from another machine

I currently run a lightning node on umbrel on a raspberry pi. I want to experiment with c-lightning and want to run a new c-lightning node on my ubuntu laptop which utilizes the blockchain data from ...
  • 41
1 vote
1 answer
260 views

Bitcoin RPC not reachable: Cant bind RPC server to IPV6

I tried every different combination in bitcoin.conf to make my bitcoin node (hosted in AWS protected behind VPN) reachable but nothing seems to work... Just to clear it out of the way, I opened the ...
  • 113
1 vote
1 answer
140 views

How to generate a public key in wallet rpc commands

I'm trying to generate a public key associated with a wallet. How would I do this using the wallet rpc commands, I couldn't find a command in reference docs which does this. Thanks.
  • 131
1 vote
1 answer
45 views

What is the correct syntax when specifying the utxos to be used in c-lightning's `withdraw`?

I tried to withdraw from one utxo with the following command: lightning-cli -k withdraw destination=bc1********** satoshi=******* feerate=normal utxos='["********":"0"]' and I got ...
0 votes
1 answer
89 views

Is there any web3.py equivalent for Bitcoin?

Is there a good python library to connect to my locally running bitcoin node and query it? Such as view data block by block, txs, network difficulty at the time of each block, and other parameters? ...
  • 33
1 vote
2 answers
89 views

Is the 'Remote' In 'Remote Procedural Call' something of a misnomer?

My understanding of an RPC is that Bitcoin-qt (client) will send an RPC to bitcoind (or an instance of bitcoind on another machine if the configuration settings are changed to make that happen) and ...
2 votes
1 answer
76 views

RPC getblockstats call using genesis block

I am running a full node, bitcoin core 22. It is not in pruned mode. But when I try to run RPC getblockstats call I get this. $ bitcoin-cli getblockstats 0 ...
0 votes
1 answer
202 views

How to run Bitcoin-Qt over RPC to another machine

I have a full node running bitcoind on computer A. On computer B I have bitcoin-cli setup to connect to computer A over RPC. Computer A is a headless machine. I don't want to re-download the chain ...
  • 140
0 votes
1 answer
210 views

Get Address from pubkey scriptPubKey

Given that address is a "convenience" field, it makes sense that it is not provided by default in many transactions. However, it seems to be possible to extract address from hex. I am ...
0 votes
0 answers
25 views

JSON errors signing transaction

I am a beginner and have been having issues creating a rawtransaction. There is no error log so it's sometimes difficult to know where the error lies. I have this tx that I want to send on Testnet, ...
1 vote
1 answer
63 views

Correct way to implement bitcoin:<address> URI handling in Gnome desktop

I run bitcoin-qt all the time, so I set the browser to handle bitcoin: URI with bitcoin-qt. Unfortunately that causes a new instance to be started, which fails coz it fails to get a lock on the ...
  • 161
0 votes
1 answer
93 views

Weird Bitcoin RPC listreceivedbyaddress behaviour

Everything was done on regtest network. So I've generated a new address using getrawchangeaddress on wallet 2 and made a 0.1 BTC transaction from wallet 1 to wallet 2 and tried check this address ...
  • 3
0 votes
2 answers
129 views

MerkleRoot requires transaction hash to build a merkle tree.... Is that the "hash" key/value within the getblocktemplate response or the "data"?

I've created a function for parsing Json Objects and values and just when I think nothing can stop me, just when I feel like I'm the king of the blockchain and I can finally join in on the mining race ...
0 votes
1 answer
49 views

Not able to verify tor setup for RPC

I'm currently in chapter 14.1 (verify your tor setup) of the learning bitcoin from the command line course by blockchaincommons. I don't get my head around doing the actual RPC verification via ...
  • 303
0 votes
1 answer
114 views

What exactly is the data required when creating a coinbase transaction? How do I insert the blocks height into the coinbase transaction?

Still trying to write a function to properly create a coinbase transaction and the only thing I can't seem to get a hold on is..... How to get the block height provided by getblocktemplate into the ...
0 votes
1 answer
82 views

RPC interface MITM protection

When I connect to my bitcoind instance over RPC, I need a password for that, but no certificate. So how are man-in-the-middle attacks prevented on that connection?
2 votes
1 answer
138 views

Validate raw transaction hex without broadcasting

I would like to check the validity of a raw transaction (i.e. whether it would be accepted by network nodes), without broadcasting the transaction to the network. I am interested in knowing what is ...
  • 198
1 vote
1 answer
74 views

Flag -deprecatedrpc=addressess - Bitcoin core

How long do we will have the -deprecatedrpc=addressess flag for Bitcoin core. Is it just for the v22.0 or will it be available for all minor and patch releases until v23.0?
0 votes
1 answer
49 views

Just to be sure, the downloads at bitcoincore.org are the safer ones?

(more than bitcoin.org?) And a few more questions regarding this: Why did they change the naming of the versions from 0.xx to xx.0? (latest update changed from 0.21 to 22.0). Why they did not add ...
  • 1
1 vote
1 answer
217 views

I am getting an RPC error when trying to run any Bitcoin-cli commands on Ubuntu

I asked this question on AskUbuntu and was told to post it here. https://askubuntu.com/q/1373657/1519292 I am trying to follow the Mastering Bitcoin tutorial. After compiling Bitcoin Core, and ...
  • 11
0 votes
1 answer
108 views

What's the difference between generateblock and generatetoaddress

Both commands generate blocks, and one specifies an address, what is the usage for each? Thanks!
0 votes
1 answer
75 views

How to accept the payment with regtest?

I sent some BTC via the regtest network from one wallet to another, and I don't see it using getbalance, but I do see it if I use the command getbalances as untrusted_pending: { "mine": { ...

1
2 3 4 5
16