# x402 Bazaar — Basename Resolution (Base L2)

> x402 Bazaar — Basename Resolution (Base L2) is a paid API for AI agents from api.relai.fi, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Resolves Base ENS names (Basenames) to Ethereum addresses and reverse-resolves addresses to their primary Basename, reading directly from the Base L2 Resolver.

## Facts

- Endpoint: POST https://api.relai.fi/relay/1782567677091/api/x402/basename
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x402-bazaar-basename-resolution-base-l2-98dae919
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_sxkgKR5B3x1FsM9mbejLt

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 x402-bazaar-basename-resolution-base-l2-98dae919 -d '<json body>'
```

Example prompt: What Ethereum address does jesse.base.eth resolve to on Base? And while you're at it, can you also reverse-lookup 0x329a7f8b91Ce7479035cb1B5D62AB41845830Ce8 to find its primary Basename?

## When to prefer this

Use this endpoint when you need on-chain, authoritative Basename resolution on Base L2 without an API key, and are comfortable with the x402 micropayment flow. Prefer it over general-purpose ENS resolvers when working specifically with Basenames (*.base.eth) rather than mainnet ENS names.

## Known failure modes

- Unregistered Basename returns null or not-found response
- Address has no primary Basename set — returns empty result
- 402 Payment Required returned if x402 micropayment not included — must pay $0.005 USDC on Base and retry
- Invalid address format or malformed Basename causes 400 bad request
- Network issues with Base L2 RPC cause resolution timeout

## How this service works

Forward + reverse Basename resolution read from the Base L2 Resolver: turn jesse.base.eth into an address, or an address into its primary Basename. No API key required. Paid via x402: $0.005 in USDC on Base (eip155:8453) to 0x973a31858f4d2125f48c880542da11a2796f12d6. Returns 402 with payment requirements; pay and retry.

## Output

Returns either the resolved Ethereum address for a given Basename, or the primary Basename for a given Ethereum address, as read from the Base L2 Resolver contract.

## 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"
    },
    "pathParams": {
     "type": "object"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "query"
     ],
     "properties": {
      "query": {
       "type": "string",
       "description": "Basename or address"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x402-bazaar-basename-resolution-base-l2-98dae919/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.relai.fi](https://www.zero.xyz/host/api.relai.fi/llms.txt)
