From 6c8f84c23d2189be89c58856df33ccb3cfc3a1c5 Mon Sep 17 00:00:00 2001 From: Sam <48280694+itrocket-team@users.noreply.github.com> Date: Thu, 17 Jul 2025 15:01:17 +0400 Subject: [PATCH] Added commands to babylon_usage_guide.mdx --- .../babylon_node/babylon_usage_guide.mdx | 171 +++++++++++++++++- 1 file changed, 170 insertions(+), 1 deletion(-) diff --git a/docs/operators/babylon_node/babylon_usage_guide.mdx b/docs/operators/babylon_node/babylon_usage_guide.mdx index 5bdf7880..0d11184b 100644 --- a/docs/operators/babylon_node/babylon_usage_guide.mdx +++ b/docs/operators/babylon_node/babylon_usage_guide.mdx @@ -3,4 +3,173 @@ sidebar_class_name: node_operators_installation_guide_sidebar sidebar_label: Usage Guide sidebar_position: 1 --- -//ITRocket guide \ No newline at end of file +# CLI Usage Guide + +### Key Management 🔑 +Add new wallet: +``` +babylond keys add +``` + +Restore executing wallet: +``` +babylond keys add --recover +``` + +List all wallets: +``` +babylond keys list +``` + +Delete wallet: +``` +babylond keys delete +``` + +Export key (saves it to `wallet.backup`): +``` +babylond keys export +``` + +Import key (restore from wallet.backup): +``` +babylond keys import wallet.backup +``` + +### Tokens 💰 +Check balance: +``` +babylond q bank balances +``` + +Withdraw all rewards: +``` +babylond tx distribution withdraw-all-rewards --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 +``` + +Withdraw rewards and commission from your validator: +``` +babylond tx distribution withdraw-rewards $(babylond keys show --bech val -a) --from --commission --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Delegate to your validator: +``` +babylond tx epoching delegate $(babylond keys show --bech val -a) ubbn --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Delegate to another validator: +``` +babylond tx epoching delegate ubbn --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Redelegate stake to another validator: +``` +babylond tx epoching redelegate ubbn --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Unbond from your validator: +``` +babylond tx epoching unbond $(babylond keys show --bech val -a) ubbn --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Unbond from another validator: +``` +babylond tx epoching unbond ubbn --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Transfer funds: +``` +babylond tx bank send ubbn --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Transfer funds to multiple accounts: +``` +babylond tx bank multi-send ubbn --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +### Governance 🗳️ +View proposals list: +``` +babylond query gov proposals +``` + +View proposal: +``` +babylond query gov proposal +``` + +Vote: +``` +babylond tx gov vote --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +### Validator Operations 👨‍💻 +Create new validator: +``` +# Create a validator.json file with validator details (replace moniker, details, etc. with your data): +echo "{\"pubkey\":{\"@type\":\"/cosmos.crypto.ed25519.PubKey\",\"key\":\"$(babylond comet show-validator | grep -Po '\"key\":\s*\"\K[^"]*')\"}, + \"amount\": \"1000000ubbn\", + \"moniker\": \"test\", + \"identity\": \"\", + \"website\": \"\", + \"security\": \"\", + \"details\": \"I love Babylon ❤️\", + \"commission-rate\": \"0.1\", + \"commission-max-rate\": \"0.2\", + \"commission-max-change-rate\": \"0.01\", + \"min-self-delegation\": \"1\" +}" > validator.json + +# Create a validator using JSON file +babylond tx checkpointing create-validator validator.json --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 +``` + +Edit validator (from `new-moniker`, `identity`, `details`, `commission-rate` flags, use only those you want to edit): +``` +babylond tx epoching edit-validator \ +--commission-rate 0.1 \ +--new-moniker "" \ +--identity "" \ +--details "" \ +--from \ +--chain-id bbn-1 \ +--gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 \ +-y +``` + +Unjail validator: +``` +babylond tx slashing unjail --from --chain-id bbn-1 --gas auto --gas-prices 0.002ubbn --gas-adjustment 1.5 -y +``` + +Your validator details: +``` +babylond query staking validator $(babylond keys show --bech val -a) +``` + +Another validator details: +``` +babylond query staking validator +``` + +Slashing parameters: +``` +babylond query slashing params +``` + +Signing and jailing info of your validator: +``` +babylond query slashing signing-info $(babylond tendermint show-validator) +``` + +Signing and jailing info of another validator: +``` +babylond query slashing signing-info '' +``` + +Active validators list: +``` +babylond query staking validators +``` + +*Guide provided by [ITRocket team](https://itrocket.net/).*