# DEBYKO Crypto Perpetuals OHLCV Candles

> DEBYKO Crypto Perpetuals OHLCV Candles is a paid API for AI agents from api.debyko.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-16).

Returns completed OHLCV candle data for crypto perpetual markets across multiple venues, built from stored trades, with timeframes from 1-minute to 1-day.

## Facts

- Endpoint: POST https://api.debyko.com/v2/candles?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/debyko-crypto-perpetuals-ohlcv-candles-c2ff309b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_K5K-4QA1qP9arJvRfR0F2

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 debyko-crypto-perpetuals-ohlcv-candles-c2ff309b -d '<json body>'
```

Example prompt: Pull 1-hour trade-price candles for BTC perpetuals on Binance from 2024-01-01T00:00:00Z to 2024-01-07T00:00:00Z, closed candles only, with volumes in quote units.

## When to prefer this

Use this endpoint when you need historical OHLCV candlestick data specifically for crypto perpetual/swap markets (not spot), aggregated from actual stored trades, across multiple venues simultaneously. It is the right choice when you need flexible timeframes (1m to 1d), multiple price types (trade, mark, index), or venue-level granularity for derivatives analytics, backtesting, or strategy research. Prefer this over generic market data APIs when you need perpetuals-specific data (mark price, index price) or cross-venue comparison in a single call.

## Known failure modes

- Invalid datetime format in 'from' or 'to' fields — must match ISO 8601 pattern with Z suffix
- Unsupported timeframe string causing a 400 error
- No data available for the requested symbol/venue combination in the given date range
- Payment failure via x402 protocol resulting in 402 response
- Requesting future candles that are not yet closed
- Invalid 'where' filter causing query rejection

## How this service works

OHLCV candles for crypto perpetual futures, 1m to 1d, on trade price (mark and index where the venue publishes them), across 19 venues (Aster Perpetuals, Avantis, Binance USD-M Futures, Bitget Perpetual Futures, Bybit Perpetuals, Coinbase Global Derivatives, Coinbase — legacy API, migrated and 12 more). Built from venue 1-minute klines; periods with no data come back as gap rows, not interpolated. DQL filter, timeframe, from, to. No charge when no candle is returned. 0.005 USDC per call.

## Output

An array of completed OHLCV candle objects per requested timeframe and venue, each containing open, high, low, close, and volume values (in the requested units), along with the candle's timestamp. Data is derived from stored trades and may include synthetic candles if enabled. Gaps can be included or excluded based on the include_gaps flag.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "to": {
   "type": "string",
   "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\\.[0-9]{3})?Z$",
   "description": "End of the window, UTC, e.g. 2026-10-01T06:00:00Z."
  },
  "from": {
   "type": "string",
   "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\\.[0-9]{3})?Z$",
   "description": "Start of the window, UTC, e.g. 2026-10-01T00:00:00Z."
  },
  "kind": {
   "enum": [
    "perpetual",
    "spot",
    "all"
   ],
   "type": "string",
   "default": "perpetual"
  },
  "as_of": {
   "type": "string",
   "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}(\\.[0-9]{3})?Z$"
  },
  "trade": {
   "type": "boolean"
  },
  "units": {
   "enum": [
    "published",
    "base"
   ],
   "type": "string",
   "default": "published"
  },
  "where": {
   "oneOf": [
    {
     "type": "string"
    },
    {
     "type": "object"
    }
   ],
   "description": "DQL selection of the markets to read, e.g. base in (BTC) or venue = HYPERLIQUID and base = BTC."
  },
  "timeframe": {
   "type": "string",
   "description": "Candle period, e.g. 1m, 15m, 1h or 1d; GET /v2/dql/catalogue lists them."
  },
  "price_type": {
   "enum": [
    "trade",
    "mark",
    "index"
   ],
   "type": "string",
   "default": "trade",
   "description": "trade (default), mark or index."
  },
  "closed_only": {
   "type": "boolean",
   "default": true
  },
  "include_gaps": {
   "type": "boolean",
   "default": true,
   "description": "true (default) keeps periods with no candle as gap rows."
  },
  "number_format": {
   "enum": [
    "json",
    "string"
   ],
   "type": "string",
   "default": "json"
  },
  "include_synthetic": {
   "type": "boolean",
   "default": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/debyko-crypto-perpetuals-ohlcv-candles-c2ff309b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.debyko.com](https://www.zero.xyz/host/api.debyko.com/llms.txt)
