# Base Address Contract Checker

> Base Address Contract Checker is a paid API for AI agents from x402-data-api.sigrunner.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-20).

Determines whether a Base mainnet address is a smart contract or an externally owned account (EOA), returning a boolean flag and bytecode size.

## Facts

- Endpoint: GET https://x402-data-api.sigrunner.workers.dev/chain/is-contract?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-20
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/base-address-contract-checker-3a3a359f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_UnabsS7XOF9OoQzAUYkwD

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 base-address-contract-checker-3a3a359f
```

Example prompt: Before I send funds to 0x4200000000000000000000000000000000000006 on Base, can you check whether it's a smart contract or a regular wallet address?

## When to prefer this

Use this endpoint when an agent needs to make a binary contract-vs-EOA determination on a Base mainnet address before executing a financial operation such as sending funds, approving token allowances, or whitelisting recipients. It is more lightweight than full contract ABI fetching and purpose-built for the Base chain. Prefer it over generic Ethereum explorers when operating within a Base-native agent workflow that already handles x402 micropayments.

## Known failure modes

- Missing or malformed address parameter — no query param provided or not a valid 0x-prefixed 20-byte hex string
- Address not found / zero-address edge cases returning ambiguous results
- Network or RPC errors on Base mainnet causing lookup failure
- Payment failure (x402 USDC payment not fulfilled) resulting in 402 response
- Rate limiting or infrastructure errors returning 5xx responses

## How this service works

Is a Base address a smart contract or an EOA? Returns is_contract and bytecode size. Use when an agent must decide whether a recipient is a contract before sending funds or approving it.

## Output

Returns a JSON object with the queried address, a boolean is_contract field (true if bytecode is present), an integer code_bytes indicating bytecode size, and the chain identifier ('base'). An EOA will have code_bytes of 0 and is_contract of false; a deployed contract will have code_bytes > 0 and is_contract of true.

## 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",
     "properties": {
      "address": {
       "type": "string",
       "description": "0x-prefixed 20-byte Base address"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "address",
      "is_contract",
      "code_bytes",
      "chain"
     ],
     "properties": {
      "chain": {
       "type": "string"
      },
      "address": {
       "type": "string"
      },
      "code_bytes": {
       "type": "integer"
      },
      "is_contract": {
       "type": "boolean"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "chain": "base",
  "address": "0x4200000000000000000000000000000000000006",
  "code_bytes": 2000,
  "is_contract": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/base-address-contract-checker-3a3a359f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-data-api.sigrunner.workers.dev](https://www.zero.xyz/host/x402-data-api.sigrunner.workers.dev/llms.txt)
