Agent402 / tools / chain-storage

Contract storage slot

$0.001 per call · USDC via x402 · GET /api/chain/storage

Read one 32-byte storage slot from a contract, the raw state under whatever the source code calls it. Returns the word as hex plus three readings of the same bytes - unsigned integer, address (low 20 bytes) and boolean - because a slot is untyped on chain and only the caller knows which it meant. Useful for proxy implementation slots, paused flags and any value the ABI does not expose. EVM chains: ethereum, base, polygon, arbitrum, optimism.

TRY IN PLAYGROUND →

Input

FieldTypeDescription
address *string0x contract address
slot *stringSlot index: a decimal number or a 0x-prefixed hex key (EIP-1967 implementation slot is 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc)
networkstringethereum | base | polygon | arbitrum | optimism (default base)
blockstringlatest (default), pending, earliest, safe, finalized, or a block number

Example output

{
  "address": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
  "network": "base",
  "slot": "0x0",
  "block": "latest",
  "value": "0x0000000000000000000000000000000000000000000000000000000000000001",
  "asUint": "1",
  "asAddress": "0x0000000000000000000000000000000000000001",
  "asBool": true
}

Try it - see the 402 challenge (free)

curl -i "https://agent402.tools/api/chain/storage?address=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913&slot=0x0&network=base"

The response is HTTP 402 Payment Required with exact payment requirements. Any x402 v2 client pays automatically and retries:

Paid call (JavaScript agent)

import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
import { metaTitle, metaDescription } from "./seo-meta.js";

const client = new x402Client();
registerExactEvmScheme(client, { signer: privateKeyToAccount(KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);

const res = await payFetch("https://agent402.tools/api/chain/storage?address=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913&slot=0x0&network=base");
Wallet-only. This tool reaches the network/browser/storage, so it is paid in USDC via x402 (no proof-of-work tier).

Related tools

Crypto order book

$0.001 · GET /api/crypto-orderbook

L2 order-book snapshot for a spot pair: best bid/ask, mid price, spread (absolute + %), and the top N aggregated price l…

try in playground →

Stablecoin peg monitor

$0.003 · GET /api/stablecoin-peg

Live $1-peg deviation for the top USD stablecoins (USDT, USDC, USDS, DAI, USDe, PYUSD, USDD, TUSD, FDUSD by default, or …

try in playground →

Wallet balance (native + ERC-20)

$0.002 · POST /api/wallet-balance

Look up the native coin balance (ETH/MATIC) plus every ERC-20 holding for a wallet address on Ethereum, Base, Polygon, A…

try in playground →