Skip to main content

eth_getBalanceValues

Returns the parameters that control an accounts rebasing ETH balance.

note

To facilitate rebasing ETH balances, accounts on Mantle store more fields than just the balance in the state trie.

Parameters

  • address: [Required] A string representing the address (20 bytes) to check for balance.
  • block parameter: [Required] A hexadecimal block number, or one of the string tags latest, earliest, pending, safe, or finalized. See the default block parameter.

Returns

Object with the following fields:

  • flags: The flags indicating specific attributes or characteristics of the account.
  • fixed: The fixed data associated with the account.
  • shares: The shares associated with the account.
  • remainder: The field indicating any remainder or residual information about the account.

Example

Replace YOUR-API-KEY with an API key from your Infura dashboard.

Request

curl https://mantle-mainnet.infura.io/v3/YOUR-API-KEY \
-X POST \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_getBalanceValues","params": ["0xd071acb641553a2e205181a42aa3a8ace97dae6d", "latest"],"id":1}'

Response

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"flags": "0x0",
"fixed": "0x0",
"shares": "0x6d6eb",
"remainder": "0xad6dc86"
}
}