QUACDocs

Getting started

Quickstart

This page builds the QUAC node, starts a single-node development chain on your machine, and sends a transfer signed with ML-DSA-65. It takes about five minutes.

Requirements

  • Go 1.26.11 or newer. With the default GOTOOLCHAIN=auto, any recent Go downloads the right version automatically.
  • git, bash and curl. On Windows, Git Bash works.
  • No C compiler. QUAC builds as pure Go.

1. Build

git clone https://github.com/dyber-pqc/quacchain.git
cd quacchain
make build            # or: go build -o build/ ./cmd/quacd ./cmd/quacfaucet
build/quacd version

The build produces two binaries:

Binary What it is
build/quacd The node: runs the chain, and doubles as the wallet and query CLI.
build/quacfaucet The faucet service that hands out test QUAC.

2. Start a devnet

scripts/devnet.sh init     # fresh chain in .devnet/
scripts/devnet.sh start    # runs the node in the foreground

init creates the chain quac-devnet-1 with one validator and three test accounts (validator, alice, bob), all with ML-DSA-65 keys:

  • validator starts with 100,000,000 QUAC and stakes 10,000,000 of it.
  • alice starts with 1,000,000 QUAC.
  • Blocks come every second.
  • The REST API is on localhost:1317, the RPC on localhost:26657.

The devnet uses the test keyring, which stores keys unencrypted in .devnet/. Never reuse these keys for anything else.

3. Watch minting

In a second terminal:

build/quacd q bank total-supply --home .devnet
build/quacd q mint inflation --home .devnet

The total supply grows every block. That is the block reward described in Monetary policy. At 5% a year on 101,000,000 QUAC it comes to about 0.8 QUAC per block.

4. Send a transfer

BOB=$(build/quacd keys show bob -a --home .devnet --keyring-backend test)

build/quacd tx bank send alice $BOB 250000000uquac \
  --home .devnet --keyring-backend test --chain-id quac-devnet-1 \
  --gas auto --gas-adjustment 1.4 --gas-prices 0.0025uquac -y

250000000uquac is 250 QUAC. Check the result:

build/quacd q bank balances $BOB --home .devnet

Look up the transaction by hash with build/quacd q tx <hash> --home .devnet. Its signer key type is /cosmos.crypto.mldsa65.PubKey, and its signature is 3,309 bytes long.

5. See a classical key get rejected

build/quacd keys add eve --key-type secp256k1 --home .devnet --keyring-backend test
EVE=$(build/quacd keys show eve -a --home .devnet --keyring-backend test)

# alice can send TO a secp256k1-derived address...
build/quacd tx bank send alice $EVE 5000000uquac --home .devnet --keyring-backend test \
  --chain-id quac-devnet-1 --gas auto --gas-adjustment 1.4 --gas-prices 0.0025uquac -y

# ...but eve can never spend it:
build/quacd tx bank send eve $BOB 1000000uquac --home .devnet --keyring-backend test \
  --chain-id quac-devnet-1 --gas 400000 --gas-prices 0.0025uquac -y
# code 8: signer 0 uses *secp256k1.PubKey; only ml_dsa_65 keys are accepted on this chain

6. Open the explorer against your devnet

The explorer is a static page. Serve the website folder and open it:

python3 -m http.server 5180 --directory website/public
# then open http://localhost:5180/explorer/

On localhost the explorer reads your local node automatically. See Block explorer.

Next

Edit this page on GitHub