> For the complete documentation index, see [llms.txt](https://sodex.com/documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sodex.com/documentation/for-developers/api-reference/json-rpc/eth-getstorageat.md).

# eth\_getStorageAt

POST `https://mainnet.valuechain.xyz`

Returns the value from a storage slot at an address.

## Parameters

| Name      | Type            | Required | Description                                                                                                                                                                                              |
| --------- | --------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `address` | address         | Yes      | Contract address.                                                                                                                                                                                        |
| `slot`    | quantity        | Yes      | Storage slot as a hex quantity.                                                                                                                                                                          |
| `block`   | quantity or tag | No       | Hex block number, or `earliest`, `latest`, `safe`, `finalized`, or `pending`. See [block tags](/documentation/for-developers/developers/valuechain-evm/differences-from-ethereum.md#consensus-finality). |

## Result

**Value** (data): 32-byte storage value.

## Example

### Response

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x0000000000000000000000000000000000000000000000000000000000000000"
}
```

## Code examples

### cURL

```bash
curl --request POST \
  --url https://mainnet.valuechain.xyz \
  --header 'Content-Type: application/json' \
  --data '{"jsonrpc": "2.0", "id": 1, "method": "eth_getStorageAt", "params": ["0x5050505050505050505050505050505050505050", "0x0", "latest"]}'
```

### JavaScript

```javascript
const options = {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({"jsonrpc": "2.0", "id": 1, "method": "eth_getStorageAt", "params": ["0x5050505050505050505050505050505050505050", "0x0", "latest"]})
};

fetch('https://mainnet.valuechain.xyz', options)
  .then((res) => res.json())
  .then((res) => console.log(res))
  .catch((err) => console.error(err));
```

### Python

```python
import requests

url = "https://mainnet.valuechain.xyz"
payload = {
  "jsonrpc": "2.0",
  "id": 1,
  "method": "eth_getStorageAt",
  "params": [
    "0x5050505050505050505050505050505050505050",
    "0x0",
    "latest"
  ]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
```
