Skip to main content

=nil; CLI usage

There are several steps that need to be completed before using the =nil; CLI.

Create a new config file

To create a config file for the =nil; CLI:

nil config init

Set the RPC endpoint

Initially, the =nil; CLI is unaware of the RPC endpoint for interacting with the cluster.

To set the RPC endpoint:

nil config set rpc_endpoint RPC_ENDPOINT

Set the faucet endpoint

The =nil; CLI can use the faucet service to top-up smart contracts with a range of currencies.

To set the faucet endpoint:

nil config set faucet_endpoint FAUCET_GLOBAL
info

Setting the faucet endpoint is mandatory for creating a new wallet.

Set the Cometa endpoint

The CLI can also use the Cometa service to assist with smart contract debugging.

To set the Cometa endpoint:

nil wallet deploy --compile-input path/to/counter.json --salt SALT

Create a new private key

Creating a new private key is the next logical step before creating a new wallet.

nil keygen new

Create a new wallet

At this point, the only remaining action is to create a new wallet:

nil wallet new

After running this command, the =nil; CLI should be fully ready to interact with the cluster.