Heimdall governance works exactly the same as Cosmos-sdk
x/gov module. https://docs.cosmos.network/master/modules/gov/
In this system, holders of the native staking token of the chain can vote on proposals on a
1 token = 1 vote basis. Next is a list of features the module currently supports:
- Proposal submission: Validators can submit proposals with a deposit. Once the minimum deposit is reached, proposal enters voting period. Valdiators that deposited on proposals can recover their deposits once the proposal is rejected or accepted.
- Vote: Validators can vote on proposals that reached MinDeposit
There are deposit period and voting period as params in
gov module. Minimum deposit has be achieved before deposit period ends, otherwise proposal will be automatically rejected.
Once minimum deposits reached within deposit period, voting period starts. In voting period, all validators should vote their choices for the proposal. After voting period ends,
tally function and accepts or rejects proposal based on
There are different types of proposals that can be implemented in Heimdall but as of now, it supports only one proposal:
- Param change proposal
Param change proposal
Using this type of proposal, validators can change any
params in any
module of Heimdall. Example: change minimum
tx_fees for the transaction in
auth module. When the proposal gets accepted, it automatically changes the
params in Heimdall state. No extra TX is needed.
Query gov params
This shows all params for governance module.
proposal.json is a file which includes proposal in json format.
To query all proposals
To query particular proposal
Vote on proposal
To vote on a particular proposal
Proposal will be automatically tallied after voting period.
|Get all proposals||GET||/gov/proposals|
|Get proposal details||GET||/gov/proposals/|
|Get all votes for the proposal||GET||/gov/proposals/|