0
I get this error:
{ Error: connect ECONNREFUSED 127.0.0.1:8332
at Object._errnoException (util.js:1022:11)
at _exceptionWithHostPort (util.js:1044:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1182:14)
code: 'ECONNREFUSED',
errno: 'ECONNREFUSED',
syscall: 'connect',
address: '127.0.0.1',
port: 8332 }
when I use this code:
var bitcoin = require('bitcoin');
var client = new bitcoin.Client({
host: 'localhost',
port: 8332,
user: 'Rohit',
pass: '12345'
});
Can you post the contents of your bitcoin.conf file (censoring any passwords as necessary)? – Andrew Chow – 2018-03-21T19:52:42.870
Welcome to Bitcoin.SE! You can help the site by marking answers as accepted if they are correct and address the question so that the question does not remain as "unanswered". – Willtech – 2018-03-22T09:55:38.133