I want to use jsonrpc to connect bitcoind. What should I do?
Closed this issue · 2 comments
vae520283995 commented
I want to use jsonrpc to connect bitcoind. What should I do?
Can you give me an example?
msgilligan commented
Create an instance of BitcoinClient and then start calling the methods you want to use. You'll need to provide URL, port, username, password to connect, of course.
Something like this:
URI server = new URI("http://server.domain.tld:8332");
BitcoinClient client = new BitcoinClient(MainNetParams.get(), server, "username", "password");
Integer count = client.getBlockCount();
msgilligan commented