0

I want to access a private data in a smart contract, I know that it is located in the second slot, and I use this code :

await web3.eth.getStorageAt('0xeB51Bceb2F930aC619815E96FfB8E57C84Fb67Cd' , 1)

but i get this error :

Uncaught (in promise) Error: Internal JSON-RPC error.
{
  "message": "Upgrade to an archive plan add-on for your account. Max height of block allowed on archive for your current plan: 128",
  "code": -32005
}

I would appreciate it if you could explain the reason and solution to me.

1 Answer 1

1

This is an RPC limit error. This means whatever product you are using is not allowing you access to the blockchain.

Explanation: RPC providers basically run their nodes and provide API to us, so that we can interact with the blockchain without running our own node.

Solution : Either you upgrade your plan on whatever provider you are using, or use a different one. There are many free providers. Like Alchemy, Quicknode etc.

1
  • Thank you, I actually used the firefox console to do it and it has this problem, and the video tutorial worked out the same way.
    – Mehran Ra
    Commented Sep 4, 2023 at 16:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.