# EVM Address Contract Detection

> EVM Address Contract Detection is a paid API for AI agents from apexfaucet.xyz, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-18).

Checks whether an Ethereum-compatible address is a smart contract (vs. EOA) on Ethereum, Base, Arc, or BNB Chain, returning code size, proxy implementation addresses, and EIP-7702 delegation info.

## Facts

- Endpoint: GET https://apexfaucet.xyz/api/x402/evm-code?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/evm-address-contract-detection-26de7bff
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_c6Rk-2q8ehD7M2Sy2dRVP

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 evm-address-contract-detection-26de7bff
```

Example prompt: Can you check whether 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 on Base is a smart contract or a regular wallet, and tell me if it's a proxy pointing to an implementation?

## When to prefer this

Use this endpoint when you need a fast, paid, multi-chain check of whether an address is a smart contract versus an EOA, especially when you also need proxy implementation addresses (EIP-1967, ZeppelinOS) or EIP-7702 delegation targets. Prefer this over free block explorers when you need programmatic, structured output without scraping, or when checking addresses on Arc chain which may not be indexed elsewhere.

## Known failure modes

- Invalid address format (not matching 0x + 40 hex chars) returns validation error
- Unsupported chain name returns enum error
- Network RPC unavailability may cause timeout or error response
- Address that is valid but not yet indexed may return stale block data
- Payment failure returns 402 before any data is returned

## How this service works

Free APEX on X1, and free USDC plus APEX on Arc, three times a day. No gas, no sign-up. Plus a swap, a screener, APEX City and token checks.

## Output

A JSON object containing: isContract (boolean), codeSize (bytes of deployed bytecode), the chain and block number at which the check was made, block timestamp, an eip7702DelegatesTo field (address or null), an eip1967Implementation field for EIP-1967 proxies, and a zeppelinosImplementation field for OpenZeppelin proxy patterns.

## 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",
    "queryParams"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "address"
     ],
     "properties": {
      "chain": {
       "enum": [
        "ethereum",
        "base",
        "arc",
        "bnb"
       ],
       "type": "string",
       "description": "Chain to read: ethereum, base, arc or bnb. Default ethereum."
      },
      "address": {
       "type": "string",
       "pattern": "^0x[0-9a-fA-F]{40}$",
       "description": "Address to inspect."
      }
     }
    }
   }
  },
  "output": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "schema": {
  "type": "object",
  "properties": {
   "ok": {
    "type": "boolean"
   },
   "data": {
    "type": "object"
   },
   "paid": {
    "type": "number"
   }
  }
 },
 "example": {
  "ok": true,
  "data": {
   "ok": true,
   "block": 52559423,
   "chain": "base",
   "address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
   "codeSize": 1852,
   "blockTime": "2026-10-13T16:16:33.000Z",
   "isContract": true,
   "eip7702DelegatesTo": null,
   "eip1967Implementation": null,
   "zeppelinosImplementation": "0x2Ce6311ddAE708829bc0784C967b7d77D19FD779"
  },
  "paid": 0.001
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/evm-address-contract-detection-26de7bff/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from apexfaucet.xyz](https://www.zero.xyz/host/apexfaucet.xyz/llms.txt)
