RSK Console

Meri Herrera edited this page May 4, 2018 · 5 revisions

There's a interactive console that allows you to send commands to an Smart node, it's just a node.js application that can be downloaded from here.

Pre-requisite

You should install:

Dependency Link Details
Node JS Node JS Runtime enviroment for JS

Next step is, from the command line execute npm install to install dependencies.

Run

From the command line, execute node console.js -server HOST:PORT (by default RSK node runs in port 4444).

If everything works as expected, the RSK command prompt will be displayed. There are several commands to interact with the node. These are a couple of examples:

  • web3.eth.blockNumber: returns the local blockchain's best block number.

  • web3.eth.getBalance(web3.eth.accounts[0]): returns the account balance of the first account in the array.

Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.