# Carbon & Cashmere Oracle Divergence API — BTC

> Carbon & Cashmere Oracle Divergence API — BTC is a paid API for AI agents from api.carbon-cashmere.de, paid per call via x402, $0.03/call, status down (last checked 2026-09-14).

Returns real-time oracle price divergence statistics between Pyth and CoinGecko for BTC, including spread percentiles, exceedance events, and latest price comparison.

## Facts

- Endpoint: GET https://api.carbon-cashmere.de/v1/oracle-divergence/BTC
- Price: $0.03/call
- Payment: x402
- Status: down
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/carbon-cashmere-oracle-divergence-api-btc-c14f004b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_iyZO4uCmfgn_CcSHqR0R7

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 carbon-cashmere-oracle-divergence-api-btc-c14f004b
```

Example prompt: Show me the oracle price divergence for BTC over the last 60 minutes — I want to see the spread between Pyth and CoinGecko, including any exceedance events and the p25/p75 spread percentiles.

## When to prefer this

Use this endpoint when you need to compare Pyth on-chain oracle prices against CoinGecko off-chain prices for BTC specifically, detect arbitrage opportunities from oracle divergence, assess oracle reliability, or monitor for anomalous price spreads in real time. Prefer this over generic price endpoints when the divergence between data sources — not just the price itself — is what matters.

## Known failure modes

- Unsupported coin symbol returns 404 or empty result
- Lookback window too large may return timeout or limited data
- Payment not attached or insufficient USDC results in 402 Payment Required
- Pyth or CoinGecko data feed temporarily unavailable causes stale or missing latest price
- Threshold parameter out of valid range returns 400 Bad Request

## How this service works

Professional crypto market intelligence. Real-time prices, signals, and market scoring.

## Output

A JSON object containing: the coin symbol, spread statistics (sample count, p25/p75/median/abs_max/abs_p95 spread percentages, exceedance rate and count), a list of individual divergence events with timestamps, direction, Pyth price, CoinGecko price, spread %, and Pyth confidence, plus the latest price snapshot from both oracles with timestamp and spread.

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "coin": "BTC",
  "stats": {
   "samples": 12,
   "spread_pct": {
    "p25": -0.082,
    "p75": 0.047,
    "median": -0.024,
    "abs_max": 0.6532,
    "abs_p95": 0.5071
   },
   "exceedance_rate": 0.333,
   "exceeded_threshold": 4
  },
  "events": [
   {
    "ts": "2026-05-09T20:43:23Z",
    "direction": "pyth_lower",
    "pyth_price": 0.42316693,
    "spread_pct": -0.6532,
    "coingecko_price": 0.425931,
    "pyth_confidence": 0.000414
   }
  ],
  "filter": {
   "threshold_pct": 0.001,
   "lookback_minutes": 60
  },
  "latest": {
   "ts": "2026-05-09T20:48:23Z",
   "pyth_price": 80781.71,
   "spread_pct": -0.0227,
   "coingecko_price": 80800
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/carbon-cashmere-oracle-divergence-api-btc-c14f004b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.carbon-cashmere.de](https://www.zero.xyz/host/api.carbon-cashmere.de/llms.txt)
