[Configuration] kaia_getParams
Returns the governance parameters effective at the given block.
NOTE: The block number can be larger than the latest block number, in which case the API returns the tentative value based on the current chain state. The future kaia parameters are subject to change via additional governance votes or GovParam contract state changes.
Key | Value |
---|---|
governance.governancemode | STRING. One of the three governance modes, "none", "single", "ballot". this parameter is immutable. |
governance.governingnode | ADDRESS. Designated governing node's address. Only works with "single" governance mode. e.g., 0xe733cb4d279da696f30d470f8c04decb54fcb0d2 |
governance.unitprice | NUMBER. Pre-Magma fixed gas price in kei. e.g., 25000000000 (25 gkei/gas) |
governance.addvalidator | ADDRESS. Address or comma-separated list of addresses of a new validator candidate. e.g., 0xe733cb4d279da696f30d470f8c04decb54fcb0d2,0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 |
governance.removevalidator | ADDRESS. Address or comma-separated list of addresses of a current validator which need to be removed. e.g., 0xe733cb4d279da696f30d470f8c04decb54fcb0d2 |
governance.deriveshaimpl | NUMBER. One of the three methods for generating the transaction hash and receipt hash in a block header. 0 (Original), 1 (Simple), 2 (Concat). |
governance.govparamcontract | ADDRESS. (since Kore) Address of the GovParam contract. e.g., 0xe733cb4d279da696f30d470f8c04decb54fcb0d2 |
istanbul.epoch | NUMBER. The voting period in header-based governance. This parameter is immutable. e.g., 86400 |
istanbul.committeesize | NUMBER. The maximum number of validators in a committee. (also known as istanbul.sub in ChainConfig) |
istanbul.policy | NUMBER. One of three proposer selection policies, 0 (RoundRobin), 1 (Sticky), 2 (WeightedRandom). This parameter is immutable. |
reward.mintingamount | STRING. Minted rewards per block in kei. Note that it must be in string type because the number can be too big for JavaScript to handle. e.g., 9600000000000000000 (9.6 KAIA/block) |
reward.ratio | STRING. Reward distribution ratio among GC/KIF/KEF. Three integers separated by "/" that adds up to 100. e.g., 50/40/10 |
reward.kip82ratio | STRING. (Since Kore) Reward distribution between block proposer and stakers. Two integers separated by "/" that adds up to 100. e.g., 20/80 . |
reward.useginicoeff | BOOL. (Before Kore) If true, proposer selection algorithm adjusts the staking amounts using Gini coefficient. This parameter is immutable. This parameter is no longer used since Kore, so false is displayed in the APIs. e.g., true |
reward.deferredtxfee | BOOL. If false, transaction fees sent to the proposer after executing each transaction. If true, transaction fees are summed up with other rewards and given to the proposer after executing all transactions. This field is immutable. |
reward.minimumstake | STRING. Minimum staking amount in KAIA to be a validator (i.e. CN). This parameter is immutable. Note that it must be in string type because the number can be too big for JavaScript to handle. e.g., 5000000 (5 million KAIA) |
reward.proposerupdateinterval | NUMBER. (Before Randao) Size of the proposer selection batch. This parameter is immutable. This parameter is no longer used since Kore, so 1 is displayed in the APIs. e.g., 3600 |
reward.stakingupdateinterval | NUMBER. (Before Kaia) The block interval in which staking information is updated. This parameter is immutable. This parameter is no longer used since Kaia, so 1 is displayed in the APIs. e.g., 86400 |
kip71.lowerboundbasefee | NUMBER. The lowest possible base fee in kei. e.g., 25000000000 |
kip71.upperboundbasefee | NUMBER. The highest possible base fee in kei. e.g., 750000000000 |
kip71.gastarget | NUMBER. The target, or neutral, block gasUsed. The base fee increases when parent block contains more than gas target, and decreases when parent block contains less than gas target. e.g., 30000000 |
kip71.basefeedenominator | NUMBER. Controls how fast the base fee changes. e.g., 20 |
kip71.maxblockgasusedforbasefee | NUMBER. The maximum block gas recognized in base fee calculation. e.g., 60000000 |
NOTE: The block number can be larger than the latest block number, in which case the API returns the tentative value based on the current chain state. The future kaia parameters are subject to change via additional governance votes or GovParam contract state changes.
NOTE: If the requested block has Kore hardfork enabled, the value of reward.useginicoeff
will be false
because all council members have an equal chance of being elected as a block proposer and thus Gini coefficient is not relevant.
NOTE: If the requested block has Randao hardfork enabled, the value of reward.proposerupdateinterval
will be 1
because proposers are no longer selected at batch.
NOTE: If the requested block has Kaia hardfork enabled, the value of reward.stakingupdateinterval
will be 1
because staking information is every block, effectively deprecating the interval.
JSONRPC: kaia_getParams
Request
- application/json
Body
Array [
- IntegerBlockNumber
- HexadecimalBlockNumber
- BlockTag
]
params
object[]
required
oneOf
the block number with type integer
number
the block number with type hexadecimal
string
the block tag [latest, pending, earliest]
string
Responses
- 200
governance items
- application/json
- Schema
- Example (from schema)
Schema
error
object
A Number that indicates the error type that occurred. This MUST be an integer.
code | message | description |
---|---|---|
-32700 | Parse error | invalid JSON was received by the server. An error occurred on the server while parsing the JSON text. |
-32602 | Invalid params | Invalid method parameter(s). |
A String providing a short description of the error. The message SHOULD be limited to a concise single sentence.
A Primitive or Structured value that contains additional information about the error. This may be omitted. The value of this member is defined by the Server (e.g. detailed error information, nested errors etc.).
governance items
{
"jsonrpc": "2.0",
"id": 0,
"error": {
"code": -32700,
"message": "Parse error",
"data": "string"
},
"result": {
"governance.governancemode": "single",
"governance.governingnode": "0x7bf29f69b3a120dae17bca6cf344cf23f2daf208",
"governance.unitprice": 25000000000,
"istanbul.committeesize": 13,
"istanbul.epoch": 30,
"istanbul.policy": 2,
"kip71.basefeedenominator": 20,
"kip71.gastarget": 30000000,
"kip71.lowerboundbasefee": 25000000000,
"kip71.maxblockgasusedforbasefee": 60000000,
"kip71.upperboundbasefee": 750000000000,
"reward.deferredtxfee": true,
"reward.minimumstake": "5000000",
"reward.mintingamount": "9600000000000000000",
"reward.proposerupdateinterval": 30,
"reward.ratio": "34/54/12",
"reward.stakingupdateinterval": 60,
"reward.useginicoeff": true
}
}