GetContractInfo

Queries a contract's information from the blockchain. The difference from the wallet/getcontract interface is that this interface returns not only the bytecode but also the runtime bytecode of the contract. Compared with bytecode, runtime bytecode does not contain constructor and constructor parameter information.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Returns

FieldTypeDescription
runtimecodestringRuntime bytecode of the contract.
smart_contractSmartContractSmart contract object. See GetContract for fields.
contract_stateContractStateState of the contract. See Dynamic Energy Model for details.
contract_state.energy_usageint64Total basic energy usage of the contract in the current maintenance cycle.
contract_state.energy_factorint64Energy factor of the contract.
contract_state.update_cycleint64Current maintenance cycle number.
Body Params
string

Contract address (format: Base58 or Hex).
Example: TG3XXyExBkPp9nzdajDZsozEu4BkaSJozs

boolean
Defaults to true

Set to true to format addresses in Base58; set to false for hex format. (Default: false)

Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json