> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chainstack.com/llms.txt
> Use this file to discover all available pages before exploring further.

# eth_getStorageValues | Robinhood

> Robinhood API method that returns the values of up to 1,024 storage slots across one or more smart contracts in a single call. Use it on Robinhood via Chainstack.

Robinhood API method that returns the values stored at multiple storage slots, across one or more smart contracts, in a single call. It replaces a batch of [eth\_getStorageAt](https://docs.chainstack.com/reference/robinhood-eth-getstorageat.md) requests when you read several slots at the same block, for example to snapshot a contract's state.

## Parameters

* `object` — an object that maps each contract address to an array of storage slot keys. Each key must be a full 32-byte hex value, such as `0x0000000000000000000000000000000000000000000000000000000000000001`; a short form such as `0x1` is rejected.
* `quantity or tag` — the block number encoded as hexadecimal, or a block tag such as `latest`.

## Response

`result` — an object that maps each requested contract address, in lowercase, to an array of 32-byte storage values in the same order as the requested slots.

A request with no slots returns `-32602` with `empty request`, and a request with more than 1,024 slots returns `-38026` with `too many slots (max 1024)`.

## `eth_getStorageValues` code examples

The examples read slots `0`, `2`, and `4` of the [USDG token contract](https://robinhoodchain.blockscout.com/token/0x5fc5360D0400a0fD4f2AF552Add042d716F1D168) in one call.

```javascript ethers.js theme={"system"}
const { ethers } = require("ethers");

const provider = new ethers.JsonRpcProvider("YOUR_CHAINSTACK_ENDPOINT");

const slot = (n) => ethers.zeroPadValue(ethers.toBeHex(n), 32);

const getStorageValues = async () => {
  const values = await provider.send("eth_getStorageValues", [
    {
      "0x5fc5360D0400a0fD4f2AF552Add042d716F1D168": [slot(0), slot(2), slot(4)],
    },
    "latest",
  ]);
  console.log(values);
};

getStorageValues();
```

```python web3.py theme={"system"}
from web3 import Web3

w3 = Web3(Web3.HTTPProvider("YOUR_CHAINSTACK_ENDPOINT"))

def slot(n):
    return "0x" + format(n, "064x")

response = w3.provider.make_request("eth_getStorageValues", [
    {
        "0x5fc5360D0400a0fD4f2AF552Add042d716F1D168": [slot(0), slot(2), slot(4)],
    },
    "latest",
])
print(response["result"])
```

## Use case

One use case for `eth_getStorageValues` is reading a consistent snapshot of several contracts' internal state. All slots come from the same block in one round trip, so a monitoring service that tracks owners, balances, or configuration slots across many contracts avoids both the request overhead of separate `eth_getStorageAt` calls and the risk of reading different slots at different blocks.


## OpenAPI

````yaml openapi/robinhood_node_api/accounts_info/eth_getStorageValues.json POST /
openapi: 3.0.0
info:
  title: Robinhood Node API
  version: 1.0.0
  description: This is an API for interacting with a Robinhood node.
servers:
  - url: >-
      https://robinhood-mainnet.core.chainstack.com/mt_c524ad9781ae5dccd9ac6f5b0370e
security: []
paths:
  /:
    post:
      tags:
        - upload
      summary: eth_getStorageValues
      operationId: getStorageValues
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                method:
                  type: string
                  default: eth_getStorageValues
                params:
                  type: array
                  items:
                    anyOf:
                      - type: object
                        title: Slots by contract
                        description: >-
                          An object that maps each contract address to an array
                          of 32-byte storage slot keys. Up to 1,024 slots in
                          total per request.
                        additionalProperties:
                          type: array
                          items:
                            type: string
                      - type: string
                        title: Block ID
                        description: The block number or tag to use as a reference.
                  default:
                    - '0x5fc5360D0400a0fD4f2AF552Add042d716F1D168':
                        - >-
                          0x0000000000000000000000000000000000000000000000000000000000000000
                        - >-
                          0x0000000000000000000000000000000000000000000000000000000000000002
                        - >-
                          0x0000000000000000000000000000000000000000000000000000000000000004
                    - latest
                id:
                  type: integer
                  default: 1
                jsonrpc:
                  type: string
                  default: '2.0'
      responses:
        '200':
          description: >-
            The storage values for each requested contract, in the order of the
            requested slots.
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                  id:
                    type: integer
                  result:
                    type: object
                    description: >-
                      An object that maps each contract address (lowercase) to
                      an array of 32-byte storage values, in the order of the
                      requested slots.
                    additionalProperties:
                      type: array
                      items:
                        type: string

````