{
  "openapi": "3.0.1",
  "info": {
    "title": "CoinMarketCap Scraper - Crypto Prices, Market Cap & Exchanges",
    "description": "Scrape CoinMarketCap data: live prices, market cap & rank, 24h volume, 1h–1y change, supply, ATH/ATL, full coin profiles, historical OHLCV, exchanges, market pairs, trending/gainers/losers and the Fear & Greed index. Keyless, no browser. Monitoring mode. JSON, CSV, Excel.",
    "version": "0.1",
    "x-build-id": "VQHhyzufpGAaiQHKo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapesage~coinmarketcap-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapesage-coinmarketcap-scraper",
        "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/scrapesage~coinmarketcap-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapesage-coinmarketcap-scraper",
        "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/scrapesage~coinmarketcap-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapesage-coinmarketcap-scraper",
        "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": "What to scrape",
            "enum": [
              "listing",
              "coin",
              "historical",
              "exchanges",
              "marketPairs",
              "spotlight",
              "fearGreed"
            ],
            "type": "string",
            "description": "<b>Coins & prices</b> = live market data for the top coins or any coins you choose (the default). <b>Coin profiles</b> = deep profile for specific coins (description, supply, ATH/ATL, links, contracts, audits). <b>Historical OHLCV</b> = candles + volume history for specific coins. <b>Exchanges</b> = trading venues with volume, score & fees. <b>Market pairs</b> = a coin's trading pairs across exchanges. <b>Spotlight</b> = trending / gainers / losers / most-visited / recently-added / most-searched. <b>Fear & Greed</b> = the sentiment index + global market overview.",
            "default": "listing"
          },
          "searchQueries": {
            "title": "Coin queries (name, symbol or slug)",
            "type": "array",
            "description": "Coins to target by name, symbol or slug, e.g. <code>bitcoin</code>, <code>BTC</code>, <code>Ethereum</code>, <code>pepe</code>, <code>SOL</code>. Used by <b>Coin profiles</b>, <b>Historical</b> and <b>Market pairs</b> modes (and as a filter in <b>Coins</b> mode). Resolved against CoinMarketCap's full coin map; for ambiguous symbols the highest-ranked coin wins.",
            "items": {
              "type": "string"
            }
          },
          "coinIds": {
            "title": "Coin IDs or slugs (exact)",
            "type": "array",
            "description": "Exact CoinMarketCap numeric ids (e.g. <code>1</code> = Bitcoin, <code>1027</code> = Ethereum) or url slugs (e.g. <code>matic-network</code>). Faster and more precise than queries.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "Direct CoinMarketCap URLs: coins (<code>coinmarketcap.com/currencies/bitcoin/</code>), markets (<code>/currencies/bitcoin/markets/</code>) or exchanges (<code>/exchanges/binance/</code>). Routed automatically by type.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "vsCurrency": {
            "title": "Quote currency",
            "type": "string",
            "description": "Currency to price everything in, e.g. <code>usd</code>, <code>eur</code>, <code>gbp</code>, <code>jpy</code>, <code>inr</code>, <code>brl</code>, <code>btc</code>, <code>eth</code>. Defaults to USD.",
            "default": "usd"
          },
          "sortBy": {
            "title": "Sort by (Coins mode)",
            "enum": [
              "market_cap",
              "volume_24h",
              "price",
              "percent_change_1h",
              "percent_change_24h",
              "percent_change_7d",
              "date_added",
              "circulating_supply"
            ],
            "type": "string",
            "description": "How to order the top-coins list. Use <b>Date added</b> for newest listings or a <b>% change</b> sort for gainers/losers.",
            "default": "market_cap"
          },
          "sortType": {
            "title": "Sort direction (Coins mode)",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Whether the Coins list is ordered high-to-low or low-to-high by the chosen sort field.",
            "default": "desc"
          },
          "cryptoType": {
            "title": "Coin type (Coins mode)",
            "enum": [
              "all",
              "coins",
              "tokens"
            ],
            "type": "string",
            "description": "Limit to coins (own chain) or tokens (issued on another chain), or include all.",
            "default": "all"
          },
          "tag": {
            "title": "Category / tag filter (Coins mode)",
            "type": "string",
            "description": "Limit Coins mode to one CoinMarketCap tag slug, e.g. <code>defi</code>, <code>memes</code>, <code>artificial-intelligence</code>, <code>real-world-assets</code>, <code>gaming</code>, <code>solana-ecosystem</code>. Leave blank for all."
          },
          "priceMin": {
            "title": "Min price",
            "type": "integer",
            "description": "Coins mode filter: minimum price in the quote currency."
          },
          "priceMax": {
            "title": "Max price",
            "type": "integer",
            "description": "Coins mode filter: maximum price."
          },
          "marketCapMin": {
            "title": "Min market cap",
            "type": "integer",
            "description": "Coins mode filter: minimum market cap."
          },
          "marketCapMax": {
            "title": "Max market cap",
            "type": "integer",
            "description": "Coins mode filter: maximum market cap."
          },
          "volume24hMin": {
            "title": "Min 24h volume",
            "type": "integer",
            "description": "Coins mode filter: minimum 24h volume."
          },
          "volume24hMax": {
            "title": "Max 24h volume",
            "type": "integer",
            "description": "Coins mode filter: maximum 24h volume."
          },
          "percentChange24hMin": {
            "title": "Min 24h % change",
            "type": "integer",
            "description": "Coins mode filter: minimum 24h price change %."
          },
          "percentChange24hMax": {
            "title": "Max 24h % change",
            "type": "integer",
            "description": "Coins mode filter: maximum 24h price change %."
          },
          "exchangeCategory": {
            "title": "Exchange type (Exchanges mode)",
            "enum": [
              "spot",
              "derivatives",
              "dex"
            ],
            "type": "string",
            "description": "Which kind of trading venue to list.",
            "default": "spot"
          },
          "pairCategory": {
            "title": "Pair type (Market pairs mode)",
            "enum": [
              "all",
              "spot",
              "perpetual",
              "futures"
            ],
            "type": "string",
            "description": "Which market-pair category to return for each coin.",
            "default": "all"
          },
          "historyDays": {
            "title": "History window",
            "enum": [
              "1",
              "7",
              "14",
              "30",
              "90",
              "180",
              "365",
              "max"
            ],
            "type": "string",
            "description": "How far back to fetch OHLCV candles (ignored if you set explicit From/To dates below). CoinMarketCap returns up to ~400 candles fitted to the window, so a shorter window gives finer resolution; each record reports the actual <code>approxIntervalHours</code>. Used by Historical and Fear & Greed modes.",
            "default": "90"
          },
          "dateFrom": {
            "title": "From date (optional)",
            "type": "string",
            "description": "Explicit start date, e.g. <code>2024-01-01</code>. Overrides History window."
          },
          "dateTo": {
            "title": "To date (optional)",
            "type": "string",
            "description": "Explicit end date, e.g. <code>2024-12-31</code>. Defaults to now."
          },
          "spotlightLists": {
            "title": "Spotlight lists",
            "type": "array",
            "description": "Which Spotlight lists to include.",
            "items": {
              "type": "string",
              "enum": [
                "trending",
                "gainers",
                "losers",
                "mostVisited",
                "recentlyAdded",
                "upcoming",
                "mostSearched"
              ],
              "enumTitles": [
                "Trending",
                "Top gainers",
                "Top losers",
                "Most visited",
                "Recently added",
                "Upcoming",
                "Most searched"
              ]
            },
            "default": [
              "trending",
              "gainers",
              "losers",
              "mostVisited",
              "recentlyAdded"
            ]
          },
          "enrichCoinDetails": {
            "title": "Fetch full coin profiles (Coins mode)",
            "type": "boolean",
            "description": "In Coins mode, fetch each coin's full profile: description, ATH/ATL, contract addresses across chains, project links (website, whitepaper, GitHub, Twitter/X, Telegram, Reddit), audits and watchlist count. Adds one API call per coin.",
            "default": false
          },
          "enrichExchangeDetails": {
            "title": "Fetch full exchange profiles (Exchanges mode)",
            "type": "boolean",
            "description": "In Exchanges mode, fetch each exchange's full profile: description, website, socials, tags and proof-of-reserves net worth. Adds one API call per exchange.",
            "default": false
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of records to scrape in this run.",
            "default": 100
          },
          "deduplicateResults": {
            "title": "Deduplicate within a run",
            "type": "boolean",
            "description": "Skip records already emitted in this run (recommended).",
            "default": true
          },
          "monitorMode": {
            "title": "Monitoring mode — only new or changed records",
            "type": "boolean",
            "description": "Remember each record's price/rank/volume across runs in a named key-value store and emit ONLY records that are new or have changed since the last run — tagged with <code>monitorEvent</code> (new, price_up, price_down, rank_change, updated). Perfect for price alerts and new-listing watches. Works with Apify Schedules.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor key",
            "type": "string",
            "description": "Names the memory used by monitoring mode. Use a distinct key per saved watch so different monitors don't share state.",
            "default": "default"
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 12,
            "type": "integer",
            "description": "Maximum parallel requests. The actor rotates a fresh proxy IP per request; 4–8 is a good range.",
            "default": 4
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxy settings. CoinMarketCap's web API is datacenter-friendly; the default Apify Proxy rotates IPs to spread rate limits.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}