{
  "openapi": "3.0.1",
  "info": {
    "title": "Binance Market Data - 24h Tickers & Klines",
    "description": "Binance spot 24-hour tickers and OHLCV candles (klines) as flat, typed rows: prices and volumes as numbers, ISO-8601 UTC times, base and quote asset on every row. All USDT pairs, any symbol list, any interval from 1s to 1M.",
    "version": "0.1",
    "x-build-id": "XccEBDcHrYm7Zeeak"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/superslowsloth~binance-market-data/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-superslowsloth-binance-market-data",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/superslowsloth~binance-market-data/runs": {
      "post": {
        "operationId": "runs-sync-superslowsloth-binance-market-data",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/superslowsloth~binance-market-data/run-sync": {
      "post": {
        "operationId": "run-sync-superslowsloth-binance-market-data",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "tickers",
              "klines"
            ],
            "type": "string",
            "description": "tickers: one row per symbol with Binance's rolling 24-hour statistics (last price, change, high, low, volume, best bid and ask). klines: OHLCV candles for each symbol at the chosen interval.",
            "default": "tickers"
          },
          "symbols": {
            "title": "Symbols",
            "type": "array",
            "description": "Binance spot symbols such as BTCUSDT or ETHBTC. BTC/USDT, btc-usdt and btc_usdt are accepted and normalised. Every symbol is checked against Binance's own symbol list before any data is requested, so a typo is reported by name instead of failing the batch it sits in. Required in klines mode. In tickers mode, leave empty to get every trading symbol on the exchange (narrow it with Quote asset).",
            "items": {
              "type": "string"
            }
          },
          "quoteAsset": {
            "title": "Quote asset (tickers mode)",
            "type": "string",
            "description": "Optional, tickers mode only. Keep only pairs quoted in this asset, e.g. USDT for all USDT pairs, or BTC, FDUSD, USDC, EUR, TRY, JPY. Matched exactly against the quote asset Binance publishes for each symbol, not against the end of the symbol name, so USD does not pick up FDUSD pairs. Ignored in klines mode."
          },
          "includeNonTrading": {
            "title": "Include halted and delisted symbols",
            "type": "boolean",
            "description": "Off by default. Binance still lists about 2,300 spot symbols whose status is BREAK (halted or delisted); their 24-hour statistics describe a window that closed weeks or years ago. Leave this off to get only symbols that are trading now. Turn it on to include them, each row marked with status BREAK.",
            "default": false
          },
          "interval": {
            "title": "Interval (klines mode)",
            "enum": [
              "1s",
              "1m",
              "3m",
              "5m",
              "15m",
              "30m",
              "1h",
              "2h",
              "4h",
              "6h",
              "8h",
              "12h",
              "1d",
              "3d",
              "1w",
              "1M"
            ],
            "type": "string",
            "description": "Candle size, klines mode only. Case matters: 1m is one minute, 1M is one month.",
            "default": "1d"
          },
          "limit": {
            "title": "Candles per symbol (klines mode)",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "How many candles to return for each symbol, klines mode only. Binance serves at most 1000 per request; larger numbers are paged automatically, up to 10,000 per symbol. With a start time the candles are the first ones from that moment; without one they are the most recent ones up to the end time (or now).",
            "default": 100
          },
          "startTime": {
            "title": "Start time (klines mode)",
            "type": "string",
            "description": "Optional, klines mode only. First candle to return: a date (YYYY-MM-DD, read as midnight UTC), an ISO-8601 datetime, or epoch milliseconds. Leave empty to get the most recent candles."
          },
          "endTime": {
            "title": "End time (klines mode)",
            "type": "string",
            "description": "Optional, klines mode only. Last candle to return, inclusive of a candle that opens at exactly this time. Same formats as the start time. Leave empty for now."
          },
          "maxItems": {
            "title": "Max rows",
            "minimum": 1,
            "type": "integer",
            "description": "Upper bound on rows across the whole run, tickers and candles alike. Each row is one billable event, so this is also a spending cap. The run never requests more symbols or candles than this allows.",
            "default": 1000
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify datacenter proxy by default, which Binance's public market-data mirror serves. Binance counts request weight per exit address per minute; the run tracks it and pauses before the limit, and a refused request (HTTP 429 or 418) is retried from a fresh address.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}