# Crypto Wallet Balance & Gas Checker (Base) via x402

> Crypto Wallet Balance & Gas Checker (Base) via x402 is a paid API for AI agents from kr-x402-mvp.kgy5612.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-31).

Returns ETH balance, USDC balance, nonce, and gas-affordability flags for a given Base wallet address, payable per-call in USDC via x402.

## Facts

- Endpoint: GET https://kr-x402-mvp.kgy5612.workers.dev/crypto/wallet?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/crypto-wallet-balance-gas-checker-base-via-x402-a85cdc61
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_UNHvmbWuAoVanKQnmvlsc

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 crypto-wallet-balance-gas-checker-base-via-x402-a85cdc61
```

Example prompt: Before sending that USDC payment, check if my wallet 0xe4be4d0bd82d8e68203deff81f79ede0529f2617 on Base has enough ETH for gas and enough USDC to cover an x402 micropayment.

## When to prefer this

Use this endpoint when your agent needs a quick, no-API-key balance and gas-feasibility check for any Base wallet before executing a transaction or x402 payment. Prefer this over general blockchain explorers when you need structured, machine-readable output with pre-computed affordability flags (can_pay_gas, can_pay_x402) rather than raw RPC data. Ideal for autonomous trading or payment agents that need to gate actions on wallet solvency.

## Known failure modes

- Invalid wallet address format (not matching ^0x[0-9a-fA-F]{40}$) returns a 400/422 error
- Payment not received or x402 handshake failure returns 402 Payment Required
- RPC backend timeout or Base network outage may cause 503 or timeout
- Wallet with zero activity still returns valid response but with eth=0, usdc=0, nonce=0
- Missing 'wallet' query param returns a 400 Bad Request

## How this service works

Pay-per-call crypto microdata for trading/onchain AI agents via x402 (USDC on Base): Base gas, token risk, balances, multi-venue prices, Hyperliquid book/funding, kimchi premium. No API keys.

## Output

Returns a JSON object with: ETH balance (float), USDC balance (float), chain name ('base'), transaction nonce (int), boolean can_pay_gas (whether ETH covers a typical ERC-20 transfer), boolean can_pay_x402 (whether USDC balance covers a $0.003 micropayment), and gas_cost_erc20_transfer_eth (estimated ETH cost of one ERC-20 transfer).

## 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": [
      "wallet"
     ],
     "properties": {
      "wallet": {
       "type": "string",
       "pattern": "^0x[0-9a-fA-F]{40}$",
       "examples": [
        "0xe4be4d0bd82d8e68203deff81f79ede0529f2617"
       ],
       "description": "Wallet"
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "eth": 0,
  "usdc": 0.079,
  "chain": "base",
  "nonce": 0,
  "wallet": "0xe4be4d0bd82d8e68203deff81f79ede0529f2617",
  "can_pay_gas": false,
  "can_pay_x402": true,
  "gas_cost_erc20_transfer_eth": 4e-7
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/crypto-wallet-balance-gas-checker-base-via-x402-a85cdc61/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from kr-x402-mvp.kgy5612.workers.dev](https://www.zero.xyz/host/kr-x402-mvp.kgy5612.workers.dev/llms.txt)
