eth_getStorageAt

The eth_getStorageAt method returns the value from a storage position at a given address on the Optimism network. This method allows direct access to a smart contract's storage slots, enabling you to read specific state variables by their storage position. It's useful for advanced contract analysis, debugging, and reading data from contracts without needing their ABI, though understanding the storage layout is required.


Parameters

parameter
type
description
address
string (required)
The contract address (20 bytes)
position
string (required)
The storage position (32 bytes, hex-encoded)
blockParameter
string (required)
Block number in hex or tag (latest, earliest, pending)
Return Object

The method returns the value at the storage position as a 32-byte hex string.

Request Example
Request
Response Example
Response

Share on
Share on FacebookShare on XShare on LinkedIn
Did you find this page useful?