⚠️Blast API (blastapi.io) ends Oct 31. Migrate to Dwellir and skip Alchemy's expensive compute units.
Switch Today →
Skip to main content

state_getKeysPaged – Mythos JSON-RPC Method

Retrieves a page of storage keys for a given prefix. This call is the preferred way to iterate large maps (such as player inventory or marketplace listings) without overloading the RPC endpoint.

Parameters

ParameterTypeRequiredDescription
keyPrefixstringYesHex-encoded storage prefix.
countnumberYesMaximum number of keys to return.
startKeystringNoKey to start after (exclusive).
atstringNoBlock hash. Defaults to latest.

Request Example

{
"jsonrpc": "2.0",
"method": "state_getKeysPaged",
"params": [
"0x26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da9",
100,
null,
null
],
"id": 1
}

Recommendations

  • Choose a page size based on workload; 100 keys keeps responses manageable while covering most use cases.
  • Record the last key returned and provide it in the next request to resume iteration.
  • Pair with state_getStorageHash when you need key existence checks without downloading full values.