CLI Cheatsheet

This page describes usefull commands, which can be used both in swisstronikd or swisstronikcli.

Chain IDs:

Testnet chain ID is used in the examples. If you want to interact with mainnet, ensure that you're using appropriate chain ID

Type
Chain ID

Mainnet

swisstronik_1848-1

Testnet

swisstronik_1291-1

Swisstronik Testnet CLI Cheatsheet

This cheatsheet collects commonly used CLI commands for node operators to easily copy and paste. A few conventions we follow:

  • Capitalized words indicate placeholders

  • Always use our own RPC endpoints

  • Always specify --chain-id and --node flags even when they are unnecessary

  • Query CLI command always uses --output json flag and pipes result through jq

Bank: Send

swisstronikd tx bank send KEY RECEIVER_ADDRESS 1000000uswtr \
  --chain-id swisstronik_1291-1 \
  --node http://148.113.8.228:26657  \
  --from KEY

Distribution: Withdraw Rewards including Commission

Gov: Query Proposal

Gov: Vote

VOTE_OTION: yes, no, no_with_veto and abstain.

Slashing: Unjail

Staking: Create Validator

Note: We use example filed values instead of capitalized dummy words for demo purpose in this command. Please make sure to adjust accordingly for your use.

If you have feedback or find errors in this cheatsheet, please let us know your feedback. Thanks!

Last updated