/wallet/getchainparameters - Tron

This endpoint returns the current network parameters set by on-chain governance, such as Energy and Bandwidth prices and transaction fees.

Parameters

This endpoint does not require parameters.

Request

bashcurl --location --request POST 'https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/wallet/getchainparameters' \
--header 'Content-Type: application/json' \
--data-raw '{}'

example.js

javascriptconst response = await fetch(
    'https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/wallet/getchainparameters',
    {
        method: 'POST',
        headers: { 'Content-Type': 'application/json' },
        body: JSON.stringify({})
    }
);
console.log(await response.json());

example.py

pythonimport requests

response = requests.post(
    'https://shared.eu-central-1.getblock.io/<ACCESS-TOKEN>/wallet/getchainparameters',
    headers={'Content-Type': 'application/json'},
    json={}
)

print(response.json())

Response

json{
  "chainParameter": [
    {
      "key": "getEnergyFee",
      "value": 210
    },
    {
      "key": "getTransactionFee",
      "value": 1000
    },
    {
      "key": "getCreateAccountFee",
      "value": 100000
    }
  ]
}

Response Parameters

FieldTypeDescription
chainParameterarrayNetwork parameters as key and value pairs
chainParameter[].keystringParameter name, such as getEnergyFee
chainParameter[].valueintegerParameter value, in SUN where a price

Use Cases

  • Fee Calculation: Read the Energy price to compute call costs
  • Cost Modeling: Read transaction and account-creation fees
  • Governance Tracking: Detect parameter changes voted on-chain
  • Wallet Configuration: Configure fee estimates from live parameters

Error Handling

HTTP StatusMessageDescription
200OKThe request succeeded; some TRON errors are returned in the 200 body as an Error field
400Bad requestThe request body is malformed or a required field is missing
500Internal errorThe node failed to process the request