{
  "openapi": "3.0.1",
  "info": {
    "title": "CoinGecko, DexScreener & Binance Scraper – Crypto Prices, OHLCV",
    "description": "CoinGecko, DexScreener, GeckoTerminal and Binance in one Actor: crypto prices, market caps, DEX pairs, trending and new pools, Binance tickers and OHLCV candles in one flat, unified format. Public APIs, no API keys, pay per result.",
    "version": "1.0",
    "x-build-id": "Sz26A0yu0oOgDYJi5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/openharvest~crypto-market-data/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-openharvest-crypto-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/openharvest~crypto-market-data/runs": {
      "post": {
        "operationId": "runs-sync-openharvest-crypto-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/openharvest~crypto-market-data/run-sync": {
      "post": {
        "operationId": "run-sync-openharvest-crypto-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": [
              "topCoins",
              "trendingCoins",
              "coinDetails",
              "searchPairs",
              "tokenPairs",
              "trendingPools",
              "newPools",
              "exchangeTickers",
              "ohlcv"
            ],
            "type": "string",
            "description": "What to fetch. <b>topCoins</b>: coins ranked by market cap (CoinGecko). <b>trendingCoins</b>: CoinGecko trending searches. <b>coinDetails</b>: full profile + market data for specific coins. <b>searchPairs</b>: DEX pairs matching a keyword (DexScreener, GeckoTerminal fallback). <b>tokenPairs</b>: all DEX pairs of token contract addresses. <b>trendingPools</b> / <b>newPools</b>: trending or newly created DEX pools (GeckoTerminal), optionally per chain. <b>exchangeTickers</b>: Binance 24h tickers. <b>ohlcv</b>: candle series (Binance, CoinGecko or any DEX pool).",
            "default": "topCoins"
          },
          "maxItems": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum number of records to save (per token address in tokenPairs mode). You pay per record, so this also caps your cost. Not used in ohlcv mode (one series per target).",
            "default": 20
          },
          "vsCurrency": {
            "title": "Quote currency (CoinGecko)",
            "type": "string",
            "description": "Currency for CoinGecko prices and market caps: <code>usd</code>, <code>eur</code>, <code>gbp</code>, <code>jpy</code>, <code>try</code>, <code>btc</code>, <code>eth</code>... Used by topCoins, coinDetails and CoinGecko OHLCV. DEX data is always in USD.",
            "default": "usd"
          },
          "category": {
            "title": "Category (topCoins)",
            "type": "string",
            "description": "Optional CoinGecko category id to rank coins within, e.g. <code>layer-1</code>, <code>meme-token</code>, <code>decentralized-finance-defi</code>, <code>artificial-intelligence</code>, <code>solana-ecosystem</code>. The id is the last part of a coingecko.com/en/categories/... URL."
          },
          "coinIds": {
            "title": "Coins (coinDetails)",
            "type": "array",
            "description": "CoinGecko coin ids (<code>bitcoin</code>), symbols (<code>BTC</code>), names or coingecko.com coin URLs. Symbols are resolved with CoinGecko search (the best-ranked match wins).",
            "items": {
              "type": "string"
            }
          },
          "searchQuery": {
            "title": "Search query (searchPairs)",
            "type": "string",
            "description": "Token name, symbol, pair (<code>SOL/USDC</code>) or address to search DEX pairs for."
          },
          "tokenAddresses": {
            "title": "Token contract addresses (tokenPairs)",
            "type": "array",
            "description": "Token contract / mint addresses. Returns every DEX pair (pool) that trades the token, sorted by liquidity. Set <b>Chain</b> to speed up lookups and avoid ambiguity.",
            "items": {
              "type": "string"
            }
          },
          "chain": {
            "title": "Chain / network",
            "type": "string",
            "description": "Optional chain filter for DEX modes: <code>ethereum</code>, <code>solana</code>, <code>bsc</code>, <code>base</code>, <code>arbitrum</code>, <code>polygon</code>, <code>avalanche</code>, <code>optimism</code>, <code>ton</code>, <code>sui</code>... Short forms (<code>eth</code>, <code>sol</code>, <code>bnb</code>) work too. Empty = all chains."
          },
          "trendingDuration": {
            "title": "Trending window (trendingPools)",
            "enum": [
              "5m",
              "1h",
              "6h",
              "24h"
            ],
            "type": "string",
            "description": "Time window GeckoTerminal uses to rank trending pools.",
            "default": "24h"
          },
          "minLiquidityUsd": {
            "title": "Min liquidity (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "DEX modes only: skip pairs/pools with less liquidity than this. Useful to filter out spam tokens in newPools.",
            "default": 0
          },
          "minVolume24hUsd": {
            "title": "Min 24h volume (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "DEX modes only: skip pairs/pools with lower 24h trading volume.",
            "default": 0
          },
          "symbols": {
            "title": "Binance symbols (exchangeTickers)",
            "type": "array",
            "description": "Binance spot symbols such as <code>BTCUSDT</code>, <code>ETH/USDT</code>, <code>SOL-USDC</code>. Leave empty to get the most traded pairs in the quote asset below.",
            "items": {
              "type": "string"
            }
          },
          "quoteAsset": {
            "title": "Quote asset (exchangeTickers without symbols)",
            "type": "string",
            "description": "When no symbols are given, list the top pairs quoted in this asset by 24h quote volume, e.g. <code>USDT</code>, <code>USDC</code>, <code>FDUSD</code>, <code>BTC</code>, <code>EUR</code>, <code>TRY</code>.",
            "default": "USDT"
          },
          "ohlcvTargets": {
            "title": "OHLCV targets (ohlcv)",
            "type": "array",
            "description": "One candle series per target. Formats: <code>binance:BTCUSDT</code> (exact intervals + volume), <code>coingecko:bitcoin</code> (aggregated price, interval chosen by CoinGecko), <code>&lt;chain&gt;:&lt;poolAddress&gt;</code> such as <code>eth:0xa43fe16908251ee70ef74718545e4fe6c5ccec9f</code>, or a GeckoTerminal / DexScreener pool URL.",
            "items": {
              "type": "string"
            }
          },
          "ohlcvInterval": {
            "title": "Candle interval (ohlcv)",
            "enum": [
              "1m",
              "5m",
              "15m",
              "1h",
              "4h",
              "12h",
              "1d"
            ],
            "type": "string",
            "description": "Candle size. Binance and DEX pools support all intervals; CoinGecko picks 30m / 4h / 4d automatically from the time window.",
            "default": "1h"
          },
          "ohlcvLimit": {
            "title": "Candles per series (ohlcv)",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Number of most recent candles per series (max 1000).",
            "default": 100
          },
          "dexSource": {
            "title": "DEX data source",
            "enum": [
              "auto",
              "dexscreener",
              "geckoterminal"
            ],
            "type": "string",
            "description": "<b>auto</b> (recommended): DexScreener first, GeckoTerminal when DexScreener fails or has no result. Or force one source. Trending/new pools always use GeckoTerminal.",
            "default": "auto"
          },
          "coingeckoApiKey": {
            "title": "CoinGecko Demo API key (optional)",
            "type": "string",
            "description": "Optional free CoinGecko Demo API key for higher, more stable rate limits on large coinDetails runs. Not needed for normal use."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}