# AgentFeed ERC20 & ETH Wallet Balance (Base / Ethereum)

> AgentFeed ERC20 & ETH Wallet Balance (Base / Ethereum) is a paid API for AI agents from x402.ochinimus.app, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-01).

Returns the token or native ETH balance for a wallet address or ENS name on Base or Ethereum mainnet, with decimals and symbol read live from the contract.

## Facts

- Endpoint: GET https://x402.ochinimus.app/api/base-balance?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agentfeed-erc20-eth-wallet-balance-base-ethereum-1f4b2752
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_dm65PwGYKuUnVfANG9q3S

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 agentfeed-erc20-eth-wallet-balance-base-ethereum-1f4b2752
```

Example prompt: What's the USDC balance for vitalik.eth on Ethereum mainnet right now?

## When to prefer this

Use this endpoint when you need a precise, correctly-scaled token or ETH balance for a specific wallet on Base or Ethereum mainnet — especially when the token might not use 18 decimals (e.g. USDC uses 6). It reads decimals() and symbol() live from the contract, avoiding the common bug of reporting balances 10^12 times too large. Prefer it over generic RPC calls when you want a clean, agent-ready numeric result without handling raw wei conversion yourself.

## Known failure modes

- Invalid or malformed 0x address returns an error
- ENS name not found or not resolved returns an error
- Unknown or unsupported token ticker returns an error
- ERC20 contract address on wrong chain returns zero or an error
- Network timeout when querying on-chain contract
- Unsupported chain value (only 'base' and 'ethereum' are valid)

## How this service works

ERC20 and native ETH wallet balance on Base or Ethereum mainnet, for a 0x address or an ENS name. decimals() and symbol() are read from the contract at request time rather than assumed, because assuming 18 reports a USDC balance a trillion times too large. Use when you need to answer: What does this EVM address hold? ENS is resolved through two independent resolvers and the answer is used only…

## Output

A JSON object containing the human-readable balance as a number, the raw balance in wei as a string, the token symbol, the asset name, the chain name, the chain ID, and the resolved wallet address. Decimals and symbol are fetched live from the contract so the value is always correctly scaled.

## 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": {
       "type": "string",
       "description": "base (default) or ethereum"
      },
      "token": {
       "type": "string",
       "description": "ERC20 contract address, or a known ticker: USDC, WETH, DAI, CBBTC, USDBC, CBETH, AERO, EURC. Omit for the native ETH balance"
      },
      "address": {
       "type": "string",
       "description": "0x address (40 hex) or an ENS name ending .eth"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "data": {
       "type": "object",
       "properties": {
        "asset": {
         "type": "string"
        },
        "chain": {
         "type": "string"
        },
        "source": {
         "type": "string"
        },
        "address": {
         "type": "string"
        },
        "balance": {
         "type": "number"
        },
        "chain_id": {
         "type": "number"
        },
        "balance_wei": {
         "type": "string"
        }
       }
      },
      "paid": {
       "type": "boolean"
      },
      "tool": {
       "type": "string"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {
   "asset": "ETH",
   "chain": "Base",
   "source": "rpc:mainnet.base.org",
   "address": "0x22DB3A9686EE5261e7Bf3ed4f91277232E8076e6",
   "balance": 0.000094829,
   "chain_id": 8453,
   "balance_wei": "94829352850506"
  },
  "paid": true,
  "tool": "get_base_balance"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agentfeed-erc20-eth-wallet-balance-base-ethereum-1f4b2752/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.ochinimus.app](https://www.zero.xyz/host/x402.ochinimus.app/llms.txt)
