Chain state

These commands compare the balance of an address against a particular token or block.

Each data structure is created by one or more tools which are detailed below

State

The following commands produce and manage states:

Tools

The balance of an address at a given block.

State data is made of the following data fields:

FieldDescriptionType
blockNumberthe block number at which this state was takenblknum
balancethe balance at the address at the given block heightwei
noncethe nonce of the address at the given block heightuint64
codethe byte code at the address (if this is a smart contract)bytes
storagethis field is un-implemented and current returns the first storage location in a smart contractbytes
addressthe address of the state being queriedaddress
deployedthe block number at which this smart contract was deployed (if a smart contact)blknum
accttypethe type of the address at the given blockstring

Result

FieldDescriptionType
blockNumberthe block number at which this call was madeblknum
addressthe address of contract being calledaddress
signaturethe canonical signature of the interfacestring
encodingthe encoding for the function callstring
bytesthe bytes data following the encoding of the callstring
callResultthe result of the call to the contractCFunction
compressedResultthe compressed version of the result of the call to the contractstring
deployedthe block number at which this smart contract was deployed (if a smart contact)blknum

Token

The following commands produce and manage tokens:

Tools

Token data is made of the following data fields:

FieldDescriptionType
holderthe address for which we are reporting the token balanceaddress
balancethe balance at the address at the given block heightwei
addressdescription: the address of the token contract being queriedaddress
namethe name of the token contract, if availablestring
symbolthe symbol for this token contractstring
decimalsthe number of decimals for the token contractuint64
isContracttrue if the address is a smart contract, false otherwisebool
isErc20true if the address is an ERC20, false otherwisebool
isErc721true if the address is an ERC720, false otherwisebool

Base types

This documentation mentions the following basic data types.

TypeDescriptionNotes
addressa 20-byte hexadecimal string starting with ‘0x’lowercase
blknuman alias for a uint64
boola value either true, false, 1, or 0
bytesan arbitrarily long string of bytes
stringa normal character string
uint64a 64-bit unsigned integer
weian unsigned big numberas a string
Published on: Feb 10, 2022 Last edited: Feb 11, 2022

Edit this page on GitHub