# Crypto OHLCV Candles with Precomputed Indicators

> Crypto OHLCV Candles with Precomputed Indicators is a paid API for AI agents from kr-x402-mvp.kgy5612.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-31).

Fetches OHLCV candlestick data for major USDT crypto pairs with precomputed EMA, RSI, ATR, trend, and pullback zone indicators so trading agents skip manual math.

## Facts

- Endpoint: GET https://kr-x402-mvp.kgy5612.workers.dev/crypto/candles?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/crypto-ohlcv-candles-with-precomputed-indicators-93715f5b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_mYhPXfAzH_kbXO70u_xDz

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 crypto-ohlcv-candles-with-precomputed-indicators-93715f5b
```

Example prompt: Pull the last 100 one-hour candles for BTC and tell me if it's in an uptrend and whether price is currently in the EMA20 pullback zone — I need RSI and ATR too before I decide on an entry.

## When to prefer this

Choose this endpoint when your trading or onchain agent needs candlestick data AND technical indicators in a single call without running its own math. It eliminates the need to separately fetch OHLCV data and compute EMA, RSI, or ATR. It is well-suited for agent loops that make trade decisions based on trend, momentum, and volatility signals. Prefer it over raw exchange APIs when you want precomputed pullback zone detection and trend classification out of the box.

## Known failure modes

- Unsupported symbol returns an error or empty candles
- Invalid interval value rejected by schema validation
- Limit outside 10-500 range rejected
- Payment not provided or insufficient USDC triggers 402 response
- Binance data source temporarily unavailable causing upstream errors
- Network timeout on Cloudflare Worker edge

## How this service works

OHLCV candlesticks (klines) for any major USDT pair with indicators precomputed, so your trading agent skips the math: symbol=BTC|ETH|SOL|BNB|XRP|DOGE|ADA|AVAX|LINK|SUI|... (or BTCUSDT), interval=1m|5m|15m|1h|4h|1d (default 1h), limit=10-500 (default 100). Returns candles [{t,o,h,l,c,v}] oldest->newest plus last close, change_pct over the window, EMA20, EMA50, RSI14, ATR14 (abs + pct), trend up|down|range, and a pullback zone EMA20 +/- 0.75*ATR (in_zone true/false).

## Output

Returns an array of OHLCV candles (oldest to newest) with timestamps, plus a summary object containing: last close price, window change percent, EMA20, EMA50, RSI14, ATR14 (absolute and as percent of price), current trend classification (up/down/range), and a pullback zone defined as EMA20 ± 0.75×ATR14 with an in_zone boolean indicating if the current price is within the zone. All indicators are precomputed server-side from Binance data.

## 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"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "limit": {
       "type": "integer",
       "maximum": 500,
       "minimum": 10,
       "description": "Number of candles (default 100)"
      },
      "symbol": {
       "type": "string",
       "examples": [
        "BTC",
        "ETH",
        "SOLUSDT"
       ],
       "description": "Base asset or pair (default BTC); quote is USDT"
      },
      "interval": {
       "enum": [
        "1m",
        "5m",
        "15m",
        "1h",
        "4h",
        "1d"
       ],
       "type": "string",
       "description": "Candle size (default 1h)"
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "n": 100,
  "last": 80436.6,
  "source": "binance",
  "symbol": "BTCUSDT",
  "candles": [
   {
    "c": 80305.21,
    "h": 80418.67,
    "l": 79916,
    "o": 80058.01,
    "t": "2026-10-29T13:00:00Z",
    "v": 792.98
   }
  ],
  "interval": "1h",
  "change_pct": 1.8,
  "indicators": {
   "zone": {
    "low": 79900.9,
    "high": 80519.9,
    "in_zone": true
   },
   "atr14": 412.7,
   "ema20": 80210.4,
   "ema50": 79880.1,
   "rsi14": 58.3,
   "trend": "up",
   "atr14_pct": 0.51
  },
  "updated_at": "2026-10-29T14:20:00Z"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/crypto-ohlcv-candles-with-precomputed-indicators-93715f5b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from kr-x402-mvp.kgy5612.workers.dev](https://www.zero.xyz/host/kr-x402-mvp.kgy5612.workers.dev/llms.txt)
