# ScrapeMole Onchain Balances

> ScrapeMole Onchain Balances is a paid API for AI agents from onchain.scrapemole.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-12).

Returns native ETH and ERC-20 token balances with USD values for a wallet address on Base or Ethereum

## Facts

- Endpoint: GET https://onchain.scrapemole.workers.dev/v1/balances?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/scrapemole-onchain-balances-bb6f00ee
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_SZbLPxKSLNH7r1gxS-JjJ

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability scrapemole-onchain-balances-bb6f00ee
```

Example prompt: What are the current token balances and total USD value for wallet 0x4200000000000000000000000000000000000006 on Base, including ETH and the major tokens?

## When to prefer this

Use this endpoint when you need real-time, on-chain wallet balance data for Base or Ethereum with USD valuations included — especially when you need multiple token balances in one call. Prefer over block explorer scraping or DEX APIs when you need canonical ERC-20 balances with USD prices attached. The pay-per-call model (no subscription) and free-on-failure guarantee make it low-risk for agent workflows.

## Known failure modes

- Invalid or malformed wallet address returns an error (call not charged)
- Unsupported chain value returns validation error
- Token symbol not in default list and no address provided may result in token not found
- Network/RPC timeout may return 5xx error (call not charged)
- More than 20 tokens requested returns a validation error

## How this service works

Pay-per-call on-chain data for agents on Base and Ethereum, read directly from chain state: Chainlink USD prices (crypto, stablecoins, FX, metals; 10 per call), ERC-20 token info, wallet balances with USD values, transaction lookup with decoded ERC-20 transfers, ENS and Basename resolution (forward and reverse), gas and fee estimates in USD, and Uniswap v3 DEX prices for long-tail tokens (verify a payment arrived). USDC via x402; failed calls are never charged.

Payments: x402 v2, scheme "exact", USDC on Base (eip155:8453). The payment is verified before the work and settled only when the response is 200. Terms: https://onchain.scrapemole.workers.dev/terms

## Output

A JSON object with the queried address, chain, native ETH balance (with symbol, amount, USD price, and USD value), an array of ERC-20 token balances (symbol, contract address, decimals, balance, USD price, USD value), total portfolio value in USD, number of tokens checked, and the block number at which the data was read.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "address"
     ],
     "properties": {
      "chain": {
       "enum": [
        "base",
        "ethereum"
       ],
       "type": "string",
       "default": "base",
       "description": "Chain."
      },
      "tokens": {
       "type": "string",
       "description": "Comma-separated token symbols (from the default list) or 0x token addresses, max 20. Default: major tokens of the chain."
      },
      "address": {
       "type": "string",
       "examples": [
        "0x4200000000000000000000000000000000000006"
       ],
       "description": "Wallet or contract address (0x…)."
      },
      "includeZero": {
       "type": "string",
       "default": "false",
       "description": "Also list zero balances (true/false)."
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "chain": "base",
  "native": {
   "symbol": "ETH",
   "balance": "1.2345",
   "priceUsd": 3912.45,
   "valueUsd": 4829.92
  },
  "tokens": [
   {
    "symbol": "USDC",
    "address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "balance": "250.5",
    "decimals": 6,
    "priceUsd": 1,
    "valueUsd": 250.5
   }
  ],
  "address": "0x…",
  "totalUsd": 5080.42,
  "blockNumber": 36500000,
  "checkedTokens": 9
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/scrapemole-onchain-balances-bb6f00ee/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from onchain.scrapemole.workers.dev](https://www.zero.xyz/host/onchain.scrapemole.workers.dev/llms.txt)
