Staking has become a cornerstone of blockchain networks that utilize Proof-of-Stake (PoS) or Delegated Proof-of-Stake (DPoS) consensus mechanisms. On the OKTC blockchain, users can actively participate in network security and governance by staking OKT tokens. This comprehensive guide walks you through the command-line interface (CLI) tools needed to stake, delegate, and earn rewards—whether you're a regular delegator or a validator.
OKTC leverages Tendermint’s Byzantine Fault Tolerant Delegated Proof-of-Stake (BFT-DPoS) consensus algorithm, enabling users to stake OKT, gain voting power, and earn passive income through staking rewards. This manual focuses exclusively on CLI operations, offering precise commands and workflows for both beginners and advanced users.
What Is Staking?
Staking refers to the process of locking up cryptocurrency tokens to support the operations of a blockchain network. In OKTC’s BFT-DPoS model, staked OKT tokens grant users voting rights proportional to their stake. These votes are used to elect validator nodes responsible for proposing and finalizing blocks.
By staking OKT, users not only contribute to network security but also become eligible for staking rewards—distributed in proportion to their delegated amount and the performance of their chosen validators.
Validators earn block rewards and share a portion with their delegators after deducting a commission rate. This creates a decentralized incentive structure that aligns the interests of all participants.
👉 Discover how staking can generate passive income with simple CLI commands.
How Ordinary Users Can Stake
For non-validator participants, staking on OKTC involves two core steps:
- Stake OKT tokens to obtain voting power.
- Delegate votes to one or more validator nodes. If the validator offers a reward-sharing model, you’ll earn a portion of the staking rewards.
The actual return depends on several factors:
- The validator’s uptime and performance
- Commission rate set by the validator
- Your total staked amount
- Network-wide staking participation
Note: For details on how voting weight is calculated, refer to the Voting Weight Calculation documentation.
Common CLI Commands for Delegators
The exchaincli tool is the primary interface for interacting with the OKTC blockchain via command line. Below are essential commands every delegator should know.
Stake OKT
To begin staking, use the following command to delegate your OKT to a validator:
exchaincli tx staking delegate [validator-address] [amount]okt --from [key-name]Replace:
[validator-address]with the target validator’s address[amount]with the number of OKT you wish to stake[key-name]with your local key name
Vote by Delegating
Delegation inherently counts as a vote. The more tokens delegated to a validator, the higher its chance of being elected as an active validator.
You can redelegate at any time:
exchaincli tx staking redelegate [src-validator] [dst-validator] [amount]okt --from [key-name]Withdraw Staked OKT
Unbonding takes time due to security locks. Initiate withdrawal with:
exchaincli tx staking unbond [validator-address] [amount]okt --from [key-name]Tokens will be released after the unbonding period (typically 21 days).
Query Staking Information
Check your current staking status:
exchaincli query staking delegation [delegator-address] [validator-address]View Pending Staking Rewards
See accumulated but unclaimed rewards:
exchaincli query distr rewards [delegator-address]Withdraw Rewards from One Validator
Claim rewards from a specific validator:
exchaincli tx distr withdraw-rewards [validator-address] --from [key-name]Withdraw All Staking Rewards
Withdraw rewards from all validators at once:
exchaincli tx distr withdraw-all-rewards --from [key-name]👉 Start earning rewards today using secure and powerful CLI tools.
Key Operations for Validators
Validators play a critical role in maintaining network integrity. They propose blocks, validate transactions, and distribute rewards to delegators.
For full validator management, refer to the Validator CLI Guide, which covers:
create-validator: Initialize a new validator nodeedit-validator: Update validator metadata (website, description, etc.)edit-validator-commission-rate: Adjust commission percentagedestroy-validator: Decommission a validator (use with caution)
Set Commission Rate
Validators define their commission rate during creation or later via:
exchaincli tx staking edit-validator-commission-rate [rate] --from [key-name]Example: Set a 10% commission:
exchaincli tx staking edit-validator-commission-rate 0.10 --from my-validator⚠️ Once set, the commission rate cannot be increased by more than 5% per day.
Query Commission Rate
Check your current commission:
exchaincli query staking validator [validator-address]Look for the commission field in the output.
Check Commission Rewards
View accrued commission earnings:
exchaincli query distr validator-outstanding-rewards [validator-address]Withdraw Commission Rewards
Withdraw your earned commission:
exchaincli tx distr withdraw-validator-commission --from [key-name]General CLI Utility Commands
The exchaincli supports various queries for monitoring account activity and network state.
Query Account Info
exchaincli query account [address]Displays balance, sequence number, and account type.
Check Transaction Results
exchaincli query tx [tx-hash]Useful for verifying transaction success or debugging failures.
List All Validators
exchaincli query staking validators --status=BOND_STATUS_BONDEDReturns active validators currently in the consensus set.
View Validator Details
exchaincli query staking validator [validator-address]Includes voting power, commission, and uptime history.
Query Module Parameters
Review staking and reward system settings:
exchaincli query staking params
exchaincli query distr paramsManage Reward Withdrawal Address
Set a separate address to receive rewards:
exchaincli tx distr set-withdraw-addr [withdraw-address] --from [key-name]Query current withdrawal address:
exchaincli query distr withdraw-addr [delegator-address]Proxy Delegation Features
OKTC supports proxy delegation for enhanced flexibility.
- Become a proxy: Register as a proxy account
- Unregister proxy: Revoke proxy status
- Bind/Unbind relationships: Link or disconnect delegators
- Query proxy delegations: List all linked accounts
These functions allow third parties (e.g., staking services) to manage delegations on behalf of users under controlled permissions.
Frequently Asked Questions (FAQ)
Q: How often are staking rewards distributed?
A: Rewards are accrued continuously and can be withdrawn at any time using CLI commands. There is no automatic payout schedule—you must claim them manually.
Q: Can I lose money while staking?
A: While OKTC does not currently implement slashing for minor infractions, validators may be penalized for downtime or malicious behavior. Always choose reliable validators with high uptime and fair commission rates.
Q: What is the unbonding period for staked OKT?
A: The standard unbonding period is 21 days. During this time, your tokens are locked and cannot earn rewards.
Q: Do I need technical expertise to use these CLI commands?
A: Basic command-line knowledge is required. However, most operations follow a consistent pattern. Practice in a test environment first if you're new.
Q: Can I delegate to multiple validators?
A: Yes. You can spread your stake across several validators to diversify risk and optimize returns.
Q: Are there fees for staking transactions?
A: Yes. Each transaction requires a small gas fee paid in OKT. Fees vary based on network congestion.
Final Thoughts
Mastering the CLI tools for staking on OKTC empowers users to take full control of their digital assets. Whether you're delegating for passive income or operating a validator node, understanding these commands ensures efficient, secure participation in the network.
With transparent reward distribution, customizable delegation options, and robust query capabilities, OKTC provides a flexible framework for both casual users and enterprise-grade operators.
👉 Unlock your earning potential—start staking with confidence today.