{
 "openapi": "3.1.0",
 "info": {
  "title": "BytNode Crypto Market Data API",
  "version": "1.1.0",
  "summary": "Crypto market data aggregated across the major venues, derivatives, order flow, options, macro, ETF and on-chain — for developers and AI agents.",
  "description": "**BytNode is a crypto market-data API built for developers and AI agents.** One key gives you market data aggregated across the major crypto venues, derivatives positioning, order flow, options, macro, ETF and on-chain fundamentals — about 120 REST routes, a consolidated real-time WebSocket and a native MCP server, all behind one consistent contract.\n\n## Why BytNode\n\n- **Aggregated across the major venues, not one exchange.** Spot and perpetual futures markets are consolidated into one number per metric: volumes are summed, rates are open-interest weighted, prices volume weighted — and the method is documented for every metric, with the number of contributing venues on every row (`venue_count`).\n- **Depth on the assets that matter.** 22 pairs: BTC, ETH, SOL, XRP, DOGE, BNB, TRX, SUI, HYPE, XLM, XMR, LINK, ADA, LTC, UNI, GRAM (ex-TON), AVAX, HBAR, NEAR, TAO, plus USDC and USDT spot pairs. This is a deliberate choice: together these assets are about 93 % of the total crypto market capitalisation (measured on 2026-09-30: 2.69 of 2.88 trillion USD), and each of them gets every family of data from every venue that lists it — quality and depth on the assets people actually trade, instead of thin coverage of thousands of tickers.\n- **Fourteen families in one API.** Prices and candles, individual trades, order book, order flow (CVD, VWAP, trade candles), funding, basis, open interest, long/short, liquidations and liquidation heatmap, tokenomics, sentiment, macro (FRED + intraday), spot ETF fundamentals (SEC EDGAR), options (OI, IV, max pain, greeks), Bitcoin network, Ethereum fundamentals, on-chain valuation, and 20 server-side technical indicators. Many providers sell these as separate products; here they share one key, one envelope and one set of conventions.\n- **Honest numbers.** Every bucketed value says whether it is final (`is_closed`); every multi-venue metric says how many venues contributed (`venue_count`, `coverage`); every empty answer says why (`unavailable`: `not_applicable`, `no_api_key`, `no_data`); every numeric field has a documented unit.\n- **Made for AI agents.** A native MCP server (3 tools, 73 fields), `llms.txt` and `llms-full.txt`, this OpenAPI contract with units and real examples, one-request snapshots of up to 61 fields, and stable machine-readable error codes.\n- **Priced for builders.** A free plan (10,000 requests/month), then Traders from 6.95 USD/month, Financial from 19.95 USD/month and Startup from 99.95 USD/month (billed yearly), with history depth and families growing with the plan. See https://bytnode.com/pricing.\n\n## Quick start\n\n1. Create a free key at https://bytnode.com/sign-up.\n2. Send it in the `X-API-KEY` header:\n\n```\ncurl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/rate?symbol=BTCUSDT\"\n```\n\n## Conventions\n\n- **Envelope.** Every success is `{status: \"ok\", timestamp, data_type, data}`, plus the effective `symbol` and `timeframe` when the route has them. `data` is an object for \"latest\" routes and a list (most recent first) for `/history` routes; a few routes document another shape.\n- **Units.** `*_pct` = percent (58.5 = 58.5 %), `*_ratio` = fraction (0.585), `*_bps` = basis points, `*_usd` = USD. Prices are in the quote currency (USDT for BTCUSDT). Volumes and quantities (`volume`, `trade_volume`, `volume_delta`, `taker_buy`...) are in BASE ASSET units (BTC for BTCUSDT), never dollars. Every response schema carries each field's unit in `x-unit`.\n- **Time.** Timestamps are ISO 8601 UTC with milliseconds (`2026-09-28T14:00:00.000Z`); every timestamped object under `data` also carries `time`. Time bounds (`since_ms`, `until_ms`) are epoch MILLISECONDS, inclusive.\n- **Closed buckets.** Bucketed routes serve the last CLOSED bucket; `?live=1` adds the open one with `is_closed: false`.\n- **Strict parameters.** An undeclared or repeated parameter is a 422 with a suggestion (`limt` -> did you mean `limit`?). `?fields=a,b.c` projects `data`.\n- **Aggregation only.** No route discloses which venue a number came from, except the inter-venue spread, whose purpose is to compare venues.\n\n## Errors\n\nEvery error has one shape:\n\n```\n{\"status\": \"error\", \"timestamp\": 1790784447808,\n \"error\": {\"code\": \"invalid_symbol\", \"message\": \"Unknown symbol 'BTCUSD'. Accepted values: ...\", \"param\": \"symbol\"},\n \"detail\": \"Unknown symbol 'BTCUSD'. Accepted values: ...\"}\n```\n\nBranch on `error.code` (stable, listed in the `Error` schema), show `error.message` (English). `detail` repeats the message for older clients. Plan refusals also carry an `X-Deny-Reason` header (`key`, `family`, `websocket`, `rate`, `quota`, `depth`); 429 and 503 carry `Retry-After`.\n\n## Limits\n\nEach plan has a per-minute rate, a monthly quota and a history window per timeframe. Responses made with a metered key carry the IETF `RateLimit-Policy` and `RateLimit` headers. Going further back than your plan allows is a 403 `history_depth`, never a silently truncated answer. Details: https://bytnode.com/docs/rate-limits.\n\n## Versioning\n\nThe contract is `v1`. Adding routes, fields or parameters is not a breaking change. A breaking change is announced in the changelog (https://bytnode.com/docs/changelog) with notice by plan: Traders 30 days, Financial 60 days, Startup 90 days, Enterprise per contract.\n\n## Links\n\nDocs https://bytnode.com/docs · Pricing https://bytnode.com/pricing · Full reference for LLMs https://bytnode.com/llms-full.txt · WebSocket `wss://api.bytnode.com/ws` · MCP `https://api.bytnode.com/mcp` · Contact contact@bytnode.com\n",
  "contact": {
   "name": "BytNode",
   "url": "https://bytnode.com",
   "email": "contact@bytnode.com"
  }
 },
 "externalDocs": {
  "description": "Guides, conventions and pricing",
  "url": "https://bytnode.com/docs"
 },
 "servers": [
  {
   "url": "https://api.bytnode.com",
   "description": "Production"
  }
 ],
 "tags": [
  {
   "name": "System",
   "description": "Health, per-feed freshness, the list of served symbols and what each symbol supports. `/v1/health` is the only route that needs no key."
  },
  {
   "name": "Snapshot",
   "description": "One request, up to 61 fields for one symbol: the fastest way to fill a dashboard or give an AI agent full market context. Each field is `name=depth` (`funding_rate_8h=1`, `klines_1h=24`, or `true` for depth 1); multi-timeframe fields are `name@tf=depth` (`cvd@1h=24`). Call it with only `symbol` to list the fields your plan includes."
  },
  {
   "name": "Market: prices & volumes",
   "description": "OHLCV candles, individual trades, price change and the aggregated order book. Volumes are aggregated across venues (spot and perpetual futures); OHLC comes from one reference spot market per symbol."
  },
  {
   "name": "Order flow",
   "description": "Who is buying and who is selling: trade candles (spot, futures, combined), CVD, VWAP, buy/sell ratio, average trade size and inter-venue spread. Every bucketed series says whether the value is final (`is_closed`)."
  },
  {
   "name": "Derivatives",
   "description": "Perpetual futures positioning, aggregated across venues: funding (settled, estimated, cumulative), basis, open interest, long/short account ratio."
  },
  {
   "name": "Liquidations",
   "description": "Forced liquidations across venues: individual events, cumulative long/short USD, big vs small liquidations, and the liquidation heatmap clusters the price is drawn to."
  },
  {
   "name": "Tokenomics & sentiment",
   "description": "Supply, market cap and FDV derived from the live price; total crypto market cap and dominance; the Crypto Fear & Greed Index."
  },
  {
   "name": "Macro",
   "description": "Daily FRED series (rates, inflation, liquidity, commodities), intraday macro candles (DXY, EUR/USD, gold, oil, US yields, VIX...), and derived crypto-macro signals: net liquidity, BTC correlations, macro momentum, risk-on/risk-off score."
  },
  {
   "name": "ETF",
   "description": "Spot BTC and ETH ETF fundamentals per issuer, anchored on SEC EDGAR filings: shares, NAV, net assets and coins held."
  },
  {
   "name": "Options",
   "description": "BTC and ETH options aggregated across venues: open interest and volume (calls/puts, USD), put/call ratio, ATM implied volatility, max pain, per-expiry and per-strike views, OI-weighted greeks."
  },
  {
   "name": "Bitcoin network",
   "description": "Bitcoin chain state: recommended fees, mempool, mining pool concentration, difficulty and the next adjustment."
  },
  {
   "name": "Ethereum",
   "description": "Ethereum fundamentals: gas, supply and burn, staking and yield, DeFi TVL, ETH/BTC ratio and derived signals (deflation, supply squeeze, gas momentum)."
  },
  {
   "name": "On-chain Bitcoin",
   "description": "Daily on-chain valuation and activity: MVRV, NVT, active addresses, miner stress."
  },
  {
   "name": "Technical indicators",
   "description": "20 technical indicators computed server-side on the same candles as `/v1/raw/klines`, several per request (RSI, MACD, Bollinger, ATR, Ichimoku, VWMA...)."
  }
 ],
 "components": {
  "schemas": {
   "Error": {
    "type": "object",
    "required": [
     "status",
     "timestamp",
     "error",
     "detail"
    ],
    "properties": {
     "status": {
      "type": "string",
      "enum": [
       "error"
      ]
     },
     "timestamp": {
      "type": "integer",
      "x-unit": "epoch milliseconds"
     },
     "error": {
      "type": "object",
      "required": [
       "code",
       "message"
      ],
      "properties": {
       "code": {
        "type": "string",
        "enum": [
         "depth_too_large",
         "edge_rate_limited",
         "history_depth",
         "insufficient_data",
         "internal_error",
         "invalid_api_key",
         "invalid_asset",
         "invalid_depth",
         "invalid_exchange",
         "invalid_indicator",
         "invalid_pair",
         "invalid_parameter",
         "invalid_series",
         "invalid_symbol",
         "invalid_time_period",
         "invalid_time_range",
         "invalid_timeframe",
         "method_not_allowed",
         "missing_expiry",
         "missing_parameter",
         "not_applicable",
         "not_found",
         "plan_family",
         "plan_websocket",
         "quota_exceeded",
         "rate_limited",
         "repeated_parameter",
         "service_unavailable",
         "timeframe_not_served",
         "unknown_field",
         "unknown_parameter",
         "upstream_timeout"
        ],
        "description": "Stable machine-readable code. Branch on it, never on the message.\n\n- `depth_too_large`: A snapshot field depth exceeds its documented maximum.\n- `edge_rate_limited`: Too many simultaneous requests from this IP address (edge anti-flood).\n- `history_depth`: The requested history goes further back than your plan allows.\n- `insufficient_data`: Not enough history to compute the requested indicator.\n- `internal_error`: Unexpected server error. Not worth retrying immediately.\n- `invalid_api_key`: The API key is missing, invalid or revoked.\n- `invalid_asset`: The asset is not served by this family. The error lists the accepted values.\n- `invalid_depth`: A snapshot field depth is not a positive integer.\n- `invalid_exchange`: The exchange value is not accepted.\n- `invalid_indicator`: The POST /v1/indicators body is invalid (id, type or parameters).\n- `invalid_pair`: The pair value is not accepted.\n- `invalid_parameter`: A parameter has an invalid type or value.\n- `invalid_series`: The macro series does not exist. See the family's /series catalogue.\n- `invalid_symbol`: The symbol is not served. The error lists the accepted values (see /v1/symbols).\n- `invalid_time_period`: The timePeriod value is not accepted.\n- `invalid_time_range`: since_ms / until_ms are not valid epoch milliseconds, or since_ms >= until_ms.\n- `invalid_timeframe`: The timeframe is not accepted by this route.\n- `method_not_allowed`: The route exists but not with this HTTP method.\n- `missing_expiry`: The route needs an options expiry; the error lists the active ones.\n- `missing_parameter`: A required parameter is missing.\n- `not_applicable`: The request has no meaning for this asset (e.g. indicators on a stablecoin).\n- `not_found`: Unknown route.\n- `plan_family`: Your plan does not include this data family.\n- `plan_websocket`: Your plan does not include the WebSocket stream.\n- `quota_exceeded`: Your plan's monthly quota is exhausted.\n- `rate_limited`: Your plan's per-minute rate is exceeded. Retry after Retry-After seconds.\n- `repeated_parameter`: A parameter appears more than once.\n- `service_unavailable`: Temporary unavailability. Retry after Retry-After seconds.\n- `timeframe_not_served`: The series exists but does not serve this timeframe.\n- `unknown_field`: A ?fields= or snapshot field name does not exist.\n- `unknown_parameter`: The route does not declare this parameter.\n- `upstream_timeout`: The request took too long. Reduce the window or depth, then retry."
       },
       "message": {
        "type": "string",
        "description": "Human-readable explanation, in English."
       },
       "param": {
        "type": "string",
        "description": "The parameter at fault, when there is one."
       },
       "details": {
        "description": "Structured complement (e.g. every validation error)."
       }
      }
     },
     "detail": {
      "type": "string",
      "description": "Same text as `error.message` (kept for older clients)."
     },
     "retry_after": {
      "type": "integer",
      "description": "Seconds to wait (429 and 503 only).",
      "x-unit": "seconds"
     }
    }
   },
   "IndicatorsRequest": {
    "properties": {
     "symbol": {
      "type": "string",
      "maxLength": 32,
      "title": "Symbol"
     },
     "timeframe": {
      "type": "string",
      "maxLength": 8,
      "title": "Timeframe"
     },
     "results": {
      "type": "integer",
      "title": "Results",
      "default": 1
     },
     "indicators": {
      "items": {
       "additionalProperties": true,
       "type": "object"
      },
      "type": "array",
      "maxItems": 50,
      "title": "Indicators"
     }
    },
    "type": "object",
    "required": [
     "symbol",
     "timeframe",
     "indicators"
    ],
    "title": "IndicatorsRequest"
   }
  },
  "responses": {
   "BadRequest": {
    "description": "The request targets a value that does not exist (`invalid_symbol`, `invalid_asset`, `invalid_series`, `invalid_depth`, `depth_too_large`, `invalid_indicator`...).",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "invalid_symbol": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "invalid_symbol",
          "message": "Unknown symbol 'BTCUSD'. Accepted values: ADAUSDT, AVAXUSDT, BNBUSDT, BTCUSDT, ...",
          "param": "symbol"
         },
         "detail": "Unknown symbol 'BTCUSD'. Accepted values: ADAUSDT, AVAXUSDT, BNBUSDT, BTCUSDT, ..."
        }
       }
      }
     }
    }
   },
   "Forbidden": {
    "description": "The key is missing, invalid or revoked (`invalid_api_key`), or your plan does not cover the request (`plan_family`, `plan_websocket`, `history_depth`).",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "invalid_api_key": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "invalid_api_key",
          "message": "API key missing, invalid or revoked. Send it in the X-API-KEY header; create one at https://bytnode.com/dashboard/keys."
         },
         "detail": "API key missing, invalid or revoked. Send it in the X-API-KEY header; create one at https://bytnode.com/dashboard/keys."
        }
       },
       "history_depth": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "history_depth",
          "message": "History depth beyond your plan: 30 day(s) requested on 1h, your plan allows 1 day(s) (i.e. at most limit=24 on this timeframe, and no since_ms/until_ms bound beyond that window).",
          "param": "limit"
         },
         "detail": "History depth beyond your plan: 30 day(s) requested on 1h, your plan allows 1 day(s) (i.e. at most limit=24 on this timeframe, and no since_ms/until_ms bound beyond that window)."
        }
       }
      }
     }
    },
    "headers": {
     "X-Deny-Reason": {
      "description": "Why the plan refused: `key`, `family`, `websocket`, `rate`, `quota` or `depth`.",
      "schema": {
       "type": "string"
      }
     }
    }
   },
   "Unprocessable": {
    "description": "A parameter is missing, unknown, repeated or has an invalid value (`missing_parameter`, `unknown_parameter`, `repeated_parameter`, `invalid_parameter`, `invalid_timeframe`, `invalid_time_range`, `unknown_field`...).",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "unknown_parameter": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "unknown_parameter",
          "message": "Unknown parameter 'limt'. Did you mean 'limit'? Accepted parameters: fields, limit, since_ms, symbol, timeframe, until_ms.",
          "param": "limt"
         },
         "detail": "Unknown parameter 'limt'. Did you mean 'limit'? Accepted parameters: fields, limit, since_ms, symbol, timeframe, until_ms."
        }
       },
       "invalid_time_range": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "invalid_time_range",
          "message": "since_ms=1790000000 looks like seconds: time bounds are epoch MILLISECONDS (e.g. since_ms=1790000000000).",
          "param": "since_ms"
         },
         "detail": "since_ms=1790000000 looks like seconds: time bounds are epoch MILLISECONDS (e.g. since_ms=1790000000000)."
        }
       }
      }
     }
    }
   },
   "TooManyRequests": {
    "description": "Your plan's per-minute rate (`rate_limited`) or monthly quota (`quota_exceeded`) is exhausted, or too many simultaneous requests from one IP (`edge_rate_limited`).",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "rate_limited": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "rate_limited",
          "message": "Rate limit exceeded: your plan allows a limited number of requests per minute. Retry after the Retry-After delay."
         },
         "detail": "Rate limit exceeded: your plan allows a limited number of requests per minute. Retry after the Retry-After delay.",
         "retry_after": 1
        }
       }
      }
     }
    },
    "headers": {
     "Retry-After": {
      "description": "Seconds to wait before retrying.",
      "schema": {
       "type": "integer"
      }
     },
     "X-Deny-Reason": {
      "description": "Why the plan refused: `key`, `family`, `websocket`, `rate`, `quota` or `depth`.",
      "schema": {
       "type": "string"
      }
     },
     "RateLimit-Policy": {
      "description": "Your plan's rate and quota (IETF draft).",
      "schema": {
       "type": "string"
      }
     },
     "RateLimit": {
      "description": "Remaining rate and quota (IETF draft).",
      "schema": {
       "type": "string"
      }
     }
    }
   },
   "ServiceUnavailable": {
    "description": "Temporary unavailability (`service_unavailable`). Retry after `Retry-After` seconds.",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "service_unavailable": {
        "value": {
         "status": "error",
         "timestamp": 1790784447808,
         "error": {
          "code": "service_unavailable",
          "message": "Service temporarily unavailable, please retry."
         },
         "detail": "Service temporarily unavailable, please retry.",
         "retry_after": 5
        }
       }
      }
     }
    },
    "headers": {
     "Retry-After": {
      "description": "Seconds to wait before retrying.",
      "schema": {
       "type": "integer"
      }
     }
    }
   }
  },
  "headers": {
   "RateLimit-Policy": {
    "description": "Your plan's rate and quota (IETF draft).",
    "schema": {
     "type": "string"
    }
   },
   "RateLimit": {
    "description": "Remaining rate and quota (IETF draft).",
    "schema": {
     "type": "string"
    }
   }
  },
  "securitySchemes": {
   "APIKeyHeader": {
    "type": "apiKey",
    "in": "header",
    "name": "X-API-KEY",
    "description": "Your API key (`cb_live_...`). Get a free one at https://bytnode.com/sign-up."
   }
  }
 },
 "security": [
  {
   "APIKeyHeader": []
  }
 ],
 "paths": {
  "/v1/basis": {
   "get": {
    "summary": "Futures-spot basis",
    "description": "Perpetual futures price versus spot, OI-weighted across venues (each venue weighted by its latest open interest within 10 minutes).",
    "operationId": "get_basis_v1_basis_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "basis_value": {
             "type": [
              "number",
              "null"
             ],
             "description": "Futures price - spot price.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "basis_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "(futures - spot) / spot, in percent. Positive = contango.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "futures_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Perpetual futures price, open-interest weighted across venues.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "spot_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Spot price across venues.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790261142,
         "data_type": "basis",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:37.309Z",
          "basis_value": -38.03961943906421,
          "basis_pct": -0.04526350810118282,
          "futures_price": 84002.17394512612,
          "spot_price": 84040.21356456519,
          "timestamp": "2026-09-30T17:43:37.309Z"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/basis?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/basis\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/basis?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/basis/history": {
   "get": {
    "summary": "Basis history",
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_basis_history_v1_basis_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "basis_value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Futures price - spot price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "basis_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "(futures - spot) / spot, in percent. Positive = contango.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "futures_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Perpetual futures price, open-interest weighted across venues.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "spot_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Spot price across venues.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790261798,
         "data_type": "basis_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "basis_value": -33.981449109710006,
           "basis_pct": -0.04029417463246244,
           "futures_price": 84298.40975007898,
           "spot_price": 84332.39119918869,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "basis_value": -35.702638083532776,
           "basis_pct": -0.04243001848673969,
           "futures_price": 84107.74754775809,
           "spot_price": 84143.45018584162,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "basis_value": -42.805161758335856,
           "basis_pct": -0.05107252133261064,
           "futures_price": 83768.58660190101,
           "spot_price": 83811.39176365935,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/basis/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/basis/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/basis/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/fees": {
   "get": {
    "summary": "Recommended Bitcoin fees",
    "description": "Fee rates for each confirmation target (sat/vB), rounded and precise, and the fee pressure.",
    "operationId": "get_btc_fees_v1_btc_fees_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "recommended": {
             "type": "object",
             "properties": {
              "fastest": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Fee rate for the next block.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "half_hour": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Fee rate for confirmation within ~30 minutes.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "hour": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Fee rate for confirmation within ~1 hour.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "economy": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Fee rate for a low-priority confirmation.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "minimum": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Minimum relay fee rate.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              }
             },
             "description": "Recommended fee rates, rounded: `fastest`, `half_hour`, `hour`, `economy`, `minimum`.",
             "x-unit": "satoshis per virtual byte (sat/vB)"
            },
            "precise": {
             "type": "object",
             "properties": {
              "fastest": {
               "type": [
                "number",
                "null"
               ],
               "description": "Fee rate for the next block.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "half_hour": {
               "type": [
                "number",
                "null"
               ],
               "description": "Fee rate for confirmation within ~30 minutes.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "hour": {
               "type": [
                "number",
                "null"
               ],
               "description": "Fee rate for confirmation within ~1 hour.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "economy": {
               "type": [
                "number",
                "null"
               ],
               "description": "Fee rate for a low-priority confirmation.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              },
              "minimum": {
               "type": [
                "number",
                "null"
               ],
               "description": "Minimum relay fee rate.",
               "x-unit": "satoshis per virtual byte (sat/vB)"
              }
             },
             "description": "Same fee rates, unrounded.",
             "x-unit": "satoshis per virtual byte (sat/vB)"
            },
            "fee_pressure": {
             "type": "object",
             "properties": {
              "ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "fastest / economy fee rate.",
               "x-unit": "dimensionless ratio"
              },
              "signal": {
               "type": "string",
               "description": "Fee pressure: `normal` (ratio <= 2), `elevated` (> 2) or `congested` (> 5)."
              }
             },
             "description": "`ratio` = fastest / economy fee rate, and its `signal`: `normal` (<= 2), `elevated` (> 2), `congested` (> 5).",
             "x-unit": "dimensionless ratio"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790292219,
         "data_type": "btc_fees",
         "data": {
          "time": "2026-09-30T17:44:06.179Z",
          "recommended": {
           "fastest": 2,
           "half_hour": 1,
           "hour": 1,
           "economy": 1,
           "minimum": 1
          },
          "precise": {
           "fastest": 1.507,
           "half_hour": 0.962,
           "hour": 0.518,
           "economy": 0.2,
           "minimum": 0.1
          },
          "fee_pressure": {
           "ratio": 2,
           "signal": "normal"
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/fees\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/fees\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/fees\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/fees/history": {
   "get": {
    "summary": "Bitcoin fees history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_btc_fees_history_v1_btc_fees_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `24h`, `1w`, `1mo` (one month), `3m`, `6m`, `1y`. `1m` also means ONE MONTH here (legacy spelling); prefer `1mo`.",
      "example": "1w"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 300
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "fastest_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Fee rate for the next block.",
              "x-unit": "satoshis per virtual byte (sat/vB)"
             },
             "half_hour_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Fee rate for ~30 minutes.",
              "x-unit": "satoshis per virtual byte (sat/vB)"
             },
             "hour_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Fee rate for ~1 hour.",
              "x-unit": "satoshis per virtual byte (sat/vB)"
             },
             "economy_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Low-priority fee rate.",
              "x-unit": "satoshis per virtual byte (sat/vB)"
             },
             "minimum_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Minimum relay fee rate.",
              "x-unit": "satoshis per virtual byte (sat/vB)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790292824,
         "data_type": "btc_fees_history",
         "data": [
          {
           "time": "2026-09-30T17:44:06.179Z",
           "fastest_fee": 2,
           "half_hour_fee": 1,
           "hour_fee": 1,
           "economy_fee": 1,
           "minimum_fee": 1
          },
          {
           "time": "2026-09-30T17:43:05.648Z",
           "fastest_fee": 2,
           "half_hour_fee": 1,
           "hour_fee": 1,
           "economy_fee": 1,
           "minimum_fee": 1
          },
          {
           "time": "2026-09-30T17:42:05.470Z",
           "fastest_fee": 4,
           "half_hour_fee": 3,
           "hour_fee": 1,
           "economy_fee": 1,
           "minimum_fee": 1
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/fees/history?timePeriod=1w&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/fees/history\",\n    params={\"timePeriod\": \"1w\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/fees/history?timePeriod=1w&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/mempool": {
   "get": {
    "summary": "Bitcoin mempool",
    "description": "Pending transactions, virtual size, total fees, fee histogram and the 1 h / 4 h / 24 h trend.",
    "operationId": "get_btc_mempool_v1_btc_mempool_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "tx_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Unconfirmed transactions in the mempool.",
             "x-unit": "count"
            },
            "vsize": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Total virtual size of the mempool.",
             "x-unit": "virtual bytes"
            },
            "total_fee": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Total fees waiting in the mempool.",
             "x-unit": "satoshis"
            },
            "fee_histogram": {
             "type": "array",
             "items": {
              "type": "array",
              "items": {
               "type": [
                "number",
                "null"
               ]
              }
             },
             "description": "`[fee_rate, vsize]` pairs: how much virtual size waits at each fee rate.",
             "x-unit": "satoshis per virtual byte (sat/vB)"
            },
            "trend": {
             "type": "object",
             "properties": {
              "vsize_delta_1h": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Mempool size change over 1 hour.",
               "x-unit": "virtual bytes"
              },
              "vsize_delta_4h": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Mempool size change over 4 hours.",
               "x-unit": "virtual bytes"
              },
              "vsize_delta_24h": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Mempool size change over 24 hours.",
               "x-unit": "virtual bytes"
              },
              "signal": {
               "type": "string",
               "description": "`filling` (vsize grew over 1 h), `draining` (shrank) or `stable`."
              }
             },
             "description": "Mempool size change over 1 h, 4 h and 24 h, and its `signal` (`filling`, `draining`, `stable`).",
             "x-unit": "virtual bytes"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790293508,
         "data_type": "btc_mempool",
         "data": {
          "time": "2026-09-30T17:44:06.179Z",
          "tx_count": 88092,
          "vsize": 44891543,
          "total_fee": 8758605,
          "fee_histogram": [
           [
            5.007924,
            50350
           ],
           [
            3.621282,
            59177
           ],
           [
            3.0182927,
            50006
           ]
          ],
          "trend": {
           "vsize_delta_1h": -2980246,
           "vsize_delta_4h": -1193654,
           "vsize_delta_24h": 1070554,
           "signal": "draining"
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/mempool\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/mempool\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/mempool\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/mempool/history": {
   "get": {
    "summary": "Mempool history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_btc_mempool_history_v1_btc_mempool_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `24h`, `1w`, `1mo` (one month), `3m`, `6m`, `1y`. `1m` also means ONE MONTH here (legacy spelling); prefer `1mo`.",
      "example": "1w"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 300
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "tx_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Unconfirmed transactions in the mempool.",
              "x-unit": "count"
             },
             "vsize": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Total virtual size of the mempool.",
              "x-unit": "virtual bytes"
             },
             "total_fee": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Total fees waiting in the mempool.",
              "x-unit": "satoshis"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790294121,
         "data_type": "btc_mempool_history",
         "data": [
          {
           "time": "2026-09-30T17:44:06.179Z",
           "tx_count": 88092,
           "vsize": 44891543,
           "total_fee": 8758605
          },
          {
           "time": "2026-09-30T17:43:05.648Z",
           "tx_count": 87592,
           "vsize": 44735546,
           "total_fee": 8335460
          },
          {
           "time": "2026-09-30T17:42:05.470Z",
           "tx_count": 88575,
           "vsize": 43043826,
           "total_fee": 11303334
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/mempool/history?timePeriod=1w&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/mempool/history\",\n    params={\"timePeriod\": \"1w\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/mempool/history?timePeriod=1w&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/mining": {
   "get": {
    "summary": "Mining pool concentration",
    "description": "Share of the largest pools, pool ranking and the latest block reward in sats and USD.",
    "operationId": "get_btc_mining_v1_btc_mining_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "concentration": {
             "type": "object",
             "properties": {
              "top1_share_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of blocks mined by the largest pool.",
               "x-unit": "percent (58.5 = 58.5 %)"
              },
              "top3_share_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of blocks mined by the three largest pools.",
               "x-unit": "percent (58.5 = 58.5 %)"
              },
              "pool_count": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Number of pools that mined at least one block.",
               "x-unit": "count"
              },
              "signal": {
               "type": "string",
               "description": "Centralisation risk from the top-3 pool share: `healthy` (<= 40 %), `moderate` (> 40 %), `high_risk` (> 50 %)."
              }
             },
             "description": "Mining pool concentration over the last period.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "latest_reward": {
             "type": "object",
             "properties": {
              "avg_reward_sats": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Average block reward.",
               "x-unit": "satoshis"
              },
              "avg_reward_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Average block reward in USD.",
               "x-unit": "USD"
              },
              "btc_price_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "BTC price used for the conversion.",
               "x-unit": "USD"
              }
             },
             "description": "Average block reward (subsidy + fees) of the latest blocks, in satoshis and USD."
            },
            "pools": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "name": {
                "type": "string",
                "description": "Name."
               },
               "slug": {
                "type": "string",
                "description": "Stable identifier."
               },
               "block_count": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Blocks mined over the period.",
                "x-unit": "count"
               },
               "rank": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Rank.",
                "x-unit": "rank (1 = first)"
               },
               "share_pct": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Share of blocks.",
                "x-unit": "percent (58.5 = 58.5 %)"
               }
              }
             },
             "description": "Pools ranked by blocks mined: `name`, `slug`, `block_count`, `rank`, `share_pct`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790294780,
         "data_type": "btc_mining",
         "data": {
          "time": "2026-09-30T17:43:15.367Z",
          "concentration": {
           "top1_share_pct": 25.58365758754864,
           "top3_share_pct": 62.45136186770428,
           "pool_count": 16,
           "signal": "high_risk"
          },
          "latest_reward": {
           "avg_reward_sats": 315067914,
           "avg_reward_usd": 265551.84063576,
           "btc_price_usd": 84284
          },
          "pools": [
           {
            "name": "Foundry USA",
            "slug": "foundryusa",
            "block_count": 263,
            "rank": 1,
            "share_pct": 25.58365758754864
           },
           {
            "name": "AntPool",
            "slug": "antpool",
            "block_count": 222,
            "rank": 2,
            "share_pct": 21.595330739299612
           },
           {
            "name": "F2Pool",
            "slug": "f2pool",
            "block_count": 157,
            "rank": 3,
            "share_pct": 15.272373540856032
           }
          ]
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/mining\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/mining\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/mining\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/mining/history": {
   "get": {
    "summary": "Mining history",
    "description": "One series selected by `dataset`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_btc_mining_history_v1_btc_mining_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "dataset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "concentration"
      },
      "description": "Which mining series to return: `concentration` (pool shares), `rewards` (block rewards), `difficulty` or `fee_rates`.",
      "example": "concentration"
     },
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `24h`, `1w`, `1mo` (one month), `3m`, `6m`, `1y`. `1m` also means ONE MONTH here (legacy spelling); prefer `1mo`.",
      "example": "1w"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 300
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "total_block_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Blocks in the period.",
              "x-unit": "count"
             },
             "top3_share_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of blocks mined by the three largest pools.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "top1_share_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of blocks mined by the largest pool.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "pool_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of pools that mined at least one block.",
              "x-unit": "count"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790295420,
         "data_type": "btc_mining_history",
         "data": [
          {
           "time": "2026-09-30T17:43:15.367Z",
           "total_block_count": 1028,
           "top3_share_pct": 62.45136186770428,
           "top1_share_pct": 25.58365758754864,
           "pool_count": 16
          },
          {
           "time": "2026-09-30T17:33:15.172Z",
           "total_block_count": 1028,
           "top3_share_pct": 62.45136186770428,
           "top1_share_pct": 25.58365758754864,
           "pool_count": 16
          },
          {
           "time": "2026-09-30T17:23:14.974Z",
           "total_block_count": 1027,
           "top3_share_pct": 62.414800389483936,
           "top1_share_pct": 25.60856864654333,
           "pool_count": 16
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/mining/history?dataset=concentration&timePeriod=1w&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/mining/history\",\n    params={\"dataset\": \"concentration\", \"timePeriod\": \"1w\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/mining/history?dataset=concentration&timePeriod=1w&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/network": {
   "get": {
    "summary": "Bitcoin network state",
    "description": "Height, difficulty, 24 h block time and the next difficulty adjustment.",
    "operationId": "get_btc_network_v1_btc_network_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "tip_height": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Height of the latest block.",
             "x-unit": "block height"
            },
            "difficulty": {
             "type": [
              "number",
              "null"
             ],
             "description": "Network mining difficulty.",
             "x-unit": "difficulty units"
            },
            "block_time": {
             "type": "object",
             "properties": {
              "avg_24h_s": {
               "type": [
                "number",
                "null"
               ],
               "description": "Average block time over 24 hours.",
               "x-unit": "seconds"
              },
              "deviation_s": {
               "type": [
                "number",
                "null"
               ],
               "description": "avg_24h_s - 600.",
               "x-unit": "seconds"
              },
              "signal": {
               "type": "string",
               "description": "24 h block time versus the 600 s target: `slow` (> +30 s), `fast` (< -30 s) or `on_target`."
              }
             },
             "description": "Average block time over 24 h (`avg_24h_s`), its deviation from the 600 s target, and a `signal`.",
             "x-unit": "seconds"
            },
            "next_adjustment": {
             "type": "object",
             "properties": {
              "progress_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "Progress through the current 2016-block difficulty period.",
               "x-unit": "percent (58.5 = 58.5 %)"
              },
              "difficulty_change_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "Expected difficulty change at the next adjustment.",
               "x-unit": "percent (58.5 = 58.5 %)"
              },
              "estimated_retarget": {
               "type": "string",
               "format": "date-time",
               "description": "Estimated instant of the next adjustment.",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "remaining_blocks": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Blocks left before the adjustment.",
               "x-unit": "count"
              },
              "remaining_time_ms": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Estimated time left before the adjustment.",
               "x-unit": "milliseconds"
              },
              "next_retarget_height": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Height of the next adjustment.",
               "x-unit": "block height"
              }
             },
             "description": "Next difficulty adjustment: progress, expected change, date, remaining blocks and time."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790296031,
         "data_type": "btc_network",
         "data": {
          "time": "2026-09-30T17:43:22.437Z",
          "tip_height": 969328,
          "difficulty": 132757073449487.5,
          "block_time": {
           "avg_24h_s": 603.9154929577464,
           "deviation_s": 3.9154929577464372,
           "signal": "on_target"
          },
          "next_adjustment": {
           "progress_pct": 81.74603174603175,
           "difficulty_change_pct": 0.09550248063647793,
           "estimated_retarget": "2026-10-03T07:02:04.088Z",
           "remaining_blocks": 368,
           "remaining_time_ms": 220723088,
           "next_retarget_height": 969696
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/network\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/network\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/network\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/btc/network/history": {
   "get": {
    "summary": "Network history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_btc_network_history_v1_btc_network_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `24h`, `1w`, `1mo` (one month), `3m`, `6m`, `1y`. `1m` also means ONE MONTH here (legacy spelling); prefer `1mo`.",
      "example": "1w"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 300
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "difficulty": {
              "type": [
               "number",
               "null"
              ],
              "description": "Network mining difficulty.",
              "x-unit": "difficulty units"
             },
             "tip_height": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Height of the latest block.",
              "x-unit": "block height"
             },
             "progress_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Progress through the current 2016-block difficulty period.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "difficulty_change_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Expected difficulty change at the next adjustment.",
              "x-unit": "percent (58.5 = 58.5 %)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790296616,
         "data_type": "btc_network_history",
         "data": [
          {
           "time": "2026-09-30T17:43:22.437Z",
           "difficulty": 132757073449487.5,
           "tip_height": 969328,
           "progress_pct": 81.74603174603175,
           "difficulty_change_pct": 0.09550248063647793
          },
          {
           "time": "2026-09-30T17:38:22.259Z",
           "difficulty": 132757073449487.5,
           "tip_height": 969327,
           "progress_pct": 81.69642857142857,
           "difficulty_change_pct": 0.06507063148870618
          },
          {
           "time": "2026-09-30T17:33:22.147Z",
           "difficulty": 132757073449487.5,
           "tip_height": 969327,
           "progress_pct": 81.69642857142857,
           "difficulty_change_pct": 0.09566181271543073
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Bitcoin network"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/btc/network/history?timePeriod=1w&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/btc/network/history\",\n    params={\"timePeriod\": \"1w\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/btc/network/history?timePeriod=1w&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/buysell/ratio": {
   "get": {
    "summary": "Buy/sell volume ratio",
    "operationId": "get_buysell_ratio_v1_buysell_ratio_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "buy_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Taker buy volume over the window.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "sell_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Taker sell volume over the window.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "buy_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "buy_volume / (buy_volume + sell_volume). Above 0.5 = buyers dominate.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790256317,
         "data_type": "buysell_ratio",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:35.160Z",
          "timestamp": "2026-09-30T17:43:35.160Z",
          "buy_volume": 414.7831900000006,
          "sell_volume": 361.0590300000007,
          "buy_ratio": 0.5346231222116269
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "description": "Taker buy share of volume over the last 5 minutes, all venues. Above 0.5 = buyers dominate.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/buysell/ratio?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/buysell/ratio\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/buysell/ratio?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/buysell/ratio/history": {
   "get": {
    "summary": "Buy/sell ratio history",
    "operationId": "get_buysell_ratio_history_v1_buysell_ratio_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "buy_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume over the window.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "sell_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker sell volume over the window.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "buy_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "buy_volume / (buy_volume + sell_volume). Above 0.5 = buyers dominate.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790256928,
         "data_type": "buysell_ratio_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "buy_volume": 227.26665000000023,
           "sell_volume": 291.9107799999998,
           "buy_ratio": 0.4377437016089089,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "buy_volume": 344.0962499999999,
           "sell_volume": 576.9466400000017,
           "buy_ratio": 0.37359416563109166,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "buy_volume": 2437.820319999956,
           "sell_volume": 1621.1675800000216,
           "buy_ratio": 0.6005980751999703,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/buysell/ratio/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/buysell/ratio/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/buysell/ratio/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/cvd": {
   "get": {
    "summary": "Cumulative volume delta per bucket",
    "description": "Net taker delta of the latest closed bucket, with its minute-by-minute path (`cvd_series`), aggregated across venues. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_cvd_v1_cvd_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "cvd_series": {
              "type": "array",
              "items": {
               "type": [
                "number",
                "null"
               ]
              },
              "description": "Cumulative volume delta inside the bucket, one point per minute, starting from 0 at the bucket start.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "net_delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume - taker sell volume over the bucket, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_buy_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker sell volume over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "points_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute points in `cvd_series`.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790252033,
         "data_type": "cvd_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "cvd_series": [
            45.888329999999726,
            69.2295500000001,
            200.21975000000012
           ],
           "net_delta": -707.4313099999853,
           "taker_buy_volume": 8806.463150000012,
           "taker_sell_volume": 9513.894459999998,
           "points_count": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/cvd?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/cvd\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/cvd?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/cvd/history": {
   "get": {
    "summary": "Cumulative volume delta history",
    "description": "Same as `/v1/cvd`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_cvd_history_v1_cvd_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "cvd_series": {
              "type": "array",
              "items": {
               "type": [
                "number",
                "null"
               ]
              },
              "description": "Cumulative volume delta inside the bucket, one point per minute, starting from 0 at the bucket start.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "net_delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume - taker sell volume over the bucket, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_buy_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker sell volume over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "points_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute points in `cvd_series`.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790252625,
         "data_type": "cvd_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "cvd_series": [
            45.888329999999726,
            69.2295500000001,
            200.21975000000012
           ],
           "net_delta": -707.4313099999853,
           "taker_buy_volume": 8806.463150000012,
           "taker_sell_volume": 9513.894459999998,
           "points_count": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "symbol": "BTCUSDT",
           "cvd_series": [
            -662.8237799999529,
            -701.9267099999539,
            -770.6161599999542
           ],
           "net_delta": -959.6718699999959,
           "taker_buy_volume": 14950.270559999979,
           "taker_sell_volume": 15909.942429999976,
           "points_count": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "symbol": "BTCUSDT",
           "cvd_series": [
            -304.04254000000515,
            -636.4162500000092,
            -977.9060600000167
           ],
           "net_delta": -1580.8624099997996,
           "taker_buy_volume": 36766.47983999995,
           "taker_sell_volume": 38347.34224999975,
           "points_count": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/cvd/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/cvd/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/cvd/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/etf/fundamentals": {
   "get": {
    "summary": "ETF fundamentals per issuer",
    "description": "Latest SEC EDGAR anchor per spot ETF: shares outstanding, NAV, net assets and coins held. `data` is a list, one row per issuer.",
    "operationId": "get_etf_fundamentals_v1_etf_fundamentals_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "ticker": {
              "type": "string",
              "description": "ETF ticker."
             },
             "issuer": {
              "type": "string",
              "description": "ETF issuer."
             },
             "period_end": {
              "type": "string",
              "format": "date",
              "description": "End of the reporting period of the filing.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "balance_date": {
              "type": "string",
              "format": "date",
              "description": "Date of the balance sheet the holdings come from.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "shares_outstanding": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETF shares outstanding.",
              "x-unit": "shares"
             },
             "nav_per_share": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net asset value per share.",
              "x-unit": "USD"
             },
             "net_assets_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net assets (AUM).",
              "x-unit": "USD"
             },
             "form": {
              "type": "string",
              "description": "SEC form type of the filing (`10-Q`, `10-K`...)."
             },
             "filed": {
              "type": "string",
              "format": "date",
              "description": "Filing date at the SEC.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "filing_url": {
              "type": "string",
              "description": "Link to the filing on SEC EDGAR."
             },
             "btc_holdings": {
              "type": [
               "number",
               "null"
              ],
              "description": "BTC held by the fund.",
              "x-unit": "BTC"
             },
             "holdings_estimated": {
              "type": "boolean",
              "description": "`true` if the holdings are derived from net assets / price rather than read in the filing."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790278319,
         "data_type": "etf_fundamentals",
         "data": [
          {
           "time": "2026-08-03",
           "ticker": "ARKB",
           "issuer": "Ark/21Shares",
           "period_end": "2026-08-03",
           "balance_date": "2026-06-30",
           "shares_outstanding": 101190000,
           "nav_per_share": 19.47,
           "net_assets_usd": 1889240000,
           "form": "10-Q",
           "filed": "2026-08-06",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1869699/000121390026086191/",
           "btc_holdings": 32178.228,
           "holdings_estimated": false
          },
          {
           "time": "2026-08-02",
           "ticker": "BITB",
           "issuer": "Bitwise",
           "period_end": "2026-08-02",
           "balance_date": "2026-06-30",
           "shares_outstanding": 68160000,
           "nav_per_share": 31.87,
           "net_assets_usd": 2125612000,
           "form": "10-Q",
           "filed": "2026-08-07",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1763415/000119312526340183/",
           "btc_holdings": 36269.90004334071,
           "holdings_estimated": true
          },
          {
           "time": "2026-07-30",
           "ticker": "BRRR",
           "issuer": "CoinShares/Valkyrie",
           "period_end": "2026-07-30",
           "balance_date": "2026-06-30",
           "shares_outstanding": 20895000,
           "nav_per_share": 16.46,
           "net_assets_usd": 342354115,
           "form": "10-Q",
           "filed": "2026-08-12",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1841175/000199937126017701/",
           "btc_holdings": 5841.682080490876,
           "holdings_estimated": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "ETF"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/etf/fundamentals?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/etf/fundamentals\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/etf/fundamentals?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/etf/fundamentals/history": {
   "get": {
    "summary": "ETF fundamentals history",
    "description": "One row per filing and issuer. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_etf_fundamentals_history_v1_etf_fundamentals_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "ticker",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "ETF ticker (e.g. `IBIT`, `FBTC`). Omit for every issuer."
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 2000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "period_end": {
              "type": "string",
              "format": "date",
              "description": "End of the reporting period of the filing.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "ticker": {
              "type": "string",
              "description": "ETF ticker."
             },
             "issuer": {
              "type": "string",
              "description": "ETF issuer."
             },
             "balance_date": {
              "type": "string",
              "format": "date",
              "description": "Date of the balance sheet the holdings come from.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "shares_outstanding": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETF shares outstanding.",
              "x-unit": "shares"
             },
             "nav_per_share": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net asset value per share.",
              "x-unit": "USD"
             },
             "net_assets_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net assets (AUM).",
              "x-unit": "USD"
             },
             "form": {
              "type": "string",
              "description": "SEC form type of the filing (`10-Q`, `10-K`...)."
             },
             "filed": {
              "type": "string",
              "format": "date",
              "description": "Filing date at the SEC.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "filing_url": {
              "type": "string",
              "description": "Link to the filing on SEC EDGAR."
             },
             "btc_holdings": {
              "type": [
               "number",
               "null"
              ],
              "description": "BTC held by the fund.",
              "x-unit": "BTC"
             },
             "holdings_estimated": {
              "type": "boolean",
              "description": "`true` if the holdings are derived from net assets / price rather than read in the filing."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790278974,
         "data_type": "etf_fundamentals_history",
         "data": [
          {
           "time": "2026-08-03",
           "period_end": "2026-08-03",
           "ticker": "ARKB",
           "issuer": "Ark/21Shares",
           "balance_date": "2026-06-30",
           "shares_outstanding": 101190000,
           "nav_per_share": 19.47,
           "net_assets_usd": 1889240000,
           "form": "10-Q",
           "filed": "2026-08-06",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1869699/000121390026086191/",
           "btc_holdings": 32178.228,
           "holdings_estimated": false
          },
          {
           "time": "2026-08-03",
           "period_end": "2026-08-03",
           "ticker": "EZBC",
           "issuer": "Franklin",
           "balance_date": "2026-06-30",
           "shares_outstanding": 9750000,
           "nav_per_share": 34.15,
           "net_assets_usd": 334694929,
           "form": "10-Q",
           "filed": "2026-08-14",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1992870/000114036126033208/",
           "btc_holdings": 5664.0163,
           "holdings_estimated": false
          },
          {
           "time": "2026-08-02",
           "period_end": "2026-08-02",
           "ticker": "BITB",
           "issuer": "Bitwise",
           "balance_date": "2026-06-30",
           "shares_outstanding": 68160000,
           "nav_per_share": 31.87,
           "net_assets_usd": 2125612000,
           "form": "10-Q",
           "filed": "2026-08-07",
           "filing_url": "https://www.sec.gov/Archives/edgar/data/1763415/000119312526340183/",
           "btc_holdings": 36269.90004334071,
           "holdings_estimated": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "ETF"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/etf/fundamentals/history?asset=BTC&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/etf/fundamentals/history\",\n    params={\"asset\": \"BTC\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/etf/fundamentals/history?asset=BTC&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/defi": {
   "get": {
    "summary": "Ethereum DeFi",
    "description": "TVL, DEX volume, TVL / market cap and the 30-day trend.",
    "operationId": "get_defi_v1_eth_defi_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "tvl_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total value locked in Ethereum DeFi.",
             "x-unit": "USD"
            },
            "dex_volume_24h_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "DEX volume over 24 h.",
             "x-unit": "USD"
            },
            "dex_volume_7d_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "DEX volume over 7 days.",
             "x-unit": "USD"
            },
            "eth_market_cap_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH market capitalisation.",
             "x-unit": "USD"
            },
            "defi_health_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "tvl_usd / eth_market_cap_usd.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "trend_30d_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "TVL change over 30 days.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "signal": {
             "type": "string",
             "description": "30-day TVL trend: `growing`, `declining` or `stable`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790303499,
         "data_type": "eth_defi",
         "data": {
          "time": "2026-09-30T17:44:23.604Z",
          "tvl_usd": 53490544615.9211,
          "dex_volume_24h_usd": 2249654934.75,
          "dex_volume_7d_usd": 10117923272.67,
          "eth_market_cap_usd": 327233499795.6087,
          "defi_health_ratio": 0.16346292372061996,
          "trend_30d_pct": -0.5136541328507458,
          "signal": "declining"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/defi\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/defi\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/defi\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/defi/history": {
   "get": {
    "summary": "DeFi history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_defi_history_v1_eth_defi_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "tvl_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total value locked in Ethereum DeFi.",
              "x-unit": "USD"
             },
             "dex_volume_24h_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "DEX volume over 24 h.",
              "x-unit": "USD"
             },
             "dex_volume_7d_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "DEX volume over 7 days.",
              "x-unit": "USD"
             },
             "eth_market_cap_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH market capitalisation.",
              "x-unit": "USD"
             },
             "defi_health_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "tvl_usd / eth_market_cap_usd.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "trend_30d_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "TVL change over 30 days.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "signal": {
              "type": "string",
              "description": "30-day TVL trend: `growing`, `declining` or `stable`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790304152,
         "data_type": "eth_defi_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "tvl_usd": 53405384381.589645,
           "dex_volume_24h_usd": 1775560176.42,
           "dex_volume_7d_usd": 9901392630.21,
           "eth_market_cap_usd": 326953868021.70447,
           "defi_health_ratio": 0.16334226202836782,
           "trend_30d_pct": -3.0525471661838295,
           "signal": "declining"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "tvl_usd": 53404796365.371086,
           "dex_volume_24h_usd": 877956617.37,
           "dex_volume_7d_usd": 10524068113.06,
           "eth_market_cap_usd": 328366469602.105,
           "defi_health_ratio": 0.16263778829209893,
           "trend_30d_pct": -1.4848964788682302,
           "signal": "declining"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "tvl_usd": 53608718060.33713,
           "dex_volume_24h_usd": 927564228,
           "dex_volume_7d_usd": 11027047435.079998,
           "eth_market_cap_usd": 328278373338.84045,
           "defi_health_ratio": 0.1633026187960411,
           "trend_30d_pct": -1.2275951141924373,
           "signal": "declining"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/defi/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/defi/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/defi/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/deflation": {
   "get": {
    "summary": "ETH deflation",
    "description": "24 h burn versus issuance and the annualised net supply change.",
    "operationId": "get_deflation_v1_eth_deflation_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "burn_24h": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH burnt over the last 24 h.",
             "x-unit": "ETH"
            },
            "net_issuance_24h": {
             "type": [
              "number",
              "null"
             ],
             "description": "New ETH issued minus ETH burnt over 24 h. Negative = deflationary.",
             "x-unit": "ETH"
            },
            "annualized_rate_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Net issuance annualised, as a percent of supply. Negative = the supply shrinks.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "zone": {
             "type": "string",
             "description": "`deflationary` (24 h net issuance < 0) or `inflationary`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790300946,
         "data_type": "eth_deflation",
         "data": {
          "time": "2026-09-30T17:44:59.321Z",
          "burn_24h": 230.75186128914356,
          "net_issuance_24h": 2750.036794245243,
          "annualized_rate_pct": 0.8221306029171951,
          "zone": "inflationary"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/deflation\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/deflation\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/deflation\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/deflation/history": {
   "get": {
    "summary": "Deflation history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_deflation_history_v1_eth_deflation_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "burn_24h": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH burnt over the last 24 h.",
              "x-unit": "ETH"
             },
             "net_issuance_24h": {
              "type": [
               "number",
               "null"
              ],
              "description": "New ETH issued minus ETH burnt over 24 h. Negative = deflationary.",
              "x-unit": "ETH"
             },
             "annualized_rate_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net issuance annualised, as a percent of supply. Negative = the supply shrinks.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "zone": {
              "type": "string",
              "description": "`deflationary` (24 h net issuance < 0) or `inflationary`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790301582,
         "data_type": "eth_deflation_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "burn_24h": 259.98423121962696,
           "net_issuance_24h": 2716.8863708376884,
           "annualized_rate_pct": 0.8122384931750257,
           "zone": "inflationary"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "burn_24h": 151.3052807012573,
           "net_issuance_24h": 2796.0945723950863,
           "annualized_rate_pct": 0.8359371251957296,
           "zone": "inflationary"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "burn_24h": 17.35258579440415,
           "net_issuance_24h": 2922.49273596704,
           "annualized_rate_pct": 0.8737458856021223,
           "zone": "inflationary"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/deflation/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/deflation/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/deflation/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/gas": {
   "get": {
    "summary": "Ethereum gas",
    "description": "Gas prices (gwei), base fee, block usage and congestion.",
    "operationId": "get_gas_v1_eth_gas_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "safe_gas_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Gas price for a low-priority transaction.",
             "x-unit": "gwei"
            },
            "propose_gas_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Gas price for a standard transaction.",
             "x-unit": "gwei"
            },
            "fast_gas_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Gas price for a fast transaction.",
             "x-unit": "gwei"
            },
            "base_fee": {
             "type": [
              "number",
              "null"
             ],
             "description": "EIP-1559 base fee (burnt).",
             "x-unit": "gwei"
            },
            "gas_used_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Block gas used / gas target over recent blocks.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "congestion": {
             "type": "string",
             "description": "`low` (gas_used_ratio < 0.5), `normal`, or `high` (> 0.8)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790297214,
         "data_type": "eth_gas",
         "data": {
          "time": "2026-09-30T17:39:58.759Z",
          "safe_gas_price": 0.592738703,
          "propose_gas_price": 0.601074552,
          "fast_gas_price": 0.872012573,
          "base_fee": 0.592738703,
          "gas_used_ratio": 0.61796753183537,
          "congestion": "normal"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/gas\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/gas\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/gas\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/gas-momentum": {
   "get": {
    "summary": "Gas momentum",
    "description": "7-day versus 30-day base fee average: rising or falling demand for block space.",
    "operationId": "get_gas_momentum_v1_eth_gas_momentum_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "base_fee": {
             "type": [
              "number",
              "null"
             ],
             "description": "EIP-1559 base fee (burnt).",
             "x-unit": "gwei"
            },
            "gas_used_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Block gas used / gas target over recent blocks.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "gas_ma7": {
             "type": [
              "number",
              "null"
             ],
             "description": "7-day moving average of the base fee.",
             "x-unit": "gwei"
            },
            "gas_ma30": {
             "type": [
              "number",
              "null"
             ],
             "description": "30-day moving average of the base fee.",
             "x-unit": "gwei"
            },
            "momentum_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Relative gap between the short and the long moving average, in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "regime": {
             "type": "string",
             "description": "`high_demand` (gas_used_ratio > 0.8 and momentum > 0), `low_demand` (< 0.5 and momentum < 0), otherwise `normal`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790298457,
         "data_type": "eth_gas_momentum",
         "data": {
          "time": "2026-09-30T17:39:58.759Z",
          "base_fee": 0.592738703,
          "gas_used_ratio": 0.61796753183537,
          "gas_ma7": 0.7359732017468117,
          "gas_ma30": 0.2898341458721775,
          "momentum_pct": 153.9290874552063,
          "regime": "normal"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/gas-momentum\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/gas-momentum\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/gas-momentum\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/gas-momentum/history": {
   "get": {
    "summary": "Gas momentum history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_gas_momentum_history_v1_eth_gas_momentum_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "base_fee": {
              "type": [
               "number",
               "null"
              ],
              "description": "EIP-1559 base fee (burnt).",
              "x-unit": "gwei"
             },
             "gas_used_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Block gas used / gas target over recent blocks.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "gas_ma7": {
              "type": [
               "number",
               "null"
              ],
              "description": "7-day moving average of the base fee.",
              "x-unit": "gwei"
             },
             "gas_ma30": {
              "type": [
               "number",
               "null"
              ],
              "description": "30-day moving average of the base fee.",
              "x-unit": "gwei"
             },
             "momentum_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Relative gap between the short and the long moving average, in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "regime": {
              "type": "string",
              "description": "`high_demand` (gas_used_ratio > 0.8 and momentum > 0), `low_demand` (< 0.5 and momentum < 0), otherwise `normal`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790299107,
         "data_type": "eth_gas_momentum_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "base_fee": 0.138473642,
           "gas_used_ratio": 0.5602710333333334,
           "gas_ma7": 0.7359732017468116,
           "gas_ma30": 0.28983414587217754,
           "momentum_pct": 153.9290874552062,
           "regime": "normal"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "base_fee": 0.854699776,
           "gas_used_ratio": 0.5104909400000001,
           "gas_ma7": 0.6062514615776523,
           "gas_ma30": 0.25637983670076747,
           "momentum_pct": 136.46612361534338,
           "regime": "normal"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "base_fee": 0.471551096,
           "gas_used_ratio": 0.429017,
           "gas_ma7": 0.4868385049680292,
           "gas_ma30": 0.21765141627727208,
           "momentum_pct": 123.67807813748952,
           "regime": "normal"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/gas-momentum/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/gas-momentum/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/gas-momentum/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/gas/history": {
   "get": {
    "summary": "Gas history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_gas_history_v1_eth_gas_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "safe_gas_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Gas price for a low-priority transaction.",
              "x-unit": "gwei"
             },
             "propose_gas_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Gas price for a standard transaction.",
              "x-unit": "gwei"
             },
             "fast_gas_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Gas price for a fast transaction.",
              "x-unit": "gwei"
             },
             "base_fee": {
              "type": [
               "number",
               "null"
              ],
              "description": "EIP-1559 base fee (burnt).",
              "x-unit": "gwei"
             },
             "gas_used_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Block gas used / gas target over recent blocks.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "congestion": {
              "type": "string",
              "description": "`low` (gas_used_ratio < 0.5), `normal`, or `high` (> 0.8)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790297856,
         "data_type": "eth_gas_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "safe_gas_price": 0.138473643,
           "propose_gas_price": 0.138473643,
           "fast_gas_price": 0.139473642,
           "base_fee": 0.138473642,
           "gas_used_ratio": 0.5602710333333334,
           "congestion": "normal"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "safe_gas_price": 0.854699776,
           "propose_gas_price": 0.855699776,
           "fast_gas_price": 1.366004339,
           "base_fee": 0.854699776,
           "gas_used_ratio": 0.5104909400000001,
           "congestion": "normal"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "safe_gas_price": 0.471551096,
           "propose_gas_price": 0.481651096,
           "fast_gas_price": 0.529816205,
           "base_fee": 0.471551096,
           "gas_used_ratio": 0.429017,
           "congestion": "low"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/gas/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/gas/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/gas/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/ratio": {
   "get": {
    "summary": "ETH/BTC ratio",
    "description": "ETH/BTC price ratio, its 7-day momentum and which asset outperforms.",
    "operationId": "get_ratio_v1_eth_ratio_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "eth_price_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH price.",
             "x-unit": "USD"
            },
            "btc_price_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "BTC price used for the conversion.",
             "x-unit": "USD"
            },
            "eth_btc_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH price / BTC price.",
             "x-unit": "BTC per ETH"
            },
            "momentum_7d_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change of the ETH/BTC ratio over 7 days.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "signal": {
             "type": "string",
             "description": "7-day momentum of ETH/BTC: `eth_outperform` (> 0), `btc_outperform` (< 0) or `neutral`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790304747,
         "data_type": "eth_ratio",
         "data": {
          "time": "2026-09-30T17:42:12.911Z",
          "eth_price_usd": 2680.2,
          "btc_price_usd": 84022.25,
          "eth_btc_ratio": 0.03189869350082865,
          "momentum_7d_pct": 0.7540813503536662,
          "signal": "eth_outperform"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/ratio\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/ratio\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/ratio\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/ratio/history": {
   "get": {
    "summary": "ETH/BTC ratio history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_ratio_history_v1_eth_ratio_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "eth_price_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH price.",
              "x-unit": "USD"
             },
             "btc_price_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "BTC price used for the conversion.",
              "x-unit": "USD"
             },
             "eth_btc_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH price / BTC price.",
              "x-unit": "BTC per ETH"
             },
             "momentum_7d_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Change of the ETH/BTC ratio over 7 days.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "signal": {
              "type": "string",
              "description": "7-day momentum of ETH/BTC: `eth_outperform` (> 0), `btc_outperform` (< 0) or `neutral`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790305400,
         "data_type": "eth_ratio_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "eth_price_usd": 2677.97,
           "btc_price_usd": 83665.62,
           "eth_btc_ratio": 0.03200800998068263,
           "momentum_7d_pct": 0.1693721109489341,
           "signal": "eth_outperform"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "eth_price_usd": 2689.6,
           "btc_price_usd": 83534,
           "eth_btc_ratio": 0.03219766801541887,
           "momentum_7d_pct": 0.44052412357081827,
           "signal": "eth_outperform"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "eth_price_usd": 2688.94,
           "btc_price_usd": 84458.6,
           "eth_btc_ratio": 0.03183737357711352,
           "momentum_7d_pct": -2.319482973188987,
           "signal": "btc_outperform"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/ratio/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/ratio/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/ratio/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/squeeze": {
   "get": {
    "summary": "ETH supply squeeze index",
    "description": "0-100 index combining the staked share and net issuance.",
    "operationId": "get_squeeze_v1_eth_squeeze_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "staking_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Share of the ETH supply staked.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "annualized_rate_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Net issuance annualised, as a percent of supply. Negative = the supply shrinks.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "squeeze_index": {
             "type": [
              "number",
              "null"
             ],
             "description": "Supply squeeze index: combines the staked share and net issuance. Higher = less liquid ETH available.",
             "x-unit": "score from 0 to 100"
            },
            "level": {
             "type": "string",
             "description": "`low` (< 33), `moderate` (>= 33), `high` (>= 66)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790305995,
         "data_type": "eth_squeeze",
         "data": {
          "time": "2026-09-30T17:44:59.321Z",
          "staking_ratio": 0.3603355802690349,
          "annualized_rate_pct": 0.8221306029171951,
          "squeeze_index": 18.427844314910345,
          "level": "low"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/squeeze\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/squeeze\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/squeeze\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/squeeze/history": {
   "get": {
    "summary": "Supply squeeze history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_squeeze_history_v1_eth_squeeze_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "staking_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of the ETH supply staked.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "annualized_rate_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Net issuance annualised, as a percent of supply. Negative = the supply shrinks.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "squeeze_index": {
              "type": [
               "number",
               "null"
              ],
              "description": "Supply squeeze index: combines the staked share and net issuance. Higher = less liquid ETH available.",
              "x-unit": "score from 0 to 100"
             },
             "level": {
              "type": "string",
              "description": "`low` (< 33), `moderate` (>= 33), `high` (>= 66)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790306639,
         "data_type": "eth_squeeze_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "staking_ratio": 0.3600193832972402,
           "annualized_rate_pct": 0.8122384931750257,
           "squeeze_index": 18.40708841144952,
           "level": "low"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "staking_ratio": null,
           "annualized_rate_pct": 0.8359371251957296,
           "squeeze_index": null,
           "level": null
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "staking_ratio": null,
           "annualized_rate_pct": 0.8737458856021223,
           "squeeze_index": null,
           "level": null
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/squeeze/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/squeeze/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/squeeze/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/staking": {
   "get": {
    "summary": "ETH staking",
    "description": "Share of ETH staked, total staked, staking APR and its spread over the Fed funds rate.",
    "operationId": "get_staking_v1_eth_staking_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "staking_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Share of the ETH supply staked.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "total_staked": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH staked (beacon chain).",
             "x-unit": "ETH"
            },
            "total_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total coins issued (circulating + locked), net of burns.",
             "x-unit": "coins"
            },
            "apr_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Annualised rate in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "fed_funds_rate_pct": {
             "type": [
              "number",
              "string",
              "null"
             ],
             "description": "US Fed funds rate, to compare with the staking yield. `null` if unavailable.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "yield_spread_pct": {
             "type": [
              "number",
              "string",
              "null"
             ],
             "description": "Staking APR - Fed funds rate. `null` if unavailable.",
             "x-unit": "percentage points"
            },
            "yield_signal": {
             "type": [
              "number",
              "string",
              "null"
             ],
             "description": "`attractive` (staking APR above the Fed funds rate), `neutral` or `unattractive`. `null` if unavailable."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790302184,
         "data_type": "eth_staking",
         "data": {
          "time": "2026-09-30T17:35:00.287Z",
          "staking_ratio": 0.3603355802690349,
          "total_staked": 43994430.65156249,
          "total_supply": 122092940.74905184,
          "apr_pct": 2.245,
          "fed_funds_rate_pct": null,
          "yield_spread_pct": null,
          "yield_signal": null
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/staking\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/staking\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/staking\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/staking/history": {
   "get": {
    "summary": "Staking history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_staking_history_v1_eth_staking_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "staking_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of the ETH supply staked.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "total_staked": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH staked (beacon chain).",
              "x-unit": "ETH"
             },
             "total_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total coins issued (circulating + locked), net of burns.",
              "x-unit": "coins"
             },
             "apr_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Annualised rate in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "fed_funds_rate_pct": {
              "type": [
               "number",
               "string",
               "null"
              ],
              "description": "US Fed funds rate, to compare with the staking yield. `null` if unavailable.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "yield_spread_pct": {
              "type": [
               "number",
               "string",
               "null"
              ],
              "description": "Staking APR - Fed funds rate. `null` if unavailable.",
              "x-unit": "percentage points"
             },
             "yield_signal": {
              "type": [
               "number",
               "string",
               "null"
              ],
              "description": "`attractive` (staking APR above the Fed funds rate), `neutral` or `unattractive`. `null` if unavailable."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790302873,
         "data_type": "eth_staking_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "staking_ratio": 0.3600193832972402,
           "total_staked": 43954835.166869424,
           "total_supply": 122090190.7122576,
           "apr_pct": 2.312,
           "fed_funds_rate_pct": null,
           "yield_spread_pct": null,
           "yield_signal": null
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "staking_ratio": null,
           "total_staked": null,
           "total_supply": 122087473.82588676,
           "apr_pct": 2.335,
           "fed_funds_rate_pct": null,
           "yield_spread_pct": null,
           "yield_signal": null
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "staking_ratio": null,
           "total_staked": null,
           "total_supply": 122084677.73131436,
           "apr_pct": 2.187,
           "fed_funds_rate_pct": null,
           "yield_spread_pct": null,
           "yield_signal": null
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/staking/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/staking/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/staking/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/supply": {
   "get": {
    "summary": "ETH supply and burn",
    "description": "Supply, staking, burnt fees, withdrawals, 24 h burn and net issuance.",
    "operationId": "get_supply_v1_eth_supply_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "eth_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH supply reported by the source.",
             "x-unit": "ETH"
            },
            "eth2_staking": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH deposited to the beacon chain, as reported by the source.",
             "x-unit": "ETH"
            },
            "burnt_fees": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH burnt since EIP-1559.",
             "x-unit": "ETH"
            },
            "withdrawn_total": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH withdrawn from staking.",
             "x-unit": "ETH"
            },
            "total_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total coins issued (circulating + locked), net of burns.",
             "x-unit": "coins"
            },
            "burn_24h": {
             "type": [
              "number",
              "null"
             ],
             "description": "ETH burnt over the last 24 h.",
             "x-unit": "ETH"
            },
            "net_issuance_24h": {
             "type": [
              "number",
              "null"
             ],
             "description": "New ETH issued minus ETH burnt over 24 h. Negative = deflationary.",
             "x-unit": "ETH"
            },
            "signal": {
             "type": "string",
             "description": "`deflationary` (24 h net issuance < 0), `inflationary` (> 0) or `neutral`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790299703,
         "data_type": "eth_supply",
         "data": {
          "time": "2026-09-30T17:39:58.759Z",
          "eth_supply": 122373866.2178,
          "eth2_staking": 4353987.930188726,
          "burnt_fees": 4634913.398936898,
          "withdrawn_total": 7618584.348954597,
          "total_supply": 122092940.74905184,
          "burn_24h": 230.75186128914356,
          "net_issuance_24h": 2750.036794245243,
          "signal": "inflationary"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/supply\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/supply\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/supply\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/eth/supply/history": {
   "get": {
    "summary": "ETH supply history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_supply_history_v1_eth_supply_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `7d`, `30d`, `90d`, `1y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "eth_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH supply reported by the source.",
              "x-unit": "ETH"
             },
             "eth2_staking": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH deposited to the beacon chain, as reported by the source.",
              "x-unit": "ETH"
             },
             "burnt_fees": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH burnt since EIP-1559.",
              "x-unit": "ETH"
             },
             "withdrawn_total": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH withdrawn from staking.",
              "x-unit": "ETH"
             },
             "total_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total coins issued (circulating + locked), net of burns.",
              "x-unit": "coins"
             },
             "burn_24h": {
              "type": [
               "number",
               "null"
              ],
              "description": "ETH burnt over the last 24 h.",
              "x-unit": "ETH"
             },
             "net_issuance_24h": {
              "type": [
               "number",
               "null"
              ],
              "description": "New ETH issued minus ETH burnt over 24 h. Negative = deflationary.",
              "x-unit": "ETH"
             },
             "signal": {
              "type": "string",
              "description": "`deflationary` (24 h net issuance < 0), `inflationary` (> 0) or `neutral`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790300333,
         "data_type": "eth_supply_history",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "eth_supply": 122373866.2178,
           "eth2_staking": 4351007.141533189,
           "burnt_fees": 4634682.647075609,
           "withdrawn_total": 7618584.348954597,
           "total_supply": 122090190.7122576,
           "burn_24h": 259.98423121962696,
           "net_issuance_24h": 2716.8863708376884,
           "signal": "inflationary"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "eth_supply": 122373866.2178,
           "eth2_staking": 4348030.270931135,
           "burnt_fees": 4634422.66284439,
           "withdrawn_total": 7618584.348954597,
           "total_supply": 122087473.82588676,
           "burn_24h": 151.3052807012573,
           "net_issuance_24h": 2796.0945723950863,
           "signal": "inflationary"
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "eth_supply": 122373866.2178,
           "eth2_staking": 4345082.8710780395,
           "burnt_fees": 4634271.357563688,
           "withdrawn_total": 7618584.348954597,
           "total_supply": 122084677.73131436,
           "burn_24h": 17.35258579440415,
           "net_issuance_24h": 2922.49273596704,
           "signal": "inflationary"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Ethereum"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/eth/supply/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/eth/supply/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/eth/supply/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/fear-greed": {
   "get": {
    "summary": "Crypto Fear & Greed Index",
    "description": "Daily index from 0 (extreme fear) to 100 (extreme greed).",
    "operationId": "get_fear_greed_v1_fear_greed_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "value": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Crypto Fear & Greed Index (alternative.me). 0 = extreme fear, 100 = extreme greed.",
             "x-unit": "score from 0 to 100"
            },
            "value_classification": {
             "type": "string",
             "description": "Label published by alternative.me: `Extreme Fear`, `Fear`, `Neutral`, `Greed` or `Extreme Greed`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790270960,
         "data_type": "fear_greed",
         "data": {
          "time": "2026-09-30T00:00:00.000Z",
          "timestamp": "2026-09-30T00:00:00.000Z",
          "value": 71,
          "value_classification": "Greed"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/fear-greed\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/fear-greed\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/fear-greed\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/fear-greed/history": {
   "get": {
    "summary": "Fear & Greed history",
    "description": "One point per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_fear_greed_history_v1_fear_greed_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "value": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Crypto Fear & Greed Index (alternative.me). 0 = extreme fear, 100 = extreme greed.",
              "x-unit": "score from 0 to 100"
             },
             "value_classification": {
              "type": "string",
              "description": "Label published by alternative.me: `Extreme Fear`, `Fear`, `Neutral`, `Greed` or `Extreme Greed`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790271571,
         "data_type": "fear_greed_history",
         "data": [
          {
           "time": "2026-09-30T00:00:00.000Z",
           "timestamp": "2026-09-30T00:00:00.000Z",
           "value": 71,
           "value_classification": "Greed"
          },
          {
           "time": "2026-09-29T00:00:00.000Z",
           "timestamp": "2026-09-29T00:00:00.000Z",
           "value": 73,
           "value_classification": "Greed"
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "timestamp": "2026-09-28T00:00:00.000Z",
           "value": 74,
           "value_classification": "Greed"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/fear-greed/history?limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/fear-greed/history\",\n    params={\"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/fear-greed/history?limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/funding/cumulative": {
   "get": {
    "summary": "Funding over the last 24 h",
    "description": "Sum of the last three settled 8-hour windows, and its annualised rate.",
    "operationId": "get_funding_cumulative_v1_funding_cumulative_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "cumulative_rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Sum of the last three settled 8-hour funding rates (24 h).",
             "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
            },
            "apr_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Annualised rate in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "window_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of 8-hour funding windows summed.",
             "x-unit": "count"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790259660,
         "data_type": "funding_cumulative_24h",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T08:00:00.000Z",
          "timestamp": "2026-09-30T08:00:00.000Z",
          "cumulative_rate": 0.0001554701434771935,
          "apr_pct": 5.674660236917563,
          "window_count": 3
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/cumulative?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/funding/cumulative\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/funding/cumulative?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/funding/cumulative/history": {
   "get": {
    "summary": "Cumulative funding history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_funding_cumulative_history_v1_funding_cumulative_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "cumulative_rate": {
              "type": [
               "number",
               "null"
              ],
              "description": "Sum of the last three settled 8-hour funding rates (24 h).",
              "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
             },
             "apr_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Annualised rate in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "window_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of 8-hour funding windows summed.",
              "x-unit": "count"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790260359,
         "data_type": "funding_cumulative_24h_history",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T08:00:00.000Z",
           "timestamp": "2026-09-30T08:00:00.000Z",
           "cumulative_rate": 0.0001554701434771935,
           "apr_pct": 5.674660236917563,
           "window_count": 3
          },
          {
           "time": "2026-09-30T00:00:00.000Z",
           "timestamp": "2026-09-30T00:00:00.000Z",
           "cumulative_rate": 0.00011811682942642308,
           "apr_pct": 4.311264274064443,
           "window_count": 3
          },
          {
           "time": "2026-09-29T16:00:00.000Z",
           "timestamp": "2026-09-29T16:00:00.000Z",
           "cumulative_rate": 0.00014946293667145142,
           "apr_pct": 5.455397188507977,
           "window_count": 3
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/cumulative/history?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/funding/cumulative/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/funding/cumulative/history?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/funding/next": {
   "get": {
    "summary": "Next funding forecast",
    "description": "Each venue's forecast of its next settlement, normalised to 8 h and OI-weighted.",
    "operationId": "get_funding_next_v1_funding_next_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "estimated_rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Venue forecast of the NEXT funding settlement, normalised to 8 h, OI-weighted.",
             "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
            },
            "settlement_at": {
             "type": "string",
             "format": "date-time",
             "description": "Instant of the next funding settlement.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "is_past": {
             "type": "boolean",
             "description": "`true` if the forecast settlement instant is already past (the next forecast is not published yet)."
            },
            "exchange_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of venues in the weighted average.",
             "x-unit": "count"
            },
            "apr_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Annualised rate in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790258997,
         "data_type": "funding_next_estimated",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-10-01T00:00:00.000Z",
          "estimated_rate": 0.00005850917027312007,
          "settlement_at": "2026-10-01T00:00:00.000Z",
          "is_past": false,
          "apr_pct": 6.406754144906649
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/next?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/funding/next\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/funding/next?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/funding/rate": {
   "get": {
    "summary": "Latest settled funding rate",
    "description": "The last fully settled 8-hour funding window, normalised to 8 h and weighted by the open interest of each venue at that time. `?live=1` for the window in progress.",
    "operationId": "get_funding_rate_v1_funding_rate_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "bucket": {
             "type": "string",
             "format": "date-time",
             "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Settled funding rate, normalised to an 8-hour period, open-interest weighted across venues.",
             "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
            },
            "apr_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Annualised rate in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "exchange_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of venues in the weighted average.",
             "x-unit": "count"
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790257566,
         "data_type": "funding_rate_8h",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T08:00:00.000Z",
          "bucket": "2026-09-30T08:00:00.000Z",
          "rate": 0.00006287020093464953,
          "apr_pct": 6.884287002344124,
          "is_closed": true
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/rate?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/funding/rate\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/funding/rate?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/funding/rate/history": {
   "get": {
    "summary": "Settled funding history",
    "description": "One row per settled 8-hour window. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_funding_rate_history_v1_funding_rate_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "rate": {
              "type": [
               "number",
               "null"
              ],
              "description": "Settled funding rate, normalised to an 8-hour period, open-interest weighted across venues.",
              "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
             },
             "exchange_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of venues in the weighted average.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             },
             "apr_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Annualised rate in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790258225,
         "data_type": "funding_rate_8h_history",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T08:00:00.000Z",
           "bucket": "2026-09-30T08:00:00.000Z",
           "rate": 0.00006287020093464953,
           "is_closed": true,
           "apr_pct": 6.884287002344124
          },
          {
           "time": "2026-09-30T00:00:00.000Z",
           "bucket": "2026-09-30T00:00:00.000Z",
           "rate": 0.0000189458991289909,
           "is_closed": true,
           "apr_pct": 2.0745759546245033
          },
          {
           "time": "2026-09-29T16:00:00.000Z",
           "bucket": "2026-09-29T16:00:00.000Z",
           "rate": 0.00007365404341355308,
           "is_closed": true,
           "apr_pct": 8.065117753784062
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/funding/rate/history?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/funding/rate/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/funding/rate/history?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/global": {
   "get": {
    "summary": "Total crypto market",
    "description": "Total market capitalisation, 24 h volume and dominance of BTC, ETH and the rest.",
    "operationId": "get_global_v1_global_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "total_market_cap_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total crypto market capitalisation.",
             "x-unit": "USD"
            },
            "total_volume_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total crypto trading volume over 24 h.",
             "x-unit": "USD"
            },
            "btc_dominance_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Bitcoin share of the total market cap.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "eth_dominance_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Ether share of the total market cap.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "others_dominance_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Share of every other asset.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "active_cryptocurrencies": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of tracked crypto assets.",
             "x-unit": "count"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790269775,
         "data_type": "global_market",
         "data": {
          "time": "2026-09-30T17:42:59.999Z",
          "timestamp": "2026-09-30T17:42:59.999Z",
          "total_market_cap_usd": 2874833696756.3394,
          "total_volume_usd": 97265311262.98,
          "btc_dominance_pct": 58.690500129705,
          "eth_dominance_pct": 11.376752459757,
          "others_dominance_pct": 29.932747410538,
          "active_cryptocurrencies": 8167
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/global\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/global\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/global\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/global/history": {
   "get": {
    "summary": "Total crypto market history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_global_history_v1_global_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "total_market_cap_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total crypto market capitalisation.",
              "x-unit": "USD"
             },
             "total_volume_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total crypto trading volume over 24 h.",
              "x-unit": "USD"
             },
             "btc_dominance_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Bitcoin share of the total market cap.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "eth_dominance_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Ether share of the total market cap.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "others_dominance_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of every other asset.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "active_cryptocurrencies": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of tracked crypto assets.",
              "x-unit": "count"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790270360,
         "data_type": "global_market_history",
         "data": [
          {
           "time": "2026-09-30T17:42:59.999Z",
           "timestamp": "2026-09-30T17:42:59.999Z",
           "total_market_cap_usd": 2874833696756.3394,
           "total_volume_usd": 97265311262.98,
           "btc_dominance_pct": 58.690500129705,
           "eth_dominance_pct": 11.376752459757,
           "others_dominance_pct": 29.932747410538,
           "active_cryptocurrencies": 8167
          },
          {
           "time": "2026-09-30T17:37:59.999Z",
           "timestamp": "2026-09-30T17:37:59.999Z",
           "total_market_cap_usd": 2874319286069.3374,
           "total_volume_usd": 97035286246.96,
           "btc_dominance_pct": 58.670416397566,
           "eth_dominance_pct": 11.373890924843,
           "others_dominance_pct": 29.955692677591,
           "active_cryptocurrencies": 8167
          },
          {
           "time": "2026-09-30T17:32:59.999Z",
           "timestamp": "2026-09-30T17:32:59.999Z",
           "total_market_cap_usd": 2878731860046.837,
           "total_volume_usd": 97035651300.5,
           "btc_dominance_pct": 58.666193931145,
           "eth_dominance_pct": 11.376852170647,
           "others_dominance_pct": 29.956953898208,
           "active_cryptocurrencies": 8167
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/global/history?limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/global/history\",\n    params={\"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/global/history?limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/health": {
   "get": {
    "summary": "Service health",
    "operationId": "health_v1_health_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "database": {
           "type": "string"
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790231487,
         "database": "connected"
        }
       }
      }
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "System"
    ],
    "description": "Liveness of the API and its database. No key needed, counted for nobody.",
    "security": [],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl \"https://api.bytnode.com/v1/health\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/health\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/health\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/heatmap/clusters": {
   "get": {
    "summary": "Liquidation heatmap clusters",
    "operationId": "get_heatmap_clusters_v1_heatmap_clusters_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "density_up": {
             "type": [
              "number",
              "null"
             ],
             "description": "Estimated liquidation density of the most attractive cluster ABOVE the price (short positions).",
             "x-unit": "dimensionless score"
            },
            "dist_up": {
             "type": [
              "number",
              "null"
             ],
             "description": "Distance from the price to the cluster above, as a fraction of the price (0.037 = 3.7 % higher).",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "density_down": {
             "type": [
              "number",
              "null"
             ],
             "description": "Estimated liquidation density of the most attractive cluster BELOW the price (long positions).",
             "x-unit": "dimensionless score"
            },
            "dist_down": {
             "type": [
              "number",
              "null"
             ],
             "description": "Distance from the price to the cluster below, as a fraction of the price.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "attraction_up": {
             "type": [
              "number",
              "null"
             ],
             "description": "density_up / dist_up²: how strongly the cluster above pulls the price.",
             "x-unit": "dimensionless score"
            },
            "attraction_down": {
             "type": [
              "number",
              "null"
             ],
             "description": "density_down / dist_down²: how strongly the cluster below pulls the price. Compare with attraction_up.",
             "x-unit": "dimensionless score"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790267332,
         "data_type": "heatmap_clusters",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:36.237Z",
          "timestamp": "2026-09-30T17:43:36.237Z",
          "density_up": 4.381205519726549,
          "dist_up": 0.037029277745770736,
          "density_down": 2.042372012549034,
          "dist_down": 0.010584555024925807,
          "attraction_up": 3195.2374936721594,
          "attraction_down": 18230.12474934765
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "description": "The most attractive cluster of estimated liquidation levels above and below the price, projected from open interest changes and the leverage mix. `attraction` = density / distance²: compare `attraction_up` and `attraction_down` to see where the price has a mechanical reason to go. Not a prediction.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/heatmap/clusters?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/heatmap/clusters\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/heatmap/clusters?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/heatmap/clusters/history": {
   "get": {
    "summary": "Liquidation clusters history",
    "operationId": "get_heatmap_clusters_history_v1_heatmap_clusters_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "density_up": {
              "type": [
               "number",
               "null"
              ],
              "description": "Estimated liquidation density of the most attractive cluster ABOVE the price (short positions).",
              "x-unit": "dimensionless score"
             },
             "dist_up": {
              "type": [
               "number",
               "null"
              ],
              "description": "Distance from the price to the cluster above, as a fraction of the price (0.037 = 3.7 % higher).",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "density_down": {
              "type": [
               "number",
               "null"
              ],
              "description": "Estimated liquidation density of the most attractive cluster BELOW the price (long positions).",
              "x-unit": "dimensionless score"
             },
             "dist_down": {
              "type": [
               "number",
               "null"
              ],
              "description": "Distance from the price to the cluster below, as a fraction of the price.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "attraction_up": {
              "type": [
               "number",
               "null"
              ],
              "description": "density_up / dist_up²: how strongly the cluster above pulls the price.",
              "x-unit": "dimensionless score"
             },
             "attraction_down": {
              "type": [
               "number",
               "null"
              ],
              "description": "density_down / dist_down²: how strongly the cluster below pulls the price. Compare with attraction_up.",
              "x-unit": "dimensionless score"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790267954,
         "data_type": "heatmap_clusters_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "density_up": 5.737933611896139,
           "dist_up": 0.033453183218485505,
           "density_down": 1.4432528637559465,
           "dist_down": 0.019690414816624865,
           "attraction_up": 5127.204277653998,
           "attraction_down": 3722.482776012855,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "density_up": 7.878246185746095,
           "dist_up": 0.03577046128165891,
           "density_down": 5.790287854911657,
           "dist_down": 0.03175910965589645,
           "attraction_up": 6157.160385641724,
           "attraction_down": 5740.682353844244,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "density_up": 8.122598498500858,
           "dist_up": 0.039996657494672884,
           "density_down": 1.652863877001746,
           "dist_down": 0.011573424695145608,
           "attraction_up": 5077.4726000692,
           "attraction_down": 12339.947386970793,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/heatmap/clusters/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/heatmap/clusters/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/heatmap/clusters/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/indicators": {
   "post": {
    "summary": "Compute technical indicators",
    "operationId": "post_indicators_v1_indicators_post",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/IndicatorsRequest"
       },
       "example": {
        "symbol": "BTCUSDT",
        "timeframe": "1h",
        "results": 3,
        "indicators": [
         {
          "id": "rsi_fast",
          "type": "rsi",
          "period": 14
         },
         {
          "id": "macd",
          "type": "macd",
          "fast": 12,
          "slow": 26,
          "signal": 9
         },
         {
          "id": "bb_mid",
          "type": "bb",
          "period": 20
         }
        ]
       }
      }
     },
     "required": true
    },
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "timeframe": {
             "type": "string",
             "description": "Bucket size of the row."
            },
            "results": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of values per indicator.",
             "x-unit": "count"
            },
            "indicators": {
             "type": "object",
             "properties": {
              "rsi_fast": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date-time",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "type": {
                 "type": "string",
                 "description": "Indicator type."
                },
                "period": {
                 "type": [
                  "integer",
                  "null"
                 ],
                 "description": "Look-back period of the indicator, in candles.",
                 "x-unit": "candles"
                },
                "values": {
                 "type": "array",
                 "items": {
                  "type": [
                   "number",
                   "null"
                  ]
                 },
                 "description": "Indicator values, oldest to newest; an object of arrays for multi-output indicators (MACD, Bollinger...).",
                 "x-unit": "quote currency (USDT for BTCUSDT)"
                },
                "as_of": {
                 "type": "string",
                 "format": "date-time",
                 "description": "Time of the candle of the last value.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                }
               }
              },
              "macd": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date-time",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "type": {
                 "type": "string",
                 "description": "Indicator type."
                },
                "fast": {
                 "type": [
                  "integer",
                  "null"
                 ],
                 "description": "Fast period, in candles.",
                 "x-unit": "candles"
                },
                "slow": {
                 "type": [
                  "integer",
                  "null"
                 ],
                 "description": "Slow period, in candles.",
                 "x-unit": "candles"
                },
                "signal": {
                 "type": [
                  "integer",
                  "null"
                 ],
                 "description": "MACD signal period, in candles.",
                 "x-unit": "candles"
                },
                "values": {
                 "type": "object",
                 "properties": {
                  "macd": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   }
                  },
                  "signal": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   },
                   "description": "MACD signal period, in candles.",
                   "x-unit": "candles"
                  },
                  "histogram": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   }
                  }
                 },
                 "description": "Indicator values, oldest to newest; an object of arrays for multi-output indicators (MACD, Bollinger...).",
                 "x-unit": "quote currency (USDT for BTCUSDT)"
                },
                "as_of": {
                 "type": "string",
                 "format": "date-time",
                 "description": "Time of the candle of the last value.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                }
               }
              },
              "bb_mid": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date-time",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "type": {
                 "type": "string",
                 "description": "Indicator type."
                },
                "period": {
                 "type": [
                  "integer",
                  "null"
                 ],
                 "description": "Look-back period of the indicator, in candles.",
                 "x-unit": "candles"
                },
                "std": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Band width, in standard deviations.",
                 "x-unit": "standard deviations"
                },
                "values": {
                 "type": "object",
                 "properties": {
                  "upper": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   }
                  },
                  "middle": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   }
                  },
                  "lower": {
                   "type": "array",
                   "items": {
                    "type": [
                     "number",
                     "null"
                    ]
                   }
                  }
                 },
                 "description": "Indicator values, oldest to newest; an object of arrays for multi-output indicators (MACD, Bollinger...).",
                 "x-unit": "quote currency (USDT for BTCUSDT)"
                },
                "as_of": {
                 "type": "string",
                 "format": "date-time",
                 "description": "Time of the candle of the last value.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                }
               }
              }
             },
             "description": "One entry per requested indicator id: its parameters, `values` (oldest to newest) and `as_of` (time of the last value)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790312091,
         "data_type": "indicators",
         "data": {
          "symbol": "BTCUSDT",
          "timeframe": "1h",
          "results": 3,
          "indicators": {
           "rsi_fast": {
            "time": "2026-09-30T16:00:00.000Z",
            "type": "rsi",
            "period": 14,
            "values": [
             50.8131287181248,
             54.16981376214668,
             56.23763630767805
            ],
            "as_of": "2026-09-30T16:00:00.000Z"
           },
           "macd": {
            "time": "2026-09-30T16:00:00.000Z",
            "type": "macd",
            "fast": 12,
            "slow": 26,
            "signal": 9,
            "values": {
             "macd": [
              174.52954986991244,
              179.8107200126251,
              199.05105878527684
             ],
             "signal": [
              55.094238485326706,
              80.03753479078638,
              103.84023958968447
             ],
             "histogram": [
              119.43531138458573,
              99.77318522183872,
              95.21081919559236
             ]
            },
            "as_of": "2026-09-30T16:00:00.000Z"
           },
           "bb_mid": {
            "time": "2026-09-30T16:00:00.000Z",
            "type": "bb",
            "period": 20,
            "std": 2,
            "values": {
             "upper": [
              84660.956588588,
              84710.15098467488,
              84787.943777102
             ],
             "middle": [
              83638.72449999998,
              83665.74549999999,
              83702.39799999999
             ],
             "lower": [
              82616.49241141196,
              82621.3400153251,
              82616.85222289797
             ]
            },
            "as_of": "2026-09-30T16:00:00.000Z"
           }
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Technical indicators"
    ],
    "description": "POST a JSON body: `symbol`, `timeframe`, `results` (values per indicator) and `indicators`, a list of `{id, type, <parameters flat>}` — e.g. `{\"id\": \"rsi_fast\", \"type\": \"rsi\", \"period\": 14}`. A nested `\"parameters\": {...}` object is also accepted. Computed on the same candles as `/v1/raw/klines`; `results + warm-up` is capped at 1000 candles. Errors on the body are 400 `invalid_indicator`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -X POST -H \"X-API-KEY: $BYTNODE_API_KEY\" -H \"Content-Type: application/json\" \\\n  -d '{\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"results\": 3, \"indicators\": [{\"id\": \"rsi_fast\", \"type\": \"rsi\", \"period\": 14}, {\"id\": \"macd\", \"type\": \"macd\", \"fast\": 12, \"slow\": 26, \"signal\": 9}, {\"id\": \"bb_mid\", \"type\": \"bb\", \"period\": 20}]}' \\\n  https://api.bytnode.com/v1/indicators"
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.post(\n    \"https://api.bytnode.com/v1/indicators\",\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    json={\n    \"symbol\": \"BTCUSDT\",\n    \"timeframe\": \"1h\",\n    \"results\": 3,\n    \"indicators\": [\n        {\n            \"id\": \"rsi_fast\",\n            \"type\": \"rsi\",\n            \"period\": 14\n        },\n        {\n            \"id\": \"macd\",\n            \"type\": \"macd\",\n            \"fast\": 12,\n            \"slow\": 26,\n            \"signal\": 9\n        },\n        {\n            \"id\": \"bb_mid\",\n            \"type\": \"bb\",\n            \"period\": 20\n        }\n    ]\n},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     }
    ]
   }
  },
  "/v1/liquidations/cumulative": {
   "get": {
    "summary": "Liquidations over the last 5 minutes",
    "operationId": "get_liq_cumulative_v1_liquidations_cumulative_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "long_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Long positions liquidated, USD.",
             "x-unit": "USD"
            },
            "short_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Short positions liquidated, USD.",
             "x-unit": "USD"
            },
            "total_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total, USD.",
             "x-unit": "USD"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790264918,
         "data_type": "liquidations_cumulative",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:37.551Z",
          "timestamp": "2026-09-30T17:43:37.551Z",
          "long_usd": 0,
          "short_usd": 24959.637600000002,
          "total_usd": 24959.637600000002
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "description": "Longs and shorts liquidated, USD, all venues.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/liquidations/cumulative?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/liquidations/cumulative\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/liquidations/cumulative?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/liquidations/cumulative/history": {
   "get": {
    "summary": "Cumulative liquidations history",
    "operationId": "get_liq_cumulative_history_v1_liquidations_cumulative_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "long_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Long positions liquidated, USD.",
              "x-unit": "USD"
             },
             "short_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Short positions liquidated, USD.",
              "x-unit": "USD"
             },
             "total_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total, USD.",
              "x-unit": "USD"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790265502,
         "data_type": "liquidations_cumulative_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "long_usd": 0,
           "short_usd": 0,
           "total_usd": 0,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "long_usd": 0,
           "short_usd": 0,
           "total_usd": 0,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "long_usd": 0,
           "short_usd": 298657.3881799999,
           "total_usd": 298657.3881799999,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/liquidations/cumulative/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/liquidations/cumulative/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/liquidations/cumulative/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/liquidations/ratio": {
   "get": {
    "summary": "Big vs small liquidations",
    "description": "Liquidations of 100,000 USD or more versus smaller ones over the latest minute with liquidations: counts, USD and ratio. A high ratio = large positions are being flushed.",
    "operationId": "get_liquidations_ratio_v1_liquidations_ratio_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "big_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Liquidations of 100,000 USD or more.",
             "x-unit": "count"
            },
            "big_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Notional of liquidations of 100,000 USD or more.",
             "x-unit": "USD"
            },
            "small_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Liquidations below 100,000 USD.",
             "x-unit": "count"
            },
            "small_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Notional of liquidations below 100,000 USD.",
             "x-unit": "USD"
            },
            "ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "big_usd / small_usd: how much of the liquidated notional comes from liquidations of 100,000 USD or more. `null` when small_usd is 0.",
             "x-unit": "big / small"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790266098,
         "data_type": "liquidation_ratio",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:42:37.587Z",
          "big_count": 0,
          "big_usd": 0,
          "small_count": 1,
          "small_usd": 24959.637600000002,
          "ratio": 0,
          "timestamp": "2026-09-30T17:42:37.587Z"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/liquidations/ratio?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/liquidations/ratio\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/liquidations/ratio?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/liquidations/ratio/history": {
   "get": {
    "summary": "Big vs small liquidations history",
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_liquidations_ratio_history_v1_liquidations_ratio_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "big_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Liquidations of 100,000 USD or more.",
              "x-unit": "count"
             },
             "big_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional of liquidations of 100,000 USD or more.",
              "x-unit": "USD"
             },
             "small_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Liquidations below 100,000 USD.",
              "x-unit": "count"
             },
             "small_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional of liquidations below 100,000 USD.",
              "x-unit": "USD"
             },
             "ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "big_usd / small_usd: how much of the liquidated notional comes from liquidations of 100,000 USD or more. `null` when small_usd is 0.",
              "x-unit": "big / small"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790266714,
         "data_type": "liquidation_ratio_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "big_count": 3,
           "big_usd": 686762.855,
           "small_count": 48,
           "small_usd": 233046.83456,
           "ratio": 2.946887720215684,
           "points": 16,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "big_count": 1,
           "big_usd": 103179.4957,
           "small_count": 89,
           "small_usd": 782962.43066,
           "ratio": 0.13178090245406107,
           "points": 19,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "big_count": 14,
           "big_usd": 3831670.9821800003,
           "small_count": 338,
           "small_usd": 3095117.8715999993,
           "ratio": 1.2379725558559245,
           "points": 32,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/liquidations/ratio/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/liquidations/ratio/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/liquidations/ratio/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/ls-ratio": {
   "get": {
    "summary": "Long/short account ratio",
    "description": "Share of accounts long, composite across venues weighted by open interest. Accounts, not volume. No `1m` timeframe. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_ls_ratio_v1_ls_ratio_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "`5m`, `15m`, `30m`, `1h`, `4h` or `1d` — no `1m`: no venue publishes a 1-minute account ratio.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timeframe": {
             "type": "string",
             "description": "Bucket size of the row."
            },
            "part_long": {
             "type": [
              "number",
              "null"
             ],
             "description": "Share of ACCOUNTS long (0.57 = 57 % of accounts are long). Accounts, not volume.",
             "x-unit": "fraction (0.585 = 58.5 %)"
            },
            "ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Long ACCOUNTS / short accounts (1.35 = 35 % more long accounts). Composite across venues, OI-weighted.",
             "x-unit": "longs / shorts"
            },
            "venue_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of venues that contributed to the value.",
             "x-unit": "count"
            },
            "weighting": {
             "type": "string",
             "description": "How venues are combined: `oi` (open-interest weighted) or `volume` (volume weighted)."
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790263708,
         "data_type": "ls_ratio_composite",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T16:00:00.000Z",
          "timestamp": "2026-09-30T16:00:00.000Z",
          "timeframe": "1h",
          "part_long": 0.5744708637730429,
          "ratio": 1.3500153452868322,
          "weighting": "oi",
          "is_closed": true
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/ls-ratio?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/ls-ratio\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/ls-ratio?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/ls-ratio/history": {
   "get": {
    "summary": "Long/short ratio history",
    "description": "Same as `/v1/ls-ratio`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_ls_ratio_history_v1_ls_ratio_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "`5m`, `15m`, `30m`, `1h`, `4h` or `1d` — no `1m`: no venue publishes a 1-minute account ratio.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 500,
       "minimum": 1,
       "default": 30
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timeframe": {
              "type": "string",
              "description": "Bucket size of the row."
             },
             "part_long": {
              "type": [
               "number",
               "null"
              ],
              "description": "Share of ACCOUNTS long (0.57 = 57 % of accounts are long). Accounts, not volume.",
              "x-unit": "fraction (0.585 = 58.5 %)"
             },
             "ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Long ACCOUNTS / short accounts (1.35 = 35 % more long accounts). Composite across venues, OI-weighted.",
              "x-unit": "longs / shorts"
             },
             "venue_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of venues that contributed to the value.",
              "x-unit": "count"
             },
             "weighting": {
              "type": "string",
              "description": "How venues are combined: `oi` (open-interest weighted) or `volume` (volume weighted)."
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790264321,
         "data_type": "ls_ratio_composite_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "timeframe": "1h",
           "part_long": 0.5744708637730429,
           "ratio": 1.3500153452868322,
           "weighting": "oi",
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "timeframe": "1h",
           "part_long": 0.5750662788177455,
           "ratio": 1.3533081752556395,
           "weighting": "oi",
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "timeframe": "1h",
           "part_long": 0.5595834191896681,
           "ratio": 1.270577547648362,
           "weighting": "oi",
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/ls-ratio/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/ls-ratio/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/ls-ratio/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro": {
   "get": {
    "summary": "Latest macro values",
    "description": "Latest value of one FRED series, or of every active series when `series` is omitted (then `data` is a list).",
    "operationId": "get_macro_v1_macro_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "series",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "FRED series id (e.g. `DGS10`). Omit to get the latest value of EVERY active series.",
      "example": "DGS10"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "series_id": {
             "type": "string",
             "description": "Series identifier."
            },
            "category": {
             "type": "string",
             "description": "Series category."
            },
            "label": {
             "type": "string",
             "description": "Human-readable name."
            },
            "frequency": {
             "type": "string",
             "description": "Publication frequency of the source (`daily`, `weekly`, `monthly`)."
            },
            "units": {
             "type": "string",
             "description": "Unit of `value` as published by the source."
            },
            "date": {
             "type": "string",
             "format": "date",
             "description": "Calendar day the value refers to.",
             "x-unit": "calendar date (YYYY-MM-DD)"
            },
            "value": {
             "type": [
              "number",
              "null"
             ],
             "description": "Latest value of the series, in the unit given by `units`.",
             "x-unit": "see `units`"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790272185,
         "data_type": "macro",
         "data": {
          "time": "2026-09-28",
          "series_id": "DGS10",
          "category": "rates",
          "label": "Treasury 10Y",
          "frequency": "daily",
          "units": "%",
          "date": "2026-09-28",
          "value": 5.24
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro?series=DGS10\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro\",\n    params={\"series\": \"DGS10\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro?series=DGS10\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/correlations": {
   "get": {
    "summary": "BTC correlation with macro",
    "description": "Rolling Pearson correlation of BTC daily returns with the dollar index, the S&P 500, gold and the VIX, over 30 and 90 days.",
    "operationId": "get_macro_correlations_v1_macro_correlations_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "method": {
             "type": "string",
             "description": "How the value is computed."
            },
            "correlations": {
             "type": "object",
             "properties": {
              "dxy": {
               "type": "object",
               "properties": {
                "30d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                },
                "90d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                }
               },
               "description": "US Dollar Index.",
               "x-unit": "index points"
              },
              "sp500": {
               "type": "object",
               "properties": {
                "30d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                },
                "90d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                }
               },
               "description": "S&P 500.",
               "x-unit": "index points"
              },
              "gold": {
               "type": "object",
               "properties": {
                "30d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                },
                "90d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                }
               },
               "description": "Gold price.",
               "x-unit": "USD per troy ounce"
              },
              "vix": {
               "type": "object",
               "properties": {
                "30d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                },
                "90d": {
                 "type": "object",
                 "properties": {
                  "correlation": {
                   "type": [
                    "number",
                    "null"
                   ],
                   "description": "Pearson correlation of daily returns.",
                   "x-unit": "from -1 to 1"
                  },
                  "n": {
                   "type": [
                    "integer",
                    "null"
                   ],
                   "description": "Number of days used.",
                   "x-unit": "count"
                  }
                 }
                }
               },
               "description": "CBOE Volatility Index.",
               "x-unit": "index points"
              }
             },
             "description": "Pearson correlation from -1 to 1, per macro series and window, with `n` = number of common days.",
             "x-unit": "dimensionless ratio"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790274029,
         "data_type": "macro_correlations",
         "data": {
          "asset": "BTC",
          "method": "Pearson correlation of daily returns (common dates), rolling window",
          "correlations": {
           "dxy": {
            "30d": {
             "correlation": -0.2916,
             "n": 19
            },
            "90d": {
             "correlation": -0.3964,
             "n": 60
            }
           },
           "sp500": {
            "30d": {
             "correlation": 0.6678,
             "n": 21
            },
            "90d": {
             "correlation": 0.3802,
             "n": 62
            }
           },
           "gold": {
            "30d": {
             "correlation": 0.452,
             "n": 30
            },
            "90d": {
             "correlation": 0.5598,
             "n": 90
            }
           },
           "vix": {
            "30d": {
             "correlation": -0.3265,
             "n": 22
            },
            "90d": {
             "correlation": -0.3002,
             "n": 64
            }
           }
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/correlations\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/correlations\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/correlations\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/history": {
   "get": {
    "summary": "Macro series history",
    "description": "Values of one series at its native frequency. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_macro_history_v1_macro_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "series",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "FRED series id, e.g. `DGS10`, `CPIAUCSL`, `WALCL`. The list: `GET /v1/macro/series`.",
      "example": "DGS10"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Value of the series on `date`.",
              "x-unit": "see the series `units`"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790273427,
         "data_type": "macro_history",
         "data": [
          {
           "time": "2026-09-28",
           "date": "2026-09-28",
           "value": 5.24
          },
          {
           "time": "2026-09-25",
           "date": "2026-09-25",
           "value": 5.17
          },
          {
           "time": "2026-09-24",
           "date": "2026-09-24",
           "value": 5.18
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/history?series=DGS10&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/history\",\n    params={\"series\": \"DGS10\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/history?series=DGS10&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/intraday/history": {
   "get": {
    "summary": "Intraday macro candles",
    "description": "OHLCV candles of one instrument. `data` is an object `{series, timeframe, candles}`, candles most recent first.",
    "operationId": "get_macro_intraday_history_v1_macro_intraday_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 500
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "series",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "The `series_id` returned by `GET /v1/macro/intraday/series` (e.g. `EURUSD`, `DXY_ICE`, `VIX_CBOE`). The `instrument_code` column is NOT accepted.",
      "example": "EURUSD"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Candle size. Optional, default `1h`. Each series serves only the timeframes listed in its catalogue entry; others return 400 `timeframe_not_served`.",
      "example": "1h"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "series": {
             "type": "string",
             "description": "Series identifier."
            },
            "timeframe": {
             "type": "string",
             "description": "Bucket size of the row."
            },
            "candles": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "time": {
                "type": "string",
                "format": "date-time",
                "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
               },
               "open": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Open.",
                "x-unit": "series unit"
               },
               "high": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "High.",
                "x-unit": "series unit"
               },
               "low": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Low.",
                "x-unit": "series unit"
               },
               "close": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Close.",
                "x-unit": "series unit"
               },
               "volume": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Volume reported by the source for this instrument (not the whole market).",
                "x-unit": "see `volume_kind`"
               }
              }
             },
             "description": "OHLCV candles, most recent first."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790277694,
         "data_type": "macro_intraday_history",
         "timeframe": "1h",
         "data": {
          "series": "EURUSD",
          "timeframe": "1h",
          "candles": [
           {
            "time": "2026-09-28T23:00:00.000Z",
            "open": 1.13714,
            "high": 1.13719,
            "low": 1.13698,
            "close": 1.13708,
            "volume": 1074.929991543293
           },
           {
            "time": "2026-09-28T22:00:00.000Z",
            "open": 1.13673,
            "high": 1.1374,
            "low": 1.13665,
            "close": 1.13715,
            "volume": 1763.1900064647198
           },
           {
            "time": "2026-09-28T21:00:00.000Z",
            "open": 1.13702,
            "high": 1.13702,
            "low": 1.13643,
            "close": 1.13673,
            "volume": 2544.100001811981
           }
          ]
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/intraday/history?series=EURUSD&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/intraday/history\",\n    params={\"series\": \"EURUSD\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/intraday/history?series=EURUSD&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/intraday/series": {
   "get": {
    "summary": "Intraday macro instruments",
    "description": "Instruments with intraday candles (FX, dollar index, gold, oil, US yields, VIX...), the timeframes each serves, their history depth and last candle.",
    "operationId": "get_macro_intraday_series_v1_macro_intraday_series_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "series_id": {
              "type": "string",
              "description": "Series identifier."
             },
             "source": {
              "type": "string",
              "description": "Upstream source."
             },
             "instrument_code": {
              "type": "string",
              "description": "Code of the instrument at the source (informative; use `series_id` in requests)."
             },
             "category": {
              "type": "string",
              "description": "Series category."
             },
             "label": {
              "type": "string",
              "description": "Human-readable name."
             },
             "units": {
              "type": "string",
              "description": "Unit of `value` as published by the source."
             },
             "volume_kind": {
              "type": "string",
              "description": "What `volume` measures for this instrument (`broker` = the source's own flow, not the whole market)."
             },
             "timeframes": {
              "type": "array",
              "items": {
               "type": "string"
              },
              "description": "Timeframes natively collected for the series."
             },
             "depth_start": {
              "type": "string",
              "format": "date",
              "description": "First day of available history.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "last_candle": {
              "type": "object",
              "properties": {
               "1m": {
                "type": "string",
                "format": "date-time"
               },
               "5m": {
                "type": "string",
                "format": "date-time"
               },
               "15m": {
                "type": "string",
                "format": "date-time"
               },
               "1h": {
                "type": "string",
                "format": "date-time"
               },
               "4h": {
                "type": "string",
                "format": "date-time"
               },
               "1d": {
                "type": "string",
                "format": "date-time"
               }
              },
              "description": "Last candle available, per timeframe.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790277084,
         "data_type": "macro_intraday_series",
         "data": [
          {
           "series_id": "DXY_ICE",
           "source": "dukascopy",
           "instrument_code": "DOLLARIDXUSD",
           "category": "fx",
           "label": "ICE Dollar Index",
           "units": "Index",
           "volume_kind": "broker",
           "timeframes": [
            "1m",
            "5m",
            "15m"
           ],
           "depth_start": "2017-12-01",
           "last_candle": {
            "1m": "2026-09-28T20:59:00.000Z",
            "5m": "2026-09-28T20:55:00.000Z",
            "15m": "2026-09-28T20:45:00.000Z",
            "1h": "2026-09-28T20:00:00.000Z",
            "4h": "2026-09-28T20:00:00.000Z",
            "1d": "2026-09-28T00:00:00.000Z"
           }
          },
          {
           "series_id": "EURUSD",
           "source": "dukascopy",
           "instrument_code": "EURUSD",
           "category": "fx",
           "label": "EUR/USD",
           "units": "USD per EUR",
           "volume_kind": "broker",
           "timeframes": [
            "1m",
            "5m",
            "15m"
           ],
           "depth_start": "2003-05-04",
           "last_candle": {
            "1m": "2026-09-28T23:59:00.000Z",
            "5m": "2026-09-28T23:55:00.000Z",
            "15m": "2026-09-28T23:45:00.000Z",
            "1h": "2026-09-28T23:00:00.000Z",
            "4h": "2026-09-28T20:00:00.000Z",
            "1d": "2026-09-28T00:00:00.000Z"
           }
          },
          {
           "series_id": "IXIC",
           "source": "yahoo",
           "instrument_code": "^IXIC",
           "category": "equities",
           "label": "NASDAQ Composite",
           "units": "Index",
           "volume_kind": "none",
           "timeframes": [
            "1d"
           ],
           "depth_start": "2016-01-01",
           "last_candle": {
            "1d": "2026-09-29T00:00:00.000Z"
           }
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/intraday/series\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/intraday/series\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/intraday/series\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/momentum": {
   "get": {
    "summary": "Macro momentum score",
    "description": "A -100 to +100 score of macro tailwind for crypto (money supply, Fed balance sheet, dollar) over 30 and 90 days, with each input's contribution.",
    "operationId": "get_macro_momentum_v1_macro_momentum_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "scale": {
             "type": "string",
             "description": "Reading scale of the score."
            },
            "30d": {
             "type": "object",
             "properties": {
              "score": {
               "type": [
                "number",
                "null"
               ],
               "description": "Macro momentum for crypto: positive = macro tailwind (weaker dollar, growing liquidity).",
               "x-unit": "score from -100 to +100"
              },
              "components": {
               "type": "array",
               "items": {
                "type": "object",
                "properties": {
                 "metric": {
                  "type": "string",
                  "description": "Input name."
                 },
                 "roc_pct": {
                  "type": [
                   "number",
                   "null"
                  ],
                  "description": "Rate of change of the input over the window.",
                  "x-unit": "percent (58.5 = 58.5 %)"
                 },
                 "contribution": {
                  "type": [
                   "number",
                   "null"
                  ],
                  "description": "Contribution of the input to the score.",
                  "x-unit": "dimensionless score"
                 }
                }
               },
               "description": "The inputs of the score and their contributions."
              }
             }
            },
            "90d": {
             "type": "object",
             "properties": {
              "score": {
               "type": [
                "number",
                "null"
               ],
               "description": "Macro momentum for crypto: positive = macro tailwind (weaker dollar, growing liquidity).",
               "x-unit": "score from -100 to +100"
              },
              "components": {
               "type": "array",
               "items": {
                "type": "object",
                "properties": {
                 "metric": {
                  "type": "string",
                  "description": "Input name."
                 },
                 "roc_pct": {
                  "type": [
                   "number",
                   "null"
                  ],
                  "description": "Rate of change of the input over the window.",
                  "x-unit": "percent (58.5 = 58.5 %)"
                 },
                 "contribution": {
                  "type": [
                   "number",
                   "null"
                  ],
                  "description": "Contribution of the input to the score.",
                  "x-unit": "dimensionless score"
                 }
                }
               },
               "description": "The inputs of the score and their contributions."
              }
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790274648,
         "data_type": "macro_momentum",
         "data": {
          "scale": "-100 (bearish) .. +100 (bullish crypto)",
          "30d": {
           "score": 3.2,
           "components": [
            {
             "metric": "dxy",
             "roc_pct": 1.591,
             "contribution": -63.6
            },
            {
             "metric": "m2",
             "roc_pct": 0.538,
             "contribution": 71.7
            },
            {
             "metric": "fed_balance_sheet",
             "roc_pct": 0.03,
             "contribution": 1.5
            }
           ]
          },
          "90d": {
           "score": 28.1,
           "components": [
            {
             "metric": "dxy",
             "roc_pct": -0.46,
             "contribution": 9.2
            },
            {
             "metric": "m2",
             "roc_pct": 1.43,
             "contribution": 71.5
            },
            {
             "metric": "fed_balance_sheet",
             "roc_pct": 0.179,
             "contribution": 3.6
            }
           ]
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/momentum\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/momentum\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/momentum\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/net-liquidity": {
   "get": {
    "summary": "US net liquidity",
    "description": "Fed balance sheet minus Treasury General Account minus overnight reverse repo, with its components.",
    "operationId": "get_net_liquidity_v1_macro_net_liquidity_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "net_liquidity_musd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Fed balance sheet (WALCL) - Treasury General Account (TGA) - overnight reverse repo (ON RRP).",
             "x-unit": "millions of USD"
            },
            "net_liquidity_usd": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Same as net_liquidity_musd, in USD.",
             "x-unit": "USD"
            },
            "unit": {
             "type": "string",
             "description": "Unit of the value."
            },
            "formula": {
             "type": "string",
             "description": "Formula used."
            },
            "components": {
             "type": "object",
             "properties": {
              "walcl": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "value": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Value of the series.",
                 "x-unit": "dimensionless score"
                },
                "unit": {
                 "type": "string",
                 "description": "Unit of the value."
                },
                "date": {
                 "type": "string",
                 "format": "date",
                 "description": "Calendar day the value refers to.",
                 "x-unit": "calendar date (YYYY-MM-DD)"
                }
               }
              },
              "tga": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "value": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Value of the series.",
                 "x-unit": "dimensionless score"
                },
                "unit": {
                 "type": "string",
                 "description": "Unit of the value."
                },
                "date": {
                 "type": "string",
                 "format": "date",
                 "description": "Calendar day the value refers to.",
                 "x-unit": "calendar date (YYYY-MM-DD)"
                }
               }
              },
              "rrp": {
               "type": "object",
               "properties": {
                "time": {
                 "type": "string",
                 "format": "date",
                 "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                 "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
                },
                "value": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Value of the series.",
                 "x-unit": "dimensionless score"
                },
                "unit": {
                 "type": "string",
                 "description": "Unit of the value."
                },
                "date": {
                 "type": "string",
                 "format": "date",
                 "description": "Calendar day the value refers to.",
                 "x-unit": "calendar date (YYYY-MM-DD)"
                }
               }
              }
             },
             "description": "The inputs of the score and their contributions."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790275860,
         "data_type": "macro_net_liquidity",
         "data": {
          "net_liquidity_musd": 5759174,
          "net_liquidity_usd": 5759174000000,
          "unit": "USD (millions)",
          "formula": "WALCL - TGA(WTREGEN) - ON_RRP(RRPONTSYD x 1000)",
          "components": {
           "walcl": {
            "time": "2026-09-23",
            "value": 6747704,
            "unit": "Millions of $",
            "date": "2026-09-23"
           },
           "tga": {
            "time": "2026-09-23",
            "value": 977084,
            "unit": "Millions of $",
            "date": "2026-09-23"
           },
           "rrp": {
            "time": "2026-09-29",
            "value": 11.446,
            "unit": "Billions of $",
            "date": "2026-09-29"
           }
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/net-liquidity\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/net-liquidity\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/net-liquidity\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/net-liquidity/history": {
   "get": {
    "summary": "Net liquidity history",
    "description": "Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_net_liquidity_history_v1_macro_net_liquidity_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 180
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "walcl_musd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Fed total assets (WALCL).",
              "x-unit": "millions of USD"
             },
             "tga_musd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Treasury General Account (WTREGEN).",
              "x-unit": "millions of USD"
             },
             "rrp_busd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Overnight reverse repo (RRPONTSYD).",
              "x-unit": "billions of USD"
             },
             "net_liquidity_musd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Fed balance sheet (WALCL) - Treasury General Account (TGA) - overnight reverse repo (ON RRP).",
              "x-unit": "millions of USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790276451,
         "data_type": "macro_net_liquidity_history",
         "data": [
          {
           "time": "2026-09-29",
           "date": "2026-09-29",
           "walcl_musd": 6747704,
           "tga_musd": 977084,
           "rrp_busd": 11.446,
           "net_liquidity_musd": 5759174
          },
          {
           "time": "2026-09-28",
           "date": "2026-09-28",
           "walcl_musd": 6747704,
           "tga_musd": 977084,
           "rrp_busd": 0.851,
           "net_liquidity_musd": 5769769
          },
          {
           "time": "2026-09-25",
           "date": "2026-09-25",
           "walcl_musd": 6747704,
           "tga_musd": 977084,
           "rrp_busd": 0.576,
           "net_liquidity_musd": 5770044
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/net-liquidity/history?limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/net-liquidity/history\",\n    params={\"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/net-liquidity/history?limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/risk": {
   "get": {
    "summary": "Risk-on / risk-off score",
    "description": "Five signals (VIX, dollar trend, 10Y-2Y curve, S&P 500 vs its 50-day average, gold trend) and the share that are risk-on, from 0 to 100.",
    "operationId": "get_macro_risk_v1_macro_risk_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "score": {
             "type": [
              "number",
              "null"
             ],
             "description": "Share of risk-on signals × 100.",
             "x-unit": "score from 0 to 100"
            },
            "regime": {
             "type": "string",
             "description": "Regime of the value."
            },
            "risk_on_signals": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Signals currently risk-on.",
             "x-unit": "count"
            },
            "available_signals": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Signals that could be evaluated (data available).",
             "x-unit": "count"
            },
            "total_signals": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Signals in the model.",
             "x-unit": "count"
            },
            "signals": {
             "type": "object",
             "properties": {
              "vix": {
               "type": "object",
               "properties": {
                "condition": {
                 "type": "string",
                 "description": "Rule of the signal."
                },
                "risk_on": {
                 "type": "boolean",
                 "description": "Whether the signal is risk-on now."
                }
               },
               "description": "CBOE Volatility Index.",
               "x-unit": "index points"
              },
              "dxy": {
               "type": "object",
               "properties": {
                "condition": {
                 "type": "string",
                 "description": "Rule of the signal."
                },
                "risk_on": {
                 "type": "boolean",
                 "description": "Whether the signal is risk-on now."
                }
               },
               "description": "US Dollar Index.",
               "x-unit": "index points"
              },
              "yield_curve": {
               "type": "object",
               "properties": {
                "condition": {
                 "type": "string",
                 "description": "Rule of the signal."
                },
                "risk_on": {
                 "type": "boolean",
                 "description": "Whether the signal is risk-on now."
                }
               }
              },
              "sp500": {
               "type": "object",
               "properties": {
                "condition": {
                 "type": "string",
                 "description": "Rule of the signal."
                },
                "risk_on": {
                 "type": "boolean",
                 "description": "Whether the signal is risk-on now."
                }
               },
               "description": "S&P 500.",
               "x-unit": "index points"
              },
              "gold": {
               "type": "object",
               "properties": {
                "condition": {
                 "type": "string",
                 "description": "Rule of the signal."
                },
                "risk_on": {
                 "type": "boolean",
                 "description": "Whether the signal is risk-on now."
                }
               },
               "description": "Gold price.",
               "x-unit": "USD per troy ounce"
              }
             },
             "description": "Each signal: its `condition` and whether it is `risk_on`."
            },
            "context": {
             "type": "object",
             "properties": {
              "vix": {
               "type": [
                "number",
                "null"
               ],
               "description": "CBOE Volatility Index.",
               "x-unit": "index points"
              },
              "dxy": {
               "type": [
                "number",
                "null"
               ],
               "description": "US Dollar Index.",
               "x-unit": "index points"
              },
              "dxy_7d_ago": {
               "type": [
                "number",
                "null"
               ],
               "description": "US Dollar Index seven days earlier.",
               "x-unit": "index points"
              },
              "yield_curve_10y2y": {
               "type": [
                "number",
                "null"
               ],
               "description": "10-year minus 2-year US Treasury yield.",
               "x-unit": "percentage points"
              },
              "sp500": {
               "type": [
                "number",
                "null"
               ],
               "description": "S&P 500.",
               "x-unit": "index points"
              },
              "sp500_sma50": {
               "type": [
                "number",
                "null"
               ],
               "description": "50-day simple moving average of the S&P 500.",
               "x-unit": "index points"
              },
              "gold": {
               "type": [
                "number",
                "null"
               ],
               "description": "Gold price.",
               "x-unit": "USD per troy ounce"
              },
              "gold_7d_ago": {
               "type": [
                "number",
                "null"
               ],
               "description": "Gold price seven days earlier.",
               "x-unit": "USD per troy ounce"
              }
             },
             "description": "The raw inputs used by the signals."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790275261,
         "data_type": "macro_risk",
         "data": {
          "score": 80,
          "regime": "risk-on",
          "risk_on_signals": 4,
          "available_signals": 5,
          "total_signals": 5,
          "signals": {
           "vix": {
            "condition": "VIX < 20",
            "risk_on": true
           },
           "dxy": {
            "condition": "DXY down over 7 days",
            "risk_on": false
           },
           "yield_curve": {
            "condition": "10Y-2Y curve positive",
            "risk_on": true
           },
           "sp500": {
            "condition": "S&P 500 > SMA50",
            "risk_on": true
           },
           "gold": {
            "condition": "Gold down over 7 days",
            "risk_on": true
           }
          },
          "context": {
           "vix": 16.04,
           "dxy": 120.33,
           "dxy_7d_ago": 119.5133,
           "yield_curve_10y2y": 0.37,
           "sp500": 7670.84,
           "sp500_sma50": 7645.157000000002,
           "gold": 4189.247701690536,
           "gold_7d_ago": 4356.842288234995
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/risk\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/risk\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/risk\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/macro/series": {
   "get": {
    "summary": "Macro series catalogue",
    "description": "Every active FRED series with its category, unit, frequency and latest value.",
    "operationId": "get_macro_series_v1_macro_series_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "category",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Filter by category, e.g. `rates`, `inflation`, `liquidity`, `commodities`."
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "series_id": {
              "type": "string",
              "description": "Series identifier."
             },
             "category": {
              "type": "string",
              "description": "Series category."
             },
             "label": {
              "type": "string",
              "description": "Human-readable name."
             },
             "frequency": {
              "type": "string",
              "description": "Publication frequency of the source (`daily`, `weekly`, `monthly`)."
             },
             "units": {
              "type": "string",
              "description": "Unit of `value` as published by the source."
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Value of the series.",
              "x-unit": "dimensionless score"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790272807,
         "data_type": "macro_series",
         "data": [
          {
           "time": "2026-09-29",
           "series_id": "DCOILWTICO",
           "category": "commodities",
           "label": "WTI Crude Oil",
           "frequency": "daily",
           "units": "USD per barrel",
           "date": "2026-09-29",
           "value": 96.16
          },
          {
           "time": "2026-09-29",
           "series_id": "GOLD_USD",
           "category": "commodities",
           "label": "Gold (PAXG proxy, USD/oz)",
           "frequency": "daily",
           "units": "USD per troy ounce",
           "date": "2026-09-29",
           "value": 4189.247701690536
          },
          {
           "time": "2026-08-01",
           "series_id": "PAYEMS",
           "category": "employment",
           "label": "Nonfarm Payrolls",
           "frequency": "monthly",
           "units": "Thousands of persons",
           "date": "2026-08-01",
           "value": 159075
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Macro"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/macro/series\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/macro/series\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/macro/series\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/oi/delta": {
   "get": {
    "summary": "Open interest change",
    "description": "Change of total open interest over the last minute, summed across venues.",
    "operationId": "get_oi_delta_v1_oi_delta_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "oi_current": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total open interest across venues at the end of the window, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "oi_previous": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total open interest at the start of the window.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "delta": {
             "type": [
              "number",
              "null"
             ],
             "description": "oi_current - oi_previous, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "delta_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Relative open interest change in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790262526,
         "data_type": "oi_delta",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:35.091Z",
          "oi_current": 343643.70848000003,
          "oi_previous": 343637.2931800001,
          "delta": 6.415299999987383,
          "delta_pct": 0.0018668811934142138,
          "timestamp": "2026-09-30T17:43:35.091Z"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/oi/delta?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/oi/delta\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/oi/delta?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/oi/delta/history": {
   "get": {
    "summary": "Open interest change history",
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_oi_delta_history_v1_oi_delta_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "oi_current": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total open interest across venues at the end of the window, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "oi_previous": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total open interest at the start of the window.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "oi_current - oi_previous, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "delta_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Relative open interest change in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790263127,
         "data_type": "oi_delta_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "oi_current": 343164.8987600001,
           "oi_previous": 342873.06846000004,
           "delta": 291.83030000008876,
           "delta_pct": 0.08511321735207501,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "oi_current": 342842.7449000001,
           "oi_previous": 341557.2792000001,
           "delta": 1285.4657000000007,
           "delta_pct": 0.3763543564379114,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "oi_current": 339753.7792000002,
           "oi_previous": 340456.93278000003,
           "delta": -703.1535799998092,
           "delta_pct": -0.20653231357582025,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Derivatives"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/oi/delta/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/oi/delta/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/oi/delta/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/active-addresses": {
   "get": {
    "summary": "Bitcoin active addresses",
    "description": "Daily active addresses, 7- and 30-day averages and momentum.",
    "operationId": "get_active_addresses_v1_onchain_active_addresses_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "date": {
             "type": "string",
             "format": "date",
             "description": "Calendar day the value refers to.",
             "x-unit": "calendar date (YYYY-MM-DD)"
            },
            "active_addresses": {
             "type": [
              "number",
              "null"
             ],
             "description": "Addresses active on the day.",
             "x-unit": "count"
            },
            "avg_7d": {
             "type": [
              "number",
              "null"
             ],
             "description": "7-day average.",
             "x-unit": "count"
            },
            "avg_30d": {
             "type": [
              "number",
              "null"
             ],
             "description": "30-day average.",
             "x-unit": "count"
            },
            "momentum_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Relative gap between the short and the long moving average, in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "signal": {
             "type": "string",
             "description": "7-day vs 30-day average: `accelerating` (> +5 %), `decelerating` (< -5 %) or `stable`."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790309629,
         "data_type": "onchain_active_addresses",
         "data": {
          "time": "2026-09-28",
          "date": "2026-09-28",
          "active_addresses": 491198,
          "avg_7d": 477345.85714285716,
          "avg_30d": 477719.6666666667,
          "momentum_pct": -0.07824871988583121,
          "signal": "stable"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/active-addresses\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/active-addresses\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/active-addresses\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/active-addresses/history": {
   "get": {
    "summary": "Active addresses history",
    "description": "One point per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_active_addresses_history_v1_onchain_active_addresses_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `30d`, `90d`, `1y`, `2y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "active_addresses": {
              "type": [
               "number",
               "null"
              ],
              "description": "Addresses active on the day.",
              "x-unit": "count"
             },
             "avg_7d": {
              "type": [
               "number",
               "null"
              ],
              "description": "7-day average.",
              "x-unit": "count"
             },
             "avg_30d": {
              "type": [
               "number",
               "null"
              ],
              "description": "30-day average.",
              "x-unit": "count"
             },
             "momentum_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Relative gap between the short and the long moving average, in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "signal": {
              "type": "string",
              "description": "7-day vs 30-day average: `accelerating` (> +5 %), `decelerating` (< -5 %) or `stable`."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790310226,
         "data_type": "onchain_active_addresses_history",
         "data": [
          {
           "time": "2026-09-28",
           "date": "2026-09-28",
           "active_addresses": 491198,
           "avg_7d": 477345.85714285716,
           "avg_30d": 477719.6666666667,
           "momentum_pct": -0.07824871988583121,
           "signal": "stable"
          },
          {
           "time": "2026-09-27",
           "date": "2026-09-27",
           "active_addresses": 416118,
           "avg_7d": 482648,
           "avg_30d": 476254.93333333335,
           "momentum_pct": 1.3423622978393612,
           "signal": "stable"
          },
          {
           "time": "2026-09-26",
           "date": "2026-09-26",
           "active_addresses": 448618,
           "avg_7d": 482500.71428571426,
           "avg_30d": 479660.63333333336,
           "momentum_pct": 0.5921021561940911,
           "signal": "stable"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/active-addresses/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/active-addresses/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/active-addresses/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/miner-stress": {
   "get": {
    "summary": "Bitcoin miner stress",
    "description": "Miner revenue per unit of difficulty against its 30-day average: healthy, stress or capitulation. Daily.",
    "operationId": "get_miner_stress_v1_onchain_miner_stress_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "date": {
             "type": "string",
             "format": "date",
             "description": "Calendar day the value refers to.",
             "x-unit": "calendar date (YYYY-MM-DD)"
            },
            "miner_stress": {
             "type": [
              "number",
              "null"
             ],
             "description": "Miner revenue / difficulty (revenue per unit of work). Read it against stress_ma30.",
             "x-unit": "dimensionless score"
            },
            "stress_ma30": {
             "type": [
              "number",
              "null"
             ],
             "description": "30-day moving average of miner_stress.",
             "x-unit": "dimensionless score"
            },
            "zone": {
             "type": "string",
             "description": "`healthy` (at or above its 30-day average), `stress` (below it), `capitulation` (below 70 % of it — historically near BTC bottoms)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790310822,
         "data_type": "onchain_miner_stress",
         "data": {
          "time": "2026-09-28",
          "date": "2026-09-28",
          "miner_stress": 3.6581775424862035e-7,
          "stress_ma30": 3.172945811918241e-7,
          "zone": "healthy"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/miner-stress\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/miner-stress\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/miner-stress\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/miner-stress/history": {
   "get": {
    "summary": "Miner stress history",
    "description": "One point per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_miner_stress_history_v1_onchain_miner_stress_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `30d`, `90d`, `1y`, `2y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "miner_stress": {
              "type": [
               "number",
               "null"
              ],
              "description": "Miner revenue / difficulty (revenue per unit of work). Read it against stress_ma30.",
              "x-unit": "dimensionless score"
             },
             "stress_ma30": {
              "type": [
               "number",
               "null"
              ],
              "description": "30-day moving average of miner_stress.",
              "x-unit": "dimensionless score"
             },
             "zone": {
              "type": "string",
              "description": "`healthy` (at or above its 30-day average), `stress` (below it), `capitulation` (below 70 % of it — historically near BTC bottoms)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790311441,
         "data_type": "onchain_miner_stress_history",
         "data": [
          {
           "time": "2026-09-28",
           "date": "2026-09-28",
           "miner_stress": 3.6581775424862035e-7,
           "stress_ma30": 3.1729458119182406e-7,
           "zone": "healthy"
          },
          {
           "time": "2026-09-27",
           "date": "2026-09-27",
           "miner_stress": 3.0790386080647216e-7,
           "stress_ma30": 3.1533250230665984e-7,
           "zone": "stress"
          },
          {
           "time": "2026-09-26",
           "date": "2026-09-26",
           "miner_stress": 3.338864865252702e-7,
           "stress_ma30": 3.151001733571237e-7,
           "zone": "healthy"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/miner-stress/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/miner-stress/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/miner-stress/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/mvrv": {
   "get": {
    "summary": "Bitcoin MVRV",
    "description": "Market value / realised value with its zone and 30-day momentum. Daily.",
    "operationId": "get_mvrv_v1_onchain_mvrv_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "date": {
             "type": "string",
             "format": "date",
             "description": "Calendar day the value refers to.",
             "x-unit": "calendar date (YYYY-MM-DD)"
            },
            "mvrv": {
             "type": [
              "number",
              "null"
             ],
             "description": "Market value / realised value.",
             "x-unit": "dimensionless ratio"
            },
            "zone": {
             "type": "string",
             "description": "`undervalued` (<= 1), `fair` (> 1), `elevated` (> 2.5), `overvalued` (> 3.5)."
            },
            "momentum_30d_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change over 30 days.",
             "x-unit": "percent (58.5 = 58.5 %)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790307229,
         "data_type": "onchain_mvrv",
         "data": {
          "time": "2026-09-23",
          "date": "2026-09-23",
          "mvrv": 1.5899,
          "zone": "fair",
          "momentum_30d_pct": 5.802888134690901
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/mvrv\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/mvrv\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/mvrv\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/mvrv/history": {
   "get": {
    "summary": "MVRV history",
    "description": "One point per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_mvrv_history_v1_onchain_mvrv_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `30d`, `90d`, `1y`, `2y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "mvrv": {
              "type": [
               "number",
               "null"
              ],
              "description": "Market value / realised value.",
              "x-unit": "dimensionless ratio"
             },
             "zone": {
              "type": "string",
              "description": "`undervalued` (<= 1), `fair` (> 1), `elevated` (> 2.5), `overvalued` (> 3.5)."
             },
             "momentum_30d_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Change over 30 days.",
              "x-unit": "percent (58.5 = 58.5 %)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790307811,
         "data_type": "onchain_mvrv_history",
         "data": [
          {
           "time": "2026-09-23",
           "date": "2026-09-23",
           "mvrv": 1.5899,
           "zone": "fair",
           "momentum_30d_pct": 5.802888134690901
          },
          {
           "time": "2026-09-22",
           "date": "2026-09-22",
           "mvrv": 1.6254,
           "zone": "fair",
           "momentum_30d_pct": 9.883720930232549
          },
          {
           "time": "2026-09-21",
           "date": "2026-09-21",
           "mvrv": 1.6366,
           "zone": "fair",
           "momentum_30d_pct": 11.477419794291949
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/mvrv/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/mvrv/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/mvrv/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/nvt": {
   "get": {
    "summary": "Bitcoin NVT",
    "description": "Network value to transactions ratio and its 90-day NVT Signal, derived on demand. Daily.",
    "operationId": "get_nvt_v1_onchain_nvt_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "date": {
             "type": "string",
             "format": "date",
             "description": "Calendar day the value refers to.",
             "x-unit": "calendar date (YYYY-MM-DD)"
            },
            "nvt": {
             "type": [
              "number",
              "null"
             ],
             "description": "Market cap / daily on-chain transaction volume (NVT ratio).",
             "x-unit": "dimensionless ratio"
            },
            "nvt_signal": {
             "type": [
              "number",
              "null"
             ],
             "description": "NVT smoothed over 90 days (NVT Signal), less noisy.",
             "x-unit": "dimensionless ratio"
            },
            "zone": {
             "type": "string",
             "description": "Zone of the NVT Signal: `undervalued` (<= 45), `fair` (> 45), `overvalued` (> 100), `bubble` (> 150)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790308422,
         "data_type": "onchain_nvt",
         "data": {
          "time": "2026-09-27",
          "date": "2026-09-27",
          "nvt": 580.1348324564798,
          "nvt_signal": 303.47902556588224,
          "zone": "bubble"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/nvt\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/nvt\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/nvt\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/onchain/nvt/history": {
   "get": {
    "summary": "NVT history",
    "description": "One point per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_nvt_history_v1_onchain_nvt_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timePeriod",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Named window: `30d`, `90d`, `1y`, `2y` or `all`.",
      "example": "30d"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 365
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "date": {
              "type": "string",
              "format": "date",
              "description": "Calendar day the value refers to.",
              "x-unit": "calendar date (YYYY-MM-DD)"
             },
             "nvt": {
              "type": [
               "number",
               "null"
              ],
              "description": "Market cap / daily on-chain transaction volume (NVT ratio).",
              "x-unit": "dimensionless ratio"
             },
             "nvt_signal": {
              "type": [
               "number",
               "null"
              ],
              "description": "NVT smoothed over 90 days (NVT Signal), less noisy.",
              "x-unit": "dimensionless ratio"
             },
             "zone": {
              "type": "string",
              "description": "Zone of the NVT Signal: `undervalued` (<= 45), `fair` (> 45), `overvalued` (> 100), `bubble` (> 150)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790309043,
         "data_type": "onchain_nvt_history",
         "data": [
          {
           "time": "2026-09-27",
           "date": "2026-09-27",
           "nvt": 580.1348324564798,
           "nvt_signal": 303.47902556588247,
           "zone": "bubble"
          },
          {
           "time": "2026-09-26",
           "date": "2026-09-26",
           "nvt": 466.41016952520494,
           "nvt_signal": 298.6212428564303,
           "zone": "bubble"
          },
          {
           "time": "2026-09-25",
           "date": "2026-09-25",
           "nvt": 128.7577049311245,
           "nvt_signal": 299.67919310847753,
           "zone": "bubble"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "On-chain Bitcoin"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/onchain/nvt/history?timePeriod=30d&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/onchain/nvt/history\",\n    params={\"timePeriod\": \"30d\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/onchain/nvt/history?timePeriod=30d&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/expiry": {
   "get": {
    "summary": "Per-expiry breakdown",
    "description": "Every active expiry: open interest, put/call ratio, max pain, top call and put strikes, ATM IV. `data` is a list.",
    "operationId": "get_options_expiry_v1_options_expiry_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "expiry": {
              "type": "string",
              "format": "date-time",
              "description": "Expiry instant (08:00 UTC). Pass its date part (`YYYY-MM-DD`) as the `expiry` parameter.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "dte_days": {
              "type": [
               "number",
               "null"
              ],
              "description": "Days to expiry (fractional).",
              "x-unit": "days"
             },
             "oi_call_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Call open interest, USD.",
              "x-unit": "USD"
             },
             "oi_put_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put open interest, USD.",
              "x-unit": "USD"
             },
             "pc_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
              "x-unit": "puts / calls"
             },
             "max_pain_strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike at which option holders lose the most at expiry (max pain).",
              "x-unit": "USD"
             },
             "top_call_strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike with the largest call open interest.",
              "x-unit": "USD"
             },
             "top_put_strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike with the largest put open interest.",
              "x-unit": "USD"
             },
             "iv_atm_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "At-the-money implied volatility, annualised, in percent (55.2 = 55.2 %).",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "pc_signal": {
              "type": "string",
              "description": "`bullish` (pc_ratio < 0.7), `neutral`, or `bearish` (pc_ratio > 1)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790290993,
         "data_type": "options_expiry",
         "data": [
          {
           "expiry": "2026-10-01T08:00:00.000Z",
           "dte_days": 0.5940510870949074,
           "oi_call_usd": 531258085.63308895,
           "oi_put_usd": 544784366.8505492,
           "pc_ratio": 1.0254608477183764,
           "max_pain_strike": 84250,
           "top_call_strike": 86000,
           "top_put_strike": 84000,
           "iv_atm_pct": 25.480000000000008,
           "pc_signal": "bearish"
          },
          {
           "expiry": "2026-10-02T08:00:00.000Z",
           "dte_days": 1.5940510870949074,
           "oi_call_usd": 1568143091.45589,
           "oi_put_usd": 1781056523.5065172,
           "pc_ratio": 1.1357742371921906,
           "max_pain_strike": 83000,
           "top_call_strike": 88000,
           "top_put_strike": 80000,
           "iv_atm_pct": 30.361844316640262,
           "pc_signal": "bearish"
          },
          {
           "expiry": "2026-10-03T08:00:00.000Z",
           "dte_days": 2.5940510870949076,
           "oi_call_usd": 95288683.02928346,
           "oi_put_usd": 137632591.88934326,
           "pc_ratio": 1.4443750035567913,
           "max_pain_strike": 84000,
           "top_call_strike": 88000,
           "top_put_strike": 80000,
           "iv_atm_pct": 32.22453280787994,
           "pc_signal": "bearish"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/expiry?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/expiry\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/expiry?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/greeks": {
   "get": {
    "summary": "Aggregated greeks",
    "description": "Delta, gamma, theta and vega of open options, recomputed under one convention and OI-weighted, so they add up across venues.",
    "operationId": "get_options_greeks_v1_options_greeks_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "delta": {
             "type": [
              "number",
              "null"
             ],
             "description": "Aggregated delta of open options, OI-weighted (per unit of underlying).",
             "x-unit": "delta"
            },
            "gamma": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change of delta for a 1 USD move of the underlying, OI-weighted.",
             "x-unit": "delta per USD"
            },
            "theta": {
             "type": [
              "number",
              "null"
             ],
             "description": "Time decay per day, OI-weighted.",
             "x-unit": "USD per day"
            },
            "vega": {
             "type": [
              "number",
              "null"
             ],
             "description": "Value change for +1 point of implied volatility, OI-weighted.",
             "x-unit": "USD per volatility point"
            },
            "coverage": {
             "type": "object",
             "properties": {
              "sources_active": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Options venues contributing.",
               "x-unit": "count"
              },
              "oi_coverage_ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of the open interest covered by the contributing venues.",
               "x-unit": "fraction (0.585 = 58.5 %)"
              }
             },
             "description": "`sources_active` (venues contributing) and `oi_coverage_ratio` (share of open interest covered, 1.0 = all)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790291610,
         "data_type": "options_greeks",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "delta": 0.15602129324574576,
          "gamma": 0.00002933199298487753,
          "theta": -34.25528485415759,
          "vega": 66.41197461414434,
          "coverage": {
           "sources_active": 4,
           "oi_coverage_ratio": 1
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/greeks?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/greeks\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/greeks?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/iv": {
   "get": {
    "summary": "ATM implied volatility",
    "description": "At-the-money implied volatility aggregated across venues, in percent.",
    "operationId": "get_options_iv_v1_options_iv_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "iv_atm_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "At-the-money implied volatility, annualised, in percent (55.2 = 55.2 %).",
             "x-unit": "percent (58.5 = 58.5 %)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790286693,
         "data_type": "options_iv",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "iv_atm_pct": 25.480000000000008
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/iv?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/iv\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/iv?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/iv/history": {
   "get": {
    "summary": "ATM IV history",
    "description": "Per bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_iv_history_v1_options_iv_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "iv_atm_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "At-the-money implied volatility, annualised, in percent (55.2 = 55.2 %).",
              "x-unit": "percent (58.5 = 58.5 %)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790287320,
         "data_type": "options_iv_history",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "iv_atm_pct": 27.51548080302511
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "iv_atm_pct": 26.369999999999997
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "iv_atm_pct": 26.03711032017726
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/iv/history?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/iv/history\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/iv/history?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/iv/klines": {
   "get": {
    "summary": "ATM IV candles",
    "description": "OHLC of the ATM implied volatility per bucket, in percent. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_iv_klines_v1_options_iv_klines_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "open": {
              "type": [
               "number",
               "null"
              ],
              "description": "ATM IV at the start of the bucket.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "high": {
              "type": [
               "number",
               "null"
              ],
              "description": "Highest ATM IV.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "low": {
              "type": [
               "number",
               "null"
              ],
              "description": "Lowest ATM IV.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "close": {
              "type": [
               "number",
               "null"
              ],
              "description": "ATM IV at the end of the bucket.",
              "x-unit": "percent (58.5 = 58.5 %)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790287966,
         "data_type": "options_iv_klines",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "open": 26.39,
           "high": 28.03013588929368,
           "low": 25.781574454476548,
           "close": 27.51548080302511
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "open": 26.354976068960383,
           "high": 26.686715563252683,
           "low": 24.998494883192603,
           "close": 26.369999999999997
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "open": 30.580000000000002,
           "high": 30.9,
           "low": 25.872897675979168,
           "close": 26.03711032017726
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/iv/klines?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/iv/klines\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/iv/klines?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/max-pain": {
   "get": {
    "summary": "Max pain per expiry",
    "description": "Max pain strike of every active expiry, with days to expiry, put/call ratio and open interest. `data` is a list.",
    "operationId": "get_options_max_pain_v1_options_max_pain_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "expiry": {
              "type": "string",
              "format": "date-time",
              "description": "Expiry instant (08:00 UTC). Pass its date part (`YYYY-MM-DD`) as the `expiry` parameter.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "dte_days": {
              "type": [
               "number",
               "null"
              ],
              "description": "Days to expiry (fractional).",
              "x-unit": "days"
             },
             "max_pain_strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike at which option holders lose the most at expiry (max pain).",
              "x-unit": "USD"
             },
             "pc_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
              "x-unit": "puts / calls"
             },
             "oi_call_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Call open interest, USD.",
              "x-unit": "USD"
             },
             "oi_put_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put open interest, USD.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790289076,
         "data_type": "options_max_pain",
         "data": [
          {
           "expiry": "2026-10-01T08:00:00.000Z",
           "dte_days": 0.5940510870949074,
           "max_pain_strike": 84250,
           "pc_ratio": 1.0254608477183764,
           "oi_call_usd": 531258085.63308895,
           "oi_put_usd": 544784366.8505492
          },
          {
           "expiry": "2026-10-02T08:00:00.000Z",
           "dte_days": 1.5940510870949074,
           "max_pain_strike": 83000,
           "pc_ratio": 1.1357742371921906,
           "oi_call_usd": 1568143091.45589,
           "oi_put_usd": 1781056523.5065172
          },
          {
           "expiry": "2026-10-03T08:00:00.000Z",
           "dte_days": 2.5940510870949076,
           "max_pain_strike": 84000,
           "pc_ratio": 1.4443750035567913,
           "oi_call_usd": 95288683.02928346,
           "oi_put_usd": 137632591.88934326
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/max-pain?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/max-pain\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/max-pain?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/max-pain/history": {
   "get": {
    "summary": "Max pain history of one expiry",
    "description": "How the max pain of ONE expiry moved. `expiry` is required. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_max_pain_history_v1_options_max_pain_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "expiry",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string",
         "format": "date"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "REQUIRED. Expiry date `YYYY-MM-DD`. Missing: 422 `missing_expiry`, and the error lists the active expiries."
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "max_pain_strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike at which option holders lose the most at expiry (max pain).",
              "x-unit": "USD"
             },
             "pc_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
              "x-unit": "puts / calls"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790289717,
         "data_type": "options_max_pain_history",
         "data": [
          {
           "time": "2026-09-30T17:44:33.986Z",
           "timestamp": "2026-09-30T17:44:33.986Z",
           "max_pain_strike": 84250,
           "pc_ratio": 1.0254608477183764
          },
          {
           "time": "2026-09-30T17:43:26.791Z",
           "timestamp": "2026-09-30T17:43:26.791Z",
           "max_pain_strike": 84250,
           "pc_ratio": 1.024230175691702
          },
          {
           "time": "2026-09-30T17:42:19.610Z",
           "timestamp": "2026-09-30T17:42:19.610Z",
           "max_pain_strike": 84250,
           "pc_ratio": 1.0242167838195655
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/max-pain/history?asset=BTC&expiry=2026-10-01&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/max-pain/history\",\n    params={\"asset\": \"BTC\", \"expiry\": \"2026-10-01\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/max-pain/history?asset=BTC&expiry=2026-10-01&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/oi": {
   "get": {
    "summary": "Options open interest",
    "description": "Calls and puts, in USD and in coins.",
    "operationId": "get_options_oi_v1_options_oi_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "total_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total, USD.",
             "x-unit": "USD"
            },
            "call_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Calls, USD.",
             "x-unit": "USD"
            },
            "put_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Puts, USD.",
             "x-unit": "USD"
            },
            "call_coin": {
             "type": [
              "number",
              "null"
             ],
             "description": "Call open interest in coins.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "put_coin": {
             "type": [
              "number",
              "null"
             ],
             "description": "Put open interest in coins.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "coverage": {
             "type": "object",
             "properties": {
              "sources_active": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Options venues contributing.",
               "x-unit": "count"
              },
              "oi_coverage_ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of the open interest covered by the contributing venues.",
               "x-unit": "fraction (0.585 = 58.5 %)"
              }
             },
             "description": "`sources_active` (venues contributing) and `oi_coverage_ratio` (share of open interest covered, 1.0 = all)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790280730,
         "data_type": "options_oi",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "total_usd": 36423347698.02251,
          "call_usd": 22218554587.502285,
          "put_usd": 14204793110.520224,
          "call_coin": 262204.62,
          "put_coin": 167789.02,
          "coverage": {
           "sources_active": 4,
           "oi_coverage_ratio": 1
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/oi?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/oi\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/oi?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/oi/delta": {
   "get": {
    "summary": "Options open interest change",
    "description": "Change of call and put open interest over the latest bucket.",
    "operationId": "get_options_oi_delta_v1_options_oi_delta_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "delta_call_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change of call open interest over the bucket, USD.",
             "x-unit": "USD"
            },
            "delta_put_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change of put open interest over the bucket, USD.",
             "x-unit": "USD"
            },
            "delta_total_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Change of total open interest over the bucket, USD.",
             "x-unit": "USD"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timeframe": {
             "type": "string",
             "description": "Bucket size of the row."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790282077,
         "data_type": "options_oi_delta",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "delta_call_usd": -65936080.49573517,
          "delta_put_usd": -51989692.115448,
          "delta_total_usd": -117925772.61118317,
          "asset": "BTC",
          "timeframe": "1h"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/oi/delta?asset=BTC&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/oi/delta\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/oi/delta?asset=BTC&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/oi/delta/history": {
   "get": {
    "summary": "Options OI change history",
    "description": "Per bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_oi_delta_history_v1_options_oi_delta_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "delta_call_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Change of call open interest over the bucket, USD.",
              "x-unit": "USD"
             },
             "delta_put_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Change of put open interest over the bucket, USD.",
              "x-unit": "USD"
             },
             "delta_total_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Change of total open interest over the bucket, USD.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790282779,
         "data_type": "options_oi_delta_history",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "delta_call_usd": 74136277.10503006,
           "delta_put_usd": 61725492.81556702,
           "delta_total_usd": 135861769.9206009
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "delta_call_usd": 121118135.45619965,
           "delta_put_usd": 149065665.02907562,
           "delta_total_usd": 270183800.48527527
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "delta_call_usd": -237661820.86148453,
           "delta_put_usd": -52983718.61921692,
           "delta_total_usd": -290645539.48070526
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/oi/delta/history?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/oi/delta/history\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/oi/delta/history?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/oi/distribution": {
   "get": {
    "summary": "Open interest per strike",
    "description": "Latest open interest per (expiry, strike), calls and puts separately. `data` is a list.",
    "operationId": "get_options_oi_distribution_v1_options_oi_distribution_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "expiry",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string",
         "format": "date"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Restrict to one expiry (`YYYY-MM-DD`). Omit for every active expiry."
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "expiry": {
              "type": "string",
              "format": "date-time",
              "description": "Expiry instant (08:00 UTC). Pass its date part (`YYYY-MM-DD`) as the `expiry` parameter.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "strike": {
              "type": [
               "number",
               "null"
              ],
              "description": "Strike price.",
              "x-unit": "USD"
             },
             "call_oi_usd": {
              "type": [
               "number",
               "string",
               "null"
              ],
              "description": "Call open interest at this strike, USD. `null` = no call listed.",
              "x-unit": "USD"
             },
             "put_oi_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put open interest at this strike, USD. `null` = no put listed.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790283398,
         "data_type": "options_oi_distribution",
         "data": [
          {
           "expiry": "2026-10-01T08:00:00.000Z",
           "strike": 74000,
           "call_oi_usd": null,
           "put_oi_usd": 1343594.08
          },
          {
           "expiry": "2026-10-01T08:00:00.000Z",
           "strike": 75000,
           "call_oi_usd": null,
           "put_oi_usd": 3543729.3860000004
          },
          {
           "expiry": "2026-10-01T08:00:00.000Z",
           "strike": 76000,
           "call_oi_usd": null,
           "put_oi_usd": 445065.539
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/oi/distribution?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/oi/distribution\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/oi/distribution?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/oi/history": {
   "get": {
    "summary": "Options open interest history",
    "description": "Per bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_oi_history_v1_options_oi_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "oi_call_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Call open interest, USD.",
              "x-unit": "USD"
             },
             "oi_put_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put open interest, USD.",
              "x-unit": "USD"
             },
             "oi_total_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total open interest, USD.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790281362,
         "data_type": "options_oi_history",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "oi_call_usd": 22291425968.727673,
           "oi_put_usd": 14259448648.632486,
           "oi_total_usd": 36550874617.36016
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "oi_call_usd": 22217289691.622643,
           "oi_put_usd": 14197723155.81692,
           "oi_total_usd": 36415012847.43956
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "oi_call_usd": 22096171556.166443,
           "oi_put_usd": 14048657490.787844,
           "oi_total_usd": 36144829046.954285
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/oi/history?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/oi/history\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/oi/history?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/pc-ratio": {
   "get": {
    "summary": "Put/call ratio",
    "description": "Put/call open interest ratio and its reading.",
    "operationId": "get_options_pc_ratio_v1_options_pc_ratio_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "pc_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
             "x-unit": "puts / calls"
            },
            "signal": {
             "type": "string",
             "description": "`bullish` (pc_ratio < 0.7), `neutral`, or `bearish` (pc_ratio > 1)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790285416,
         "data_type": "options_pc_ratio",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "pc_ratio": 0.6393212058227351,
          "signal": "bullish"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/pc-ratio?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/pc-ratio\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/pc-ratio?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/pc-ratio/history": {
   "get": {
    "summary": "Put/call ratio history",
    "description": "Per bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_pc_ratio_history_v1_options_pc_ratio_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "pc_ratio": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
              "x-unit": "puts / calls"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790286056,
         "data_type": "options_pc_ratio_history",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "pc_ratio": 0.6396831081437708
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "pc_ratio": 0.6390393856713485
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "pc_ratio": 0.6357960000028713
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/pc-ratio/history?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/pc-ratio/history\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/pc-ratio/history?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/summary": {
   "get": {
    "summary": "Options market summary",
    "description": "Open interest and volume (calls/puts, USD), put/call ratio and signal, ATM IV and the nearest expiry, aggregated across options venues.",
    "operationId": "get_options_summary_v1_options_summary_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "underlying_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Price of the underlying used by the options venues.",
             "x-unit": "USD"
            },
            "open_interest": {
             "type": "object",
             "properties": {
              "total_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Total, USD.",
               "x-unit": "USD"
              },
              "call_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Calls, USD.",
               "x-unit": "USD"
              },
              "put_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Puts, USD.",
               "x-unit": "USD"
              }
             },
             "description": "Options open interest in USD: `total_usd`, `call_usd`, `put_usd`.",
             "x-unit": "USD"
            },
            "volume": {
             "type": "object",
             "properties": {
              "total_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Total, USD.",
               "x-unit": "USD"
              },
              "call_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Calls, USD.",
               "x-unit": "USD"
              },
              "put_usd": {
               "type": [
                "number",
                "null"
               ],
               "description": "Puts, USD.",
               "x-unit": "USD"
              }
             },
             "description": "Volume traded, AGGREGATED across venues (spot + perpetual futures), in base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "pc_ratio": {
             "type": [
              "number",
              "null"
             ],
             "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
             "x-unit": "puts / calls"
            },
            "pc_signal": {
             "type": "string",
             "description": "`bullish` (pc_ratio < 0.7), `neutral`, or `bearish` (pc_ratio > 1)."
            },
            "iv_atm_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "At-the-money implied volatility, annualised, in percent (55.2 = 55.2 %).",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "nearest_expiry": {
             "type": "object",
             "properties": {
              "expiry": {
               "type": "string",
               "format": "date-time",
               "description": "Expiry instant (08:00 UTC). Pass its date part (`YYYY-MM-DD`) as the `expiry` parameter.",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "dte_days": {
               "type": [
                "number",
                "null"
               ],
               "description": "Days to expiry (fractional).",
               "x-unit": "days"
              },
              "max_pain_strike": {
               "type": [
                "number",
                "null"
               ],
               "description": "Strike at which option holders lose the most at expiry (max pain).",
               "x-unit": "USD"
              },
              "pc_ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "Put/call open interest ratio. Below 1 = more calls than puts.",
               "x-unit": "puts / calls"
              },
              "iv_atm_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "At-the-money implied volatility, annualised, in percent (55.2 = 55.2 %).",
               "x-unit": "percent (58.5 = 58.5 %)"
              }
             },
             "description": "The next expiry: date, days left, max pain, put/call ratio, ATM IV."
            },
            "coverage": {
             "type": "object",
             "properties": {
              "sources_active": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Options venues contributing.",
               "x-unit": "count"
              },
              "oi_coverage_ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of the open interest covered by the contributing venues.",
               "x-unit": "fraction (0.585 = 58.5 %)"
              }
             },
             "description": "`sources_active` (venues contributing) and `oi_coverage_ratio` (share of open interest covered, 1.0 = all)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790280113,
         "data_type": "options_summary",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "underlying_price": 84671.87,
          "open_interest": {
           "total_usd": 36423347698.02251,
           "call_usd": 22218554587.502285,
           "put_usd": 14204793110.520224
          },
          "volume": {
           "total_usd": 1161041146.495026,
           "call_usd": 570939143.4677235,
           "put_usd": 590102003.0273026
          },
          "pc_ratio": 0.6393212058227351,
          "pc_signal": "bullish",
          "iv_atm_pct": 25.480000000000008,
          "nearest_expiry": {
           "expiry": "2026-10-01T08:00:00.000Z",
           "dte_days": 0.5940510870949074,
           "max_pain_strike": 84250,
           "pc_ratio": 1.0254608477183764,
           "iv_atm_pct": 25.480000000000008
          },
          "coverage": {
           "sources_active": 4,
           "oi_coverage_ratio": 1
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/summary?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/summary\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/summary?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/volume": {
   "get": {
    "summary": "Options volume",
    "description": "Calls and puts traded, USD.",
    "operationId": "get_options_volume_v1_options_volume_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "asset": {
             "type": "string",
             "description": "Asset, e.g. `BTC`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "total_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total, USD.",
             "x-unit": "USD"
            },
            "call_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Calls, USD.",
             "x-unit": "USD"
            },
            "put_usd": {
             "type": [
              "number",
              "null"
             ],
             "description": "Puts, USD.",
             "x-unit": "USD"
            },
            "coverage": {
             "type": "object",
             "properties": {
              "sources_active": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Options venues contributing.",
               "x-unit": "count"
              },
              "oi_coverage_ratio": {
               "type": [
                "number",
                "null"
               ],
               "description": "Share of the open interest covered by the contributing venues.",
               "x-unit": "fraction (0.585 = 58.5 %)"
              }
             },
             "description": "`sources_active` (venues contributing) and `oi_coverage_ratio` (share of open interest covered, 1.0 = all)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790284152,
         "data_type": "options_volume",
         "data": {
          "time": "2026-09-30T17:44:33.986Z",
          "asset": "BTC",
          "timestamp": "2026-09-30T17:44:33.986Z",
          "total_usd": 1161041146.495026,
          "call_usd": 570939143.4677235,
          "put_usd": 590102003.0273026,
          "coverage": {
           "sources_active": 4,
           "oi_coverage_ratio": 1
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/volume?asset=BTC\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/volume\",\n    params={\"asset\": \"BTC\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/volume?asset=BTC\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/options/volume/history": {
   "get": {
    "summary": "Options volume history",
    "description": "Per bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_options_volume_history_v1_options_volume_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "1h"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 5000,
       "minimum": 1,
       "default": 200
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "asset",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "default": "BTC"
      },
      "description": "Asset, e.g. `BTC` or `ETH` (no quote currency). Unknown: 400 `invalid_asset`.",
      "example": "BTC"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "vol_call_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Call volume over the bucket, USD.",
              "x-unit": "USD"
             },
             "vol_put_usd": {
              "type": [
               "number",
               "null"
              ],
              "description": "Put volume over the bucket, USD.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790284804,
         "data_type": "options_volume_history",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "vol_call_usd": 562615460.4712248,
           "vol_put_usd": 578584644.1821741
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "vol_call_usd": 539939649.8949113,
           "vol_put_usd": 546795561.3387902
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "vol_call_usd": 522140110.47708505,
           "vol_put_usd": 530128814.60147095
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Options"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/options/volume/history?asset=BTC&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/options/volume/history\",\n    params={\"asset\": \"BTC\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/options/volume/history?asset=BTC&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/orderbook/aggregated": {
   "get": {
    "summary": "Order book statistics per bucket",
    "operationId": "get_orderbook_aggregated_v1_orderbook_aggregated_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "bid_total_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "bid_total_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "bid_total_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "imbalance_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_std": {
              "type": [
               "number",
               "null"
              ],
              "description": "Standard deviation of the imbalance over the bucket (how unstable the book was).",
              "x-unit": "fraction"
             },
             "samples_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of order book snapshots averaged in the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790253648,
         "data_type": "orderbook_aggregated_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "bid_total_avg": 77.31108677777776,
           "bid_total_min": 15.91023,
           "bid_total_max": 167.77567,
           "ask_total_avg": 60.23020433333331,
           "ask_total_min": 13.96013,
           "ask_total_max": 195.13756999999998,
           "imbalance_avg": 0.11016540017034959,
           "imbalance_min": -0.7572062426851045,
           "imbalance_max": 0.8213553258747318,
           "imbalance_std": 0.33307667708489624,
           "samples_count": 360,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Average, min and max of bid/ask liquidity and imbalance over the latest closed bucket. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/orderbook/aggregated?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/orderbook/aggregated\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/orderbook/aggregated?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/orderbook/aggregated/history": {
   "get": {
    "summary": "Order book statistics history",
    "operationId": "get_orderbook_aggregated_history_v1_orderbook_aggregated_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "bid_total_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "bid_total_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "bid_total_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum bid liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "ask_total_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum ask liquidity over the bucket.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "imbalance_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_min": {
              "type": [
               "number",
               "null"
              ],
              "description": "Minimum book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_max": {
              "type": [
               "number",
               "null"
              ],
              "description": "Maximum book imbalance over the bucket.",
              "x-unit": "fraction from -1 to 1"
             },
             "imbalance_std": {
              "type": [
               "number",
               "null"
              ],
              "description": "Standard deviation of the imbalance over the bucket (how unstable the book was).",
              "x-unit": "fraction"
             },
             "samples_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of order book snapshots averaged in the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790254338,
         "data_type": "orderbook_aggregated_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "bid_total_avg": 77.31108677777776,
           "bid_total_min": 15.91023,
           "bid_total_max": 167.77567,
           "ask_total_avg": 60.23020433333331,
           "ask_total_min": 13.96013,
           "ask_total_max": 195.13756999999998,
           "imbalance_avg": 0.11016540017034959,
           "imbalance_min": -0.7572062426851045,
           "imbalance_max": 0.8213553258747318,
           "imbalance_std": 0.33307667708489624,
           "samples_count": 360,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "symbol": "BTCUSDT",
           "bid_total_avg": 97.48639438888884,
           "bid_total_min": 18.47669,
           "bid_total_max": 637.77143,
           "ask_total_avg": 60.95369705555554,
           "ask_total_min": 17.22111,
           "ask_total_max": 184.00522,
           "imbalance_avg": 0.18011210536554623,
           "imbalance_min": -0.6685603180787127,
           "imbalance_max": 0.920172262040769,
           "imbalance_std": 0.34668077416820864,
           "samples_count": 360,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "symbol": "BTCUSDT",
           "bid_total_avg": 76.40199952777775,
           "bid_total_min": 15.42072,
           "bid_total_max": 589.87834,
           "ask_total_avg": 69.66592174999997,
           "ask_total_min": 15.17512,
           "ask_total_max": 199.04109,
           "imbalance_avg": 0.0009829514470542126,
           "imbalance_min": -0.8204603241070808,
           "imbalance_max": 0.8587994759285994,
           "imbalance_std": 0.38886771881931853,
           "samples_count": 360,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Same as `/v1/orderbook/aggregated`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/orderbook/aggregated/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/orderbook/aggregated/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/orderbook/aggregated/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/price-change": {
   "get": {
    "summary": "Price change over 1m to 1w",
    "description": "Rolling price change in percent over eight windows, from the latest price. Spot-based for stablecoins.",
    "operationId": "get_price_change_v1_price_change_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Price.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "changes": {
             "type": "object",
             "properties": {
              "1m": {
               "type": [
                "number",
                "null"
               ]
              },
              "5m": {
               "type": [
                "number",
                "null"
               ]
              },
              "15m": {
               "type": [
                "number",
                "null"
               ]
              },
              "30m": {
               "type": [
                "number",
                "null"
               ]
              },
              "1h": {
               "type": [
                "number",
                "null"
               ]
              },
              "4h": {
               "type": [
                "number",
                "null"
               ]
              },
              "1d": {
               "type": [
                "number",
                "null"
               ]
              },
              "1w": {
               "type": [
                "number",
                "null"
               ]
              }
             },
             "description": "Price change over each window, keyed by window (`1m` … `1w`), in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790241839,
         "data_type": "price_change",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:42:00.000Z",
          "symbol": "BTCUSDT",
          "price": 84038,
          "timestamp": "2026-09-30T17:42:00.000Z",
          "changes": {
           "1m": 0.01874503479733047,
           "5m": 0.13617127553449587,
           "15m": -0.10699171417461885,
           "30m": -0.3125685782578008,
           "1h": -0.3084296187335405,
           "4h": -0.588380795309514,
           "1d": 1.0557960557960557,
           "1w": -0.11648995477678913
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/price-change?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/price-change\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/price-change?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/futures-ticks": {
   "get": {
    "summary": "Individual futures trades",
    "operationId": "get_futures_ticks_v1_raw_futures_ticks_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 10000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "side": {
              "type": "string",
              "description": "Trades: `buy` or `sell` (aggressor side). Liquidations: `long` or `short` (the position liquidated)."
             },
             "price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "quantity": {
              "type": [
               "number",
               "null"
              ],
              "description": "Quantity traded or liquidated, in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "usd_value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional value: price × quantity.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790238775,
         "data_type": "raw_futures_ticks",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:43:58.119Z",
           "timestamp": "2026-09-30T17:43:58.119Z",
           "side": "sell",
           "price": 84009.1,
           "quantity": 0.012,
           "usd_value": 1008.1092000000001
          },
          {
           "time": "2026-09-30T17:43:58.119Z",
           "timestamp": "2026-09-30T17:43:58.119Z",
           "side": "sell",
           "price": 84009.1,
           "quantity": 0.002,
           "usd_value": 168.0182
          },
          {
           "time": "2026-09-30T17:43:58.119Z",
           "timestamp": "2026-09-30T17:43:58.119Z",
           "side": "sell",
           "price": 84009.1,
           "quantity": 0.002,
           "usd_value": 168.0182
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Raw perpetual futures executions across venues, most recent first. Kept 72 hours.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/futures-ticks?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/futures-ticks\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/futures-ticks?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/klines": {
   "get": {
    "summary": "1-minute OHLCV candles",
    "operationId": "get_klines_v1_raw_klines_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 60
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "open": {
              "type": [
               "number",
               "null"
              ],
              "description": "Opening price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "high": {
              "type": [
               "number",
               "null"
              ],
              "description": "Highest price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "low": {
              "type": [
               "number",
               "null"
              ],
              "description": "Lowest price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "close": {
              "type": [
               "number",
               "null"
              ],
              "description": "Closing price of the candle (last price for the open candle).",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume traded, AGGREGATED across venues (spot + perpetual futures), in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) buy volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) sell volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "volume_estimated": {
              "type": "boolean",
              "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790235511,
         "data_type": "raw_klines",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:42:00.000Z",
           "timestamp": "2026-09-30T17:42:00.000Z",
           "open": 84022.24,
           "high": 84038.01,
           "low": 84010,
           "close": 84038,
           "volume": 38.62342667000003,
           "taker_buy": 20.54720392,
           "taker_sell": 18.076222750000024,
           "volume_estimated": false
          },
          {
           "time": "2026-09-30T17:41:00.000Z",
           "timestamp": "2026-09-30T17:41:00.000Z",
           "open": 84014.86,
           "high": 84022.25,
           "low": 84004,
           "close": 84022.25,
           "volume": 20.711201289999988,
           "taker_buy": 13.07271575999999,
           "taker_sell": 7.638485529999997,
           "volume_estimated": false
          },
          {
           "time": "2026-09-30T17:40:00.000Z",
           "timestamp": "2026-09-30T17:40:00.000Z",
           "open": 84008.01,
           "high": 84014.87,
           "low": 83982,
           "close": 84014.86,
           "volume": 22.87509986999998,
           "taker_buy": 13.033891349999985,
           "taker_sell": 9.841208519999991,
           "volume_estimated": false
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "OHLC from one reference SPOT market per symbol; volume, taker buy and taker sell AGGREGATED across venues, spot and futures. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/klines?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/klines\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/klines?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/klines/{interval}": {
   "get": {
    "summary": "OHLCV candles for an interval",
    "operationId": "get_klines_multi_v1_raw_klines__interval__get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "interval",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Candle interval in the path: `1m`, `5m`, `15m`, `30m`, `1h`, `4h`, `1d` or `1w`.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "open": {
              "type": [
               "number",
               "null"
              ],
              "description": "Opening price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "high": {
              "type": [
               "number",
               "null"
              ],
              "description": "Highest price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "low": {
              "type": [
               "number",
               "null"
              ],
              "description": "Lowest price of the candle.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "close": {
              "type": [
               "number",
               "null"
              ],
              "description": "Closing price of the candle (last price for the open candle).",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume traded, AGGREGATED across venues (spot + perpetual futures), in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) buy volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) sell volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "volume_estimated": {
              "type": "boolean",
              "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790236326,
         "data_type": "raw_klines_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "open": 84134.43,
           "high": 84490.01,
           "low": 84134.43,
           "close": 84349.44,
           "volume": 2280.227277129998,
           "taker_buy": 1170.2562601299987,
           "taker_sell": 1109.9710169999994,
           "volume_estimated": false
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "open": 83800.01,
           "high": 84295.71,
           "low": 83694,
           "close": 84134.43,
           "volume": 3350.4473884966005,
           "taker_buy": 1741.3496877999999,
           "taker_sell": 1609.0977006966007,
           "volume_estimated": false
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "open": 84637.74,
           "high": 84644.83,
           "low": 83373,
           "close": 83800.01,
           "volume": 6771.307420519992,
           "taker_buy": 3160.2593737299967,
           "taker_sell": 3611.0480467899947,
           "volume_estimated": false
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Same as `/v1/raw/klines` for `5m` to `1w`. The last candle is the one in progress. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/klines/1h?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/klines/1h\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/klines/1h?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/liquidations": {
   "get": {
    "summary": "Individual liquidations",
    "description": "Forced liquidations across futures venues. Without `min_usd`, `limit` is a look-back in minutes; with it, a number of events. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_liquidations_v1_raw_liquidations_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 30
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "min_usd",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "number"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional minimum notional in USD. With it, `limit` counts events; without it, `limit` is a look-back in minutes."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "side": {
              "type": "string",
              "description": "`long` (a long position was liquidated: forced sell) or `short` (forced buy)."
             },
             "price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "quantity": {
              "type": [
               "number",
               "null"
              ],
              "description": "Quantity traded or liquidated, in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "usd_value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional value: price × quantity.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790241222,
         "data_type": "raw_liquidations",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:42:05.086Z",
           "timestamp": "2026-09-30T17:42:05.086Z",
           "side": "short",
           "price": 84323.1,
           "quantity": 0.296,
           "usd_value": 24959.637600000002
          },
          {
           "time": "2026-09-30T17:37:48.302Z",
           "timestamp": "2026-09-30T17:37:48.302Z",
           "side": "long",
           "price": 83608.9,
           "quantity": 0.041,
           "usd_value": 3427.9649
          },
          {
           "time": "2026-09-30T17:37:48.103Z",
           "timestamp": "2026-09-30T17:37:48.103Z",
           "side": "long",
           "price": 83870.8,
           "quantity": 0.0602,
           "usd_value": 5049.0221599999995
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Liquidations"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/liquidations?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/liquidations\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/liquidations?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/oi": {
   "get": {
    "summary": "Total open interest per minute",
    "description": "Open interest summed across futures venues, per minute. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_oi_v1_raw_oi_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 30
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "oi_total": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total open interest across venues, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790240616,
         "data_type": "raw_oi",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:44:00.000Z",
           "timestamp": "2026-09-30T17:44:00.000Z",
           "oi_total": 344631.13178000005
          },
          {
           "time": "2026-09-30T17:43:00.000Z",
           "timestamp": "2026-09-30T17:43:00.000Z",
           "oi_total": 344631.13178000005
          },
          {
           "time": "2026-09-30T17:42:00.000Z",
           "timestamp": "2026-09-30T17:42:00.000Z",
           "oi_total": 344689.02418000007
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/oi?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/oi\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/oi?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/orderbook": {
   "get": {
    "summary": "Aggregated order book, latest",
    "description": "Bid and ask liquidity and imbalance from the latest book of each venue (a venue silent for 30 s is not summed).",
    "operationId": "get_orderbook_v1_raw_orderbook_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "bid_total": {
             "type": [
              "number",
              "null"
             ],
             "description": "Resting bid liquidity summed over the top of book of each venue, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "ask_total": {
             "type": [
              "number",
              "null"
             ],
             "description": "Resting ask liquidity summed over the top of book of each venue, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "imbalance": {
             "type": [
              "number",
              "null"
             ],
             "description": "(bid_total - ask_total) / (bid_total + ask_total) across venues.",
             "x-unit": "fraction from -1 to 1"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790239392,
         "data_type": "raw_orderbook",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:58.138Z",
          "timestamp": "2026-09-30T17:43:58.138Z",
          "bid_total": 64.76607000000001,
          "ask_total": 69.16233,
          "imbalance": -0.0328254500165759
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/orderbook?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/orderbook\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/orderbook?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/spot-ticks": {
   "get": {
    "summary": "Individual spot trades",
    "operationId": "get_spot_ticks_v1_raw_spot_ticks_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 10000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "side": {
              "type": "string",
              "description": "Trades: `buy` or `sell` (aggressor side). Liquidations: `long` or `short` (the position liquidated)."
             },
             "price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "quantity": {
              "type": [
               "number",
               "null"
              ],
              "description": "Quantity traded or liquidated, in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "usd_value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional value: price × quantity.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790238168,
         "data_type": "raw_spot_ticks",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:43:57.861Z",
           "timestamp": "2026-09-30T17:43:57.861Z",
           "side": "buy",
           "price": 84038.1,
           "quantity": 0.00002379,
           "usd_value": 1.9992663990000001
          },
          {
           "time": "2026-09-30T17:43:57.657Z",
           "timestamp": "2026-09-30T17:43:57.657Z",
           "side": "sell",
           "price": 84046,
           "quantity": 0.00497,
           "usd_value": 417.70861999999994
          },
          {
           "time": "2026-09-30T17:43:57.609Z",
           "timestamp": "2026-09-30T17:43:57.609Z",
           "side": "buy",
           "price": 84038.1,
           "quantity": 0.00058779,
           "usd_value": 49.39675479900001
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Raw spot executions across venues, most recent first. Kept 72 hours.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/spot-ticks?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/spot-ticks\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/spot-ticks?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/taker-combined": {
   "get": {
    "summary": "Taker buy/sell volume per minute",
    "operationId": "get_taker_combined_v1_raw_taker_combined_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 30
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "taker_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) buy volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Aggressive (taker) sell volume, aggregated across venues.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790240002,
         "data_type": "raw_taker_combined",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:42:00.000Z",
           "timestamp": "2026-09-30T17:42:00.000Z",
           "taker_buy": 55.96537000000028,
           "taker_sell": 76.6487100000001
          },
          {
           "time": "2026-09-30T17:41:00.000Z",
           "timestamp": "2026-09-30T17:41:00.000Z",
           "taker_buy": 63.93851000000009,
           "taker_sell": 42.53864
          },
          {
           "time": "2026-09-30T17:40:00.000Z",
           "timestamp": "2026-09-30T17:40:00.000Z",
           "taker_buy": 109.69762000000007,
           "taker_sell": 100.76166000000012
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Aggressive buy and sell volume per minute, aggregated across venues. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/taker-combined?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/taker-combined\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/taker-combined?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/trades": {
   "get": {
    "summary": "Trades aggregated per second",
    "description": "Every trade of every venue summed per second: volume, trade count, taker buy and sell. Kept 72 hours. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_trades_v1_raw_trades_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 60
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "total_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total traded volume over the period, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades.",
              "x-unit": "count"
             },
             "taker_buy_vol": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker buy volume.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "taker_sell_vol": {
              "type": [
               "number",
               "null"
              ],
              "description": "Taker sell volume.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790236947,
         "data_type": "raw_trades",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:43:55.000Z",
           "timestamp": "2026-09-30T17:43:55.000Z",
           "total_volume": 1.04198,
           "trade_count": 34,
           "taker_buy_vol": 0.8699800000000001,
           "taker_sell_vol": 0.17200000000000001
          },
          {
           "time": "2026-09-30T17:43:54.000Z",
           "timestamp": "2026-09-30T17:43:54.000Z",
           "total_volume": 0.11987,
           "trade_count": 9,
           "taker_buy_vol": 0.11257,
           "taker_sell_vol": 0.0073
          },
          {
           "time": "2026-09-30T17:43:53.000Z",
           "timestamp": "2026-09-30T17:43:53.000Z",
           "total_volume": 0.6443000000000001,
           "trade_count": 9,
           "taker_buy_vol": 0.6309000000000001,
           "taker_sell_vol": 0.0134
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/trades?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/trades\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/trades?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/raw/trades/large": {
   "get": {
    "summary": "Large individual trades",
    "operationId": "get_trades_large_v1_raw_trades_large_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "min_usd",
      "in": "query",
      "required": false,
      "schema": {
       "type": "number",
       "minimum": 1000,
       "default": 100000
      },
      "description": "Minimum notional in USD (default 100000, minimum 1000).",
      "example": "100000"
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 50
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "side": {
              "type": "string",
              "description": "Trades: `buy` or `sell` (aggressor side). Liquidations: `long` or `short` (the position liquidated)."
             },
             "price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "quantity": {
              "type": [
               "number",
               "null"
              ],
              "description": "Quantity traded or liquidated, in base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "usd_value": {
              "type": [
               "number",
               "null"
              ],
              "description": "Notional value: price × quantity.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790237569,
         "data_type": "raw_trades_large",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-30T17:43:33.084Z",
           "timestamp": "2026-09-30T17:43:33.084Z",
           "side": "sell",
           "price": 84012.5,
           "quantity": 1.2113,
           "usd_value": 101764.34125
          },
          {
           "time": "2026-09-30T17:43:17.525Z",
           "timestamp": "2026-09-30T17:43:17.525Z",
           "side": "sell",
           "price": 84015.1,
           "quantity": 1.1906,
           "usd_value": 100028.37806000002
          },
          {
           "time": "2026-09-30T17:43:03.938Z",
           "timestamp": "2026-09-30T17:43:03.938Z",
           "side": "sell",
           "price": 84027.2,
           "quantity": 2.9764,
           "usd_value": 250098.55808
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Market: prices & volumes"
    ],
    "description": "Individual trades above `min_usd` (default 100,000 USD), all venues, spot and futures. The venue is not disclosed (aggregation-only contract). Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/raw/trades/large?symbol=BTCUSDT&min_usd=100000&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/raw/trades/large\",\n    params={\"symbol\": \"BTCUSDT\", \"min_usd\": \"100000\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/raw/trades/large?symbol=BTCUSDT&min_usd=100000&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/snapshot": {
   "get": {
    "summary": "Many fields for one symbol in one request",
    "description": "Up to 61 fields for one symbol in a single call: prices, flow, derivatives, liquidations, macro, on-chain, options. Each query key is a field and its value a depth: `funding_rate_8h=1` (or `=true`), `klines_1h=24`. Multi-timeframe fields take `@tf`: `cvd@1h=24`. Call it with only `symbol` to get `available_fields` (fields without a timeframe), `available_multi_tf_fields`, `timeframes` and `max_depth`. An empty field carries `unavailable` (`not_applicable`, `no_api_key` or `no_data`) so 'no measure' is never mistaken for 'nothing happened'. Response: `data` is an object keyed by field name, plus `coverage` (venues per multi-venue metric) and `partial` (true if a field failed).",
    "operationId": "get_snapshot_v1_snapshot_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list. Alone, it returns the catalogue of the fields your plan includes.",
      "schema": {
       "type": "string"
      },
      "example": "BTCUSDT"
     },
     {
      "name": "basis",
      "in": "query",
      "required": false,
      "description": "Futures-spot basis (N latest minutes). Same content as `/v1/basis`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 60
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "btc_fees",
      "in": "query",
      "required": false,
      "description": "Recommended Bitcoin fees. Same content as `/v1/btc/fees`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "btc_mempool",
      "in": "query",
      "required": false,
      "description": "Bitcoin mempool. Same content as `/v1/btc/mempool`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "btc_mining",
      "in": "query",
      "required": false,
      "description": "Mining pool concentration. Same content as `/v1/btc/mining`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "btc_network",
      "in": "query",
      "required": false,
      "description": "Bitcoin network state. Same content as `/v1/btc/network`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "buysell_ratio",
      "in": "query",
      "required": false,
      "description": "Buy/sell volume ratio. Same content as `/v1/buysell/ratio`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_defi",
      "in": "query",
      "required": false,
      "description": "Ethereum DeFi. Same content as `/v1/eth/defi`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_deflation",
      "in": "query",
      "required": false,
      "description": "ETH deflation. Same content as `/v1/eth/deflation`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_gas",
      "in": "query",
      "required": false,
      "description": "Ethereum gas. Same content as `/v1/eth/gas`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_gas_momentum",
      "in": "query",
      "required": false,
      "description": "Gas momentum. Same content as `/v1/eth/gas-momentum`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_ratio",
      "in": "query",
      "required": false,
      "description": "ETH/BTC ratio. Same content as `/v1/eth/ratio`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_squeeze",
      "in": "query",
      "required": false,
      "description": "ETH supply squeeze index. Same content as `/v1/eth/squeeze`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_staking",
      "in": "query",
      "required": false,
      "description": "ETH staking. Same content as `/v1/eth/staking`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "eth_supply",
      "in": "query",
      "required": false,
      "description": "ETH supply and burn. Same content as `/v1/eth/supply`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "fear_greed",
      "in": "query",
      "required": false,
      "description": "Crypto Fear & Greed Index. Same content as `/v1/fear-greed`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "funding_cumulative",
      "in": "query",
      "required": false,
      "description": "Funding summed over 24 h. Same content as `/v1/funding/cumulative`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "funding_next",
      "in": "query",
      "required": false,
      "description": "Next funding forecast. Same content as `/v1/funding/next`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "funding_rate_8h",
      "in": "query",
      "required": false,
      "description": "Latest settled funding window. Same content as `/v1/funding/rate`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "futures_ticks",
      "in": "query",
      "required": false,
      "description": "Individual futures trades (N trades), bounded by your plan's tick window. Same content as `/v1/raw/futures-ticks`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 10000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "global_market",
      "in": "query",
      "required": false,
      "description": "Total crypto market cap and dominance. Same content as `/v1/global`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "heatmap",
      "in": "query",
      "required": false,
      "description": "Liquidation heatmap clusters. Same content as `/v1/heatmap/clusters`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_15m",
      "in": "query",
      "required": false,
      "description": "15-minute OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_1d",
      "in": "query",
      "required": false,
      "description": "Daily OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_1h",
      "in": "query",
      "required": false,
      "description": "1-hour OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_1m",
      "in": "query",
      "required": false,
      "description": "1-minute OHLCV candles (N candles). Same content as `/v1/raw/klines`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_1w",
      "in": "query",
      "required": false,
      "description": "Weekly OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_30m",
      "in": "query",
      "required": false,
      "description": "30-minute OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_4h",
      "in": "query",
      "required": false,
      "description": "4-hour OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "klines_5m",
      "in": "query",
      "required": false,
      "description": "5-minute OHLCV candles (N candles). Same content as `/v1/raw/klines/{interval}`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "liq_cumulative",
      "in": "query",
      "required": false,
      "description": "Liquidations long/short USD (N latest minutes). Same content as `/v1/liquidations/cumulative`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "liq_ratio",
      "in": "query",
      "required": false,
      "description": "Big vs small liquidations. Same content as `/v1/liquidations/ratio`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "liquidations",
      "in": "query",
      "required": false,
      "description": "Individual liquidations over the last N minutes. Same content as `/v1/raw/liquidations`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "macro",
      "in": "query",
      "required": false,
      "description": "Latest value of every FRED series. Same content as `/v1/macro`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "macro_correlations",
      "in": "query",
      "required": false,
      "description": "BTC correlation with DXY, S&P 500, gold, VIX. Same content as `/v1/macro/correlations`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "macro_momentum",
      "in": "query",
      "required": false,
      "description": "Macro momentum score. Same content as `/v1/macro/momentum`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "macro_risk",
      "in": "query",
      "required": false,
      "description": "Risk-on / risk-off score. Same content as `/v1/macro/risk`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "net_liquidity",
      "in": "query",
      "required": false,
      "description": "US net liquidity. Same content as `/v1/macro/net-liquidity`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "oi_delta",
      "in": "query",
      "required": false,
      "description": "Open interest change (N latest minutes). Same content as `/v1/oi/delta`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 60
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "oi_history",
      "in": "query",
      "required": false,
      "description": "Total open interest per minute (N minutes). Same content as `/v1/raw/oi`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "oi_snapshots",
      "in": "query",
      "required": false,
      "description": "Latest total open interest. Same content as `/v1/raw/oi`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "onchain_active_addresses",
      "in": "query",
      "required": false,
      "description": "Bitcoin active addresses. Same content as `/v1/onchain/active-addresses`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "onchain_miner_stress",
      "in": "query",
      "required": false,
      "description": "Bitcoin miner stress. Same content as `/v1/onchain/miner-stress`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "onchain_mvrv",
      "in": "query",
      "required": false,
      "description": "Bitcoin MVRV. Same content as `/v1/onchain/mvrv`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "onchain_nvt",
      "in": "query",
      "required": false,
      "description": "Bitcoin NVT. Same content as `/v1/onchain/nvt`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "options",
      "in": "query",
      "required": false,
      "description": "Options market summary for the symbol's asset. Same content as `/v1/options/summary`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook",
      "in": "query",
      "required": false,
      "description": "Latest aggregated order book. Same content as `/v1/raw/orderbook`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "price_change",
      "in": "query",
      "required": false,
      "description": "Price change over 1m to 1w, in percent. Same content as `/v1/price-change`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spot_ticks",
      "in": "query",
      "required": false,
      "description": "Individual spot trades (N trades), bounded by your plan's tick window. Same content as `/v1/raw/spot-ticks`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 10000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "taker_combined",
      "in": "query",
      "required": false,
      "description": "Taker buy/sell volume per minute (N minutes). Same content as `/v1/raw/taker-combined`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "tokenomics",
      "in": "query",
      "required": false,
      "description": "Supply, market cap, FDV. Same content as `/v1/tokenomics`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_size",
      "in": "query",
      "required": false,
      "description": "Average trade size. Same content as `/v1/trades/avg-size`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trades_raw",
      "in": "query",
      "required": false,
      "description": "Trades aggregated per second (N seconds). Same content as `/v1/raw/trades`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 3600
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap",
      "in": "query",
      "required": false,
      "description": "Intraday VWAP (N latest minutes). Same content as `/v1/vwap`. Value: depth N, or `true` for 1.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 60
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@1m",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 1m. Same content as `/v1/cvd?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@5m",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 5m. Same content as `/v1/cvd?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@15m",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 15m. Same content as `/v1/cvd?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@30m",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 30m. Same content as `/v1/cvd?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@1h",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 1h. Same content as `/v1/cvd?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@4h",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 4h. Same content as `/v1/cvd?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "cvd@1d",
      "in": "query",
      "required": false,
      "description": "CVD per bucket (N latest closed buckets). Timeframe 1d. Same content as `/v1/cvd?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 200
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@5m",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 5m. Same content as `/v1/ls-ratio?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@15m",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 15m. Same content as `/v1/ls-ratio?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@30m",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 30m. Same content as `/v1/ls-ratio?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@1h",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 1h. Same content as `/v1/ls-ratio?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@4h",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 4h. Same content as `/v1/ls-ratio?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "ls_ratio@1d",
      "in": "query",
      "required": false,
      "description": "Long/short account ratio per bucket (no 1m). Timeframe 1d. Same content as `/v1/ls-ratio?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 500
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@1m",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 1m. Same content as `/v1/orderbook/aggregated?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@5m",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 5m. Same content as `/v1/orderbook/aggregated?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@15m",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 15m. Same content as `/v1/orderbook/aggregated?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@30m",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 30m. Same content as `/v1/orderbook/aggregated?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@1h",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 1h. Same content as `/v1/orderbook/aggregated?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@4h",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 4h. Same content as `/v1/orderbook/aggregated?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "orderbook_aggregated@1d",
      "in": "query",
      "required": false,
      "description": "Order book statistics per bucket. Timeframe 1d. Same content as `/v1/orderbook/aggregated?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@1m",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 1m. Same content as `/v1/spread/interexchange?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@5m",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 5m. Same content as `/v1/spread/interexchange?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@15m",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 15m. Same content as `/v1/spread/interexchange?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@30m",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 30m. Same content as `/v1/spread/interexchange?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@1h",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 1h. Same content as `/v1/spread/interexchange?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@4h",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 4h. Same content as `/v1/spread/interexchange?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "spread_interexchange@1d",
      "in": "query",
      "required": false,
      "description": "Inter-venue spread per bucket. Timeframe 1d. Same content as `/v1/spread/interexchange?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 50
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@1m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 1m. Same content as `/v1/trades?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@5m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 5m. Same content as `/v1/trades?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@15m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 15m. Same content as `/v1/trades?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@30m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 30m. Same content as `/v1/trades?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@1h",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 1h. Same content as `/v1/trades?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@4h",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 4h. Same content as `/v1/trades?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade@1d",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot + futures (N latest closed buckets). Timeframe 1d. Same content as `/v1/trades?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@1m",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 1m. Same content as `/v1/trades/future?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@5m",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 5m. Same content as `/v1/trades/future?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@15m",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 15m. Same content as `/v1/trades/future?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@30m",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 30m. Same content as `/v1/trades/future?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@1h",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 1h. Same content as `/v1/trades/future?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@4h",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 4h. Same content as `/v1/trades/future?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_future@1d",
      "in": "query",
      "required": false,
      "description": "Trade candles, futures only. Timeframe 1d. Same content as `/v1/trades/future?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@1m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 1m. Same content as `/v1/trades/spot?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@5m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 5m. Same content as `/v1/trades/spot?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@15m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 15m. Same content as `/v1/trades/spot?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@30m",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 30m. Same content as `/v1/trades/spot?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@1h",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 1h. Same content as `/v1/trades/spot?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@4h",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 4h. Same content as `/v1/trades/spot?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "trade_spot@1d",
      "in": "query",
      "required": false,
      "description": "Trade candles, spot only. Timeframe 1d. Same content as `/v1/trades/spot?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1440
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@1m",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 1m. Same content as `/v1/vwap/window?timeframe=1m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@5m",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 5m. Same content as `/v1/vwap/window?timeframe=5m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@15m",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 15m. Same content as `/v1/vwap/window?timeframe=15m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@30m",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 30m. Same content as `/v1/vwap/window?timeframe=30m`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@1h",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 1h. Same content as `/v1/vwap/window?timeframe=1h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@4h",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 4h. Same content as `/v1/vwap/window?timeframe=4h`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     },
     {
      "name": "vwap_window@1d",
      "in": "query",
      "required": false,
      "description": "VWAP per bucket (N latest closed buckets). Timeframe 1d. Same content as `/v1/vwap/window?timeframe=1d`.",
      "schema": {
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 1000
        },
        {
         "type": "string",
         "enum": [
          "true"
         ]
        }
       ]
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "partial": {
           "type": "boolean"
          },
          "data": {
           "type": "object",
           "properties": {
            "funding_rate_8h": {
             "type": "object",
             "properties": {
              "time": {
               "type": "string",
               "format": "date-time",
               "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "bucket": {
               "type": "string",
               "format": "date-time",
               "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "rate": {
               "type": [
                "number",
                "null"
               ],
               "description": "Settled funding rate, normalised to an 8-hour period, open-interest weighted across venues.",
               "x-unit": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)"
              },
              "apr_pct": {
               "type": [
                "number",
                "null"
               ],
               "description": "Annualised rate in percent.",
               "x-unit": "percent (58.5 = 58.5 %)"
              },
              "exchange_count": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Number of venues in the weighted average.",
               "x-unit": "count"
              }
             }
            },
            "basis": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "time": {
                "type": "string",
                "format": "date-time",
                "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
               },
               "timestamp": {
                "type": "string",
                "format": "date-time",
                "description": "Measurement instant (start of the bucket for aggregated rows).",
                "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
               },
               "basis_value": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Futures price - spot price.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               },
               "basis_pct": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "(futures - spot) / spot, in percent. Positive = contango.",
                "x-unit": "percent (58.5 = 58.5 %)"
               },
               "futures_price": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Perpetual futures price, open-interest weighted across venues.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               },
               "spot_price": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Spot price across venues.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               }
              }
             }
            },
            "fear_greed": {
             "type": "object",
             "properties": {
              "time": {
               "type": "string",
               "format": "date-time",
               "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "timestamp": {
               "type": "string",
               "format": "date-time",
               "description": "Measurement instant (start of the bucket for aggregated rows).",
               "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
              },
              "value": {
               "type": [
                "integer",
                "null"
               ],
               "description": "Value of the series.",
               "x-unit": "dimensionless score"
              },
              "value_classification": {
               "type": "string",
               "description": "Label published by alternative.me: `Extreme Fear`, `Fear`, `Neutral`, `Greed` or `Extreme Greed`."
              }
             }
            },
            "cvd@1h": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "time": {
                "type": "string",
                "format": "date-time",
                "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
                "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
               },
               "bucket": {
                "type": "string",
                "format": "date-time",
                "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
                "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
               },
               "symbol": {
                "type": "string",
                "description": "Trading pair, e.g. `BTCUSDT`."
               },
               "cvd_series": {
                "type": "array",
                "items": {
                 "type": [
                  "number",
                  "null"
                 ]
                },
                "description": "Cumulative volume delta inside the bucket, one point per minute, starting from 0 at the bucket start.",
                "x-unit": "base asset quantity (BTC for BTCUSDT)"
               },
               "net_delta": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Taker buy volume - taker sell volume over the bucket, base asset units.",
                "x-unit": "base asset quantity (BTC for BTCUSDT)"
               },
               "taker_buy_volume": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Taker buy volume over the bucket.",
                "x-unit": "base asset quantity (BTC for BTCUSDT)"
               },
               "taker_sell_volume": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Taker sell volume over the bucket.",
                "x-unit": "base asset quantity (BTC for BTCUSDT)"
               },
               "points_count": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Number of one-minute points in `cvd_series`.",
                "x-unit": "count"
               }
              }
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "coverage": {
           "type": "object",
           "properties": {
            "funding_rate_8h": {
             "type": "object",
             "properties": {
              "status": {
               "type": "string"
              },
              "effect": {
               "type": "string"
              },
              "count_field": {
               "type": "string"
              },
              "venues_expected": {
               "type": [
                "integer",
                "null"
               ]
              }
             }
            },
            "basis": {
             "type": "object",
             "properties": {
              "status": {
               "type": "string"
              },
              "reason": {
               "type": "string"
              }
             }
            },
            "cvd@1h": {
             "type": "object",
             "properties": {
              "status": {
               "type": "string"
              },
              "reason": {
               "type": "string"
              }
             }
            }
           },
           "description": "`sources_active` (venues contributing) and `oi_coverage_ratio` (share of open interest covered, 1.0 = all)."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790234258,
         "data_type": "snapshot",
         "partial": false,
         "data": {
          "funding_rate_8h": {
           "time": "2026-09-30T08:00:00.000Z",
           "bucket": "2026-09-30T08:00:00.000Z",
           "rate": 0.00006287020093464952,
           "apr_pct": 6.884287002344122
          },
          "basis": [
           {
            "time": "2026-09-30T17:43:37.309Z",
            "timestamp": "2026-09-30T17:43:37.309Z",
            "basis_value": -38.03961943906421,
            "basis_pct": -0.04526350810118282,
            "futures_price": 84002.17394512612,
            "spot_price": 84040.21356456519
           }
          ],
          "fear_greed": {
           "time": "2026-09-30T00:00:00.000Z",
           "timestamp": "2026-09-30T00:00:00.000Z",
           "value": 71,
           "value_classification": "Greed"
          },
          "cvd@1h": [
           {
            "time": "2026-09-30T16:00:00.000Z",
            "bucket": "2026-09-30T16:00:00.000Z",
            "symbol": "BTCUSDT",
            "cvd_series": [
             45.888329999999726,
             69.2295500000001,
             200.21975000000012
            ],
            "net_delta": -707.4313099999853,
            "taker_buy_volume": 8806.463150000012,
            "taker_sell_volume": 9513.894459999998,
            "points_count": 60
           },
           {
            "time": "2026-09-30T15:00:00.000Z",
            "bucket": "2026-09-30T15:00:00.000Z",
            "symbol": "BTCUSDT",
            "cvd_series": [
             -662.8237799999529,
             -701.9267099999539,
             -770.6161599999542
            ],
            "net_delta": -959.6718699999959,
            "taker_buy_volume": 14950.270559999979,
            "taker_sell_volume": 15909.942429999976,
            "points_count": 60
           }
          ]
         },
         "coverage": {
          "funding_rate_8h": {
           "status": "available",
           "effect": "weighted",
           "count_field": "exchange_count"
          },
          "basis": {
           "status": "unavailable",
           "reason": "pre_aggregated"
          },
          "cvd@1h": {
           "status": "unavailable",
           "reason": "pre_aggregated"
          }
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Snapshot"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/snapshot?symbol=BTCUSDT&funding_rate_8h=1&basis=1&fear_greed=1&cvd@1h=2\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/snapshot\",\n    params={\"symbol\": \"BTCUSDT\", \"funding_rate_8h\": \"1\", \"basis\": \"1\", \"fear_greed\": \"1\", \"cvd@1h\": \"2\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/snapshot?symbol=BTCUSDT&funding_rate_8h=1&basis=1&fear_greed=1&cvd@1h=2\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/spread/interexchange": {
   "get": {
    "summary": "Inter-venue price spread",
    "description": "Each venue's premium versus the volume-weighted reference price over the bucket, and the widest gap between two venues. The only route that names venues. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_spread_interexchange_v1_spread_interexchange_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "timeframe": {
             "type": "string",
             "description": "Bucket size of the row."
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            },
            "ref_price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Reference price: the volume-weighted average price across venues over the bucket.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "weighting": {
             "type": "string",
             "description": "How venues are combined: `oi` (open-interest weighted) or `volume` (volume weighted)."
            },
            "max_spread_bps": {
             "type": [
              "number",
              "null"
             ],
             "description": "Gap between the highest and the lowest venue price, relative to ref_price.",
             "x-unit": "basis points (1 bp = 0.01 %)"
            },
            "max_spread_pct": {
             "type": [
              "number",
              "null"
             ],
             "description": "Same gap as max_spread_bps, in percent.",
             "x-unit": "percent (58.5 = 58.5 %)"
            },
            "high": {
             "type": "object",
             "properties": {
              "exchange": {
               "type": "string",
               "description": "Venue name (this route is the only one that names venues)."
              },
              "price": {
               "type": [
                "number",
                "null"
               ],
               "description": "Volume-weighted price of the venue over the bucket.",
               "x-unit": "quote currency (USDT for BTCUSDT)"
              }
             },
             "description": "Venue with the highest price over the bucket, and that price (`{exchange, price}`).",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "low": {
             "type": "object",
             "properties": {
              "exchange": {
               "type": "string",
               "description": "Venue name (this route is the only one that names venues)."
              },
              "price": {
               "type": [
                "number",
                "null"
               ],
               "description": "Volume-weighted price of the venue over the bucket.",
               "x-unit": "quote currency (USDT for BTCUSDT)"
              }
             },
             "description": "Venue with the lowest price over the bucket, and that price (`{exchange, price}`).",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "venue_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of venues that contributed to the value.",
             "x-unit": "count"
            },
            "venues": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "exchange": {
                "type": "string",
                "description": "Venue name (this route is the only one that names venues)."
               },
               "price": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Volume-weighted price of the venue over the bucket.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               },
               "premium_bps": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Venue price premium (positive) or discount (negative) versus ref_price.",
                "x-unit": "basis points (1 bp = 0.01 %)"
               }
              }
             },
             "description": "Per-venue prices and premiums (`[{exchange, price, premium_bps}]`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790255032,
         "data_type": "spread_interexchange_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T16:00:00.000Z",
          "timestamp": "2026-09-30T16:00:00.000Z",
          "timeframe": "1h",
          "is_closed": true,
          "ref_price": 84302.13575805252,
          "weighting": "volume",
          "max_spread_bps": 7.265255263451655,
          "max_spread_pct": 0.07265255263451655,
          "high": {
           "exchange": "venue_a",
           "price": 84339.01594956248
          },
          "low": {
           "exchange": "venue_b",
           "price": 84277.76829600884
          },
          "venues": [
           {
            "exchange": "venue_a",
            "price": 84339.01594956248,
            "premium_bps": 4.374763602171059
           },
           {
            "exchange": "venue_c",
            "price": 84311.22011829651,
            "premium_bps": 1.077595503636774
           },
           {
            "exchange": "venue_d",
            "price": 84308.69709339853,
            "premium_bps": 0.7783118763251422
           }
          ]
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/spread/interexchange?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/spread/interexchange\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/spread/interexchange?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/spread/interexchange/history": {
   "get": {
    "summary": "Inter-venue spread history",
    "description": "Same as `/v1/spread/interexchange`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_spread_interexchange_history_v1_spread_interexchange_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 500,
       "minimum": 1,
       "default": 30
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timeframe": {
              "type": "string",
              "description": "Bucket size of the row."
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             },
             "ref_price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Reference price: the volume-weighted average price across venues over the bucket.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "weighting": {
              "type": "string",
              "description": "How venues are combined: `oi` (open-interest weighted) or `volume` (volume weighted)."
             },
             "max_spread_bps": {
              "type": [
               "number",
               "null"
              ],
              "description": "Gap between the highest and the lowest venue price, relative to ref_price.",
              "x-unit": "basis points (1 bp = 0.01 %)"
             },
             "max_spread_pct": {
              "type": [
               "number",
               "null"
              ],
              "description": "Same gap as max_spread_bps, in percent.",
              "x-unit": "percent (58.5 = 58.5 %)"
             },
             "high": {
              "type": "object",
              "properties": {
               "exchange": {
                "type": "string",
                "description": "Venue name (this route is the only one that names venues)."
               },
               "price": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Volume-weighted price of the venue over the bucket.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               }
              },
              "description": "Venue with the highest price over the bucket, and that price (`{exchange, price}`).",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "low": {
              "type": "object",
              "properties": {
               "exchange": {
                "type": "string",
                "description": "Venue name (this route is the only one that names venues)."
               },
               "price": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Volume-weighted price of the venue over the bucket.",
                "x-unit": "quote currency (USDT for BTCUSDT)"
               }
              },
              "description": "Venue with the lowest price over the bucket, and that price (`{exchange, price}`).",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "venue_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of venues that contributed to the value.",
              "x-unit": "count"
             },
             "venues": {
              "type": "array",
              "items": {
               "type": "object",
               "properties": {
                "exchange": {
                 "type": "string",
                 "description": "Venue name (this route is the only one that names venues)."
                },
                "price": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Volume-weighted price of the venue over the bucket.",
                 "x-unit": "quote currency (USDT for BTCUSDT)"
                },
                "premium_bps": {
                 "type": [
                  "number",
                  "null"
                 ],
                 "description": "Venue price premium (positive) or discount (negative) versus ref_price.",
                 "x-unit": "basis points (1 bp = 0.01 %)"
                }
               }
              },
              "description": "Per-venue prices and premiums (`[{exchange, price, premium_bps}]`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790255706,
         "data_type": "spread_interexchange_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "timeframe": "1h",
           "is_closed": true,
           "ref_price": 84302.13575805252,
           "weighting": "volume",
           "max_spread_bps": 7.265255263451655,
           "max_spread_pct": 0.07265255263451655,
           "high": {
            "exchange": "venue_a",
            "price": 84339.01594956248
           },
           "low": {
            "exchange": "venue_b",
            "price": 84277.76829600884
           },
           "venues": [
            {
             "exchange": "venue_a",
             "price": 84339.01594956248,
             "premium_bps": 4.374763602171059
            },
            {
             "exchange": "venue_c",
             "price": 84311.22011829651,
             "premium_bps": 1.077595503636774
            },
            {
             "exchange": "venue_d",
             "price": 84308.69709339853,
             "premium_bps": 0.7783118763251422
            }
           ]
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "timeframe": "1h",
           "is_closed": true,
           "ref_price": 83977.32824027882,
           "weighting": "volume",
           "max_spread_bps": 7.230792694184376,
           "max_spread_pct": 0.07230792694184376,
           "high": {
            "exchange": "venue_e",
            "price": 84006.19755398165
           },
           "low": {
            "exchange": "venue_f",
            "price": 83945.47528882996
           },
           "venues": [
            {
             "exchange": "venue_e",
             "price": 84006.19755398165,
             "premium_bps": 3.4377509153696106
            },
            {
             "exchange": "venue_a",
             "price": 84003.38969198865,
             "premium_bps": 3.1033913862157356
            },
            {
             "exchange": "venue_c",
             "price": 83991.16097920474,
             "premium_bps": 1.6471992162387497
            }
           ]
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "timeframe": "1h",
           "is_closed": true,
           "ref_price": 83845.17999729452,
           "weighting": "volume",
           "max_spread_bps": 10.780061118052815,
           "max_spread_pct": 0.10780061118052814,
           "high": {
            "exchange": "venue_b",
            "price": 83915.2046517969
           },
           "low": {
            "exchange": "venue_f",
            "price": 83824.8190353144
           },
           "venues": [
            {
             "exchange": "venue_b",
             "price": 83915.2046517969,
             "premium_bps": 8.351661300583206
            },
            {
             "exchange": "venue_c",
             "price": 83863.89622905052,
             "premium_bps": 2.2322370536509726
            },
            {
             "exchange": "venue_a",
             "price": 83862.72855779529,
             "premium_bps": 2.0929718919247287
            }
           ]
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/spread/interexchange/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/spread/interexchange/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/spread/interexchange/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/status": {
   "get": {
    "summary": "Freshness of every feed",
    "operationId": "status_v1_status_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data": {
           "type": "object",
           "properties": {
            "feeds_checked": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Public feeds checked.",
             "x-unit": "count"
            },
            "feeds_stale": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Feeds older than their threshold.",
             "x-unit": "count"
            },
            "feeds_in_error": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Feeds that could not be checked.",
             "x-unit": "count"
            },
            "max_age_seconds": {
             "type": [
              "number",
              "null"
             ],
             "description": "Age of the oldest feed.",
             "x-unit": "seconds"
            },
            "feeds": {
             "type": "array",
             "items": {
              "type": "object",
              "properties": {
               "feed": {
                "type": "string",
                "description": "Feed name."
               },
               "family": {
                "type": "string",
                "description": "Data family the feed belongs to."
               },
               "age_seconds": {
                "type": [
                 "number",
                 "null"
                ],
                "description": "Age of the latest row of the feed.",
                "x-unit": "seconds"
               },
               "expected_interval_seconds": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Maximum legitimate age of the feed.",
                "x-unit": "seconds"
               },
               "threshold_seconds": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Age above which the feed is stale (1.5 × expected_interval_seconds).",
                "x-unit": "seconds"
               },
               "is_stale": {
                "type": "boolean",
                "description": "Whether the feed is stale."
               },
               "stale_venues": {
                "type": [
                 "integer",
                 "null"
                ],
                "description": "Venues lagging on this feed.",
                "x-unit": "count"
               }
              }
             },
             "description": "One row per public feed."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790110622,
         "data": {
          "feeds_checked": 67,
          "feeds_stale": 0,
          "feeds_in_error": 0,
          "max_age_seconds": 150111.5,
          "feeds": [
           {
            "feed": "klines_futures_1m",
            "family": "prix-volume",
            "age_seconds": 111.2,
            "expected_interval_seconds": 120,
            "threshold_seconds": 180,
            "is_stale": false,
            "stale_venues": 0
           },
           {
            "feed": "klines_1m",
            "family": "prix-volume",
            "age_seconds": 111.2,
            "expected_interval_seconds": 180,
            "threshold_seconds": 270,
            "is_stale": false,
            "stale_venues": 0
           },
           {
            "feed": "klines_multi",
            "family": "prix-volume",
            "age_seconds": 411.2,
            "expected_interval_seconds": 660,
            "threshold_seconds": 990,
            "is_stale": false,
            "stale_venues": null
           }
          ]
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "System"
    ],
    "description": "One row per public feed with its age and staleness threshold (1.5 × the feed's expected interval). Use it to tell 'no event' from 'feed down'. Not counted in your quota.",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/status\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/status\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/status\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/symbols": {
   "get": {
    "summary": "List the served trading pairs",
    "operationId": "get_symbols_v1_symbols_get",
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "base_asset": {
              "type": "string",
              "description": "Base asset of the pair."
             },
             "name": {
              "type": "string",
              "description": "Name."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790232799,
         "data_type": "symbols",
         "data": [
          {
           "symbol": "ADAUSDT",
           "base_asset": "ADA",
           "name": "Cardano"
          },
          {
           "symbol": "AVAXUSDT",
           "base_asset": "AVAX",
           "name": "Avalanche"
          },
          {
           "symbol": "BNBUSDT",
           "base_asset": "BNB",
           "name": "BNB"
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "System"
    ],
    "description": "The 22 served pairs: 20 USDT-margined perpetual markets (BTC, ETH, SOL, XRP, DOGE, BNB, TRX, SUI, HYPE, XLM, XMR, LINK, ADA, LTC, UNI, GRAM, AVAX, HBAR, NEAR, TAO) plus two spot-only stablecoin pairs (USDCUSDT, USDTUSDC).",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/symbols\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/symbols\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/symbols\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/symbols/{symbol}/capabilities": {
   "get": {
    "summary": "What a symbol supports",
    "description": "Which raw feeds were active over the last 24 h, and which derived metrics are available, blocked (with the missing feeds) or not applicable (stablecoins have no futures).",
    "operationId": "get_symbol_capabilities_v1_symbols__symbol__capabilities_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "asset_class": {
             "type": "string",
             "description": "`crypto` or `stablecoin` (spot only, no futures metrics)."
            },
            "feeds_active_last_24h": {
             "type": "object",
             "properties": {
              "futures_klines": {
               "type": "boolean"
              },
              "spot_ticks": {
               "type": "boolean"
              },
              "futures_ticks": {
               "type": "boolean"
              },
              "oi_snapshots": {
               "type": "boolean"
              },
              "funding_rates": {
               "type": "boolean"
              },
              "liquidations": {
               "type": "boolean"
              },
              "trades_raw": {
               "type": "boolean"
              },
              "klines_multi": {
               "type": "boolean"
              },
              "spot_klines": {
               "type": "boolean"
              },
              "spot_klines_multi": {
               "type": "boolean"
              }
             },
             "description": "Per raw feed: whether it received data in the last 24 h."
            },
            "computed_metrics_available": {
             "type": "array",
             "items": {
              "type": "string"
             },
             "description": "Derived metrics available for the symbol."
            },
            "computed_metrics_blocked": {
             "type": "object",
             "properties": {},
             "description": "Derived metrics unavailable, with the missing feeds."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790233542,
         "data_type": "symbol_capabilities",
         "symbol": "BTCUSDT",
         "data": {
          "symbol": "BTCUSDT",
          "asset_class": "crypto",
          "feeds_active_last_24h": {
           "futures_klines": true,
           "spot_ticks": true,
           "futures_ticks": true,
           "oi_snapshots": true,
           "funding_rates": true,
           "liquidations": true,
           "trades_raw": true,
           "klines_multi": true,
           "spot_klines": true,
           "spot_klines_multi": true
          },
          "computed_metrics_available": [
           "basis",
           "buysell_ratio",
           "funding_cumulative_24h"
          ],
          "computed_metrics_blocked": {}
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "System"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/symbols/BTCUSDT/capabilities\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/symbols/BTCUSDT/capabilities\",\n    params={},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/symbols/BTCUSDT/capabilities\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/tokenomics": {
   "get": {
    "summary": "Supply, market cap and FDV",
    "description": "Circulating, total and max supply, with market cap and FDV derived from the latest price at request time (pegged at 1 for stablecoins, FDV null).",
    "operationId": "get_tokenomics_v1_tokenomics_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "circulating_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "Coins in circulation.",
             "x-unit": "coins"
            },
            "total_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total coins issued (circulating + locked), net of burns.",
             "x-unit": "coins"
            },
            "max_supply": {
             "type": [
              "number",
              "null"
             ],
             "description": "Hard cap on supply. `null` = no cap.",
             "x-unit": "coins"
            },
            "price": {
             "type": [
              "number",
              "null"
             ],
             "description": "Latest price used for market_cap and fdv.",
             "x-unit": "USD"
            },
            "market_cap": {
             "type": [
              "number",
              "null"
             ],
             "description": "circulating_supply × current price, derived at request time.",
             "x-unit": "USD"
            },
            "fdv": {
             "type": [
              "number",
              "null"
             ],
             "description": "Fully diluted valuation: max_supply (or total_supply if uncapped) × price. `null` for stablecoins.",
             "x-unit": "USD"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790268578,
         "data_type": "tokenomics",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:33:15.926Z",
          "symbol": "BTCUSDT",
          "timestamp": "2026-09-30T17:33:15.926Z",
          "circulating_supply": 20090909,
          "total_supply": 20090909,
          "max_supply": 21000000,
          "price": 84046.01,
          "market_cap": 1688560738723.0898,
          "fdv": 1764966210000
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/tokenomics?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/tokenomics\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/tokenomics?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/tokenomics/history": {
   "get": {
    "summary": "Supply and market cap history",
    "description": "One row per day. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_tokenomics_history_v1_tokenomics_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "price": {
              "type": [
               "number",
               "null"
              ],
              "description": "Daily closing price used for the derived values.",
              "x-unit": "USD"
             },
             "circulating_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "Coins in circulation.",
              "x-unit": "coins"
             },
             "total_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total coins issued (circulating + locked), net of burns.",
              "x-unit": "coins"
             },
             "max_supply": {
              "type": [
               "number",
               "null"
              ],
              "description": "Hard cap on supply. `null` = no cap.",
              "x-unit": "coins"
             },
             "market_cap": {
              "type": [
               "number",
               "null"
              ],
              "description": "circulating_supply × current price, derived at request time.",
              "x-unit": "USD"
             },
             "fdv": {
              "type": [
               "number",
               "null"
              ],
              "description": "Fully diluted valuation: max_supply (or total_supply if uncapped) × price. `null` for stablecoins.",
              "x-unit": "USD"
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790269174,
         "data_type": "tokenomics_history",
         "symbol": "BTCUSDT",
         "data": [
          {
           "time": "2026-09-29T00:00:00.000Z",
           "bucket": "2026-09-29T00:00:00.000Z",
           "price": 83663.66,
           "circulating_supply": 20090909,
           "total_supply": 20090909,
           "max_supply": 21000000,
           "market_cap": 1680878979666.9402,
           "fdv": 1756936860000
          },
          {
           "time": "2026-09-28T00:00:00.000Z",
           "bucket": "2026-09-28T00:00:00.000Z",
           "price": 83461.1,
           "circulating_supply": 20090662,
           "total_supply": 20090662,
           "max_supply": 21000000,
           "market_cap": 1676788750248.2002,
           "fdv": 1752683100000.0002
          },
          {
           "time": "2026-09-27T00:00:00.000Z",
           "bucket": "2026-09-27T00:00:00.000Z",
           "price": 84432.9,
           "circulating_supply": 20090284,
           "total_supply": 20090284,
           "max_supply": 21000000,
           "market_cap": 1696280939943.5999,
           "fdv": 1773090899999.9998
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Tokenomics & sentiment"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/tokenomics/history?symbol=BTCUSDT&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/tokenomics/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/tokenomics/history?symbol=BTCUSDT&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades": {
   "get": {
    "summary": "Trade candle, spot + futures combined",
    "description": "Trade count, volumes buy/sell, delta, average size and rate for the latest closed bucket, all venues, spot and futures. Volumes are in BASE ASSET units (BTC for BTCUSDT). Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_trades_v1_trades_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "bucket": {
             "type": "string",
             "format": "date-time",
             "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "exchange": {
             "type": "string",
             "description": "Always `combined`: the value aggregates every venue."
            },
            "trades_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of trades in the bucket, all venues.",
             "x-unit": "count"
            },
            "trades_count_buy": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of buyer-initiated trades.",
             "x-unit": "count"
            },
            "trades_count_sell": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of seller-initiated trades.",
             "x-unit": "count"
            },
            "trade_count_dom": {
             "type": [
              "integer",
              "null"
             ],
             "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
             "x-unit": "count"
            },
            "trades_avg": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of buy trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of sell trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Buyer-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Seller-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "volume_delta": {
             "type": [
              "number",
              "null"
             ],
             "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average number of trades per second over the bucket.",
             "x-unit": "trades per second"
            },
            "volume_estimated": {
             "type": "boolean",
             "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790243344,
         "data_type": "trades_candle_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T16:00:00.000Z",
          "bucket": "2026-09-30T16:00:00.000Z",
          "symbol": "BTCUSDT",
          "exchange": "combined",
          "trades_count": 675268,
          "trades_count_buy": 351422,
          "trades_count_sell": 323846,
          "trade_count_dom": 27576,
          "trades_avg": 0.030507578690431178,
          "trade_avg_buy": 0.028389836265600935,
          "trade_avg_sell": 0.03280565023807613,
          "trade_volume": 20600.79164713008,
          "trade_volume_buy": 9976.813040130011,
          "trade_volume_sell": 10623.978607000001,
          "volume_delta": -647.1655668699896,
          "trade_rate": 187.57444444444445,
          "volume_estimated": false,
          "is_closed": true
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/avg-size": {
   "get": {
    "summary": "Average trade size",
    "description": "Average trade size over the latest minute written, all venues (null if no trade in the last day).",
    "operationId": "get_trades_avg_size_v1_trades_avg_size_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "avg_size": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average trade size, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "total_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Total traded volume over the period, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of trades.",
             "x-unit": "count"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790248079,
         "data_type": "trade_size_avg",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:35.306Z",
          "avg_size": 0.02829312860266349,
          "total_volume": 142.34273000000002,
          "trade_count": 5031,
          "timestamp": "2026-09-30T17:43:35.306Z"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/avg-size?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/avg-size\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/avg-size?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/avg-size/history": {
   "get": {
    "summary": "Average trade size history",
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_trades_avg_size_history_v1_trades_avg_size_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "avg_size": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average trade size, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "total_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total traded volume over the period, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades.",
              "x-unit": "count"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790248705,
         "data_type": "trade_size_avg_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "avg_size": 0.04530373758231661,
           "total_volume": 17749.09831,
           "trade_count": 391780,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "avg_size": 0.04430684004913295,
           "total_volume": 29181.415299999993,
           "trade_count": 658621,
           "points": 59,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "avg_size": 0.05038130838811356,
           "total_volume": 73782.87194000004,
           "trade_count": 1464489,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/avg-size/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/avg-size/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/avg-size/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/future": {
   "get": {
    "summary": "Trade candle, futures only",
    "description": "Same as `/v1/trades`, perpetual futures only. Stablecoins have no futures: `data: null` with `unavailable`. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_trades_future_v1_trades_future_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "bucket": {
             "type": "string",
             "format": "date-time",
             "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "exchange": {
             "type": "string",
             "description": "Always `combined`: the value aggregates every venue."
            },
            "trades_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of trades in the bucket, all venues.",
             "x-unit": "count"
            },
            "trades_count_buy": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of buyer-initiated trades.",
             "x-unit": "count"
            },
            "trades_count_sell": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of seller-initiated trades.",
             "x-unit": "count"
            },
            "trade_count_dom": {
             "type": [
              "integer",
              "null"
             ],
             "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
             "x-unit": "count"
            },
            "trades_avg": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of buy trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of sell trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Buyer-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Seller-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "volume_delta": {
             "type": [
              "number",
              "null"
             ],
             "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average number of trades per second over the bucket.",
             "x-unit": "trades per second"
            },
            "volume_estimated": {
             "type": "boolean",
             "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790246706,
         "data_type": "trades_candle_future_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T16:00:00.000Z",
          "bucket": "2026-09-30T16:00:00.000Z",
          "symbol": "BTCUSDT",
          "exchange": "combined",
          "trades_count": 405045,
          "trades_count_buy": 202872,
          "trades_count_sell": 202173,
          "trade_count_dom": 699,
          "trades_avg": 0.045230935747880084,
          "trade_avg_buy": 0.04340942456327149,
          "trade_avg_sell": 0.04705874468895452,
          "trade_volume": 18320.564370000087,
          "trade_volume_buy": 8806.556780000014,
          "trade_volume_sell": 9514.007590000001,
          "volume_delta": -707.4508099999875,
          "trade_rate": 112.5125,
          "volume_estimated": false,
          "is_closed": true
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/future?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/future\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/future?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/future/history": {
   "get": {
    "summary": "Trade candles history, futures only",
    "description": "Same as `/v1/trades/future`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_trades_future_history_v1_trades_future_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "exchange": {
              "type": "string",
              "description": "Always `combined`: the value aggregates every venue."
             },
             "trades_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades in the bucket, all venues.",
              "x-unit": "count"
             },
             "trades_count_buy": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of buyer-initiated trades.",
              "x-unit": "count"
             },
             "trades_count_sell": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of seller-initiated trades.",
              "x-unit": "count"
             },
             "trade_count_dom": {
              "type": [
               "integer",
               "null"
              ],
              "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
              "x-unit": "count"
             },
             "trades_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of buy trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of sell trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Buyer-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Seller-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "volume_delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_rate": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average number of trades per second over the bucket.",
              "x-unit": "trades per second"
             },
             "volume_estimated": {
              "type": "boolean",
              "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790247486,
         "data_type": "trades_candle_future_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 405045,
           "trades_count_buy": 202872,
           "trades_count_sell": 202173,
           "trade_count_dom": 699,
           "trades_avg": 0.045230935747880084,
           "trade_avg_buy": 0.04340942456327149,
           "trade_avg_sell": 0.04705874468895452,
           "trade_volume": 18320.564370000087,
           "trade_volume_buy": 8806.556780000014,
           "trade_volume_sell": 9514.007590000001,
           "volume_delta": -707.4508099999875,
           "trade_rate": 112.5125,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 685554,
           "trades_count_buy": 352098,
           "trades_count_sell": 333456,
           "trade_count_dom": 18642,
           "trades_avg": 0.04501438543134438,
           "trade_avg_buy": 0.04245970854705205,
           "trade_avg_sell": 0.04771188261719679,
           "trade_volume": 30859.791989999867,
           "trade_volume_buy": 14949.978459999933,
           "trade_volume_sell": 15909.813529999974,
           "volume_delta": -959.835070000041,
           "trade_rate": 190.43166666666667,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 1488875,
           "trades_count_buy": 747321,
           "trades_count_sell": 741554,
           "trade_count_dom": 5767,
           "trades_avg": 0.05044640762992069,
           "trade_avg_buy": 0.04919763092432828,
           "trade_avg_sell": 0.0517048959617233,
           "trade_volume": 75108.39515999817,
           "trade_volume_buy": 36766.422739999936,
           "trade_volume_sell": 38341.97241999976,
           "volume_delta": -1575.5496799998218,
           "trade_rate": 413.5763888888889,
           "volume_estimated": false,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/future/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/future/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/future/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/history": {
   "get": {
    "summary": "Trade candles history, combined",
    "description": "Same as `/v1/trades`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_trades_history_v1_trades_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "exchange": {
              "type": "string",
              "description": "Always `combined`: the value aggregates every venue."
             },
             "trades_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades in the bucket, all venues.",
              "x-unit": "count"
             },
             "trades_count_buy": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of buyer-initiated trades.",
              "x-unit": "count"
             },
             "trades_count_sell": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of seller-initiated trades.",
              "x-unit": "count"
             },
             "trade_count_dom": {
              "type": [
               "integer",
               "null"
              ],
              "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
              "x-unit": "count"
             },
             "trades_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of buy trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of sell trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Buyer-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Seller-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "volume_delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_rate": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average number of trades per second over the bucket.",
              "x-unit": "trades per second"
             },
             "volume_estimated": {
              "type": "boolean",
              "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790244370,
         "data_type": "trades_candle_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 675268,
           "trades_count_buy": 351422,
           "trades_count_sell": 323846,
           "trade_count_dom": 27576,
           "trades_avg": 0.030507578690431178,
           "trade_avg_buy": 0.028389836265600935,
           "trade_avg_sell": 0.03280565023807613,
           "trade_volume": 20600.79164713008,
           "trade_volume_buy": 9976.813040130011,
           "trade_volume_sell": 10623.978607000001,
           "volume_delta": -647.1655668699896,
           "trade_rate": 187.57444444444445,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 1086360,
           "trades_count_buy": 577625,
           "trades_count_sell": 508735,
           "trade_count_dom": 68890,
           "trades_avg": 0.03149070232565307,
           "trade_avg_buy": 0.02889647807452921,
           "trade_avg_sell": 0.03443622166883854,
           "trade_volume": 34210.239378496466,
           "trade_volume_buy": 16691.328147799934,
           "trade_volume_sell": 17518.911230696576,
           "volume_delta": -827.5830828966427,
           "trade_rate": 301.76666666666665,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 2179719,
           "trades_count_buy": 1079687,
           "trades_count_sell": 1100032,
           "trade_count_dom": -20345,
           "trades_avg": 0.037564338605351515,
           "trade_avg_buy": 0.03697986741873333,
           "trade_avg_sell": 0.038138000046171155,
           "trade_volume": 81879.7025805182,
           "trade_volume_buy": 39926.682113729934,
           "trade_volume_sell": 41953.02046678975,
           "volume_delta": -2026.3383530598148,
           "trade_rate": 605.4775,
           "volume_estimated": false,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/spot": {
   "get": {
    "summary": "Trade candle, spot only",
    "description": "Same as `/v1/trades`, spot venues only. Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "operationId": "get_trades_spot_v1_trades_spot_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "bucket": {
             "type": "string",
             "format": "date-time",
             "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "symbol": {
             "type": "string",
             "description": "Trading pair, e.g. `BTCUSDT`."
            },
            "exchange": {
             "type": "string",
             "description": "Always `combined`: the value aggregates every venue."
            },
            "trades_count": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of trades in the bucket, all venues.",
             "x-unit": "count"
            },
            "trades_count_buy": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of buyer-initiated trades.",
             "x-unit": "count"
            },
            "trades_count_sell": {
             "type": [
              "integer",
              "null"
             ],
             "description": "Number of seller-initiated trades.",
             "x-unit": "count"
            },
            "trade_count_dom": {
             "type": [
              "integer",
              "null"
             ],
             "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
             "x-unit": "count"
            },
            "trades_avg": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of buy trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_avg_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average size of sell trades, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_buy": {
             "type": [
              "number",
              "null"
             ],
             "description": "Buyer-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_volume_sell": {
             "type": [
              "number",
              "null"
             ],
             "description": "Seller-initiated volume, base asset units.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "volume_delta": {
             "type": [
              "number",
              "null"
             ],
             "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "trade_rate": {
             "type": [
              "number",
              "null"
             ],
             "description": "Average number of trades per second over the bucket.",
             "x-unit": "trades per second"
            },
            "volume_estimated": {
             "type": "boolean",
             "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
            },
            "is_closed": {
             "type": "boolean",
             "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790245158,
         "data_type": "trades_candle_spot_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": {
          "time": "2026-09-30T16:00:00.000Z",
          "bucket": "2026-09-30T16:00:00.000Z",
          "symbol": "BTCUSDT",
          "exchange": "combined",
          "trades_count": 270223,
          "trades_count_buy": 148550,
          "trades_count_sell": 121673,
          "trade_count_dom": 26877,
          "trades_avg": 0.008438316786987017,
          "trade_avg_buy": 0.00787786105775832,
          "trade_avg_sell": 0.009122574581049201,
          "trade_volume": 2280.2272771299927,
          "trade_volume_buy": 1170.2562601299985,
          "trade_volume_sell": 1109.9710169999994,
          "volume_delta": 60.28524312999912,
          "trade_rate": 75.06194444444445,
          "volume_estimated": false,
          "is_closed": true
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/spot?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/spot\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/spot?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/trades/spot/history": {
   "get": {
    "summary": "Trade candles history, spot only",
    "description": "Same as `/v1/trades/spot`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_trades_spot_history_v1_trades_spot_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "symbol": {
              "type": "string",
              "description": "Trading pair, e.g. `BTCUSDT`."
             },
             "exchange": {
              "type": "string",
              "description": "Always `combined`: the value aggregates every venue."
             },
             "trades_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades in the bucket, all venues.",
              "x-unit": "count"
             },
             "trades_count_buy": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of buyer-initiated trades.",
              "x-unit": "count"
             },
             "trades_count_sell": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of seller-initiated trades.",
              "x-unit": "count"
             },
             "trade_count_dom": {
              "type": [
               "integer",
               "null"
              ],
              "description": "trades_count_buy - trades_count_sell. Positive = more buy trades.",
              "x-unit": "count"
             },
             "trades_avg": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average trade size, base asset units (NOT dollars: multiply by the price for a notional).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of buy trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_avg_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average size of sell trades, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Traded volume in the bucket, base asset units (BTC for BTCUSDT, NOT dollars).",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_buy": {
              "type": [
               "number",
               "null"
              ],
              "description": "Buyer-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_volume_sell": {
              "type": [
               "number",
               "null"
              ],
              "description": "Seller-initiated volume, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "volume_delta": {
              "type": [
               "number",
               "null"
              ],
              "description": "trade_volume_buy - trade_volume_sell, base asset units. Positive = net buying.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_rate": {
              "type": [
               "number",
               "null"
              ],
              "description": "Average number of trades per second over the bucket.",
              "x-unit": "trades per second"
             },
             "volume_estimated": {
              "type": "boolean",
              "description": "`true` when the aggregated volume of this candle was reconstructed (history before full multi-venue coverage); `false` = measured."
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790245928,
         "data_type": "trades_candle_spot_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 270223,
           "trades_count_buy": 148550,
           "trades_count_sell": 121673,
           "trade_count_dom": 26877,
           "trades_avg": 0.008438316786987017,
           "trade_avg_buy": 0.00787786105775832,
           "trade_avg_sell": 0.009122574581049201,
           "trade_volume": 2280.2272771299927,
           "trade_volume_buy": 1170.2562601299985,
           "trade_volume_sell": 1109.9710169999994,
           "volume_delta": 60.28524312999912,
           "trade_rate": 75.06194444444445,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 400806,
           "trades_count_buy": 225527,
           "trades_count_sell": 175279,
           "trade_count_dom": 50248,
           "trades_avg": 0.008359274533057393,
           "trade_avg_buy": 0.007721247069308773,
           "trade_avg_sell": 0.009180208129305853,
           "trade_volume": 3350.4473884966014,
           "trade_volume_buy": 1741.3496877999996,
           "trade_volume_sell": 1609.0977006966007,
           "volume_delta": 132.25198710339896,
           "trade_rate": 111.335,
           "volume_estimated": false,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "symbol": "BTCUSDT",
           "exchange": "combined",
           "trades_count": 690844,
           "trades_count_buy": 332366,
           "trades_count_sell": 358478,
           "trade_count_dom": -26112,
           "trades_avg": 0.009801499934167531,
           "trade_avg_buy": 0.009508371415036425,
           "trade_avg_sell": 0.010073276593793746,
           "trade_volume": 6771.307420520034,
           "trade_volume_buy": 3160.2593737299967,
           "trade_volume_sell": 3611.0480467899943,
           "volume_delta": -450.78867305999756,
           "trade_rate": 191.9011111111111,
           "volume_estimated": false,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/trades/spot/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/trades/spot/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/trades/spot/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/vwap": {
   "get": {
    "summary": "Intraday VWAP",
    "description": "Volume-weighted average price since 00:00 UTC, across venues.",
    "operationId": "get_vwap_v1_vwap_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "data": {
           "type": "object",
           "properties": {
            "time": {
             "type": "string",
             "format": "date-time",
             "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            },
            "vwap": {
             "type": [
              "number",
              "null"
             ],
             "description": "Volume-weighted average price.",
             "x-unit": "quote currency (USDT for BTCUSDT)"
            },
            "cumulative_volume": {
             "type": [
              "number",
              "null"
             ],
             "description": "Volume accumulated since 00:00 UTC used by the intraday VWAP.",
             "x-unit": "base asset quantity (BTC for BTCUSDT)"
            },
            "timestamp": {
             "type": "string",
             "format": "date-time",
             "description": "Measurement instant (start of the bucket for aggregated rows).",
             "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790249449,
         "data_type": "vwap",
         "symbol": "BTCUSDT",
         "data": {
          "time": "2026-09-30T17:43:35.012Z",
          "vwap": 84134.93151031101,
          "cumulative_volume": 481654.8924199963,
          "timestamp": "2026-09-30T17:43:35.012Z"
         }
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/vwap?symbol=BTCUSDT\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/vwap\",\n    params={\"symbol\": \"BTCUSDT\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/vwap?symbol=BTCUSDT\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/vwap/history": {
   "get": {
    "summary": "Intraday VWAP history",
    "description": "Per minute, or per bucket with `timeframe`. Most recent first. Page backwards with `until_ms`.",
    "operationId": "get_vwap_history_v1_vwap_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "timeframe",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "string"
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Optional. With it, rows are aggregated per bucket and carry `is_closed`; without it, one row per minute.",
      "example": "1h"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "timestamp": {
              "type": "string",
              "format": "date-time",
              "description": "Measurement instant (start of the bucket for aggregated rows).",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "vwap": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume-weighted average price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "cumulative_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume accumulated since 00:00 UTC used by the intraday VWAP.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "points": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of one-minute source points inside the bucket.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790250061,
         "data_type": "vwap_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "timestamp": "2026-09-30T16:00:00.000Z",
           "vwap": 84136.1012346141,
           "cumulative_volume": 467094.5892599979,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "timestamp": "2026-09-30T15:00:00.000Z",
           "vwap": 84129.33791306509,
           "cumulative_volume": 448732.89329999924,
           "points": 60,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "timestamp": "2026-09-30T14:00:00.000Z",
           "vwap": 84140.64956432498,
           "cumulative_volume": 417838.5442400001,
           "points": 60,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/vwap/history?symbol=BTCUSDT&limit=3&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/vwap/history\",\n    params={\"symbol\": \"BTCUSDT\", \"limit\": \"3\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/vwap/history?symbol=BTCUSDT&limit=3&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/vwap/window": {
   "get": {
    "summary": "VWAP per bucket",
    "operationId": "get_vwap_window_v1_vwap_window_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "live",
      "in": "query",
      "required": false,
      "schema": {
       "type": "boolean",
       "default": false
      },
      "description": "`1` or `true` to return the CURRENT, still-open period computed on the fly (`is_closed: false`). Default: the last closed period only."
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "vwap": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume-weighted average price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "total_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total traded volume over the period, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790250780,
         "data_type": "vwap_window_1h",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "vwap": 84302.13575805251,
           "total_volume": 18320.35761,
           "trade_count": 404455,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "description": "Volume-weighted average price of each closed bucket (not cumulative, unlike `/v1/vwap`). Bucketed: `is_closed` says whether the value is final. Add `?live=1` for the open period.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/vwap/window?symbol=BTCUSDT&timeframe=1h\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/vwap/window\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/vwap/window?symbol=BTCUSDT&timeframe=1h\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  },
  "/v1/vwap/window/history": {
   "get": {
    "summary": "VWAP per bucket history",
    "operationId": "get_vwap_window_history_v1_vwap_window_history_get",
    "security": [
     {
      "APIKeyHeader": []
     }
    ],
    "parameters": [
     {
      "name": "timeframe",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Bucket size: `1m`, `5m`, `15m`, `30m`, `1h`, `4h` or `1d`. Other values: 422 `invalid_timeframe` with the accepted list.",
      "example": "1h"
     },
     {
      "name": "since_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Lower time bound, INCLUSIVE, in epoch MILLISECONDS (13 digits). A value in seconds returns 422 `invalid_time_range`."
     },
     {
      "name": "until_ms",
      "in": "query",
      "required": false,
      "schema": {
       "anyOf": [
        {
         "type": "integer",
         "minimum": 0
        },
        {
         "type": "null"
        }
       ]
      },
      "description": "Upper time bound, INCLUSIVE, in epoch milliseconds. To page backwards, pass the oldest `time` you received minus 1 ms (see the pagination guide)."
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "maximum": 1000,
       "minimum": 1,
       "default": 100
      },
      "description": "Number of rows to return, most recent first. Also bounded by your plan's history window (403 `history_depth` beyond it).",
      "example": "3"
     },
     {
      "name": "symbol",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string"
      },
      "description": "Trading pair, e.g. `BTCUSDT`. Required. The 22 served pairs: `GET /v1/symbols`. An unknown pair returns 400 `invalid_symbol` with the accepted list.",
      "example": "BTCUSDT"
     }
    ],
    "responses": {
     "200": {
      "description": "Success. The example is a real response, trimmed to 3 rows.",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "status",
          "timestamp"
         ],
         "properties": {
          "status": {
           "type": "string",
           "enum": [
            "ok"
           ],
           "description": "`ok` on success."
          },
          "timestamp": {
           "type": "integer",
           "description": "Server time of the response, epoch milliseconds.",
           "x-unit": "epoch milliseconds"
          },
          "data_type": {
           "type": "string",
           "description": "Name of the payload type (stable)."
          },
          "symbol": {
           "type": "string",
           "description": "Effective `symbol` of the request."
          },
          "timeframe": {
           "type": "string",
           "description": "Effective `timeframe` of the request."
          },
          "data": {
           "type": "array",
           "items": {
            "type": "object",
            "properties": {
             "time": {
              "type": "string",
              "format": "date-time",
              "description": "The instant of the row: a copy of `bucket`, `timestamp`, `date`, `period_end`, `settlement_at`, `day` or `as_of`, present on every timestamped object so a generic client needs one key.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "bucket": {
              "type": "string",
              "format": "date-time",
              "description": "Start of the bucket (left edge). A 1h bucket at 14:00 covers 14:00:00 to 14:59:59.999.",
              "x-unit": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)"
             },
             "vwap": {
              "type": [
               "number",
               "null"
              ],
              "description": "Volume-weighted average price.",
              "x-unit": "quote currency (USDT for BTCUSDT)"
             },
             "total_volume": {
              "type": [
               "number",
               "null"
              ],
              "description": "Total traded volume over the period, base asset units.",
              "x-unit": "base asset quantity (BTC for BTCUSDT)"
             },
             "trade_count": {
              "type": [
               "integer",
               "null"
              ],
              "description": "Number of trades.",
              "x-unit": "count"
             },
             "is_closed": {
              "type": "boolean",
              "description": "`true` = the bucket is final and will never change; `false` = provisional (only with `?live=1`)."
             }
            }
           },
           "description": "The payload. Most recent first when it is a list."
          },
          "unavailable": {
           "type": "string",
           "enum": [
            "not_applicable",
            "no_api_key",
            "no_data"
           ],
           "description": "Present only when `data` is empty: why. `not_applicable` = the metric does not exist for this asset (e.g. futures on a stablecoin); `no_api_key` = the upstream source is not wired; `no_data` = nothing measured in the window."
          }
         }
        },
        "example": {
         "status": "ok",
         "timestamp": 1790790251421,
         "data_type": "vwap_window_1h_history",
         "symbol": "BTCUSDT",
         "timeframe": "1h",
         "data": [
          {
           "time": "2026-09-30T16:00:00.000Z",
           "bucket": "2026-09-30T16:00:00.000Z",
           "vwap": 84302.13575805251,
           "total_volume": 18320.35761,
           "trade_count": 404455,
           "is_closed": true
          },
          {
           "time": "2026-09-30T15:00:00.000Z",
           "bucket": "2026-09-30T15:00:00.000Z",
           "vwap": 83977.32824027885,
           "total_volume": 30860.212989999996,
           "trade_count": 685071,
           "is_closed": true
          },
          {
           "time": "2026-09-30T14:00:00.000Z",
           "bucket": "2026-09-30T14:00:00.000Z",
           "vwap": 83845.17999729452,
           "total_volume": 75113.8220900001,
           "trade_count": 1488572,
           "is_closed": true
          }
         ]
        }
       }
      },
      "headers": {
       "RateLimit-Policy": {
        "$ref": "#/components/headers/RateLimit-Policy"
       },
       "RateLimit": {
        "$ref": "#/components/headers/RateLimit"
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/BadRequest"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/TooManyRequests"
     },
     "503": {
      "$ref": "#/components/responses/ServiceUnavailable"
     }
    },
    "tags": [
     "Order flow"
    ],
    "description": "Same as `/v1/vwap/window`, one row per closed bucket. Most recent first. Page backwards with `until_ms`.",
    "x-codeSamples": [
     {
      "lang": "curl",
      "label": "curl",
      "source": "curl -H \"X-API-KEY: $BYTNODE_API_KEY\" \"https://api.bytnode.com/v1/vwap/window/history?symbol=BTCUSDT&timeframe=1h&limit=3\""
     },
     {
      "lang": "python",
      "label": "Python",
      "source": "import os, requests\n\nr = requests.get(\n    \"https://api.bytnode.com/v1/vwap/window/history\",\n    params={\"symbol\": \"BTCUSDT\", \"timeframe\": \"1h\", \"limit\": \"3\"},\n    headers={\"X-API-KEY\": os.environ[\"BYTNODE_API_KEY\"]},\n    timeout=30,\n)\nr.raise_for_status()\nprint(r.json()[\"data\"])"
     },
     {
      "lang": "javascript",
      "label": "JavaScript",
      "source": "const r = await fetch(\"https://api.bytnode.com/v1/vwap/window/history?symbol=BTCUSDT&timeframe=1h&limit=3\", {\n  headers: { \"X-API-KEY\": process.env.BYTNODE_API_KEY },\n});\nconst body = await r.json();\nif (body.status === \"error\") throw new Error(body.error.code);\nconsole.log(body.data);"
     }
    ]
   }
  }
 },
 "x-units": {
  "active_addresses": "count",
  "active_cryptocurrencies": "count",
  "age_seconds": "seconds",
  "annualized_rate_pct": "percent (58.5 = 58.5 %)",
  "apr_pct": "percent (58.5 = 58.5 %)",
  "as_of": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "ask_total": "base asset quantity (BTC for BTCUSDT)",
  "ask_total_avg": "base asset quantity (BTC for BTCUSDT)",
  "ask_total_max": "base asset quantity (BTC for BTCUSDT)",
  "ask_total_min": "base asset quantity (BTC for BTCUSDT)",
  "attraction_down": "dimensionless score",
  "attraction_up": "dimensionless score",
  "available_signals": "count",
  "avg_24h_s": "seconds",
  "avg_30d": "count",
  "avg_7d": "count",
  "avg_reward_sats": "satoshis",
  "avg_reward_usd": "USD",
  "avg_size": "base asset quantity (BTC for BTCUSDT)",
  "balance_date": "calendar date (YYYY-MM-DD)",
  "base_fee": "gwei",
  "basis_pct": "percent (58.5 = 58.5 %)",
  "basis_value": "quote currency (USDT for BTCUSDT)",
  "bid_total": "base asset quantity (BTC for BTCUSDT)",
  "bid_total_avg": "base asset quantity (BTC for BTCUSDT)",
  "bid_total_max": "base asset quantity (BTC for BTCUSDT)",
  "bid_total_min": "base asset quantity (BTC for BTCUSDT)",
  "big_count": "count",
  "big_usd": "USD",
  "block_count": "count",
  "block_time": "seconds",
  "btc_dominance_pct": "percent (58.5 = 58.5 %)",
  "btc_holdings": "BTC",
  "btc_price_usd": "USD",
  "bucket": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "burn_24h": "ETH",
  "burnt_fees": "ETH",
  "buy_ratio": "fraction (0.585 = 58.5 %)",
  "buy_volume": "base asset quantity (BTC for BTCUSDT)",
  "call_coin": "base asset quantity (BTC for BTCUSDT)",
  "call_oi_usd": "USD",
  "call_usd": "USD",
  "changes": "percent (58.5 = 58.5 %)",
  "circulating_supply": "coins",
  "close": "quote currency (USDT for BTCUSDT)",
  "concentration": "percent (58.5 = 58.5 %)",
  "contribution": "dimensionless score",
  "correlation": "from -1 to 1",
  "correlations": "dimensionless ratio",
  "cumulative_rate": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)",
  "cumulative_volume": "base asset quantity (BTC for BTCUSDT)",
  "cvd_series": "base asset quantity (BTC for BTCUSDT)",
  "date": "calendar date (YYYY-MM-DD)",
  "defi_health_ratio": "fraction (0.585 = 58.5 %)",
  "delta": "base asset quantity (BTC for BTCUSDT)",
  "delta_call_usd": "USD",
  "delta_pct": "percent (58.5 = 58.5 %)",
  "delta_put_usd": "USD",
  "delta_total_usd": "USD",
  "density_down": "dimensionless score",
  "density_up": "dimensionless score",
  "depth_start": "calendar date (YYYY-MM-DD)",
  "deviation_s": "seconds",
  "dex_volume_24h_usd": "USD",
  "dex_volume_7d_usd": "USD",
  "difficulty": "difficulty units",
  "difficulty_change_pct": "percent (58.5 = 58.5 %)",
  "dist_down": "fraction (0.585 = 58.5 %)",
  "dist_up": "fraction (0.585 = 58.5 %)",
  "dte_days": "days",
  "dxy": "index points",
  "dxy_7d_ago": "index points",
  "economy": "satoshis per virtual byte (sat/vB)",
  "economy_fee": "satoshis per virtual byte (sat/vB)",
  "estimated_rate": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)",
  "estimated_retarget": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "eth2_staking": "ETH",
  "eth_btc_ratio": "BTC per ETH",
  "eth_dominance_pct": "percent (58.5 = 58.5 %)",
  "eth_holdings": "ETH",
  "eth_market_cap_usd": "USD",
  "eth_price_usd": "USD",
  "eth_supply": "ETH",
  "exchange_count": "count",
  "expected_interval_seconds": "seconds",
  "expiry": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "fast": "candles",
  "fast_gas_price": "gwei",
  "fastest": "satoshis per virtual byte (sat/vB)",
  "fastest_fee": "satoshis per virtual byte (sat/vB)",
  "fdv": "USD",
  "fed_funds_rate_pct": "percent (58.5 = 58.5 %)",
  "fee_histogram": "satoshis per virtual byte (sat/vB)",
  "fee_pressure": "dimensionless ratio",
  "feeds_checked": "count",
  "feeds_in_error": "count",
  "feeds_stale": "count",
  "filed": "calendar date (YYYY-MM-DD)",
  "futures_price": "quote currency (USDT for BTCUSDT)",
  "gamma": "delta per USD",
  "gas_ma30": "gwei",
  "gas_ma7": "gwei",
  "gas_used_ratio": "fraction (0.585 = 58.5 %)",
  "gold": "USD per troy ounce",
  "gold_7d_ago": "USD per troy ounce",
  "half_hour": "satoshis per virtual byte (sat/vB)",
  "half_hour_fee": "satoshis per virtual byte (sat/vB)",
  "high": "quote currency (USDT for BTCUSDT)",
  "hour": "satoshis per virtual byte (sat/vB)",
  "hour_fee": "satoshis per virtual byte (sat/vB)",
  "imbalance": "fraction from -1 to 1",
  "imbalance_avg": "fraction from -1 to 1",
  "imbalance_max": "fraction from -1 to 1",
  "imbalance_min": "fraction from -1 to 1",
  "imbalance_std": "fraction",
  "iv_atm_pct": "percent (58.5 = 58.5 %)",
  "last_candle": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "long_usd": "USD",
  "low": "quote currency (USDT for BTCUSDT)",
  "market_cap": "USD",
  "max_age_seconds": "seconds",
  "max_pain_strike": "USD",
  "max_spread_bps": "basis points (1 bp = 0.01 %)",
  "max_spread_pct": "percent (58.5 = 58.5 %)",
  "max_supply": "coins",
  "miner_stress": "dimensionless score",
  "minimum": "satoshis per virtual byte (sat/vB)",
  "minimum_fee": "satoshis per virtual byte (sat/vB)",
  "momentum_30d_pct": "percent (58.5 = 58.5 %)",
  "momentum_7d_pct": "percent (58.5 = 58.5 %)",
  "momentum_pct": "percent (58.5 = 58.5 %)",
  "mvrv": "dimensionless ratio",
  "n": "count",
  "nav_per_share": "USD",
  "net_assets_usd": "USD",
  "net_delta": "base asset quantity (BTC for BTCUSDT)",
  "net_issuance_24h": "ETH",
  "net_liquidity_musd": "millions of USD",
  "net_liquidity_usd": "USD",
  "next_retarget_height": "block height",
  "nvt": "dimensionless ratio",
  "nvt_signal": "dimensionless ratio",
  "oi_call_usd": "USD",
  "oi_coverage_ratio": "fraction (0.585 = 58.5 %)",
  "oi_current": "base asset quantity (BTC for BTCUSDT)",
  "oi_previous": "base asset quantity (BTC for BTCUSDT)",
  "oi_put_usd": "USD",
  "oi_total": "base asset quantity (BTC for BTCUSDT)",
  "oi_total_usd": "USD",
  "open": "quote currency (USDT for BTCUSDT)",
  "open_interest": "USD",
  "others_dominance_pct": "percent (58.5 = 58.5 %)",
  "part_long": "fraction (0.585 = 58.5 %)",
  "pc_ratio": "puts / calls",
  "period": "candles",
  "period_end": "calendar date (YYYY-MM-DD)",
  "points": "count",
  "points_count": "count",
  "pool_count": "count",
  "precise": "satoshis per virtual byte (sat/vB)",
  "premium_bps": "basis points (1 bp = 0.01 %)",
  "price": "quote currency (USDT for BTCUSDT)",
  "progress_pct": "percent (58.5 = 58.5 %)",
  "propose_gas_price": "gwei",
  "put_coin": "base asset quantity (BTC for BTCUSDT)",
  "put_oi_usd": "USD",
  "put_usd": "USD",
  "quantity": "base asset quantity (BTC for BTCUSDT)",
  "rank": "rank (1 = first)",
  "rate": "rate per 8 h, fraction (0.0001 = 0.01 % per 8 h)",
  "ratio": "dimensionless ratio",
  "recommended": "satoshis per virtual byte (sat/vB)",
  "ref_price": "quote currency (USDT for BTCUSDT)",
  "remaining_blocks": "count",
  "remaining_time_ms": "milliseconds",
  "results": "count",
  "risk_on_signals": "count",
  "roc_pct": "percent (58.5 = 58.5 %)",
  "rrp_busd": "billions of USD",
  "safe_gas_price": "gwei",
  "samples_count": "count",
  "score": "dimensionless score",
  "sell_volume": "base asset quantity (BTC for BTCUSDT)",
  "settlement_at": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "share_pct": "percent (58.5 = 58.5 %)",
  "shares_outstanding": "shares",
  "short_usd": "USD",
  "slow": "candles",
  "small_count": "count",
  "small_usd": "USD",
  "sources_active": "count",
  "sp500": "index points",
  "sp500_sma50": "index points",
  "spot_price": "quote currency (USDT for BTCUSDT)",
  "squeeze_index": "score from 0 to 100",
  "staking_ratio": "fraction (0.585 = 58.5 %)",
  "stale_venues": "count",
  "std": "standard deviations",
  "stress_ma30": "dimensionless score",
  "strike": "USD",
  "taker_buy": "base asset quantity (BTC for BTCUSDT)",
  "taker_buy_vol": "base asset quantity (BTC for BTCUSDT)",
  "taker_buy_volume": "base asset quantity (BTC for BTCUSDT)",
  "taker_sell": "base asset quantity (BTC for BTCUSDT)",
  "taker_sell_vol": "base asset quantity (BTC for BTCUSDT)",
  "taker_sell_volume": "base asset quantity (BTC for BTCUSDT)",
  "tga_musd": "millions of USD",
  "theta": "USD per day",
  "threshold_seconds": "seconds",
  "time": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "timestamp": "ISO 8601 UTC, milliseconds (2026-09-28T14:00:00.000Z)",
  "tip_height": "block height",
  "top1_share_pct": "percent (58.5 = 58.5 %)",
  "top3_share_pct": "percent (58.5 = 58.5 %)",
  "top_call_strike": "USD",
  "top_put_strike": "USD",
  "total_block_count": "count",
  "total_fee": "satoshis",
  "total_market_cap_usd": "USD",
  "total_signals": "count",
  "total_staked": "ETH",
  "total_supply": "coins",
  "total_usd": "USD",
  "total_volume": "base asset quantity (BTC for BTCUSDT)",
  "total_volume_usd": "USD",
  "trade_avg_buy": "base asset quantity (BTC for BTCUSDT)",
  "trade_avg_sell": "base asset quantity (BTC for BTCUSDT)",
  "trade_count": "count",
  "trade_count_dom": "count",
  "trade_rate": "trades per second",
  "trade_volume": "base asset quantity (BTC for BTCUSDT)",
  "trade_volume_buy": "base asset quantity (BTC for BTCUSDT)",
  "trade_volume_sell": "base asset quantity (BTC for BTCUSDT)",
  "trades_avg": "base asset quantity (BTC for BTCUSDT)",
  "trades_count": "count",
  "trades_count_buy": "count",
  "trades_count_sell": "count",
  "trend": "virtual bytes",
  "trend_30d_pct": "percent (58.5 = 58.5 %)",
  "tvl_usd": "USD",
  "tx_count": "count",
  "underlying_price": "USD",
  "usd_value": "USD",
  "value": "dimensionless score",
  "values": "quote currency (USDT for BTCUSDT)",
  "vega": "USD per volatility point",
  "venue_count": "count",
  "vix": "index points",
  "vol_call_usd": "USD",
  "vol_put_usd": "USD",
  "volume": "base asset quantity (BTC for BTCUSDT)",
  "volume_delta": "base asset quantity (BTC for BTCUSDT)",
  "vsize": "virtual bytes",
  "vsize_delta_1h": "virtual bytes",
  "vsize_delta_24h": "virtual bytes",
  "vsize_delta_4h": "virtual bytes",
  "vwap": "quote currency (USDT for BTCUSDT)",
  "walcl_musd": "millions of USD",
  "window_count": "count",
  "withdrawn_total": "ETH",
  "yield_curve_10y2y": "percentage points",
  "yield_spread_pct": "percentage points"
 },
 "x-examples-captured-at": "2026-09-30T17:43:51Z"
}
