# AgentIndex x402 Live Crypto Prices

> AgentIndex x402 Live Crypto Prices is a paid API for AI agents from x402.agentindex.world, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-02).

Fetches real-time cryptocurrency prices and 24-hour percentage changes for up to 20 coins in a specified fiat currency

## Facts

- Endpoint: GET https://x402.agentindex.world/crypto?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agentindex-x402-live-crypto-prices-fe9c982c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_1f1of5cr4krLAhI9AhJCj

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 agentindex-x402-live-crypto-prices-fe9c982c
```

Example prompt: What are the current prices of Bitcoin, Ethereum, and Solana in USD, and how much have they moved in the last 24 hours?

## When to prefer this

Choose this endpoint when you need live cryptocurrency prices and 24h change data for up to 20 coins simultaneously, paid per-call in USDC on Base via x402. It is ideal for AI agents that need real-time market data without a subscription, especially for DeFi workflows, portfolio monitoring, or any use case requiring trustless, pay-per-use pricing. Prefer this over subscription APIs when usage is sporadic or when the agent must autonomously pay for data access on-chain.

## Known failure modes

- Unknown coin ticker or CoinGecko ID returns an error or omits the coin from results
- Requesting more than 20 coins returns a validation error
- Unsupported vs_currency value may return an error or fall back to USD
- Payment insufficient or missing triggers a 402 response requiring USDC payment on Base
- Network or upstream CoinGecko outage may return a 5xx error

## How this service works

Live spot prices for crypto coins (BTC, ETH, SOL, ...) in USD or another fiat, with 24h change. Accepts tickers or CoinGecko ids. Try GET /crypto/sample.

## Output

A JSON object containing a list of coin objects each with their CoinGecko ID, ticker symbol, current price in the requested fiat currency, and 24-hour percentage price change. Also includes the quote currency used and an x402 payment receipt.

## 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",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "coins"
     ],
     "properties": {
      "coins": {
       "oneOf": [
        {
         "type": "string"
        },
        {
         "type": "array",
         "items": {
          "type": "string"
         },
         "maxItems": 20,
         "minItems": 1
        }
       ],
       "description": "Coin tickers (btc, eth, sol) and/or CoinGecko ids. String, comma-separated string, or array. Up to 20."
      },
      "vs_currency": {
       "type": "string",
       "description": "Fiat quote currency, default usd (also eur, gbp, ...)."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "vs_currency",
      "prices"
     ],
     "properties": {
      "prices": {
       "type": "array",
       "items": {
        "type": "object",
        "properties": {
         "id": {
          "type": "string"
         },
         "price": {
          "type": "number"
         },
         "symbol": {
          "type": "string"
         },
         "change_24h_pct": {
          "type": "number"
         }
        }
       }
      },
      "vs_currency": {
       "type": "string"
      },
      "x402_receipt": {
       "type": "object"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "prices": [
   {
    "id": "bitcoin",
    "price": 81218,
    "symbol": "btc",
    "change_24h_pct": -1.2
   },
   {
    "id": "ethereum",
    "price": 2634.1,
    "symbol": "eth",
    "change_24h_pct": 0.4
   }
  ],
  "vs_currency": "usd"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agentindex-x402-live-crypto-prices-fe9c982c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.agentindex.world](https://www.zero.xyz/host/x402.agentindex.world/llms.txt)
