66trust / 100

Perps Candles

by Aayat AI in Onchain & crypto

x402 APIFailing, checked 2 h ago

OHLCV candles for a perpetual futures market on Hyperliquid or dYdX (1m to 1d, up to 500), with a summary: change, high/low, USD volume and annualised realised volatility. Pass ?coin=ETH&interval=1h&limit=24 (&venue=dydx).

GET https://aayatai.com/perps/candles

Last 30 days

All checks passedSome failedAll failedNot checked
Uptime
50.0%
Response time
81 ms typical, 81 ms slowest 5%
Last check
2 h ago: Expected HTTP 402, got 410
Next check
any minute now

How to call it

# See the payment challenge (nothing is charged)
curl -i -X GET "https://aayatai.com/perps/candles?coin=BTC&interval=1h&limit=6"
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const client = new x402Client().register(
  "eip155:8453",
  new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);

// Not sure it's safe to pay? Preflight it first for $0.005:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Faayatai.com%2Fperps%2Fcandles
const res = await pay("https://aayatai.com/perps/candles?coin=BTC&interval=1h&limit=6");
console.log(await res.json());

Example input

{
  "coin": "BTC",
  "interval": "1h",
  "limit": 6
}

Example output

{
  "asOf": "2026-09-30T03:35:00.000Z",
  "attribution": "Data from Hyperliquid's public info API (api.hyperliquid.xyz).",
  "candles": [
    {
      "close": 83573,
      "high": 83697,
      "low": 83464,
      "open": 83465,
      "time": "2026-09-29T22:00:00.000Z",
      "trades": 8004,
      "volumeCoins": 648.69592,
      "volumeUsd": 54213464
    },
    {
      "close": 83620,
      "high": 83801,
      "low": 83568,
      "open": 83573,
      "time": "2026-09-29T23:00:00.000Z",
      "trades": 6156,
      "volumeCoins": 489.27094,
      "volumeUsd": 40912836
    },
    {
      "close": 83411,
      "high": 83689,
      "low": 83301,
      "open": 83620,
      "time": "2026-09-30T00:00:00.000Z",
      "trades": 8016,
      "volumeCoins": 656.57928,
      "volumeUsd": 54765934
    },
    {
      "close": 83405,
      "high": 83521,
      "low": 83294,
      "open": 83412,
      "time": "2026-09-30T01:00:00.000Z",
      "trades": 5677,
      "volumeCoins": 381.18808,
      "volumeUsd": 31792992
    },
    {
      "close": 83344,
      "high": 83581,
      "low": 83250,
      "open": 83405,
      "time": "2026-09-30T02:00:00.000Z",
      "trades": 6077,
      "volumeCoins": 302.27044,
      "volumeUsd": 25192428
    },
    {
      "close": 83289,
      "high": 83399,
      "low": 83133,
      "open": 83349,
      "time": "2026-09-30T03:00:00.000Z",
      "trades": 5001,
      "volumeCoins": 580.14654,
      "volumeUsd": 48319825
    }
  ],
  "coin": "BTC",
  "interval": "1h",
  "summary": {
    "candles": 6,
    "changePct": -0.211,
    "close": 83289,
    "from": "2026-09-29T22:00:00.000Z",
    "high": 83801,
    "low": 83133,
    "open": 83465,
    "realizedVolAnnualPct": 10.71,
    "to": "2026-09-30T03:00:00.000Z",
    "volumeUsd": 255197479
  },
  "venue": "hyperliquid"
}

Security scan

  • No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.

Recent checks

WhenResultHTTPTimePrice
2 h agoExpected HTTP 402, got 41041040 ms-
7 h agoPassed40281 ms$0.002