Skip to content

Setup

The consensus command gives you the whole network from a terminal: tunnels, proxying, WebSockets, and leased IPs. Run it with no arguments for the full-screen TUI, or call a command directly.

The CLI runs on Bun 1.3.0 or newer. Install Bun, then the package:

Terminal window
curl -fsSL https://bun.com/install | bash
npm install -g @canister-software/consensus-cli

Check that it works:

Terminal window
consensus help

During the public beta the network runs in free mode, so you can skip this step: every command works without credentials.

When payment is enabled, run setup once:

Terminal window
consensus setup

It offers two modes:

  • Self-managed keys (recommended). Enter an EVM private key, a Solana keypair, and optionally the path to an ICP PEM file. Setup writes them as CONSENSUS_EVM_KEY, CONSENSUS_SVM_KEY, and CONSENSUS_PEM_PATH to your shell profile, and payments are signed locally. Keys never leave your machine. Run the source command setup prints, or open a new shell, to load them.
  • Managed wallet. Creates a wallet from your Coinbase Developer Platform credentials, set as CDP_API_KEY_ID, CDP_API_KEY_SECRET, and CDP_WALLET_SECRET in a .env file. The keys are held by the proxy service.

Payments settle on test networks: Base Sepolia, Solana Devnet, and ICP’s TESTICP ledger. Setup prints your addresses with faucet links so you can fund them.

To start over, run consensus setup --force.

Expose a local web server on a public HTTPS URL:

Terminal window
consensus tunnel http localhost:3000

Send one request through the network:

Terminal window
consensus proxy fetch https://api.example.com/prices --verbose

List nodes, then pin your traffic to one of them, and so to its IP address:

Terminal window
consensus ip list --region east-us
consensus ip lease <node-id-or-domain>

Usage lists every command and option.

The CLI stores its configuration, leased node, preferences, and session history in ~/.consensus/. Self-managed keys live in your shell profile, not in that directory.