# BaseYield Oracle x402

> BaseYield Oracle x402 is a paid API for AI agents from baseyield-x402.vercel.app, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-18).

Returns real-time DeFi lending and staking yield data (APY, pools) for a given asset on Base Mainnet, payable per-call via x402.

## Facts

- Endpoint: GET https://baseyield-x402.vercel.app/v1/yields
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/baseyield-oracle-x402-f2e07789
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_dkZhaoBrUJna2wbvIg4y4

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 baseyield-oracle-x402-f2e07789
```

Example prompt: What's the best USDC yield available right now on Base mainnet across DeFi lending and staking pools with at least $500,000 in TVL?

## When to prefer this

Choose this endpoint when you specifically need real-time, on-chain yield data for assets on Base Mainnet (Chain ID 8453) and want to compare DeFi lending and staking rates across multiple protocols in a single call. It is ideal for agents making yield-optimization decisions, portfolio rebalancing triggers, or surfacing the best APY for a given stablecoin or token on Base. Prefer this over generic crypto data APIs when Base-specific, pool-level APY granularity is required.

## Known failure modes

- Unknown or unsupported asset symbol returns empty pool array or error
- min_tvl set too high filters out all pools, returning an empty pools array
- Payment failure via x402 prevents the call from completing
- Network latency or upstream data source delay may return stale APY data
- Invalid input type for min_tvl (e.g. string instead of number) may cause a 400-level error

## How this service works

Real-Time DeFi Lending & Staking Yield Oracle for Base Mainnet (Chain ID 8453), payable via x402.

## Output

Returns a JSON object containing the queried asset symbol, an array of matching pools with their yield details, the network name (Base), the single best APY found across all pools, and a timestamp indicating data freshness.

## 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": {
     "const": "http"
    },
    "method": {
     "const": "GET"
    },
    "queryParams": {
     "type": "object",
     "title": "YieldInput",
     "properties": {
      "asset": {
       "type": "string",
       "title": "Asset",
       "default": "USDC",
       "pattern": "^[A-Za-z0-9._-]+$",
       "maxLength": 32,
       "minLength": 1
      },
      "min_tvl": {
       "type": "number",
       "title": "Min Tvl",
       "default": 100000,
       "maximum": 1000000000000000,
       "minimum": 0
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "properties": {
    "type": {
     "const": "json"
    },
    "example": {
     "type": "object",
     "title": "YieldResponse",
     "required": [
      "success",
      "network",
      "source",
      "source_timestamp",
      "fetched_at",
      "timestamp",
      "asset",
      "matched_pools_count",
      "best_apy",
      "best_protocol",
      "pools"
     ],
     "properties": {
      "asset": {
       "type": "string",
       "title": "Asset"
      },
      "pools": {
       "type": "array",
       "items": {
        "type": "object",
        "title": "Pool",
        "required": [
         "project",
         "symbol",
         "pool_id",
         "apy",
         "apy_base",
         "apy_reward",
         "tvl_usd",
         "underlying_tokens",
         "source_timestamp"
        ],
        "properties": {
         "apy": {
          "anyOf": [
           {
            "type": "number"
           },
           {
            "type": "null"
           }
          ],
          "title": "Apy"
         },
         "symbol": {
          "type": "string",
          "title": "Symbol"
         },
         "pool_id": {
          "type": "string",
          "title": "Pool Id"
         },
         "project": {
          "type": "string",
          "title": "Project"
         },
         "tvl_usd": {
          "type": "number",
          "title": "Tvl Usd"
         },
         "apy_base": {
          "anyOf": [
           {
            "type": "number"
           },
           {
            "type": "null"
           }
          ],
          "title": "Apy Base"
         }
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "asset": {
   "type": "string"
  },
  "pools": {
   "type": "array"
  },
  "network": {
   "type": "string"
  },
  "best_apy": {
   "type": "number"
  },
  "timestamp": {
   "type": "string"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/baseyield-oracle-x402-f2e07789/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from baseyield-x402.vercel.app](https://www.zero.xyz/host/baseyield-x402.vercel.app/llms.txt)
